Skip to main content
Endpoints that take a limit page in two different models. Offset paging walks a fixed window with limit and offset and stops when hasMore is false. Use it for a ranked or ordered list that is not changing while you read it. Cursor paging walks an append-only log by change id, forwards with sinceId or backwards with beforeId. Use it for change history, where new rows land while you page and an offset would skip or repeat them. Case law pages this way: cross-state and related have no page two, so raise limit to its maximum if you want the whole set.
cited-by pages on offset. Pass the previous response’s nextOffset as offset while hasMore is true. total is the count of citing sections across all pages (a lower bound when totalCitersIsLowerBound is true). returned is the number of rows on this page.

Search paging

POST /us/statutes/search is the endpoint most integrations page. Two request fields set the window, and one response flag tells you when to stop.

Response fields

Each search response includes these top-level fields:
  • results: the array of result objects for this page.
  • count: the number of results returned on this page, not the corpus-wide match count.
  • total: a deprecated alias for count. Read count in new code. It is never a corpus total.
  • offset: the offset that was applied.
  • hasMore: true when more results are reachable beyond this page.
  • changedSectionCount: only when changedSince is set. How many sections changed in that window, before ranking.
  • creditsConsumed: what this call cost.
count and hasMore describe the results this query can reach, not the corpus. No field reports the total number of matches. Loop on hasMore, and narrow the query instead of paging deeper.

How deep you can page

The deepest reachable result is offset + limit. Ranked modes (any, all, phrase) rank a pool of 120 results once per query, so every page is a free slice of that ranking. hasMore is false on the last reachable page. With the largest page size, offset 70 reaches the end of the pool:
matchType: "boolean" pages to the end of the matches. Keep limit at 50 or below and send each nextOffset back as offset until hasMore is false. To survey a jurisdiction more broadly, scope with corpusType and state and run several narrower queries, as Best practices describes.

Page until hasMore is false

This loop walks every reachable page of a ranked search.
The last ranked page is clamped to offset 70, so with page_size 50 it overlaps the page before it. The loop drops repeats by actId.

Offset paging on the list endpoints

GET /boards and GET /watches both take limit and offset and return their page inside data. GET /boards returns data.total and data.hasMore. GET /watches returns neither. Advance offset until a page comes back shorter than limit. One page is enough there, because the watch cap (see Law change alerts) never exceeds the default limit of 100. The GET /boards limit defaults to 500, which is also the maximum. Page on offset using hasMore instead of trusting one call.
Python
This route is free, but it still counts against your rate limit. A 429 on a free route is handled the same way as on a charged one.

Cursor paging on change history

GET /watches/{id}/changes and GET /us/statutes/section/{actId}/changes page by change id, not by offset. GET /watches/{id}/deliveries uses the same backwards beforeId contract, with the next cursor in meta.nextBeforeId. Change ids only increase, so an id is a stable position in the log. The two endpoints return the cursor in different places:
  • GET /watches/{id}/changes returns it as meta.cursor, alongside meta.hasMore.
  • GET /us/statutes/section/{actId}/changes returns it as a top-level cursor, alongside a top-level hasMore.
The cursor is the highest id on the page. It is null on an empty page, so an idle poll must keep the cursor it already holds. To poll forwards, save the cursor and pass it as sinceId with order=asc on the next call. To walk backwards, pass the lowest id you have seen as beforeId, with the default order=desc. Repeat until a page comes back short of limit.
Python
On both change endpoints, hasMore means this page filled to limit. The next page can be empty. Treat an empty page as the end.

Law Change Alerts

Subscribe to a board, then poll its changes with a cursor.

SDKs

The official Python and TypeScript SDKs hide these paging styles behind one iterator, with page and credit limits.
Last modified on November 22, 2026