Pagination
ChronaPilot list endpoints use cursor-based pagination. No offsets, no skipped records, stable under concurrent writes.
Anatomy of a paginated response
JSON
{
"object": "list",
"data": [ { "id": "evt_1abc…", "object": "event", … }, … ],
"has_more": true,
"next_cursor": "evt_z9y8x7w6"
}To fetch the next page, pass starting_after set to the id of the last record, or use next_cursor directly.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| limit | integer | 25 | Max 100. |
| starting_after | string | — | Cursor: include records strictly after this ID. |
| ending_before | string | — | Cursor: include records strictly before this ID (reverse pagination). |
| created[gte] | timestamp | — | Filter by creation time. Also supports lte, gt, lt. Available on most list endpoints — check each resource's reference page. |
Example
curl
curl https://api.chronapilot.com/v1/events?limit=10 \ -H "Authorization: Bearer sk_live_…" # Next page curl 'https://api.chronapilot.com/v1/events?limit=10&starting_after=evt_z9y8x7w6' \ -H "Authorization: Bearer sk_live_…"
Iteration with SDKs
Node.js
for await (const event of cp.events.list({ limit: 100 })) { await processEvent(event); }
The Node, Python, and Go SDKs hide pagination behind iterators that page automatically.
Ordering
Lists are returned newest-first by created_at unless an endpoint specifies otherwise. The events endpoint also accepts order=start_time_asc for calendar-style display.
Stability
Cursors are stable across new inserts. A record inserted after you began paging will not appear unless it falls into the cursor's range — you will not see duplicates and you will not skip rows due to insertion shuffle.