Skip to main content
Glama

Search bills

search_bills
Read-only

Search or list legislation with structured filters (GET /v1/bills). Use this when you know the jurisdiction, sponsor, topic, or status you want. Every filter is optional and they combine with AND. A bill number typed into q (e.g. 'HB 1', 'SB0002') matches that bill directly. Returns bill summaries plus pagination; call get_bill for the full record. Corpus is 2026-forward only. status_id values: 1=Introduced, 2=In Committee, 3=Passed One Chamber, 4=Passed Both Chambers (for a simple resolution, bill_type_id 2: Adopted, its final step), 5=Signed into Law, 6=Vetoed, 7=Failed/Dead, 8=Chaptered. Aggregate buckets: passed={4,5,8}, failed={6,7}, alive={1,2,3}.

Input Schema

NameRequiredDescriptionDefault
qNoFree-text search across title, description, and subject names.
limitNoMax rows to return (default 25).
stateNo2-letter postal code (e.g. FL), DC, or US for Congress.
topicNoCanonical topic slug, e.g. 'healthcare'. See list_topics.
offsetNoPagination offset.
subjectNoRaw subject name (ILIKE match).
status_idNoFilter by status. status_id values: 1=Introduced, 2=In Committee, 3=Passed One Chamber, 4=Passed Both Chambers (for a simple resolution, bill_type_id 2: Adopted, its final step), 5=Signed into Law, 6=Vetoed, 7=Failed/Dead, 8=Chaptered. Aggregate buckets: passed={4,5,8}, failed={6,7}, alive={1,2,3}.
session_idNoNarrow to one session.
bill_numberNoBill number, compact (HB1) or padded (HB0001).
updated_sinceNoISO-8601 date or timestamp; only bills changed since then.
title_containsNoSubstring match against the bill title only.
include_sponsorsNoAttach a sponsors array (people_id, name, party, district, sponsor_type) to every bill. Use this whenever the answer needs to name who sponsored the bills.
sponsor_last_nameNoLast name of a bill sponsor.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / status_id / description
      Previous value: -"Filter by status. status_id values: 1=Introduced, 2=In Committee, 3=Passed One Chamber, 4=Passed Both Chambers, 5=Signed into Law, 6=Vetoed, 7=Failed/Dead, 8=Chaptered. Aggregate buckets: passed={4,5,8}, failed={6,7}, alive={1,2,3}."New value: +"Filter by status. status_id values: 1=Introduced, 2=In Committee, 3=Passed One Chamber, 4=Passed Both Chambers (for a simple resolution, bill_type_id 2: Adopted, its final step), 5=Signed into Law, 6=Vetoed, 7=Failed/Dead, 8=Chaptered. Aggregate buckets: passed={4,5,8}, failed={6,7}, alive={1,2,3}."
  2. First observed

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already declare readOnly/openWorld/non-destructive, and the description goes well beyond by disclosing the corpus boundary ("2026-forward only"), that results are summaries plus pagination rather than full records, and that a bill number placed in q matches directly. These are behavioral facts the annotations and schema do not carry.

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

Conciseness4/5

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

Front-loaded with purpose, then trigger, then filter behavior, then the get_bill handoff — a sensible order with no filler sentences. The status_id value list and aggregate buckets are useful domain knowledge but occupy half the description and duplicate the schema, costing some tightness.

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?

For a 13-parameter tool with no output schema, the description covers what is returned (summaries plus pagination), where to go for the full record, and a real coverage limit in the 2026-forward corpus. Nothing an agent needs to call this correctly is missing.

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 coverage is 100%, so the baseline is 3; the description earns an extra point by adding real semantics the schema lacks — the AND-combination rule and the non-obvious q behavior where "HB 1" or "SB0002" resolves to a specific bill. The long status_id enumeration is, however, a verbatim restatement of the schema field rather than added meaning.

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

Purpose4/5

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

Names a specific verb and resource ("Search or list legislation") and scopes it with "structured filters," which implicitly separates it from the free-text keyword_search_bills and semantic_search_bills siblings. It explicitly routes to get_bill for full records, but never names the closest search siblings, so the differentiation is inferred rather than stated.

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?

"Use this when you know the jurisdiction, sponsor, topic, or status you want" gives a clear positive trigger, and "Every filter is optional and they combine with AND" tells the agent how filters behave. It states no explicit exclusion (e.g., use keyword_search_bills when you have only a fuzzy phrase), so the when-not case is left to inference.

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.

Resources