Skip to main content
Glama

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

fees_optimize

Return an unsigned, fee-optimized version of a transaction. $0.005 per call — USDC on Solana via x402 (over MCP: call without payment to get the PaymentRequired challenge, then retry with the payment at _meta["x402/payment"]). HTTP equivalent: POST https://exchangerebel.com/toll/fees/optimize.

Input Schema

NameRequiredDescriptionDefault
priorityNolow|medium|high
transaction_base64Nostring

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, openWorldHint=true, idempotentHint=false, and destructiveHint=false. The description adds valuable context beyond annotations: the cost ($0.005 per call), payment mechanism (USDC on Solana via x402), and that the returned transaction is unsigned. It does not contradict annotations.

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 description is front-loaded with the core purpose and then provides necessary payment details. It is appropriately sized, though the payment mechanics add some length; every sentence contributes useful 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?

Given the tool's complexity as a paid API with no output schema, the description covers the critical payment flow and the nature of the return value (unsigned transaction). It is largely complete, though it could clarify parameter usage or alternatives.

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%, so the schema already documents both parameters. The description does not add meaning beyond the schema for priority or transaction_base64, so the baseline score of 3 is appropriate.

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 verb and resource: 'Return an unsigned, fee-optimized version of a transaction.' It clearly distinguishes the action from a fee estimate, though it does not explicitly name the sibling tool fees_estimate as an alternative.

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?

The description explains the payment flow for using the tool, including the x402 challenge and retry mechanism, but it does not state when to use this tool versus alternatives like fees_estimate or fee_oracle_recipe. Usage is implied rather than explicitly guided.

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