Skip to main content
Glama
ymylive
by ymylive

compare_prices

Concurrently fetch and compare cryptocurrency prices from CoinGecko, CCXT exchanges, and DexScreener to validate quotes, find divergences, or identify arbitrage.

Instructions

Concurrently fetch the price of one coin from many sources and compare.

Use for cross-source sanity checks, finding venue-vs-aggregator divergences, or simple arbitrage spotting. Contrast with:

  • get_price: single source (CoinGecko aggregated).

  • compare_funding_rates: perp funding across venues.

Sources fanned out in parallel:

  • CoinGecko aggregated /simple/price

  • For each exchange_id: CCXT fetch_ticker(base/quote) where base is derived from coin_id via a small mapping (bitcoin->BTC, ethereum->ETH, solana->SOL, ripple->XRP, cardano->ADA, dogecoin->DOGE, tron->TRX, polkadot->DOT, chainlink->LINK, avalanche-2->AVAX, matic-network->MATIC) and quote is USDT for vs_currency=usd, else vs_currency.upper().

  • DexScreener (only when vs_currency is "usd"): top-liquidity pair.

Args: coin_id: CoinGecko coin ID (e.g. "bitcoin"). vs_currency: Quote currency. "usd" works on all sources; others skip DexScreener. exchange_ids: Comma-separated CCXT exchange IDs.

Returns: Object with coin_id, vs_currency, prices (per-source array with source, ok, and either price or error), max, min, spread_bps, n_ok, n_error. Unknown coin_ids still return per-source error envelopes pointing at get_exchange_ticker.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
coin_idNobitcoin
vs_currencyNousd
exchange_idsNobinance,okx,coinbase,kraken

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

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

With no annotations, description fully discloses behavior: parallel fan-out to CoinGecko, CCXT per exchange, DexScreener; per-coin mapping; error handling; return structure including max/min/spread. No contradictions.

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?

Well-structured with clear sections, but slightly verbose (lists exchanges and coin mapping in prose). Front-loaded with purpose, but could trim some redundant detail.

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

Completeness5/5

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

Comprehensive coverage: input/output description, source details, edge cases (unknown coin_ids), and output schema exists for return values. No gaps for effective agent understanding.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, but description explains all three parameters: coin_id (CoinGecko ID), vs_currency (quote currency with special handling), exchange_ids (comma-separated CCXT IDs). Adds defaults and usage details beyond schema.

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?

Description clearly states the tool fetches prices from many sources concurrently and compares them. It explicitly differentiates from siblings like `get_price` (single source) and `compare_funding_rates` (perp funding).

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

Usage Guidelines5/5

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

Explicit usage guidance: cross-source sanity checks, finding divergences, arbitrage spotting. Contrasts with sibling tools and explains conditions (e.g., DexScreener only for 'usd'), enabling appropriate selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ymylive/coin-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server