Skip to main content
Glama

Search Debates

search_debates
Read-onlyIdempotent

List Hansard speeches (debate contributions) by a specific MP and/or party, optionally within a date range. Returns who spoke, when, and the speech text. IMPORTANT: the OpenParliament API has NO free-text/topic search, you must filter by politician (MP slug; find one via list_politicians) and/or party. There is no way to search debates by subject keyword.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "limit": 10,
      "politician": "justin-trudeau"
    },
    "name": "search_debates"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNo1-100 (default 20)
partyNoParty slug (e.g. "liberal", "conservative", "ndp")
offsetNo0-based offset
date_toNoYYYY-MM-DD
date_fromNoYYYY-MM-DD
politicianNoMP slug, e.g. "justin-trudeau" (use list_politicians to find slugs)

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • changedInput schema / examples
      Previous value: -[
      -  {
      -    "query": "climate change"
      -  },
      -  {
      -    "date_from": "2023-01-01",
      -    "date_to": "2023-12-31",
      -    "limit": 50,
      -    "party": "liberal",
      -    "query": "healthcare funding"
      -  }
      -]New value: +[
      +  {
      +    "limit": 10,
      +    "politician": "justin-trudeau"
      +  },
      +  {
      +    "date_from": "2024-01-01",
      +    "date_to": "2024-12-31",
      +    "limit": 50,
      +    "party": "liberal"
      +  }
      +]
    • changedInput schema / properties / party / description
      Previous value: -"Party slug (e.g. \"liberal\", \"conservative\")"New value: +"Party slug (e.g. \"liberal\", \"conservative\", \"ndp\")"
    • changedInput schema / properties / politician / description
      Previous value: -"Politician slug"New value: +"MP slug, e.g. \"justin-trudeau\" (use list_politicians to find slugs)"
    • removedInput schema / properties / query
      Removed value: -{
      -  "description": "Full-text query",
      -  "type": "string"
      -}
    • removedInput schema / required
      Removed value: -[
      -  "query"
      -]
  2. Changed2 schema fields changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "query": "climate change"
      +  },
      +  {
      +    "date_from": "2023-01-01",
      +    "date_to": "2023-12-31",
      +    "limit": 50,
      +    "party": "liberal",
      +    "query": "healthcare funding"
      +  }
      +]
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "description": "Search results from Hansard contributions (debates)",
      +  "type": "object"
      +}
  3. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, open-world behavior, so the safety profile is covered. The description adds genuinely non-structured context: the upstream API has no keyword search and cannot filter by subject, plus a brief statement of what the records contain (speaker, time, speech text). It stops short of discussing pagination or result-size behavior.

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?

The core scope and the critical API limitation are front-loaded, which is the right structure. The final sentence restates the no-keyword-search point already made in the capitalized warning, so a small amount of text is redundant.

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?

With an output schema, full schema description coverage and annotations present, the definition only needs to supply the constraint that cannot be inferred from structured data — the absence of topic search and how to work around it — which it does explicitly. 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.

Parameters3/5

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

Schema coverage is 100% with per-parameter descriptions and examples, so the schema already carries the burden; baseline 3 applies. The description only reiterates the politician-slug convention and date range, adding little beyond what the schema states.

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 specific verb and resource ('List Hansard speeches (debate contributions)') plus the exact filter axes (MP and/or party, optional date range). An agent can immediately tell this is a filtered enumeration of parliamentary speeches, not a topic search.

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

Usage Guidelines5/5

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

Explicitly says what selects this tool (filter by politician and/or party) and what does not exist (no free-text/topic search), and routes the agent to list_politicians to obtain slugs. This is a clear when-to-use and how-to-qualify instruction set.

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.