Skip to main content
Glama
gsampaio-rh

NHS MCP Server

by gsampaio-rh

Prescribing Spending Trends

prescriptions_spending_trends

Analyze monthly prescribing trends for any drug or BNF category, filtering by organization to see items, quantities, and costs over the last 5 years.

Instructions

Analyse prescribing spending trends over time for a drug or BNF category. Data sourced from OpenPrescribing (last 5 years of monthly data). Returns monthly items, quantities, and costs. Can be filtered by organisation (Sub-ICB Location or practice).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
orgNoSpecific organisation code to filter by (e.g., 'QWO' for West Yorkshire ICB, 'A81001' for a practice)
bnf_codeYesBNF code to analyse (e.g., '0212' for lipid-regulating drugs, '0407010H0' for Paracetamol). Supports section, paragraph, chemical, and presentation codes.
org_typeNoOrganisation type to group by: 'sicbl' for Sub-ICB Locations or 'practice' for GP practices
Behavior4/5

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

With no annotations provided, the description carries the full burden. It discloses the data source (OpenPrescribing), the time range (last 5 years), the granularity (monthly), and the returned fields (items, quantities, costs). It also mentions the filtering option by organisation type. This is more than basic transparency, though it does not discuss pagination or error behavior.

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 four sentences long, each contributing essential information (purpose, data source, return values, filtering). It is front-loaded with the main action and avoids unnecessary detail. No filler or repetition.

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

Completeness4/5

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

The tool has 3 parameters (one required) and no output schema, so the description must explain what the tool returns. It covers the monthly items, quantities, costs, and the organisation filter. However, it does not explicitly state that the output is a time series or how the data is aggregated by org type, but this is partially implied. Overall, it is sufficiently complete for an analysis tool, with a minor gap.

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 explains all parameters thoroughly (bnf_code, org, org_type) with examples. The description adds no new parameter-level meaning beyond restating 'drug or BNF category' and 'filtered by organisation.' Hence, it does not exceed the baseline.

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 clearly states the tool's function: 'Analyse prescribing spending trends over time for a drug or BNF category.' The verb 'analyse' plus the resource 'prescribing spending trends' and the temporal scope ('over time') is specific. It distinguishes itself from siblings like prescriptions_search or cost_analysis by emphasizing the time trend aspect.

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 provides clear context: this tool is for analysing trends over time, using data from OpenPrescribing, filtering by organisation. However, it does not explicitly mention when not to use it or point to alternative tools for different use cases (e.g., cost comparison). The 'over time' phrasing implies the intended use, but exclusions are absent.

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/gsampaio-rh/nhs-mcp'

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