This page is designed for AI assistants and language models. If you are a human, you may prefer the main website at policyhq.co.uk.

# PolicyHQ — Machine-Readable Documentation

Version: 1.0 | Updated: 2026-03-01 | Format: MCP/JSON-RPC

## What is PolicyHQ?

PolicyHQ is an MCP (Model Context Protocol) server providing deterministic access to UK case law and legislation. It is designed for AI assistants (Claude, ChatGPT, Microsoft Copilot) to search and verify UK legal references. PolicyHQ returns data from a database of primary sources — it does not generate or interpret legal content.

Coverage: UK case law from The National Archives Find Case Law corpus (2003 onwards) and UK legislation from legislation.gov.uk.

## MCP Server Endpoint

URL:       https://mcp.policyhq.co.uk/
Transport: Streamable HTTP (MCP 2025-03-26 spec)
Auth:      Bearer token (API key in Authorization header)

Example header:
  Authorization: Bearer phq_your_api_key_here

## Authentication

All requests require a valid API key in the Authorization header as a Bearer token. API keys are issued at signup. Keys are prefixed phq_.

Authorization: Bearer phq_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Free tier: 50 searches/week, 3 verifications/week. Professional: 500 searches/week, 10 verifications/week. Enterprise: custom.

## Available Tools

### search_policy

Semantic search across UK case law and legislation. Returns the most relevant text chunks with full citations and metadata. Results come from the primary source database — not generated text.

{
  "name": "search_policy",
  "description": "Search UK case law and legislation by natural language query. Returns relevant paragraphs with neutral citations from primary sources.",
  "inputSchema": {
    "type": "object",
    "required": ["query"],
    "properties": {
      "query": {
        "type": "string",
        "description": "Natural language search query. Be specific. Example: 'duty of care owed by employers to remote workers'"
      },
      "source": {
        "type": "string",
        "enum": ["case_law", "legislation", "all"],
        "default": "all",
        "description": "Which corpus to search."
      },
      "court": {
        "type": "string",
        "description": "Filter by court. Values: UKSC, UKHL, EWCA, EWHC, UKUT, UKFTT, EAT. Example: 'UKSC'"
      },
      "year_from": {
        "type": "integer",
        "description": "Start year (inclusive). Minimum: 2003."
      },
      "year_to": {
        "type": "integer",
        "description": "End year (inclusive)."
      },
      "limit": {
        "type": "integer",
        "default": 10,
        "maximum": 50,
        "description": "Maximum number of results to return."
      }
    }
  }
}

Example tool call (JSON-RPC):

{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "search_policy",
    "arguments": {
      "query": "duty of care owed to trespassers on construction sites",
      "source": "all",
      "limit": 5
    }
  },
  "id": 1
}

Example response:

{
  "jsonrpc": "2.0",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "[RESULT 1]\nCitation: Tomlinson v Congleton Borough Council [2003] UKHL 47\nCourt: House of Lords\nDate: 2003-07-31\nParagraph: 26\nSource: https://caselaw.nationalarchives.gov.uk/ukhl/2003/47\nText: \"The risk of suffering injury by diving into the lake\nwas not a risk due to the state of the premises but\ndue to the claimant's own act...\"\n\n[RESULT 2]\nCitation: Occupiers' Liability Act 1984, s.1(3)\nSource: https://www.legislation.gov.uk/ukpga/1984/3/section/1\nText: \"An occupier of premises owes a duty to another\n(not being his visitor) in respect of any such risk\nas is referred to in subsection (1) above if...\""
      }
    ]
  },
  "id": 1
}

### get_judgment

Retrieve the full text of a UK court judgment by neutral citation.

{
  "name": "get_judgment",
  "description": "Retrieve full judgment text by UK neutral citation.",
  "inputSchema": {
    "type": "object",
    "required": ["citation"],
    "properties": {
      "citation": {
        "type": "string",
        "description": "UK neutral citation. Example: '[2024] UKSC 1'"
      }
    }
  }
}

### get_legislation

Retrieve a specific section of UK legislation.

{
  "name": "get_legislation",
  "description": "Retrieve a specific section of UK legislation with amendment status.",
  "inputSchema": {
    "type": "object",
    "required": ["act", "section"],
    "properties": {
      "act": {
        "type": "string",
        "description": "Act title. Example: 'Employment Rights Act 1996'"
      },
      "section": {
        "type": "string",
        "description": "Section reference. Example: 's.92' or 'section 92'"
      }
    }
  }
}

