Skip to main content
Glama
dwain-barnes

MCP Server Police UK

by dwain-barnes

get_outcomes_for_crime

Retrieve the outcome of a UK crime using its 64-character unique persistent ID. Get closure details such as court results or police actions for specific crimes.

Instructions

Retrieve outcomes for a specific crime by persistent ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
persistent_idYesThe 64-character unique identifier for the crime

Implementation Reference

  • Handler function that executes the 'get_outcomes_for_crime' tool logic. Extracts the 'persistent_id' from args and calls the UK Police API endpoint 'outcomes-for-crime/{persistent_id}'.
    async function getOutcomesForCrime(args: any) {
      const { persistent_id } = args;
      const endpoint = `outcomes-for-crime/${persistent_id}`;
      return await makeApiRequest(endpoint) || {};
    }
  • Schema/input validation definition for the 'get_outcomes_for_crime' tool, specifying the required 'persistent_id' string parameter.
    {
      name: 'get_outcomes_for_crime',
      description: 'Retrieve outcomes for a specific crime by persistent ID',
      inputSchema: {
        type: 'object',
        properties: {
          persistent_id: { type: 'string', description: 'The 64-character unique identifier for the crime' }
        },
        required: ['persistent_id']
      }
    },
  • src/index.ts:447-456 (registration)
    Registration mapping that links the tool name 'get_outcomes_for_crime' to its handler function getOutcomesForCrime.
    const toolFunctions = {
      get_street_level_crimes: getStreetLevelCrimes,
      get_street_level_outcomes: getStreetLevelOutcomes,
      get_crimes_at_location: getCrimesAtLocation,
      get_crimes_no_location: getCrimesNoLocation,
      get_crime_categories: getCrimeCategories,
      get_last_updated: getLastUpdated,
      get_outcomes_for_crime: getOutcomesForCrime,
      get_list_of_forces: getListOfForces,
      get_force_details: getForceDetails,
  • Helper utility used by getOutcomesForCrime to make HTTP GET requests to the data.police.uk API.
    async function makeApiRequest(endpoint: string, params?: Record<string, any>) {
      const baseUrl = 'https://data.police.uk/api';
      const url = `${baseUrl}/${endpoint}`;
      
      try {
        const response = await axios.get(url, { params, timeout: 10000 });
        return response.data;
      } catch (error) {
        console.error(`API request failed: ${error}`);
        return null;
      }
    }
Behavior2/5

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

No annotations are provided, so the description bears full responsibility for behavioral disclosure. It does not state whether the operation is read-only, idempotent, or safe. It does not mention authentication, rate limits, or error behavior (e.g., what happens if the persistent ID is invalid).

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 description is a single sentence with no wasted words. It is front-loaded with the key action. However, it could be slightly more informative without sacrificing conciseness.

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?

Given the low parameter count and no output schema, the description is minimally complete. It conveys the core functionality but lacks context on response format, possible error states, or any prerequisites. For a simple tool, this is adequate but not thorough.

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 the parameter 'persistent_id' described as 'The 64-character unique identifier for the crime'. The description echoes 'by persistent ID' but adds no additional semantics. Baseline 3 is appropriate as the description adds marginal value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Retrieve outcomes for a specific crime by persistent ID', which is a specific verb+resource combination. It distinguishes from sibling tools like 'get_street_level_outcomes' by specifying 'by persistent ID' and 'specific crime'. However, it could be more explicit about how this differs from similar retrieval tools.

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

Usage Guidelines2/5

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

There is no guidance on when to use this tool versus alternatives like 'get_street_level_outcomes' or 'get_crimes_at_location'. No when-not-to-use information or prerequisites are provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/dwain-barnes/police-uk-api-mcp-server'

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