The sync filter: changedSince
changedSince takes a YYYY-MM-DD date and limits a search to sections that changed since then.
GET /us/statutes/section/{actId}/changes to see what moved.
A 422 means the window is too broad. Use a later date, corpusType or state (see Errors).
How changedSince behaves
How changedSince behaves
- Dates are when we saw the change. They are an upper bound on when it took effect, not an effective date.
- An empty result means no captured change in the window. It does not prove nothing was amended.
- A window that is too broad returns
422instead of partial results. Narrow it withcorpusTypeandstate. - A search still needs a
query. Run one search per topic you track.
limit caps at 50 and offset at 70, so the deepest result is 120.
Boolean mode (matchType: "boolean") pages to the end of the matches, with offset up to 10,000.
See Search.An empty window is charged the ordinary 4-credit search price. Read creditsConsumed.A nightly job
Python
The other question: a jurisdiction gaining a new corpus
changedSince cannot show that a state you do not yet query has gained regulations.
To catch that, snapshot GET /us/statutes/coverage on a schedule and diff the snapshots.
Daily or weekly is enough.
Snapshot and diff code
Snapshot and diff code
The response is 2. Save and diffSave each snapshot as JSON. Compare two snapshots for a new jurisdiction, a new corpus, or a corpus whose count grew.Example output when a state gained regulations (counts are placeholders):
{ "data": {...}, "meta": {...} }.
Inside data are a corpusTypes legend and a jurisdictions array. Each jurisdiction has a corpora object that maps a corpusType token to its section count (the same count Coverage shows).1. Fetch and flatten the coverage matrixPython
Python
Related
- Law Change Alerts: section-level change notifications with a webhook or email, no polling.
- Coverage matrix: the human-readable jurisdiction and corpus matrix.
- Enrich a citation database: attach canonical citations, excerpts and source links to a batch of rows.

