binance_get_prevented_matches
List orders rejected by Self-Trade Prevention (STP) for a symbol, showing blocked price and quantity. Query by prevented match ID or order ID to audit STP behavior.
Instructions
List orders rejected by Self-Trade Prevention (STP) for a symbol.
Calls GET /api/v3/myPreventedMatches (SIGNED, USER_DATA). IP weight 2 when
queried by prevented_match_id, 20 when queried by order_id.
When to Use:
To see which of your own orders were prevented from matching against each other (STP), including the price and quantity that was blocked.
To audit STP behavior for a specific order via
order_id.
When NOT to Use:
For orders that DID execute — use
binance_get_my_trades(trade history).
Returns:
A markdown list (or JSON) of prevented matches: preventedMatchId,
tradeGroupId, taker/maker order ids, maker symbol, price, maker quantity
prevented (via fmt_num), the self-trade-prevention mode, and the
transaction time. Display is capped at MAX_DISPLAY_ROWS (50); JSON mode
returns {count, truncated, displayLimit, items} rather than a bare array,
so truncation stays valid JSON.
Pagination:
Only valid together with order_id: from_prevented_match_id is an
inclusive cursor — pass the last-seen preventedMatchId (or one past it)
to page forward, and limit (only sent when from_prevented_match_id is
set; Binance default 500, max 1000) caps how many rows come back per call.
Display is additionally capped at MAX_DISPLAY_ROWS (50) regardless of
limit.
Examples: params = {"symbol": "BTCUSDT", "prevented_match_id": 1} params = {"symbol": "BTCUSDT", "order_id": 12345, "from_prevented_match_id": 5}
Error Handling:
Exactly one of prevented_match_id or order_id is required — validated
locally before the call. from_prevented_match_id requires order_id.
-1121 means an invalid symbol; -2013/-2011 mean the order id does not exist.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| params | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |