Skip to main content
Glama

Get Order Book

get_order_book
Read-onlyIdempotent

Retrieve order book depth (bids/asks with prices and quantities) for a given instrument ticker. Supports file output for bulk data.

Instructions

Order book (L2 depth of market) for one instrument: bids/asks with prices and quantities, total volumes. Bond prices are quoted in % of face value, not currency. Outside the trading session the API may report 404 "no data".

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tickerYesTicker, e.g. SBER
classCodeNoBoard class code (resolved via find_instrument when omitted)
outputPathNoWrite the full result to this file (path relative to the output root: BCS_OUTPUT_DIR or server cwd) instead of returning it inline. The response becomes a short summary {savedTo, records, bytes, sample}. Use for bulk data to keep the context clean. For get_candles this also enables full-history fetching (chunking beyond the 1000-bar API limit).
outputFormatNoFile format; default json (or csv if outputPath ends with .csv). csv writes the main flat array of the response.
Behavior4/5

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

Annotations already indicate read-safe, idempotent, non-destructive behavior. The description adds useful behavioral context: bond price quoting convention and the potential 404 error. No contradictions 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?

The description is very concise with three sentences, each providing essential information. No filler or redundancy. Front-loaded with the core purpose.

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?

Given no output schema, the description adequately covers return contents (bids/asks with prices, quantities, total volumes) and important edge cases (bond pricing, 404 error). Could mention depth level or pagination, but overall sufficient for this tool.

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%, so the description does not need to add parameter meaning. The description adds no additional parameter context beyond schema, but the baseline is 3.

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 retrieves an order book (L2 depth of market) for one instrument, listing specific data (bids/asks, prices, quantities, total volumes). This is distinct from siblings like get_quotes (top of book) or get_candles (historical prices).

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 provides some usage context, noting that bond prices are in % of face value and that the API may return 404 outside trading sessions. However, it does not explicitly state when to use this tool over alternatives or provide prerequisites.

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/human-turn/bcs-mcp'

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