Overview
List endpoints — invoices, receipts, bills, credit notes, debit notes, expenses, and similar collections — use cursor-based pagination. There is no page parameter; you page through a collection by passing back a cursor from the previous response.
Request parameters
last_id and keyset are opaque tokens. Don’t parse them or construct them yourself — treat them as values to copy from one response into the next request.
Fetching the first page
Omit last_id and keyset entirely:
Response shape
Fetching subsequent pages
Pass the last_id and keyset you got back straight through as query parameters:
Keep requesting the next page with the last_id/keyset pair from each response. You’ve reached the end of the collection when a response comes back with last_id: null — stop there rather than counting pages.
These endpoints don’t support offset or page-number pagination. A page (or offset) parameter is not read and is silently ignored — the response will just be the first page again. Always drive pagination off last_id/keyset, never a page count.
Sorting
Paginated collections are always returned newest first (created_at descending). A sort_by/sort_order parameter isn’t honored on these endpoints: the cursor is anchored to created_at, so sorting by a different column would desync the cursor from the sort order and produce skipped or repeated rows across pages.

