Skip to main content

Paginate list endpoints

Page DALP list endpoints with JSON:API sort, page, and filter query parameters, follow links.next, and stay inside the 200-item page-size cap.

Overview

Most v2 collection endpoints return offset-and-limit pages with navigation links. Query them with page[offset], page[limit], sort, and filter[{field}], then follow links.next until it is null.

These endpoints refuse flat keys (limit, offset, sortBy, sortDirection, and filters) with 400 Bad Request. Endpoints that use their own flat limit, offset, cursor, or event streams are covered under Other pagination shapes in the API.

curl --globoff "$DALP_API_URL/api/v2/tokens?sort=-createdAt&page[offset]=0&page[limit]=50" \
  -H "X-Api-Key: $DALP_API_KEY"

Read the response

Offset-based responses return data, meta.total, and navigation links:

{
  "data": [],
  "meta": { "total": 214 },
  "links": {
    "self": "/api/v2/tokens?sort=-createdAt&page%5Boffset%5D=0&page%5Blimit%5D=50",
    "first": "/api/v2/tokens?sort=-createdAt&page%5Boffset%5D=0&page%5Blimit%5D=50",
    "prev": null,
    "next": "/api/v2/tokens?sort=-createdAt&page%5Boffset%5D=50&page%5Blimit%5D=50",
    "last": "/api/v2/tokens?sort=-createdAt&page%5Boffset%5D=200&page%5Blimit%5D=50"
  }
}

Brackets in links are percent-encoded (page%5Boffset%5D). Follow links.next and links.prev verbatim instead of calculating offsets yourself, because each link preserves the active sort and filters.

links.next is the only reliable end-of-walk signal: it is non-null whenever another page follows and null on the final page. Never stop early because data.length is smaller than page[limit] or empty, because concurrent writes between requests can shrink a page. See A page walk is not a consistent read.

When the total is a lower bound

meta.totalIsLowerBound: true means at least meta.total rows match. The flag is omitted when the total is exact.

When meta.totalIsLowerBound is true, DALP does not compute the final page offset: links.last repeats links.next (or links.self on the last page). Always follow links.next until it is null, and narrow your filters when you need an exact total.

Endpoint
Cap and behaviour
GET /api/v2/platform-status/transactions-list
Caps meta.total and meta.facets at 10,000. Sending counts=false omits facets, counts only up to the end of the page, and sets totalIsLowerBound: true whenever another page exists.
GET /api/v2/reporting/trail, .../trail/operator, .../trail/resource
Caps meta.total at 10,000. The trail and operator routes page with cursor and limit via links.next. The resource read returns one page with links.self only.
GET /api/v2/users/me/events, GET /api/v2/participants/{participantId}/activities, GET /api/v2/system/accounts/{accountAddress}/activities, GET /api/v2/tokens/{assetId}/events
Caps meta.total at 10,000. Follow links.next. The user and participant event routes also return meta.nextCursor. Cursor pages of the participant list repeat the first page's total. V1 routes keep exact totals.
GET /api/v2/tokens/{assetId}/historical-balances
Caps meta.total at 10,000 and returns only links.self. Page with page[offset] and page[limit], or filter with filter[account] for an exact total.
GET /api/v2/system/identities
Caps meta.total and meta.facets at 10,000. Past offset 10,000, follow links.next using page[cursor]. See Read deep pages with a cursor.
GET /api/v2/transaction-requests
Caps total at 10,000 and sets totalIsLowerBound: true above it. Page with offset. nextCursor is always null.
GET /api/v2/participants
With filter[eligibleForToken], sets totalIsLowerBound: true whenever a page fills before every matching participant is checked, even below 10,000.

On offset-paged token and system-account lists, meta.facets is returned on the first page (page[offset]=0) only. Counts come from stored hourly and daily totals where they can answer the request. A request they cannot answer, such as a text search, a time bound inside an hour, a block number or transaction hash filter, a predicate, or an address held through a watched external token, counts live with a 5-second budget. If the facets query times out, the response sets meta.totalsSkipped: "timeout", omits meta.facets, and keeps the capped meta.total. If the total query times out too, meta.total is omitted. Responses with meta.totalsSkipped are never cached, so retrying queries fresh data.

When a page runs past its budget

GET /api/v2/users/me/events, GET /api/v2/participants/{participantId}/activities and GET /api/v2/system/accounts/{accountAddress}/activities read their rows inside the hours that stored hourly totals say hold matches. An event, asset or network filter, or a range that starts and ends on the hour, that matches nothing answers at once with an empty page.

A text search, a time bound inside an hour, or an EVM filter on another event field, such as a block number, transaction hash or sender address, makes DALP examine events one by one. On the participant route an event filter does too. Family, network and Canton filters do not. The system account route counts its search from stored totals, because it matches the event name only. Such a page reads under a 10-second budget. So does every page of these routes while a deployment rebuilds its stored totals after an upgrade, and every page of a system account that watches external tokens, whatever its filter. Past the budget, the response is 200 with an empty data array, meta.rowsSkipped: "timeout" and no meta.facets. On /users/me/events and the participant route, meta.nextCursor is null. The system account route is offset-paged and returns no meta.nextCursor. meta.total is omitted, except on the participant route, where it reads 0 with meta.totalIsLowerBound: true. An empty data array without meta.rowsSkipped means nothing matched.

Narrow the time range or make the search more specific: the same request meets the same budget. Responses with meta.rowsSkipped are never cached. When only the Canton events of a mixed page run out, the response keeps its EVM rows without the marker and meta.nextCursor starts the Canton events. V1 routes keep their unbudgeted reads.

