# Api requests

Requests made with the organization's API keys

Endpoint: `https://api.bookingmood.com/v1/api_requests`, supporting `GET`. Authenticate with the header `Authorization: Bearer YOUR_API_KEY` (see [authentication](https://www.bookingmood.com/el-GR/api-reference/authentication.md)).

## The api request object

| Attribute | Type | Description |
| --- | --- | --- |
| `id` | `int32` | Unique identifier. |
| `api_key_id` | `uuid \| null` | Identifier of the API key used for the request. Either this or grant_id is set. References `api_keys.id`. |
| `grant_id` | `uuid \| null` | Identifier of the OAuth grant whose token made the request. Either this or api_key_id is set. |
| `request_id` | `uuid \| null` | Identifier of the request, also on activity_log. |
| `created_at` | `timestamp with time zone` | Creation timestamp. Read-only: set by the database. |
| `created_on` | `date` | Creation date. |
| `endpoint` | `text` | Endpoint of the request. |
| `method` | `text` | HTTP method of the request. |
| `search` | `text` | Search params of the request. |
| `status` | `int32` | HTTP status code of the response. |

```json
{
  "id": 0,
  "api_key_id": "00000000-0000-0000-0000-000000000000",
  "grant_id": "00000000-0000-0000-0000-000000000000",
  "request_id": "00000000-0000-0000-0000-000000000000",
  "created_at": "2026-11-30T11:21:40.435Z",
  "created_on": "2026-11-30",
  "endpoint": "",
  "method": "",
  "search": "",
  "status": 0
}
```

## List api requests

`GET /v1/api_requests` · requires the `organization:read` scope

Filter on any attribute with `column=operator.value` (see [filtering](https://www.bookingmood.com/el-GR/api-reference/filtering.md)). Choose columns and embed related resources with `select` (see [selecting](https://www.bookingmood.com/el-GR/api-reference/selecting.md)), and sort and paginate with `order`, `limit` and `offset` (see [sorting and pagination](https://www.bookingmood.com/el-GR/api-reference/sorting-pagination.md)).

```bash
curl "https://api.bookingmood.com/v1/api_requests?select=*&limit=10" \
  -H "Authorization: Bearer YOUR_API_KEY"
```

Responses:

- `200`: A list of api requests with the selected columns. `206` when the list is a partial range.
- `400`: The request is malformed, for example an unknown column or an invalid filter.
- `401`: The API key is missing or invalid.
- `403`: The API key or access token doesn't have the scope this request needs.
- `429`: The API key made more requests per minute than its rate limit allows. Retry after the number of seconds in the `Retry-After` header.

Errors have a JSON body with a `code`, `message`, `details` and `hint`. See the [introduction](https://www.bookingmood.com/el-GR/api-reference.md) for more on errors. The full API is described by the OpenAPI spec at https://api.bookingmood.com/v1/openapi.json.
