Skip to main content
Glama

Measure distance, area, radius or buffer

measure
Read-onlyIdempotent

Use this when the user wants a straight-line (as the crow flies) distance between places with midpoint and bearing, the length of a drawn line, the area and perimeter of a polygon, a circle of a given radius around a place, or a buffer of a given width around a drawn line or polygon. Distances and areas are geodesic on the WGS 84 ellipsoid, buffers are built in a local equidistant projection; every figure states its unit (m, km, m², ha, km²). method "distance" takes 2 or more points or place names, or a line in geometry; "area" takes 3 or more points or a polygon in geometry; "radius" takes a center and radius_m; "buffer" takes a geometry and radius_m. Not a road or travel distance. Returns the numbers, a map and GeoJSON, KML, Shapefile zip or CSV downloads. Never use the user's current location unless they type it. Give the place as the user names it (place name, address or coordinates): this tool locates it, so find_places is not needed first. Download links build their file when opened; no file is saved. Never pass these links to open_gis_file: list every format the user needs in formats, in this one call.

Input Schema

NameRequiredDescriptionDefault
centerNoFor radius: the center, a point or a place name. The place the user asks about, not the user's own location.
methodYesWhat to measure.
pointsNoFor distance (2+) and area (3+): points or place names in order. The place the user asks about, not the user's own location.
formatsNoDownload formats.
geometryNoA drawn geometry as GeoJSON (Point, LineString, Polygon, MultiLineString or MultiPolygon, WGS 84 longitude, latitude), or a Feature holding one.
radius_mNoFor radius and buffer: the distance in metres (convert km or miles to metres first).

Output Schema

NameRequiredDescriptionDefault
codeNoError code, on errors only.
hintNoWhat to do next, on errors only.
messageNoError message, on errors only.
sourcesNoData sources and licences of the result.
downloadsNoDownload links; each builds its file when opened.
truncatedNo
totalFoundNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already cover read-only/idempotent/non-destructive, so the description adds the parts annotations cannot: geodesic math on WGS 84 for distances and areas versus a local equidistant projection for buffers, unit disclosure for every figure, and the non-obvious download-link behavior (the file is built on open, nothing is persisted). The output contract is described only briefly ('the numbers, a map and GeoJSON, KML...'), which the output schema covers anyway, so a small gap remains rather than a contradiction.

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?

Front-loaded with the capability and mode list, then rules and exclusions, so an agent gets the essentials in the first sentence. It is dense and the closing run of imperatives (location, place naming, download links, open_gis_file) is somewhat stream-of-consciousness, though essentially every clause carries distinct operational information.

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

Completeness5/5

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

For a four-mode, six-parameter tool with nested geometry, this leaves nothing an agent needs unresolved: mode selection, input formats, units, projection choice, precision limits (radius_m max 2,000,000), download behavior, and the two sibling traps are all addressed. The output schema covers return shape, so the short mention of returns is sufficient.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3, but the description adds genuine semantics the schema cannot express: it maps each method value to the specific parameter set it consumes, which matters because only 'method' is required and the conditional requirements are invisible in the schema. It also states the minimum point counts and the metres-only unit convention for radius_m, plus multi-format batching guidance.

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 set (measure distance, line length, area/perimeter, radius circle, buffer) with the exact outputs per mode (midpoint, bearing, perimeter). It explicitly carves out the alternative it is not — 'Not a road or travel distance' — which separates it cleanly from get_route and get_travel_area, and the method enum names are all defined in prose.

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

Usage Guidelines5/5

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

Gives explicit per-method trigger conditions (distance = 2+ points or a line; area = 3+ points or polygon; radius = center + radius_m; buffer = geometry + radius_m) and explicit exclusions ('Not a road or travel distance'). It also resolves the two most likely sibling confusions in advance: find_places is not needed first, and download links must never be routed to open_gis_file.

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.

Resources