Skip to main content
Glama

ScrapeMole Onchain: prices, DEX prices, ENS/Basenames, gas, tokens, balances, holders and transactions on Base and Ethereum: DEX price (Uniswap v3, on-chain)

dex_price
Read-onlyIdempotent

Use when a token has no Chainlink feed (long-tail, new or memecoins) and you need its current market price: finds every Uniswap v3 pool of the token against WETH, USDC (and USDT on Ethereum) across fee tiers, reads each pool's price (slot0) and reserves in one multicall, converts to USD with Chainlink, and returns the price from the deepest pool plus all pools with their depth. Flags thin liquidity. Uniswap v3 only (Aerodrome and other DEXs not included). Paid tool: x402 USDC on Base, $0.002 per successful call; call without payment to receive the PaymentRequired object.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "token": "<token>"
    },
    "name": "dex_price"
  }
}

Input Schema

NameRequiredDescriptionDefault
chainNoChain.base
tokenYesERC-20 contract address.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations cover the safety profile (readOnly, idempotent, openWorld), so the bar is lower, yet the description adds substantial behavior: a single multicall batched across fee tiers, thin-liquidity flagging, deepest-pool selection logic, and the x402 USDC-on-Base paid model at $0.002 per successful call. That is materially more than the annotations convey.

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?

Front-loaded with the usage trigger ('Use when...') followed by mechanism, then constraints, then pricing — a sensible ordering with little filler. It is dense and long, but nearly every clause carries operational information an agent needs (pool set, exclusion, payment protocol).

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?

With no output schema, the description carries the return contract and does so: the deepest-pool price plus all pools with their depth, plus a thin-liquidity flag. Combined with the coverage/exclusion caveats and payment behavior, nothing an agent needs to call this correctly is missing.

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 coverage is 100% and both parameters are documented there (token as ERC-20 contract address, chain enum with default), so the schema does the heavy lifting. The description adds only indirect meaning — that USDT pairs exist on Ethereum, implying chain-dependent pool sets — but no param-specific syntax or format detail. Baseline 3 applies.

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?

States a specific verb and resource: finds every Uniswap v3 pool for a token against WETH/USDC(/USDT), reads slot0 and reserves, converts to USD, returns price from deepest pool. It also distinguishes itself from the sibling `price` tool by scoping to tokens with no Chainlink feed. An agent can tell exactly what it gets without opening the schema.

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 when-to-use (token has no Chainlink feed — long-tail, new, memecoins) and when-not (Uniswap v3 only; Aerodrome and other DEXs excluded). It also documents the payment flow — call without payment to receive the PaymentRequired object — which is exactly the prerequisite an agent needs before invoking.

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