Skip to main content
Glama

Call an API

call

Route a call to the Routavo network, meter it, and return the result. Give either a provider id from discover(), or a capability and let Routavo pick using its published routing rule. Optional max_price and max_latency_ms constrain the choice. Failed calls are recorded but cost nothing.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
planNoInstead of one call, a sequence of up to 8 steps: [{ id, capability | provider, arguments, max_price?, max_latency_ms? }]. A later step may take a value from an earlier one with { "$ref": "<step id>.output.<path>" }, e.g. { "$ref": "geo.output.results[0].lat" }. The whole plan is quoted before anything runs; with dry_run it is only quoted. Steps run in order and stop at the first failure. Each step returns its own receipt and the response carries one total.
batchNoInstead of one arguments object, up to 50 of them for the same capability or provider. Run in parallel, each with its own receipt, one total. Failed items cost nothing and do not stop the others.
budgetNoA task budget: { id, max }. Spend under this id is tracked across any number of calls, plans and batches, and a call that would take it past max is refused with code "budget". { id, statement: true } returns what the budget has spent and the receipts behind it.
fieldsNoReturn only these output paths, e.g. ["results.name", "results.lat", "results.lng"]. Saves tokens; the receipt still hashes the full answer.
quorumNoAsk 2 or 3 providers the same question and get an agreement score with every answer. Each provider is charged. Refused if fewer providers clear your constraints, so quote it first with dry_run.
recipeNoA named, published plan, e.g. "weather_for_place". Give its arguments and it runs the steps for you, quoted first, with the last step's output on top. discover() lists recipes with their inputs and estimated price.
walletNoYour wallet address, asserted. Attributes metering and a daily cap on the free tier; it proves nothing. To pay from a balance, prove the wallet once at /api/wallet and send the key it returns as wallet_key or as Authorization: Bearer rw_...
dry_runNoQuote only: which provider would be chosen, at what price, with what latency, and why. Nothing is called, charged or counted.
paymentNoPay this one call with x402: { rail: "x402", payload: <PaymentPayload> }, an EIP-3009 authorization to the pay-to address for at least the price, signed by your wallet. The requirements to sign are in discover() and in any payment_required error. A facilitator verifies and settles it; the receipt carries the transaction.
failoverNoDefault true when routing by capability: if the chosen provider fails, the next eligible one is tried and only the one that answered is charged. Set false to fail fast.
providerNoProvider id, e.g. "open-meteo.geocode". Omit to route by capability.
argumentsNoArguments in the capability contract shape from discover(). Learn geocode once; every provider behind it takes the same input and returns the same output.
max_priceNoDo not route above this price per call, e.g. "0.0030"
max_totalNoFor a plan: do not run if the quoted total exceeds this, e.g. "0.0100".
capabilityNoCapability to route on, e.g. "geocode". Ignored when provider is given.
wallet_keyNoA wallet key (rw_...) from /api/wallet. Proves the wallet, and calls are paid from its deposited USDC balance. Prefer sending it as the Authorization: Bearer header.
max_latency_msNoDo not route to a provider slower than this p50
idempotency_keyNoYour own id for this call, up to 64 characters. A retry with the same key within 24 hours returns the same result and receipt and is never charged again. The output is kept for those 24 hours only because you asked for replay.

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden of disclosure, and it does address the key behavioral trait: calls are metered, and 'failed calls are recorded but cost nothing.' It doesn't explicitly state that successful calls incur charges or require a wallet, but 'meter it' plus the failure-cost note makes the paid nature clear. This is much more transparent than a bare 'call an API' description.

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?

Three short sentences front-load the core action, routing modes, constraints, and failure-cost behavior, with no filler. Every sentence earns its place, and the most important information appears first.

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

Completeness3/5

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

For an 18-parameter tool with plans, batches, budgets, quorum, payment, failover, and idempotency, the description only orients the agent to the single-call mode and two routing parameters. The schema is rich and 100% covered, so nothing is hidden, but the description fails to signal the tool's advanced capabilities and never mentions output structure. A more complete overview would at least hint at the plan/batch/budget/payment modes.

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 meaning beyond the schema by linking provider ids to discover() and explaining capability routing via 'published routing rule.' It also identifies max_price and max_latency_ms as the choice-constraining parameters, which helps the agent understand how the parameters work together. This goes slightly beyond simply repeating the schema's per-parameter descriptions.

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 opens with a specific verb-resource pair: 'Route a call to the Routavo network, meter it, and return the result.' It then explains the two invocation modes (provider id vs. capability), which clearly distinguishes it from siblings like discover, dispute, and verify. It is not a tautology and tells the agent exactly what the tool does.

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?

The description explicitly directs agents to 'give either a provider id from discover(), or a capability and let Routavo pick using its published routing rule,' which is clear when-to-use guidance for the two main invocation styles. It also names max_price and max_latency_ms as constraints, helping the agent choose parameters. It doesn't explicitly contrast with dispute or verify, but those are not natural alternatives to calling an API.

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.

TDQS

A4.5/5.0
Disambiguation5/5

Each tool occupies a clear stage in the workflow: discover searches for providers, call executes the metered call, verify checks receipts, and dispute handles post-call issues. Even though discover and call both reference capabilities, their purposes are distinct and unlikely to be confused.

Naming Consistency5/5

All four tools use the same concise single-verb imperative style: call, discover, dispute, verify. The pattern is consistent and predictable, with no mixed conventions or misleading names.

Tool Count5/5

Four tools is well-scoped for the focused domain of routing calls on the Routavo network, metering them, and handling verification and disputes. Each tool earns its place, and none feels redundant or missing.

Completeness5/5

The tool surface covers the full client-side lifecycle: discover capabilities, make a call, verify the receipt, and dispute a charge. The only possible additions would be conveniences like history or dispute tracking, but the core workflow is complete.

Resources