Skip to main content
Glama

Calculate the mileage allowance

calculate_mileage_allowance
Read-only

Calculate the tax-free business mileage allowance for a year at HMRC's approved mileage rates for a car or van, motorcycle or bicycle, including the passenger rate, and the tax it saves at the basic or higher rate.

Input Schema

NameRequiredDescriptionDefault
taxBandNoIncome tax band, for the saving; defaults to basic
vehicleTypeNoDefaults to car (cars and vans)
passengerTripsNoBusiness trips with a passenger
annualBusinessMilesYesBusiness miles in the year
averageMilesPerPassengerTripNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false and openWorldHint=false, so the safety profile is covered. The description adds real domain context beyond that: the rates are HMRC-approved and tax-free, the passenger rate is included, and the saving depends on tax band — useful behavioural framing for a pure-computation tool. It stops short of disclosing the 10,000-mile rate threshold or rounding rules.

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?

A single dense sentence with the core action front-loaded and every clause carrying information (rates, vehicle scope, passenger rate, tax saving). No filler or repetition of the title.

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?

With annotations covering the read-only safety profile and no output schema to explain, the description gives enough to call the tool correctly. It leaves some gaps — defaults for taxBand/vehicleType are only in the schema, and the mileage threshold that changes the rate is never mentioned — but nothing critical is missing.

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 80%, so the baseline is 3. The description loosely maps to parameters (vehicle types → vehicleType, passenger rate → passengerTrips, basic/higher rate → taxBand), but it adds no syntax, defaults or units, and says nothing about averageMilesPerPassengerTrip, which is undocumented in both the schema and the description.

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?

States a specific verb and resource (calculate the business mileage allowance) and pins the domain precisely: HMRC approved mileage rates, car/van/motorcycle/bicycle, passenger rate, and basic/higher rate tax saving. An agent can distinguish this from log_mileage_trip or get_mileage_summary purely from the description.

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

Usage Guidelines3/5

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

Usage is implied by the scope (an annual allowance computation) but there is no explicit when-to-use guidance, no statement of when NOT to use it, and no pointer to the obvious siblings get_mileage_summary and log_mileage_trip, which an agent could easily confuse it with.

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.