Skip to main content
Glama

Search Parliamentary Divisions

votes_search_divisions
Read-onlyIdempotent

USE THIS TOOL WHEN searching Commons or Lords formal votes by topic, date, or member.

Returns one page of division summaries (title, date, vote counts, pass/fail) plus total, the source's count of all matching divisions. While has_more is true, re-call with offset=offset+returned. AFTER calling, pass division_id + house into votes_get_division for the full member-by-member voter lists.

Authoritative source for UK parliamentary vote records.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
houseNoWhich house to search.Commons
limitNoMaximum divisions to return. Default 25. The Lords API honours up to 100; the Commons API returns at most 25 per call, so page by `returned`, not `limit`.
queryNoSearch term for division titles, e.g. 'Rwanda' or 'Online Safety Bill'. Omit to browse recent divisions.
offsetNoNumber of divisions to skip before this page. Default 0. Re-call with offset=offset+returned while has_more is true.
to_dateNoEnd date (YYYY-MM-DD).
from_dateNoStart date (YYYY-MM-DD).
member_idNoFilter to divisions where this member voted. Get the member ID from parliament_find_member.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
houseYesCommons or Lords
limitNoPage size requested (the Commons API returns at most 25 regardless)
queryNoThe search term, if any (None = browse recent)
totalYesTotal divisions matching the filters, from the source API's searchTotalResults count
offsetNoSkip applied to this page
has_moreNoTrue if divisions beyond this page exist (offset + returned < total)
returnedYesNumber of divisions returned in this call
divisionsNoMatching divisions. Use the integer `id` field with votes_get_division to fetch the full voter list.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changed
    • changedInput schema / properties / limit / description
      Previous value: -"Maximum divisions to return. Default 25 (Commons API max-per-page)."New value: +"Maximum divisions to return. Default 25. The Lords API honours up to 100; the Commons API returns at most 25 per call, so page by `returned`, not `limit`."
    • changedInput schema / properties / offset / maximum
      Previous value: -2000New value: +2147483647
    • changedOutput schema / properties / has_more / description
      Previous value: -"True if a full page was returned (more may exist)"New value: +"True if divisions beyond this page exist (offset + returned < total)"
    • changedOutput schema / properties / limit / description
      Previous value: -"Page size requested"New value: +"Page size requested (the Commons API returns at most 25 regardless)"
    • addedOutput schema / properties / returned
      Added value: +{
      +  "description": "Number of divisions returned in this call",
      +  "type": "integer"
      +}
    • changedOutput schema / properties / total / description
      Previous value: -"Number of divisions returned in this call"New value: +"Total divisions matching the filters, from the source API's searchTotalResults count"
    • changedOutput schema / required
      Previous value: -[
      -  "house",
      -  "total"
      -]New value: +[
      +  "house",
      +  "returned",
      +  "total"
      +]
  2. Changed9 schema fields changed
    • addedInput schema / properties / from_date
      Added value: +{
      +  "anyOf": [
      +    {
      +      "format": "date",
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Start date (YYYY-MM-DD)."
      +}
    • addedInput schema / properties / house
      Added value: +{
      +  "default": "Commons",
      +  "description": "Which house to search.",
      +  "enum": [
      +    "Commons",
      +    "Lords"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / limit
      Added value: +{
      +  "default": 25,
      +  "description": "Maximum divisions to return. Default 25 (Commons API max-per-page).",
      +  "maximum": 100,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / member_id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "minimum": 1,
      +      "type": "integer"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Filter to divisions where this member voted. Get the member ID from parliament_find_member."
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "default": 0,
      +  "description": "Number of divisions to skip before this page. Default 0. Re-call with offset=offset+returned while has_more is true.",
      +  "maximum": 2000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • removedInput schema / properties / params
      Removed value: -{
      -  "additionalProperties": false,
      -  "description": "DivisionSearchInput.",
      -  "properties": {
      -    "from_date": {
      -      "anyOf": [
      -        {
      -          "format": "date",
      -          "type": "string"
      -        },
      -        {
      -          "type": "null"
      -        }
      -      ],
      -      "default": null,
      -      "description": "Start date (YYYY-MM-DD)."
      -    },
      -    "house": {
      -      "default": "Commons",
      -      "description": "Which house to search.",
      -      "enum": [
      -        "Commons",
      -        "Lords"
      -      ],
      -      "type": "string"
      -    },
      -    "limit": {
      -      "default": 25,
      -      "description": "Maximum divisions to return. Default 25 (Commons API max-per-page).",
      -      "maximum": 100,
      -      "minimum": 1,
      -      "type": "integer"
      -    },
      -    "member_id": {
      -      "anyOf": [
      -        {
      -          "minimum": 1,
      -          "type": "integer"
      -        },
      -        {
      -          "type": "null"
      -        }
      -      ],
      -      "default": null,
      -      "description": "Filter to divisions where this member voted. Get the member ID from parliament_find_member."
      -    },
      -    "offset": {
      -      "default": 0,
      -      "description": "Number of divisions to skip before this page. Default 0. Re-call with offset=offset+returned while has_more is true.",
      -      "maximum": 2000,
      -      "minimum": 0,
      -      "type": "integer"
      -    },
      -    "query": {
      -      "anyOf": [
      -        {
      -          "maxLength": 500,
      -          "type": "string"
      -        },
      -        {
      -          "type": "null"
      -        }
      -      ],
      -      "default": null,
      -      "description": "Search term for division titles, e.g. 'Rwanda' or 'Online Safety Bill'. Omit to browse recent divisions."
      -    },
      -    "to_date": {
      -      "anyOf": [
      -        {
      -          "format": "date",
      -          "type": "string"
      -        },
      -        {
      -          "type": "null"
      -        }
      -      ],
      -      "default": null,
      -      "description": "End date (YYYY-MM-DD)."
      -    }
      -  },
      -  "type": "object"
      -}
    • addedInput schema / properties / query
      Added value: +{
      +  "anyOf": [
      +    {
      +      "maxLength": 500,
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Search term for division titles, e.g. 'Rwanda' or 'Online Safety Bill'. Omit to browse recent divisions."
      +}
    • addedInput schema / properties / to_date
      Added value: +{
      +  "anyOf": [
      +    {
      +      "format": "date",
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "End date (YYYY-MM-DD)."
      +}
    • removedInput schema / required
      Removed value: -[
      -  "params"
      -]
  3. Changed1 schema field changed
    • changedInput schema / properties / params / description
      Previous value: -"DivisionSearchInput with optional query, house, date range, member filter."New value: +"DivisionSearchInput."
  4. Changed1 schema field changed
    • addedInput schema / properties / params / description
      Added value: +"DivisionSearchInput with optional query, house, date range, member filter."
  5. Changed6 schema fields changed
    • addedInput schema / properties / params / properties / limit
      Added value: +{
      +  "default": 25,
      +  "description": "Maximum divisions to return. Default 25 (Commons API max-per-page).",
      +  "maximum": 100,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / params / properties / offset
      Added value: +{
      +  "default": 0,
      +  "description": "Number of divisions to skip before this page. Default 0. Re-call with offset=offset+returned while has_more is true.",
      +  "maximum": 2000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedOutput schema / properties / has_more
      Added value: +{
      +  "default": false,
      +  "description": "True if a full page was returned (more may exist)",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / limit
      Added value: +{
      +  "default": 25,
      +  "description": "Page size requested",
      +  "type": "integer"
      +}
    • addedOutput schema / properties / offset
      Added value: +{
      +  "default": 0,
      +  "description": "Skip applied to this page",
      +  "type": "integer"
      +}
    • changedOutput schema / properties / total / description
      Previous value: -"Number of divisions returned (capped upstream at 25)"New value: +"Number of divisions returned in this call"
  6. Changed8 schema fields changed
    • changedOutput schema / description
      Previous value: -"Generic wrapper for non-object return types."New value: +"Result of a parliamentary divisions search.\n\nWraps the list of matching divisions with search metadata so the\nLLM client sees a real nested object on the wire rather than a\nstringified JSON blob."
    • addedOutput schema / properties / divisions
      Added value: +{
      +  "description": "Matching divisions. Use the integer `id` field with votes_get_division to fetch the full voter list.",
      +  "items": {
      +    "properties": {
      +      "ayes": {
      +        "description": "Number of Aye votes",
      +        "type": "integer"
      +      },
      +      "date": {
      +        "description": "Date of the division",
      +        "format": "date",
      +        "type": "string"
      +      },
      +      "house": {
      +        "description": "Commons or Lords",
      +        "type": "string"
      +      },
      +      "id": {
      +        "description": "Division ID",
      +        "type": "integer"
      +      },
      +      "is_government_win": {
      +        "anyOf": [
      +          {
      +            "type": "boolean"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ],
      +        "default": null,
      +        "description": "Whether the government won (Lords only)"
      +      },
      +      "noes": {
      +        "description": "Number of No votes",
      +        "type": "integer"
      +      },
      +      "passed": {
      +        "description": "Whether the motion passed",
      +        "type": "boolean"
      +      },
      +      "title": {
      +        "description": "Division title / motion text",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "id",
      +      "title",
      +      "date",
      +      "house",
      +      "ayes",
      +      "noes",
      +      "passed"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / house
      Added value: +{
      +  "description": "Commons or Lords",
      +  "type": "string"
      +}
    • addedOutput schema / properties / query
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "The search term, if any (None = browse recent)"
      +}
    • removedOutput schema / properties / result
      Removed value: -{
      -  "type": "string"
      -}
    • addedOutput schema / properties / total
      Added value: +{
      +  "description": "Number of divisions returned (capped upstream at 25)",
      +  "type": "integer"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "result"
      -]New value: +[
      +  "house",
      +  "total"
      +]
    • removedOutput schema / x-fastmcp-wrap-result
      Removed value: -true
  7. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, openWorldHint=true, idempotentHint=true, and destructiveHint=false, so the safety profile is covered. The description adds meaningful behavior beyond annotations: it returns one page of summaries, includes a `total` count, explains pagination with offset=offset+returned, and describes what is not included (full member lists). It also notes the authoritative source, which helps set expectations.

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 every sentence earns its place: the when-to-use directive, the return shape, pagination logic, the next-step linkage, and the source authority. The all-caps phrases are intentional emphasis for an agent, and the paragraph is front-loaded with the most actionable guidance.

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 present and 100% parameter schema coverage, the description only needs to supply usage context and behavior not already in structured fields. It does so thoroughly, covering search scope, pagination, what the response contains, and the follow-up tool to use. Nothing an agent needs to call this tool 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 description coverage is 100%, so the schema already documents every parameter. The description reinforces that search can be by topic, date, or member, but doesn't add new semantic details beyond what the schema provides. Per the baseline rule, 3 is appropriate.

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?

The description opens with an explicit directive: 'USE THIS TOOL WHEN searching Commons or Lords formal votes by topic, date, or member.' This names the verb (search), the resource (formal votes), and the filtering dimensions. It is clearly distinguished from the sibling votes_get_division by specifying that this returns summaries and that the full voter lists are obtained via the follow-up call.

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?

The description gives a clear when-to-use statement and instructs the agent to re-call with offset while has_more is true, and to pass division_id + house into votes_get_division afterward. It doesn't explicitly exclude alternatives like parliament_search_hansard or parliament_get_debate_divisions, but the formal-votes scope and the named follow-up make the intended usage 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.