Skip to main content
Glama

MCPFax Macro & Market Intelligence

On-chain token prices

defi_token_prices
Read-onlyIdempotent

Price arbitrary on-chain tokens with DefiLlama's coins API, addressed as chain:address (or coingecko:id), returning price in USD, symbol, decimals, a confidence score and the pricing timestamp for each. Use it to value a DeFi position holding tokens no exchange lists. This is NOT the exchange spot-price tool: use the crypto spot tool for a plain price of a major asset. A token DefiLlama cannot price inside search_width returns null, never a substituted price. Costs $0.005 USDC per call via x402 on Base; an unpaid call returns the payment challenge instead of data, and a call that returns no data is never settled so it costs nothing. Equivalent HTTP route: GET /defi/token-prices.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
coinsNoComma-separated DefiLlama coin ids as chain:address or coingecko:id, up to 20 (required) Example: 'base:0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913,coingecko:ethereum'.
search_widthNoHow far back a price may be taken from (default 6h) Example: '6h'.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / coins / examples
      Added value: +[
      +  "base:0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913,coingecko:ethereum"
      +]
    • addedInput schema / properties / search_width / examples
      Added value: +[
      +  "6h"
      +]
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the annotations (readOnly, openWorld, idempotent), the description adds concrete behavioral details: the $0.005 USDC cost per call, the payment challenge for unpaid calls, and the fact that calls returning no data are never settled. It also explains that unpriced tokens return null rather than a substituted price, which is valuable behavior information.

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 a single dense paragraph that covers purpose, usage, cost, and error behavior. It is well-structured but slightly verbose; breaking it into separate sentences or bullet points could improve scannability. Still, it is concise enough and every sentence contributes useful information.

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?

Given there is no output schema, the description adequately describes the return fields (price, symbol, decimals, confidence, timestamp). It also covers edge cases (null for unpriced tokens, payment challenge, no-settlement on no-data), providing a complete picture of the tool's behavior and output.

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?

The schema already provides 100% coverage with descriptions and examples for both parameters. The description further clarifies the coins parameter format (chain:address or coingecko:id) and the search_width default, adding slight semantic value beyond the 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?

The description clearly states the tool's purpose: 'Price arbitrary on-chain tokens with DefiLlama's coins API'. It also specifies the address format and return fields, and explicitly differentiates it from the sibling crypto spot tool, making its scope unambiguous.

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?

The description gives explicit usage guidance: 'Use it to value a DeFi position holding tokens no exchange lists' and explicitly states what it is NOT for: 'This is NOT the exchange-price tool: use the crypto spot tool for a plain price of a major asset'. This provides clear when-to-use and when-not-to-use instructions.

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