Skip to main content
Glama

Get Bill

openstates_get_bill
Read-onlyIdempotent

Fetch full detail for a specific state bill. Accepts either the three-part path (jurisdiction + session + bill_id) or a direct OCD bill ID (openstates_id from search results). Use include to request votes, actions, sponsorships, documents, and versions in one call rather than searching again. include=votes returns the full vote tally and per-legislator positions. include=actions returns the complete action history. Prefer openstates_id when available to avoid session identifier lookup.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bill_idNoBill identifier as used by the legislature (e.g., "HB 1000", "SB 42"). Required with jurisdiction + session.
includeNoRelated data to inline. "sponsorships", "actions", "votes" are most commonly needed. "versions" and "documents" provide links to bill text and fiscal notes.
sessionNoSession identifier. Required with jurisdiction + bill_id.
jurisdictionNoState name, abbreviation, or OCD-ID. Required when using path-based lookup with session + bill_id.
openstates_idNoOCD bill ID from openstates_search_bills results (e.g., "ocd-bill/..."). Preferred over the three-part path when available.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoOCD bill ID.
errorNoPresent when the call failed. Absent on success.
titleNoBill title.
votesNoVote events when include=votes is requested.
actionsNoFull action history when include=actions is requested.
sessionNoLegislative session identifier.
sourcesNoSource documents when include=sources is requested.
subjectNoSubject tags.
versionsNoBill text versions when include=versions is requested.
abstractsNoBill abstracts when include=abstracts is requested.
documentsNoBill documents (fiscal notes, etc.) when include=documents is requested.
identifierNoBill identifier as used by the legislature.
updated_atNoTimestamp Open States last updated this record — the field openstates_search_bills sorts by under the default sort=updated_desc.
jurisdictionNoOriginating jurisdiction.
other_titlesNoAlternate titles when include=other_titles is requested.
sponsorshipsNoSponsorships when include=sponsorships is requested.
related_billsNoRelated bills when include=related_bills is requested.
classificationNoBill classifications.
openstates_urlNoOpen States URL for this bill.
first_action_dateNoDate of first recorded action.
from_organizationNoOriginating chamber.
other_identifiersNoAlternate identifiers when include=other_identifiers is requested.
latest_action_dateNoDate of most recent action.
latest_passage_dateNoDate bill passed (when applicable).
latest_action_descriptionNoMost recent action description.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed8 schema fields changed
    • removedOutput schema / properties / first_action_date / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / first_action_date / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / latest_action_date / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / latest_action_date / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / latest_action_description / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / latest_action_description / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / latest_passage_date / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / latest_passage_date / type
      Added value: +[
      +  "string",
      +  "null"
      +]
  2. Changed6 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedInput schema / additionalProperties
      Added value: +false
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedOutput schema / anyOf
      Added value: +[
      +  {
      +    "not": {
      +      "required": [
      +        "error"
      +      ]
      +    },
      +    "required": [
      +      "id",
      +      "identifier",
      +      "title",
      +      "session",
      +      "jurisdiction",
      +      "from_organization",
      +      "classification",
      +      "subject",
      +      "first_action_date",
      +      "latest_action_date",
      +      "latest_action_description",
      +      "latest_passage_date"
      +    ]
      +  },
      +  {
      +    "required": [
      +      "error"
      +    ]
      +  }
      +]
    • addedOutput schema / properties / error
      Added value: +{
      +  "additionalProperties": {},
      +  "description": "Present when the call failed. Absent on success.",
      +  "properties": {
      +    "code": {
      +      "description": "JSON-RPC error code for this failure.",
      +      "maximum": 9007199254740991,
      +      "minimum": -9007199254740991,
      +      "type": "integer"
      +    },
      +    "data": {
      +      "additionalProperties": {},
      +      "properties": {
      +        "reason": {
      +          "description": "Machine-readable failure mode. Declared by this tool: `missing_lookup_params`: Neither openstates_id nor the complete jurisdiction+session+bill_id triple was provided. `not_found`: Bill does not exist at the given path or OCD ID. `upstream_timeout`: Open States did not answer within the per-request timeout. Other values are possible when a failure originates below the handler.",
      +          "examples": [
      +            "missing_lookup_params",
      +            "not_found",
      +            "upstream_timeout"
      +          ],
      +          "type": "string"
      +        },
      +        "recovery": {
      +          "additionalProperties": {},
      +          "description": "Actionable next step for the caller.",
      +          "properties": {
      +            "hint": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "hint"
      +          ],
      +          "type": "object"
      +        },
      +        "retryable": {
      +          "description": "Whether retrying may succeed.",
      +          "type": "boolean"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "message": {
      +      "description": "Human-readable description of what went wrong.",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "code",
      +    "message"
      +  ],
      +  "type": "object"
      +}
    • removedOutput schema / required
      Removed value: -[
      -  "id",
      -  "identifier",
      -  "title",
      -  "session",
      -  "jurisdiction",
      -  "from_organization",
      -  "classification",
      -  "subject",
      -  "first_action_date",
      -  "latest_action_date",
      -  "latest_action_description",
      -  "latest_passage_date"
      -]
  3. Changed10 schema fields changed
    • changedOutput schema / properties / abstracts / items / properties / note / description
      Previous value: -"Source note."New value: +"Source note. Empty string when Open States recorded no note."
    • changedOutput schema / properties / actions / items / properties / date / description
      Previous value: -"Action date."New value: +"Action date. Empty string when Open States recorded no date."
    • changedOutput schema / properties / documents / items / properties / date / description
      Previous value: -"Document date."New value: +"Document date. Empty string when Open States recorded no date, which is the usual case for bill documents."
    • changedOutput schema / properties / documents / items / properties / note / description
      Previous value: -"Document note."New value: +"Document note. Empty string when Open States recorded no note."
    • changedOutput schema / properties / other_titles / items / properties / note / description
      Previous value: -"Note describing the alternate title."New value: +"Note describing the alternate title. Empty string when Open States recorded no note."
    • changedOutput schema / properties / sources / items / properties / note / description
      Previous value: -"Source note."New value: +"Source note. Empty string when Open States recorded no note."
    • changedOutput schema / properties / sponsorships / items / properties / person / properties / id / description
      Previous value: -"OCD person ID."New value: +"OCD person ID. Pass it to openstates_search_people as id for the full legislator record, or back to openstates_search_bills as the sponsor filter for their other bills."
    • changedOutput schema / properties / versions / items / properties / date / description
      Previous value: -"Version date."New value: +"Version date. Empty string when Open States recorded no date, which is the usual case for bill versions."
    • changedOutput schema / properties / versions / items / properties / note / description
      Previous value: -"Version note."New value: +"Version note. Empty string when Open States recorded no note."
    • changedOutput schema / properties / votes / items / properties / start_date / description
      Previous value: -"Vote date."New value: +"Vote date. Empty string when Open States recorded no date."
  4. Changed2 schema fields changed
    • changedOutput schema / properties / other_identifiers / items / properties / scheme / description
      Previous value: -"Identifier scheme (the issuing system)."New value: +"Identifier scheme (the issuing system). Absent for bills — Open States omits it on every bill record observed."
    • changedOutput schema / properties / other_identifiers / items / required
      Previous value: -[
      -  "identifier",
      -  "scheme"
      -]New value: +[
      +  "identifier"
      +]
  5. Changed1 schema field changed
    • addedOutput schema / properties / updated_at
      Added value: +{
      +  "description": "Timestamp Open States last updated this record — the field openstates_search_bills sorts by under the default sort=updated_desc.",
      +  "type": "string"
      +}
  6. Changed3 schema fields changed
    • addedOutput schema / properties / other_identifiers
      Added value: +{
      +  "description": "Alternate identifiers when include=other_identifiers is requested.",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "Alternate identifier record.",
      +    "properties": {
      +      "identifier": {
      +        "description": "Alternate bill identifier.",
      +        "type": "string"
      +      },
      +      "scheme": {
      +        "description": "Identifier scheme (the issuing system).",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "identifier",
      +      "scheme"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / other_titles
      Added value: +{
      +  "description": "Alternate titles when include=other_titles is requested.",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "Alternate title record.",
      +    "properties": {
      +      "note": {
      +        "description": "Note describing the alternate title.",
      +        "type": "string"
      +      },
      +      "title": {
      +        "description": "Alternate bill title.",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "title",
      +      "note"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / sources
      Added value: +{
      +  "description": "Source documents when include=sources is requested.",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "Source record.",
      +    "properties": {
      +      "note": {
      +        "description": "Source note.",
      +        "type": "string"
      +      },
      +      "url": {
      +        "description": "Source URL.",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "url",
      +      "note"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  7. First observed

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, openWorldHint, and idempotentHint, so the safety profile is covered. The description adds meaningful behavioral context beyond annotations: include=votes returns the full tally and per-legislator positions, and include=actions returns complete action history. No contradictions found.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded with the core purpose, then moves into identifier options and include semantics. Each sentence earns its place, with no filler, tautology, or unnecessary repetition of schema content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers everything an agent needs to call this correctly: identifier alternatives, when to prefer one over the other, and how to request related data. The output schema handles return-value details, and annotations cover safety, so the description is complete for decision-making.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3, but the description adds real value beyond the schema: explains the two mutually exclusive lookup modes, the precedence of openstates_id over the three-part path, and what specific include values return. This pushes it above baseline.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a clear action ('Fetch full detail') and resource ('specific state bill'), making the tool's purpose unmistakable. It also distinguishes itself from search_bills by emphasizing identifier-based lookup versus searching again, and it names the primary query modes (path vs OCD ID).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides concrete usage guidance: use include to pull related data in one call rather than searching again, and prefer openstates_id when available to avoid session lookup. It does not explicitly contrast with sibling get_* tools, but the bill-specific scope and identifier guidance make the intended use clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.