Skip to main content
Glama

ExchangeRebel — pay-per-call APIs for AI agents (x402 on Solana)

token_efficiency_budget

$0.02 USDC on Solana per call — the payment buys one signed payload-budget report for one submitted payload and your stated token budget: (1) a fit verdict stating the payload's token count under the pinned cl100k_base tokenizer, your effective budget, and whether it fits or the exact excess; (2) where it does not fit, a shaped payload produced only by the four published mechanical operations (S-1 duplicate removal, S-2 empty-field removal, S-3 per-field truncation, S-4 tail truncation, in that order); and (3) a drop receipt listing every operation applied, by field, with token counts before and after that reconcile exactly. No operation selects content by meaning; nothing is summarised or rewritten by a model. Submitted payloads are processed in memory only and never stored; the paid retry re-sends the payload.

Input Schema

NameRequiredDescriptionDefault
payloadYesThe one payload to check, as text or as JSON text. Processed in memory only and never stored.
keep_fieldsNoOptional field paths protected from shaping operations.
budget_tokensYesThe token budget the payload must fit, counted under the published pinned tokenizer (cl100k_base). No default: a call without a valid budget_tokens is a free validation refusal.
reserve_tokensNoOptional reserve subtracted from budget_tokens to form the effective budget.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.8/5.0
Behavior5/5

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

With no annotations supplied, the description carries the full burden and does so: it discloses cost and payment rail, determinism guarantees ('produced only by the four published mechanical operations ... in that order', 'No operation selects content by meaning; nothing is summarised or rewritten by a model'), data handling ('processed in memory only and never stored'), and reconcile-exactly accounting in the receipt. It also explains retry behavior ('the paid retry re-sends the payload'). The only unaddressed behavior is whether a failed/refused call is charged, which is minor against this level of disclosure.

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?

The pricing and the core deliverable are front-loaded, and the (1)/(2)/(3) enumeration makes the three-part output scannable. It is essentially one very long run-on sentence with nested parentheticals, which makes it dense to parse, but nearly every clause (operation ordering, no-model guarantee, in-memory processing, exact reconciliation) carries decision-relevant information.

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?

With no output schema and no annotations, the description must describe the return value — and it does so thoroughly, down to what the receipt reconciles. It also covers the payment model and privacy posture. The remaining gaps are how the 'signed' report is verified and what happens to the payment when a call is refused or fails, which leaves the agent slightly short on failure-mode expectations for a paid tool.

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 the baseline is 3, but the description adds real meaning: it fixes the counting method (pinned cl100k_base tokenizer) and introduces the 'effective budget' concept that links budget_tokens to reserve_tokens. keep_fields is only glossed indirectly via 'by field' and 'protected from shaping operations' lives in the schema, so the prose does not fully map every parameter — hence 4 rather than 5.

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 concrete verb and deliverable — 'the payment buys one signed payload-budget report for one submitted payload and your stated token budget' — and itemizes the three artifacts returned (fit verdict, shaped payload, drop receipt). That is far more specific than the name alone. It never names its obvious siblings token_efficiency_precheck or token_efficiency_criteria, so an agent still has to infer that a free/dry-run check exists elsewhere.

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

Usage Guidelines2/5

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

Useful decision inputs are present (price of $0.02 USDC on Solana, one payload per call, 'the paid retry re-sends the payload'), which tells the agent this is a metered, single-shot call. However, there is no explicit when-to-use versus when-not guidance, no pointer to token_efficiency_precheck as a cheaper validation path, and no statement of prerequisites such as wallet/payment setup.

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