Skip to main content
Glama

UK Data: UK government and law

mp_lookup

Read-onlyIdempotent

Find the MP for a postcode, or search current MPs and peers by name. (cost: 1 credit)

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "mp_lookup"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameNostring
limitNonumber
postcodeNostring

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.9/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, openWorldHint, idempotentHint and destructiveHint=false, so the safety profile is covered. The description adds genuinely useful context — a cost of 1 credit per call — but says nothing about result shape, pagination, or what happens with an invalid postcode, which matters for an open-world lookup.

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?

One sentence for the two modes with the cost note appended in parentheses — front-loaded and zero waste.

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

Completeness3/5

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

For a three-parameter lookup with no required fields and no output schema, the definition should clarify the mutual-exclusivity or fallback behavior between name and postcode and the meaning of 'limit'. The cost disclosure is a plus, but these gaps keep it at minimum viable.

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 nominally 100%, but the schema descriptions are placeholders ('string', 'number'), so the description is the only real source of meaning for name and postcode. It clarifies those two but leaves 'limit' completely unexplained and never states that at least one of name/postcode should be provided.

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 names a specific verb and resource ('Find the MP for a postcode') plus a second mode ('search current MPs and peers by name'), so an agent knows exactly what the tool returns and can distinguish it from the unrelated sibling tools like govuk_search or legislation_search.

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?

It implicitly tells the agent which parameter selects which behavior: postcode for a constituency lookup, name for a search. There are no explicit exclusions and no guidance on what happens when neither is supplied, but the input-mode routing is 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.

Resources