Skip to content

Pagination

Dockt collection endpoints use cursor pagination.

Use limit to request between 1 and 100 resources. The default is 20:

GET /v1/assessments?limit=50

Collection responses include:

{
"object": "list",
"data": [],
"has_more": true,
"next_cursor": "OPAQUE_CURSOR"
}

When has_more is true, send the returned next_cursor unchanged:

GET /v1/assessments?limit=50&cursor=OPAQUE_CURSOR

Stop when has_more is false or next_cursor is null.

  • Treat the cursor as an opaque string.
  • Don’t parse, modify, or construct cursors.
  • Keep the same filters and page size while walking one collection view.
  • Start a new pagination sequence when filters change.
  • Handle an invalid or expired cursor as 400 Bad Request and restart from the first page when appropriate.
  • Don’t use a cursor from one endpoint on another endpoint.

Collection-specific filters appear in the API reference.