Pagination

List endpoints return a page of results with metadata at a time, so you can walk the full dataset without loading it at once. Query parameters control the slice; the JSON body echoes what was applied and gives the total row count for the current query.

Query parameters

Parameter Meaning Default Constraints
take Maximum number of items to return in this response 50 Integer
> 0, ≤ 500
skip Number of items to skip from the start of the result set 0 Integer
≥ 0

Example: take=100&skip=200 asks for up to 100 rows, starting after the first 200 ones.

Response shape

Successful list responses follow this structure:

  • items: array of resources for this page (may be shorter than take on the last page, or empty).
  • pagination: object with :
    • take — page size used for this response (same idea as the request).
    • skip — offset used for this response.
    • total — total number of rows matching the query — before applying skip/take

Example:

{
  "pagination": {
    "take": 50,
    "skip": 0,
    "total": 247
  },
  "items": [ /* … up to 50 elements … */ ]
}

Walking pages

Use skip as an offset in steps of take until skip + items.length >= total (or items.length === 0).

Example:

With take = 50 and total = 247,

  1. First request: skip=0 → up to 50 items, total still 247.
  2. Next: skip=50, then skip=100, skip=150, skip=200.
  3. Last page: skip=200 returns 47 items (200 + 47 = 247).

Combining with filters

On routes that support filters, send pagination args and filters in the same query string.

Example:

GET /v1/example?take=25&skip=50&filters[status][in][]=active
  • Returned items will be filtered
  • The pagination.total number will represent the filtered total