Sort

Send sort={field} for ascending order or sort=-{field} for descending order. DALP accepts one sort field per request, not a comma-separated list.

Each route defines its own default sort and sortable fields in the API reference. Never assume -createdAt: send sort explicitly when order matters. Unknown sort fields either fail with 400 (such as TOKEN_LIST_FILTER_INVALID, DALP-9289 on the token list, with data.filterId naming the rejected term, or for unknown fields[token] values) or fall back to the default sort while echoing your parameter in links.

Routes append deterministic tiebreaker columns to your sort field, so repeated identical queries on unchanged data return rows in the same order. That tiebreaking applies within one fixed state, not across concurrent inserts or deletes.

Page window

page[offset] is the zero-based starting index (default 0). page[limit] is the page size from 1 through 200 (default 50). To read more than 200 rows, follow links.next.

Negative or fractional offsets and limits outside 1 through 200 fail with 400 REQUEST_INVALID (DALP-14261), with data.errors naming the field. DALP never clamps invalid values.

Most lists have no offset ceiling, but GET /api/v2/system/identities rejects offsets of 10,000 or more with 400 COLLECTION_PAGE_OFFSET_OUT_OF_RANGE (DALP-9275). Its links.next automatically switches to page[cursor] before reaching 10,000. Because high offsets force the database to scan skipped rows, use cursors for deep walks.

Read deep pages with a cursor

Lists that declare page[cursor] in their route schema return meta.nextCursor, an opaque position token (null on the final page). Pass it back as page[cursor] with the same sort and filters to seek straight to the next page at constant cost.

Cursor-enabled routes include GET /api/v2/system/identities, GET /api/v2/webhooks, GET /api/v2/webhooks/{webhookId}/deliveries, GET /api/v2/webhook-receipts, GET /api/v2/operations/cases, GET /api/v2/users/me/events, GET /api/v2/tokens/{assetId}/transfers, and the reporting statement, confirmation, and transaction-report lists.

curl --globoff "$DALP_API_URL/api/v2/webhook-receipts?sort=-receivedAt&page[limit]=200&page[cursor]=eyJ..." \
  -H "X-Api-Key: $DALP_API_KEY"

On a cursor walk, links.self echoes your cursor, links.next carries meta.nextCursor, and links.prev is null because cursors move forward only. When page[cursor] is present, page[offset] is ignored.

Treat cursors as opaque strings bound to the original sort and filters. Altering a cursor or changing sort, filters, or search terms fails with 400 COLLECTION_PAGE_CURSOR_MISMATCH (DALP-9565). A cursor never widens access beyond your key's scope.

Some cursor lists scan a bounded slice of history per request and can return fewer rows than page[limit] (or zero rows) with a non-null meta.nextCursor. Stop only when meta.nextCursor is null. See Delivery list sorting and short pages.

A page walk is not a consistent read

DALP does not snapshot a collection when a walk starts. Each page request runs live against current state, including meta.total, so concurrent writes can shift rows between pages or cause duplicates or omissions without notice.

For reconciliation or exports, filter to a fixed creation-time window that excludes new rows (for example, filter[createdAt][lt] set to your start time on GET /api/v2/tokens) and deduplicate by resource ID. A cursor keeps your place in the sort order for rows whose sort value does not change, though updates to the sort field or deletes can still shift rows.

Because meta.total is recomputed on every request, reconcile against the unique resource IDs you collected rather than assuming the first page's total equals your final count.

Filter

Use filter[{field}]={value} for a field's default operator (usually equality), or name an explicit operator such as filter[status][inArray]=active,paused.

Operator
Behaviour
eq, ne, gt, gte, lt, lte
Equality and ordering comparisons.
iLike, notILike
Case-insensitive substring matching.
inArray, notInArray
Membership list of 1 to 100 non-blank values.
between
Inclusive two-value range.
isEmpty, isNotEmpty
Empty check (takes no value).

Lists exceeding 100 items, blank list items, undeclared fields, or unsupported operators fail with 400 REQUEST_INVALID (DALP-14261) naming the key in data.errors. Unknown enum values fail with 400 COLLECTION_FILTER_VALUE_INVALID (DALP-9355).

On endpoints with global search enabled, filter[q]={term} searches across the endpoint's default text fields.

No flat aliases

Endpoints that accept sort, page[offset], page[limit], page[cursor], filter[{field}], or fields[{type}] reject the flat keys sortBy, sortDirection, limit, offset, and filters with 400 REQUEST_INVALID. Rejecting them prevents a silently ignored limit or filters parameter from returning an unfiltered first page.

Other pagination shapes in the API

Not every list uses JSON:API page[...] parameters. Check each route's schema in the API reference:

  • Top-level cursor and limit with items envelope: GET /api/v2/monitoring/api/request-logs and GET /api/v2/blockchain-monitoring/health-snapshots return { items, nextCursor, totalCount, facets }. Send nextCursor back as cursor until it is null.
  • Flat limit with offset or cursor: GET /api/v2/transaction-requests (returns data, total, and an always-null nextCursor, paged with offset), trading venue lists, /api/v2/custody-ops lists (such as GET /api/v2/custody-ops/reconciliation/breaks, returning data, links, meta), and GET /api/v2/reporting/trail declare flat parameters directly.
  • SSE event streams: Streams such as request-log and health-snapshot feeds have no pagination or resume cursor. A dropped connection misses events during the gap, so read historical data from the matching list endpoint.

Next steps

  • Errors covers error payloads for out-of-range page sizes and invalid filters.
  • V2 API reference lists each endpoint's sortable and filterable fields.

Was this page helpful?