Skip to main content
Glama
paulieb89

UK Legal Research MCP Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault

No arguments

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
extensions
{
  "io.modelcontextprotocol/ui": {}
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
judgment_get_headerA

Get metadata for a UK court judgment: parties, judges, neutral citation, court, dates.

Use case_law_search to find the slug, then call this for orientation before reading specific paragraphs via judgment_get_paragraph.

judgment_get_indexA

Get the paragraph navigation index for a UK court judgment.

Returns eId: first_line pairs for every paragraph. Use this to discover paragraph identifiers, then call judgment_get_paragraph to read specific ones.

judgment_get_paragraphA

Get a single paragraph from a UK court judgment by its LegalDocML eId.

Use judgment_get_index first to discover available eIds. Returns the paragraph XML content (400–1,700 tokens typical).

case_law_searchA

Search UK case law via the TNA Find Case Law API.

Returns paginated judgment summaries: neutral citations, court, dates, stable URIs. Use the judgment://{slug}/header resource to inspect a result, then judgment://{slug}/index to discover paragraphs and judgment://{slug}/para/{eId} to read individual paragraphs. For content-based discovery within a judgment, use case_law_grep_judgment.

case_law_grep_judgmentA

Find paragraphs in a single judgment whose text matches a pattern.

Returns a list of {eId, snippet, match} hits — small per-paragraph snippets centred on the match — so the LLM can decide which full paragraphs to read via judgment://{slug}/para/{eId}.

Use this when answering content-based questions ("what did the judges say about negligence?", "find the test for foreseeability", "did this case cite Donoghue?") rather than navigating by paragraph number (which uses the index resource).

Pattern is regex; if it doesn't compile, falls back to literal substring search.

legislation_searchA

Search UK legislation on legislation.gov.uk.

Returns ranked results: title, type, year, number, and legislation.gov.uk URL. Use legislation_get_toc to explore structure, then legislation_get_section for provisions.

legislation_get_sectionA

Retrieve a specific section of a UK Act or Statutory Instrument.

Returns the full section text, territorial extent, in-force status, and prospective flag. Content is capped per max_chars (default 10,000, ~2,500 tokens) — raise max_chars for unusually long definition sections. Check content_truncated in the response to see if it was cut.

IMPORTANT: Always check extent — a section may apply to England & Wales but not Scotland or Northern Ireland.

Alternative: read the resource template legislation://{type}/{year}/{number}/section/{section} to get raw CLML XML directly. Use this tool when you want the parsed structured response (extent, in-force, version_date) instead of raw XML.

legislation_get_tocA

Retrieve the table of contents for a UK Act or SI.

Returns structural elements (parts, chapters, sections, schedules) with XML id and title, e.g. 'section-47: Definitions'. When calling legislation_get_section, pass only the numeric part — use '47', not 'section-47'.

Large statutes (Companies Act 2006 has 1300+ items) are paginated via offset/limit. Check has_more and total_items on the response.

Alternative: read the resource template legislation://{type}/{year}/{number}/toc for the full TOC as a newline-separated id: title string (no pagination). Use this tool when you need the structured LegislationTOC response with offset/limit/has_more for stepping through Companies-Act-scale lists.

parliament_search_hansardA

Search Hansard for parliamentary debates, questions, and speeches.

Returns contributions from MPs and Lords including date, party, debate title, and text (capped at 3000 chars per contribution). Useful for understanding legislative intent or political context.

parliament_vibe_checkA

Assess the likely parliamentary reception of a policy proposal.

Searches Hansard for relevant debate contributions, then uses LLM sampling to classify sentiment and extract supporters, opponents, and key concerns.

Degrades gracefully if sampling is unavailable — returns contributions only.

parliament_find_memberA

Search for a current or former MP or Lord by name.

Returns all members matching the name query, each with the integer id required by parliament_member_debates and parliament_member_interests, plus party, constituency, house, and current-sitting status.

parliament_member_debatesA

Retrieve Hansard contributions by a specific member, optionally filtered by topic.

Use parliament_find_member first to obtain the integer member ID. Each contribution's text field is capped at 3000 characters.

parliament_member_interestsA

Look up registered financial interests for a member of Parliament.

Returns ONE PAGE of interests (default 20, caller controls via limit). For prolific members (big donors, many directorships, extensive land holdings), re-call with offset=offset+returned while has_more is true to paginate. Description text is capped per max_description_chars; raise it for forensic provenance work that needs the full narrative.

Use parliament_find_member first to obtain the integer member_id.

parliament_search_petitionsA

Search UK Parliament petitions by keyword.

Returns petition title, state, signature count, and dates for government response or parliamentary debate if applicable.

bills_search_billsA

Search UK parliamentary bills by keyword, session, house, or legislative stage.

Returns a paginated page of bill summaries including title, current stage, and whether it has become an Act. Use bills_get_bill with the bill ID for full detail.

bills_get_billA

Get full detail for a specific parliamentary bill.

Returns sponsors, current stage, long title, summary, and Royal Assent date if enacted. Summary text is capped per max_summary_chars — check summary_truncated in the response to see if it was cut.

votes_search_divisionsA

Search parliamentary divisions (votes) in the Commons or Lords.

Returns division summaries including title, date, vote counts, and whether the motion passed. Use votes_get_division with the division ID for full voter lists.

votes_get_divisionA

Get full detail for a parliamentary division including how each member voted.

Voter lists are truncated to 100 per side to fit response limits. Total voter counts are always accurate regardless of truncation.

committees_search_committeesA

Search or list UK parliamentary select committees.

Returns committee names, house, and active status. Use committees_get_committee with the committee ID for membership detail.

committees_get_committeeA

Get detail for a parliamentary committee including current membership.

Fetches committee metadata and member list in parallel.

committees_search_evidenceA

Search oral and written evidence submitted to a parliamentary committee.

Returns ONE PAGE of evidence (default 20). Free-text titles are capped per max_title_chars; witness lists are capped at 10 per item. For committees with many submissions, re-call with offset=offset+returned while has_more is true.

citations_parseA

Extract and classify all OSCOLA legal citations from free text.

Identifies: neutral citations ([2024] UKSC 12), law reports ([2024] 1 WLR 100), legislation sections (s.47 Companies Act 2006), SIs (SI 2018/1234), and retained EU law (Regulation (EU) 2016/679).

Ambiguous citations (e.g. bare [2024] EWHC without division) are optionally disambiguated via LLM sampling. Resolves citations to TNA / legislation.gov.uk URLs.

citations_resolveA

Parse and resolve a single OSCOLA citation to its canonical URL.

Supports: neutral citations, SIs, legislation sections, retained EU law. Returns parsed fields and resolved_url if resolvable. Raises ValueError if no recognised citation is found in the input.

citations_networkA

Map all citations within a judgment — cases cited, legislation referenced, SIs, EU law.

Fetches the judgment XML from TNA and parses all OSCOLA citations within it. Returns citations grouped by type for easy analysis. Each bucket is de-duplicated and sorted.

hmrc_get_vat_rateA

Look up the UK VAT rate for a commodity or service type.

Returns the rate category (standard 20%, reduced 5%, zero 0%, exempt), effective date, and any relevant conditions or exceptions. Uses a static lookup table current as of 22 Nov 2023 (Autumn Statement). Rates may have changed — always verify against GOV.UK for recent Budgets.

hmrc_check_mtd_statusA

Check a business's Making Tax Digital VAT mandate status via the HMRC API.

NOTE: Connects to the HMRC sandbox by default. Set HMRC_API_BASE env var to 'https://api.service.hmrc.gov.uk' for production. Requires HMRC_CLIENT_ID and HMRC_CLIENT_SECRET environment variables (OAuth 2.0). Returns whether the business is mandated for MTD, effective date, and trading name.

hmrc_search_guidanceA

Search GOV.UK for HMRC tax guidance documents.

Returns matching guidance titles, URLs, summaries, and last-updated dates. Searches the official GOV.UK content API filtered to HMRC publications.

list_promptsA

List all available prompts.

Returns JSON with prompt metadata including name, description, and optional arguments.

get_promptA

Get a prompt by name with optional arguments.

Returns the rendered prompt as JSON with a messages array. Arguments should be provided as a dict mapping argument names to values.

Prompts

Interactive templates invoked by user choice

NameDescription
legislation_summarise_actSummarise a UK Act of Parliament or Statutory Instrument. Produces a structured legal summary covering purpose, key definitions, operative provisions, territorial extent, and commencement status.
legislation_compare_legislationCompare two pieces of UK legislation on a specific topic. Useful for comparing original Act vs amending SI, or equivalent provisions across jurisdictions (e.g. England vs Scotland).
parliament_policy_vibe_checkAssess the likely parliamentary reception of a policy proposal. Searches Hansard for relevant recent debates and analyses political dynamics.
parliament_member_position_analysisAnalyse a specific parliamentarian's stated position on a topic. Uses parliament_find_member and parliament_member_debates to build a picture of a member's views from their own words.

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/paulieb89/uk-legal-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server