Skip to main content
Glama

Reverse geocode GPS to address

bus_reverse_geocode
Read-onlyIdempotent

Convert WGS-84 latitude and longitude to a full Chinese postal address with province, city, district, township, and administrative codes.

Instructions

Convert WGS-84 lat/lng to a Chinese postal address (province, city, district, township, formatted address).

Useful when you have raw GPS coordinates and need a human-readable place name, or the citycode/adcode to pass to other tools.

Args:

  • lat (string, required): WGS-84 latitude, decimal, e.g. '31.230416'

  • lng (string, required): WGS-84 longitude, decimal, e.g. '121.473701'

  • response_format ('markdown' | 'json')

Returns (json): { "formatted": "上海市黄浦区...", "province": "上海市", "city": "上海市", "district": "黄浦区", "township": "南京东路街道", "citycode": "021", "adcode": "310101" }

For municipalities (Shanghai/Beijing/Tianjin/Chongqing) the upstream emits an empty 'city' value; this tool back-fills it with 'province' so the field is always a usable string.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
latYesLatitude, WGS-84, e.g. '31.230416'
lngYesLongitude, WGS-84, e.g. '121.473701'
response_formatNoOutput format: 'markdown' for human-readable text, 'json' for full structured datamarkdown
Behavior4/5

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

Annotations already indicate read-only and idempotent. The description adds a specific edge case: for municipalities, the upstream emits empty 'city' but the tool back-fills with 'province'. This is valuable beyond annotations.

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?

Description is well-structured: main sentence, usage guide, args list, return structure, special note. No redundant content, front-loaded with key info.

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?

Given the tool's simplicity (3 params, flat structure), the description fully covers purpose, parameters, return format, and edge cases. No output schema needed due to detailed return description.

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

Parameters5/5

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

Schema coverage is 100%, but description adds examples, explains coordinate system (WGS-84), and details the response format including the back-fill behavior for city. This greatly enhances parameter understanding.

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 action: 'Convert WGS-84 lat/lng to a Chinese postal address'. The verb 'convert' and resource 'lat/lng to address' are explicit, and the tool is distinct from bus-route siblings.

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?

Explicitly says 'Useful when you have raw GPS coordinates and need a human-readable place name, or the citycode/adcode to pass to other tools.' Provides clear context, though no exclusion or alternative is needed.

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/PeanutSplash/chelaile-mcp'

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