Retrieving Bills
To retrieve a list of bills, send aGET request to the /bills endpoint. For example, the following request retrieves Texas bills that mention data centers, latest milestone first:
GET request to /bills/{id}. The response contains the bill along with its sponsors and latest milestone.
Filtering Bills
The/bills endpoint accepts the following query parameters. Any of them may be combined:
The Bill Object
A bill looks like the following. The values below are illustrative:status attribute describes the bill’s legal state. It is deliberately coarse, so that it means the same thing in every legislature, and contains one of the following values: draft, in_procedure, adopted, in_force, withdrawn, rejected, repealed, or expired.
The summary.source attribute tells you who wrote the summary: official when the legislature publishes one, editor when our team wrote it, and ai when PolicyMate generated it from the bill’s text.
Milestones
A bill’s history is made of milestones: its introduction, committee actions, readings, votes, and final outcome. You may retrieve a bill’s milestones, oldest first, using theGET /bills/{id}/milestones endpoint:
type is one of proposed, committee_action, reading, chamber_vote, adopted, signed_into_law, entered_into_force, rejected, withdrawn, expired, repealed, document_published, or other. When the source publishes vote counts, the milestone also includes a vote object.
Bill Texts
TheGET /bills/{id}/texts endpoint returns each version of a bill’s text. Every version includes a link to the original file and, when available, a link to its plain text:
text_method attribute describes how the plain text was obtained: source when the legislature publishes the text itself, extracted when we read it from the file, or ocr when the file is a scan.