Skip to main content
Glama

Duo Data Utilities: IBAN, ISIN, VAT & Tax ID, Barcode, Timezone, Geo APIs

Plus code (Open Location Code) encoder and decoder

plus_code_encode_decode
Read-onlyIdempotent

Plus code (Open Location Code) encoder and decoder: encode coordinates as a plus code at a chosen length, or decode a full code back to its bounding box and centre. Also shortens a full code against a reference coordinate and recovers a shortened code given a reference, which is how plus codes are normally exchanged in text. Returns code length, precision in metres and validity. Price: $0.05 per successful call, paid over x402 (USDC on Base).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
opNoencode (default), decode, shorten or recover. Accepted: encode, decode, shorten, recover.
latNoLatitude for op=encode. Accepted: a number between -90 and 90.
lonNoLongitude for op=encode. Accepted: a number between -180 and 180.
codeNoPlus code for decode, shorten or recover. Accepted: at most 20 characters.
lengthNoInteger code length for op=encode: one of 2,4,6,8,10 (default),11,12,13,14,15. Other integers in 2-15 are 400 UNSUPPORTED_VALUE. Accepted: one of 2,4,6,8,10,11,12,13,14,15.
ref_latNoReference latitude for op=shorten/recover. Accepted: a number between -90 and 90.
ref_lonNoReference longitude for op=shorten/recover. Accepted: a number between -180 and 180.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already establish readOnly, idempotent, and non-open-world behavior, so the safety profile is covered. The description adds material context beyond that: a per-call price of $0.05 paid over x402 in USDC on Base, which is an auth/payment requirement an agent must know before calling. It also states the shape of the returned data (code length, precision in metres, validity).

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 sentences, purpose front-loaded first, with operation semantics before the pricing note. The prose is dense but every sentence carries distinct information; slightly long for the value delivered, but nothing is redundant.

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?

No output schema exists, and the description compensates by naming the return fields (code length, precision, validity). Payment and the default op=encode are covered by the description and schema respectively. Only minor gaps remain, such as what an invalid code yields or error-shape expectations.

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%, and each property already documents its accepted values and which op it belongs to, so the schema does the heavy lifting. The description reinforces the op-to-parameter mapping (encode at a chosen length, shorten/recover against a reference coordinate) but adds no format or constraint detail beyond the schema. Baseline 3 is appropriate.

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?

Names the specific resource (Plus code / Open Location Code) and enumerates the four concrete operations it performs: encode, decode, shorten, recover. An agent can distinguish it from the similarly-named sibling geohash_encode_decode without opening the schema, since the code system is stated explicitly.

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?

Explains the context for each operation, notably that shorten/recover is 'how plus codes are normally exchanged in text', which tells an agent when those ops are relevant. However, it offers no explicit when-not-to-use guidance and never names an alternative sibling (e.g. geohash for a different grid system).

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.