nextCursor. Check the HTTP status before reading
a response: an error isn’t an empty result.
Page through results
Request the first page with your filters:filings and nextCursor. While nextCursor isn’t null, send it as cursor
with everything else unchanged:
POST search, resend the same JSON body with cursor added.
Stop when nextCursor is null. A page can be empty and still have a cursor; keep going. Results
reflect live data, so records can change between pages.
Resume after a lost response
Keep the cursor you sent until you’ve stored that page. If a response is lost, resend the same cursor; only move on to the newnextCursor after saving the results. Retries can return a different
cursor string, so don’t compare cursors. Deduplicate results by id.
Change the query
A cursor only works with the query it was issued for: the same filters, sort,limit and other
inputs. Changing the state from TX to CA but sending the Texas cursor returns 400 invalid_cursor.
Start the new query without a cursor and keep its results separate.
Some cursors expire. Each operation’s API reference says what its cursor is tied to and whether it
expires. If a cursor is rejected as invalid_cursor, restart the same query without one.