# Logs

Log of the calls made with your keys.

## Log of the account's API calls (method, route, status, duration, error code, requestId)

`GET /logs/requests`

Authentication: portal session

Parameters:

| Name | Location | Type | Description |
|---|---|---|---|
| `environmentId` | query | string | Filter by environment. |
| `status` | query | string | `success` (status < 400) or `error` (status ≥ 400). |
| `method` | query | string | Filter by HTTP method (GET, POST…). |
| `route` | query | string | Filter by path (e.g. /messages) |
| `limit` | query | number | Number of items per page, from 1 to 200 (default 50). |
| `cursor` | query | string | `nextCursor` value from the previous page, to get the next one. |

```bash
curl "$INBOX_API/logs/requests" \
  -H "Authorization: Bearer $INBOX_SESSION"
```

Response 200:

```json
{
  "data": [
    {
      "id": "67528eac-848d-4155-8763-7e775550d557",
      "requestId": "req_7484f6f8-cc27-4b8e-8bfa-987494dd32e0",
      "method": "GET",
      "route": "/api/v1/usage",
      "status": 200,
      "durationMs": 15,
      "errorCode": null,
      "environmentId": "7d3d2aa8-d312-48d7-894c-25b906dfa11a",
      "apiKeyId": "5ef37bc9-8aac-43ef-81b1-6bb3bdb66e78",
      "at": "2026-11-12T08:33:46.423Z"
    },
    {
      "id": "e04e4028-3c28-496c-8d3e-d99572a15170",
      "requestId": "req_a2f45ea7-9fa9-4132-8cab-6492beab475e",
      "method": "POST",
      "route": "/api/v1/webhook-deliveries/:id/replay",
      "status": 202,
      "durationMs": 19,
      "errorCode": null,
      "environmentId": "7d3d2aa8-d312-48d7-894c-25b906dfa11a",
      "apiKeyId": "5ef37bc9-8aac-43ef-81b1-6bb3bdb66e78",
      "at": "2026-11-12T08:33:46.395Z"
    },
    {
      "id": "fd8ab473-5174-48e6-8924-058fb102c7e3",
      "requestId": "req_3019ad2e-845a-43b9-8963-8d851c0d0652",
      "method": "GET",
      "route": "/api/v1/webhook-deliveries/:id",
      "status": 200,
      "durationMs": 16,
      "errorCode": null,
      "environmentId": "7d3d2aa8-d312-48d7-894c-25b906dfa11a",
      "apiKeyId": "5ef37bc9-8aac-43ef-81b1-6bb3bdb66e78",
      "at": "2026-11-12T08:33:46.374Z"
    }
  ],
  "nextCursor": "MjAyNi0xMS0xMlQwODozMzo0Ni4zNzRafGM3MjdmMTYxLWQ3NjYtNGMwNy1hNDc3LTc0YzBiYWI2NGQ1OQ"
}
```