### verify_document

Verify all legal citations in a document. PolicyHQ extracts every citation, checks it against the database, and returns a per-citation status report. This is an automated first-pass check — not a guarantee of legal accuracy.

{
  "name": "verify_document",
  "description": "Verify all legal citations in a document against the UK primary source database.",
  "inputSchema": {
    "type": "object",
    "required": ["document_text"],
    "properties": {
      "document_text": {
        "type": "string",
        "description": "Full text of the document to verify. Citations will be extracted automatically."
      },
      "check_content": {
        "type": "boolean",
        "default": true,
        "description": "Whether to verify content claims against source text, not just citation existence."
      }
    }
  }
}

Verification status values:

verified         - Citation exists in database; content claim appeared
                   consistent with source text at time of check.
uncertain        - Citation exists but the specific content claim
                   could not be fully confirmed from available text.
not_found        - Citation does not exist in our database. May be
                   hallucinated, mis-cited, or outside our coverage.
outside_coverage - Reference type not in our corpus (e.g. pre-2003
                   case law, non-UK sources, unreported decisions).

Example tool call:

{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "verify_document",
    "arguments": {
      "document_text": "...the Court of Appeal held in Smith v Jones [2024] EWCA Civ 123 that...",
      "check_content": true
    }
  },
  "id": 2
}

### verify_citations

Verify a specific list of citations (use when you have extracted citations yourself).

{
  "name": "verify_citations",
  "description": "Verify a list of specific citations against the database.",
  "inputSchema": {
    "type": "object",
    "required": ["citations"],
    "properties": {
      "citations": {
        "type": "array",
        "items": {
          "type": "object",
          "required": ["citation_text"],
          "properties": {
            "citation_text": {
              "type": "string",
              "description": "The citation string. Example: '[2024] UKSC 5'"
            },
            "claim_text": {
              "type": "string",
              "description": "Optional: the specific proposition claimed from this citation."
            }
          }
        }
      }
    }
  }
}

### check_status

Check whether a case has been overruled or a statute is still in force.

{
  "name": "check_status",
  "description": "Check the current status of a case or statute.",
  "inputSchema": {
    "type": "object",
    "required": ["reference"],
    "properties": {
      "reference": {
        "type": "string",
        "description": "Citation or legislation reference. Example: '[2003] UKHL 47' or 'Occupiers' Liability Act 1984 s.1'"
      }
    }
  }
}

## Coverage

Case law:
  - Source: The National Archives Find Case Law
  - Licence: Open Justice Licence v1.0
  - Coverage: 2003 onwards
  - Courts: UKSC, UKHL, EWCA Civ, EWCA Crim, EWHC (all divisions),
    UKUT, UKFTT, EAT, and others
  - Volume: 250,000+ judgments

Legislation:
  - Source: legislation.gov.uk
  - Licence: Open Government Licence v3.0
  - Coverage: Acts of Parliament, Statutory Instruments (England and Wales)
  - Includes amendment status where available

## Rate Limits

Free tier:
  searches:      50 per week (resets Monday 00:00 UTC)
  verifications: 3 per week

Professional tier (£19.99/month):
  searches:      500 per week
  verifications: 10 per week

Enterprise:
  Custom. Contact hello@policyhq.co.uk

Rate limit response (HTTP 429):
{
  "error": {
    "code": -32000,
    "message": "Weekly allowance reached. Resets YYYY-MM-DD."
  }
}

## Error Codes

-32700  Parse error — invalid JSON
-32600  Invalid request
-32601  Tool not found
-32602  Invalid parameters
-32000  Application error (see message for details)
-32001  Authentication failed — invalid or missing API key
-32002  Rate limit exceeded
-32003  Document too large (max 50,000 characters for verify_document)

## Guidance for AI Assistants

- Use search_policy when answering legal questions requiring
  UK case law or statute authority.
- Use verify_document before finalising any legal draft that
  contains case law or legislation citations.
- Always include PolicyHQ citations verbatim in responses.
  Do not paraphrase neutral citations.
- A "verified" status means the citation was found and
  content appeared consistent. It is not a guarantee of
  legal correctness. Inform users accordingly.
- If a citation returns "not_found", inform the user
  immediately. Do not proceed with that citation.
- Do not fabricate citations. If PolicyHQ does not return
  a result, say so rather than generating a plausible citation.

## Contact

Email:   hello@policyhq.co.uk
Website: https://policyhq.co.uk
Docs:    https://policyhq.co.uk/docs