> ## Documentation Index
> Fetch the complete documentation index at: https://docs.datalane.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Pagination

> Traverse campaigns with opaque cursor pagination.

`campaigns/list` uses cursor pagination and returns campaigns newest first. The default page size is 25 and the maximum is 100.

```bash theme={null}
curl --request POST \
  --url https://api.datalane.com/v1/campaigns/list \
  --header "Authorization: Bearer $DATALANE_API_KEY" \
  --header "Content-Type: application/json" \
  --data '{"limit": 100, "filters": {"createdVia": "api"}}'
```

When `nextCursor` is non-null, pass it unchanged in the next request:

```json theme={null}
{
  "limit": 100,
  "cursor": "CURSOR_FROM_PREVIOUS_RESPONSE",
  "filters": {
    "createdVia": "api"
  }
}
```

<Warning>
  Treat cursors as opaque. Do not decode, construct, or modify them. An invalid cursor returns `400 invalid_request`.
</Warning>

Keep the same filters and page size while traversing a result set. Stop when `nextCursor` is `null`.
