Skip to main content
Glama

AgentPay — trust routing + spend caps for x402 agents

orderbook_depth

Read-only

Get real bid/ask depth and slippage estimates at $10k, $50k, and $250k notional from Binance, Bybit and OKX. Use before sizing a position to know if you can execute without moving the market.

Use when: You need to estimate slippage before executing a large trade. Tells you how much a $10k, $50k, or $250k order will move the market. Not for: you need market cap or 24h volume — token_market_data; a full pre-trade verdict at your size — pre_trade_check. Centralised-exchange books (Binance/Bybit/OKX) only, not DEX pools. Returns: best_bid, best_ask, spread_pct, depth with slippage_pct at $10k/$50k/$250k notional, per-exchange best prices Example response: {"asset":"ETH","pair":"ETH/USDT","best_ask":2071.5,"best_bid":2071.2,"spread_pct":0.0145,"depth":[{"notional_usd":10000,"slippage_pct":0.002,"executable":true},{"notional_usd":50000,"slippage_pct":0.008,"executable":true},{"notional_usd":250000,"slippage_pct":0.031,"executable":true}],"exchanges":[{"exchange":"Binance","best_ask":2071.5,"best_bid":2071.2},{"exchange":"Bybit","best_ask":2071.6,"best_bid":2071.1}],"source":"binance/bybit/okx"}

Price: $0.000 USDC per call

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": {
      "asset": "<asset>"
    },
    "name": "orderbook_depth"
  }
}

Input Schema

NameRequiredDescriptionDefault
assetYesToken symbol, e.g. 'BTC', 'ETH', 'SOL'ETH

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint and openWorldHint, so the description earns credit for what it adds: the exact data sources, the fixed notional tiers, the returned field set and a concrete example response. It stops short of disclosing data freshness/latency of the books, which materially affects a slippage estimate, so it is not a 5.

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 action and the sizing use case, then structured as Use when / Not for / Returns / Example — easy to scan. The inline example JSON is long, though it substitutes for the missing output schema, so it largely earns its space.

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?

No output schema exists, and the description compensates with an explicit Returns list plus a full example payload covering best_bid/ask, spread_pct, per-tier slippage and per-exchange prices. Nothing an agent needs to call or interpret this single-param tool 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% with a documented 'asset' field and a default, so the schema carries the semantics and baseline 3 applies. The description adds only that the notional tiers are fixed rather than user-supplied — useful framing but not new meaning for the parameter itself.

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 ('Get real bid/ask depth and slippage estimates') and pins the exact fixed notionals ($10k/$50k/$250k) and venues (Binance/Bybit/OKX). The 'Not for' lines explicitly separate it from token_market_data and pre_trade_check, so an agent can pick it 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 'Use when' (estimate slippage before a large trade) and 'Not for' clauses that name the alternative sibling for each exclusion (token_market_data for cap/volume, pre_trade_check for a full pre-trade verdict). It also bounds coverage — centralised-exchange books only, not DEX pools.

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.