Full-text search US state (and federal) legislation to find out what bills are about a given topic. Searches one state or nationwide (ALL) and returns matching bills with number, title, state, last action, and a LegiScan bill_id you can pass to get_bill. Example: search_bills({ query: "data priva...
AI agents call search_bills to retrieve information from Legiscan without modifying anything — typically the context-gathering step in research, monitoring, and reporting workflows, before the agent takes action elsewhere.
| Parameter | Type | Required | Description |
|---|---|---|---|
year | number | — | LegiScan year code: 1 = all years, 2 = current + prior session (default), or a specific year like 2024. |
query | string | Yes | Search terms, e.g. "data privacy", "minimum wage", "abortion" |
state | string | — | 2-letter state abbreviation (e.g. "CA", "TX") or "ALL" to search every state. Default "ALL". |
_apiKey | string | — | Optional — your own LegiScan API key for higher limits; omit to use the shared Pipeworx key. |
Parameters from the server's own tool schema.
This tool queries legislative data and retrieves results without side effects. It is a read-only search operation that returns bill information. No data is created, modified, deleted, or executed. The blast radius of misuse is minimal—an AI agent could only retrieve information already publicly available through the LegiScan API.
From the tool's definition Tool performs 'Full-text search' and 'returns matching bills' with metadata. No modification, deletion, or execution of code/commands occurs. The description uses search/query/return verbs typical of retrieval operations.
Risk signalsAccepts freeform code/query input (query)
Attacks that exploit this kind of access
Full-text search US state (and federal) legislation to find out what bills are about a given topic. Searches one state or nationwide (ALL) and returns matching bills with number, title, state, last action, and a LegiScan bill_id you can pass to get_bill. Example: search_bills({ query: "data privacy", state: "CA" }). It is categorised as a Read tool in the Legiscan MCP Server, which means it retrieves data without modifying state.
search_bills accepts 4 parameters: year, query, state, _apiKey. Required: query. The full parameter table on this page comes from the server's own tool schema.
Register the Legiscan MCP server in PolicyLayer and add a rule for search_bills: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Legiscan. Nothing to install.
search_bills is a Read tool with low risk. Read-only tools are generally safe to allow by default.
Yes. Add a rate_limit block to the search_bills rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for search_bills. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
search_bills is provided by the Legiscan MCP server (pipeworx-io/mcp-legiscan). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
Every MCP server has a record like this.
Type a name, get the same breakdown: verified identity, auth posture, risk grade, capabilities, recommended policy.
Teams ship this data inside their own products. See what a licence covers →