> This page is for API.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.eon.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.eon.io/_mcp/server.

# Pagination

API methods that can deliver lists of results typically support paginated responses.
This allows you to retrieve large sets of data in smaller, more manageable chunks.
Eon uses cursor-based pagination, where each page of results includes a cursor that you can use to request the next page of results.

Although this article covers how to use pagination in Eon API methods in general, always use the reference pages for your specific method.

## Requests

The pagination request parameters are consistent across all paginated methods, although depending on the API method, they may be query parameters or in the request body in the `queryParams` object.
Behavior is the same, regardless of where the parameters are located.

If you request a filtered or sorted list of results in the first page, you'll need to include the same filters and sorting options in subsequent pages, along with the `nextToken` returned in the previous response.

#### Request parameters

| Parameter           | Description                                                                                                                                                                                                   |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `nextToken`  string | Token that points to the first record in the next page of results. For example, if your first request had a page size of 100, this token points to record 101. This token is never used in the first request. |
| `pageSize`  integer | Number of items to return in the response.                                                                                                                                                                    |

#### See request examples

**`In a request body`**

```json title="In a request body" {5-6}
{
  "sorts": [ ... ],
  "filters": { ... },
  "queryParams": {
    "nextToken": "GDcVsHpjeGbudx0Ks0KWg6u8VD4c3Dzr9gWrOQfkZkuQlskfgHJ2E1JSOSIHQEZ2",
    "pageSize": 50
  }
}
```

**`In query parameters`**

```txt title="In query parameters"
?pageSize=50&nextToken=GDcVsHpjeGbudx0Ks0KWg6u8VD4c3Dzr9gWrOQfkZkuQlskfgHJ2E1JSOSIHQEZ2
```

## Responses

The response to a paginated request includes the requested array of results and a `nextToken` that you can use to request the next page of results.

#### See a response example

**`Response object`**

```json title="Response object" {3}
{
  "results": [ ... ],
  "nextToken": "GDcVsHpjeGbudx0Ks0KWg6u8VD4c3Dzr9gWrOQfkZkuQlskfgHJ2E1JSOSIHQEZ2"
}
```