Skip to main content
Glama

Get best swap quote

get_swap_quote
Read-onlyIdempotent

Get the best swap route across DEX aggregator venues. Returns the winning venue quote plus every venue quote for transparency, and the fee recipient address (auditable against get_meta). Cross-chain quotes (e.g. USDT on Arbitrum -> USDC on Base) are supported on EVM.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
buyYes
sellYes
amountYesInteger amount in base units of the sell token, e.g. '100000000000000000' for 0.1 WETH
slippageBpsNoMax slippage in basis points, default 50

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, openWorldHint, idempotentHint, and destructiveHint=false. The description adds useful behavioral context by specifying that the tool returns the winning venue quote, every venue quote for transparency, and the fee recipient address auditable against get_meta. No contradiction with 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?

Three sentences with no filler: the purpose is front-loaded, the return behavior is summarized, and the cross-chain capability is stated concisely. Every sentence earns its place.

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, the description usefully explains the return values: winning venue quote, all venue quotes, and the fee recipient address. It also covers a notable edge case (cross-chain EVM support). It does not mention quote expiry or error behavior, but for a read-only quote tool this is reasonably complete.

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 50%; the schema documents amount and slippageBps, while the description adds cross-chain semantics for sell/buy tokens with the Arbitrum-to-Base example. It does not restate or clarify nested buy/sell object structure beyond what the schema provides, so it only partially compensates for the gap.

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 and resource: 'Get the best swap route across DEX aggregator venues.' This clearly distinguishes it from siblings like build_swap_transaction, which would construct a transaction, and get_chart, which serves a different purpose.

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 implies use when a best swap quote is needed and notes cross-chain support on EVM, but it does not explicitly state when to use this tool versus siblings such as build_swap_transaction or plan_route. No exclusions or alternative routing are provided.

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