Skip to main content
Glama
trustxai

amazing-binance-mcp

by trustxai

binance_get_algo_sub_orders

Read-onlyIdempotent

Retrieve each slice order of a TWAP algorithm, including filled quantity, average price, and fees, to audit what the strategy actually executed.

Instructions

List the individual orders a TWAP placed on the book, with fills and fees.

Calls GET /sapi/v1/algo/spot/subOrders (SIGNED, IP weight 1). A TWAP is executed as a stream of ordinary orders; this is the only place to see them — what each slice filled, at what average price, and what it cost in fees.

When to Use:

  • Answering "what did this TWAP actually get me?" — the executedQty / executedAmt / fee totals for one algoId.

  • Auditing a cancelled TWAP: what traded before the cancel landed.

When NOT to Use:

  • To find the algoId in the first place — that comes from binance_get_open_algo_orders or binance_get_algo_order_history.

  • For a symbol-wide trade list — binance_get_my_trades (trade_history.py) covers every fill, algo or not.

Returns: The order-level totals (total, executedQty, executedAmt) followed by a table of sub-orders: bookTime, subId, orderId, symbol, side, orderStatus, executedQty, executedAmt, avgPrice and the fee with its asset.

Pagination: page (1-based) and page_size (1-100, default 100) map to Binance's page / pageSize. Only 50 rows are rendered, so a full 100-row page hides rows 51-100: lower page_size to 50, or use response_format="json", for the rest.

Examples: params = {"algo_id": 14511} params = {"algo_id": 14511, "page": 2, "page_size": 50}

Error Handling: An unknown algoId comes back as a Binance rejection, not an empty page. An empty subOrders array means the TWAP has not traded yet. -2015 means the key lacks Reading permission or this IP is not allowlisted. /sapi does not exist on the spot testnet.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare readOnlyHint, idempotentHint, and destructiveHint false, but the description adds substantial behavioral context beyond that: error handling for unknown algoId, the -2015 permission error, the testnet limitation, and the 50-row rendering quirk. This goes well beyond the structured annotations.

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 long but well-structured with clear headers (When to Use, Returns, Pagination, Examples, Error Handling). Every section carries information; there's minimal fluff. It could be slightly tightened but is far from verbose or redundant.

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 the tool's complexity, the presence of an output schema, and rich annotations, the description covers all necessary call-time knowledge: use cases, exclusions, pagination nuances, error handling, and examples. Nothing an agent needs to invoke it correctly is missing.

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 descriptions for each parameter (algo_id, page, page_size, response_format), so baseline is 3. The description adds meaningful semantics by explaining pagination mapping, the 50-row display limit, and when to use response_format='json'. This is 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 opens with a specific verb+resource: 'List the individual orders a TWAP placed on the book, with fills and fees.' It explicitly differentiates from siblings by stating this is the only place to see slice-level fills and naming alternatives like binance_get_my_trades and binance_get_open_algo_orders. The purpose is unambiguous and distinct.

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 has dedicated 'When to Use' and 'When NOT to Use' sections that name exact sibling tools and conditions, such as finding algoId via binance_get_open_algo_orders and using binance_get_my_trades for symbol-wide trade lists. It leaves no ambiguity about when to select this tool.

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

Deploy Server

Other Tools