# List calls

`GET` `https://goblins-call-api.onrender.com/v1/calls`

Returns your workspace’s calls, newest first, a page at a time.

Works with a [workspace API key](https://www.cracklehq.com/docs/authentication) or the agent’s own key.

## Query parameters

- `agentId` (string, optional): Only calls handled by this agent.
- `status` (enum, optional, created · active · ended): Only calls in this state.
- `limit` (integer, optional, 1–100; default 50): How many calls to return.
- `before` (string, optional): The `nextCursor` of the page before, to fetch older calls.
- `userId` (string, optional): A workspace ID. A key belongs to one workspace, so this is never needed with one; naming another workspace answers `403`.

## Response

- `total` (integer): How many calls match, across all pages.
- `nextCursor` (string): Pass as `before` for the next page. `null` on the last page.

## Errors

- `400`: `status`, `limit` or `before` is not valid.

Every request can also answer `401`, `429` and `500`: see [Errors](https://www.cracklehq.com/docs/errors).

## Notes

- Each call is the full object shown under Get a call. With an agent’s own key the list holds that agent’s calls.

Request:

cURL:

```bash
curl "https://goblins-call-api.onrender.com/v1/calls?agentId=ua_3f9a1c2b&status=ended&limit=20" \
  -H "Authorization: Bearer $CRACKLE_API_KEY"
```

Node.js:

```js
const response = await fetch('https://goblins-call-api.onrender.com/v1/calls?agentId=ua_3f9a1c2b&status=ended&limit=20', {
  headers: {
    Authorization: `Bearer ${process.env.CRACKLE_API_KEY}`,
  },
});
if (!response.ok) throw new Error(await response.text());
const data = await response.json();
```

Python:

```python
import os
import requests

response = requests.get(
    "https://goblins-call-api.onrender.com/v1/calls?agentId=ua_3f9a1c2b&status=ended&limit=20",
    headers={"Authorization": f"Bearer {os.environ['CRACKLE_API_KEY']}"},
    timeout=30,
)
response.raise_for_status()
data = response.json()
```

Response · 200 OK:

```json
{
  "calls": [
    {
      "id": "8f1c2c1e-7b1a-4e0a-9c55-2f6f0d3b1a90",
      "status": "ended",
      "createdAt": "2026-10-11T05:56:12.000Z",
      "endReason": "user-left",
      "durationSeconds": 184,
      "callCost": 0.2147,
      "metadata": { "agentId": "ua_3f9a1c2b", "orderId": "A-1042" },
      "transcript": [ … ]
    }
  ],
  "total": 107,
  "nextCursor": "MjAyNi0xMC0xMVQwNTo1NjoxMi4wMDBafDhmMWMy…"
}
```

Source: https://www.cracklehq.com/docs/reference/calls/list
