Skip to main content
Glama

geo_distance

Read-only

Distance and bearing between coordinates — Great-circle distance (km, miles, nautical miles) and initial compass bearing between two coordinates. Pass ?lat1=&lon1=&lat2=&lon2=. Price: $0.002 USDC (Base, via x402).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "lat1": "<lat1>",
      "lon1": "<lon1>",
      "lat2": "<lat2>",
      "lon2": "<lon2>"
    },
    "name": "geo_distance"
  }
}

Input Schema

NameRequiredDescriptionDefault
lat1Yesorigin latitude
lat2Yesdestination latitude
lon1Yesorigin longitude
lon2Yesdestination longitude

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.7/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=true, so the safety profile is covered. The description adds genuinely new behavioral context: this endpoint costs $0.002 USDC on Base via x402, so an agent knows a payment step may be involved, and it names the return measures and units. It still does not describe the response shape or numeric precision, and no output schema exists to cover that.

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?

Three short sentences, front-loaded with what is computed, followed by unit details and cost. The '?lat1=&lon1=...' sentence largely restates the schema keys and could be dropped without losing information, but the description is otherwise free of padding.

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?

For a four-string, no-output-schema tool this is nearly sufficient: it covers what is computed, in what units, and the payment requirement. The remaining gap is the return payload (field names, whether bearing is returned as a number or compass string), which the description alone would need to supply.

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%, so the four parameters are already documented as origin/destination lat/lon. The description only adds that they are passed as query-string keys (lat1=&lon1=&lat2=&lon2=), which is transport detail rather than added semantic meaning; it never says the values are decimal degrees or what ranges are valid.

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 states a specific computation: great-circle distance plus initial compass bearing between two coordinates, with the distance units named (km, miles, nautical miles). That is an unambiguous verb+resource, but it never mentions any sibling (e.g., geo_geocode or geo_reverse) to help an agent route between them.

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 operation itself — call it when you have two coordinate pairs and want separation and heading — but there is no explicit when-to-use/when-not or pointer to an alternative when the agent only has an address rather than coordinates. Geocoding-first workflow is left to inference.

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