Skip to content

Find orders#

GET https://api.pro.anboto.xyz/api/v2/trading/order/find

Only matched order within 3 days will be return ApiKeyAuth required.

Query params#

startMs integer
The start time for the query as ms since epoch
endMs integer
The end time for the query as ms since epoch
limit integer
The maximum number of orders to return in the results
include_trades boolean
Whether to include the fills (trades) of the matching orders
include_fees boolean
Whether to include aggregated fees per currency for the matching orders

Headers#

Header
X-API-KEY string required
X-TIMESTAMP int64 ms required
X-SIGN string required
X-RECV-WINDOW int, default 5000

Responses#

200 The list of matching orders.
401 Unauthorized: missing or unknown API key
429 Rate limit exceeded, retry later

Response fields — OrderDetailsList#

orders array[OrderDetails] required
The list of order details for separate orders.
orders[].order_id integer
The Anboto generated order id
Example: 123456
orders[].client_order_id string
The client provided order id
Example: xxx-yyy-zzz
orders[].symbol string
The order symbol in Anboto's symbology
orders[].status enum
The order status — PENDING_NEW, ACCEPTED, REJECTED, PARTIALLY_FILLED, FILLED, PENDING_CANCEL, CANCELLED, PENDING_PAUSE, … (12 values)
orders[].asset_class enum
The Asset category of the order. — SPOT, FUTURE
Example: SPOT
orders[].exchange enum
The exchanges available for order placement via the API — BINANCE, HUOBI, GATEIO, KRAKEN, KUCOIN, OKX, BYBIT, BITGET, … (17 values)
orders[].strategy enum
The execution strategy for the order. — TWAP, VWAP, ICEBERG, POV, MARKET, LIMIT, IS, SCALE
Example: VWAP
orders[].start_time number
The time when the order start trading from epoch time in ms
orders[].end_time number
The scheduled end of the execution from epoch time in ms while the order is working (e.g. start_time + duration for a TWAP); the time the order reached its terminal state once finished
orders[].quantity number
The total quantity of the parent order in base asset, as placed. Absent for value-target (notional) orders, see target_value
Example: 6
orders[].filled_quantity number required
The absolute amount of the order quantity filled
Example: 0
orders[].leaves_quantity number required
The absolute amount of the parent order quantity remaining to be filled (quantity - filled_quantity, 0 once the order is terminal). This is the parent order's remainder, never the leaves of the child order currently working it
Example: 0
orders[].progress number
Execution progress of the parent order between 0 and 1: filled_quantity / quantity, or filled notional / target_value for value-target orders. Same computation as the WebSocket order topic orderProgress; 1 once FILLED. Absent when the parent order is not known
Example: 0.1783
orders[].side enum
The side of the book to trade. — BUY, SELL
orders[].last_quantity number required
The last qty received in a fill from the exchange
Example: 0
orders[].last_price number required
The last price executed on the exchange
Example: 0
orders[].average_price number required
The average execution price of the order
Example: 0
orders[].limit_price number
The limit price of the parent order, if one was set
orders[].clip_size_type enum
The clip size for the child orders. The default is AUTOMATIC — ABSOLUTE, PERCENTAGE, AUTOMATIC, ORDER_COUNT
orders[].clip_size_val number
The clip size value of the parent order, as placed
orders[].target_value number
The target notional of a value-target order (e.g. a multi-leg order leg); quantity is absent for such orders
orders[].params OrderParams
The advanced order parameters to modify the execution behavior.
orders[].trades array[TradeDetails]
The list of trades associated with this order when include_trades=true
orders[].trades[].trade_id string
The trade id assigned by the exchange, or the Anboto platform trade id when no exchange trade id was captured
Example: 1204004183
orders[].trades[].symbol string required
The symbol of the fill in Anboto's symbology
Example: BTC/USDT:USDT
orders[].trades[].exchange_order_id string
The exchange order id of the child order the fill belongs to
Example: 151990408
orders[].trades[].client_order_id string
The client order id of the child order the fill belongs to
orders[].trades[].quantity number required
The absolute amount filled by this trade, in base asset
Example: 0.5
orders[].trades[].price number required
The traded price
Example: 92.91
orders[].trades[].direction enum
The direction of the trade — BUY, SELL
Example: BUY
orders[].trades[].maker_or_taker enum
Whether the fill was made as maker or taker — MAKER, TAKER
Example: MAKER
orders[].trades[].exec_time integer
The execution time of the trade as ms since epoch
Example: 1758276000000
orders[].trades[].fee number
The fee charged on the trade, in fee_currency
Example: 0.0021
orders[].trades[].fee_currency string
The asset the fee was charged in
Example: USDT
orders[].trades[].parent_order_id integer
The Anboto id of the parent order the fill belongs to (the order_id of the enclosing order)
Example: 596990285759373312
orders[].trades[].child_order_id integer
The Anboto id of the child (slice) order that executed on the exchange; the WebSocket trade topic carries it as order_id
Example: 596990290020118528
orders[].fees_infos object
Aggregated fees per currency when include_fees=true
curl -X GET "$BASE/api/v2/trading/order/find?startMs=0" \
  -H "X-API-KEY: $API_KEY" -H "X-TIMESTAMP: $ts" \
  -H "X-SIGN: $sign"
params = {"startMs": ..., "endMs": ..., "limit": ..., "include_trades": ..., "include_fees": ...}
r = requests.get(f"{BASE}/api/v2/trading/order/find",
    params=params
    headers=signed_headers_query(params))
print(r.json())
let resp = client
    .get(format!("{BASE}/api/v2/trading/order/find?startMs=0"))
    .headers(signed_headers_query(&params))
    .send()?;
println!("{}", resp.text()?);
req, _ := http.NewRequest("GET", BASE+"/api/v2/trading/order/find?startMs=0", nil)
for k, v := range signedHeadersQuery(req.URL.Query()) {
    req.Header.Set(k, v)
}
resp, err := http.DefaultClient.Do(req)
if err != nil {
    log.Fatal(err)
}
defer resp.Body.Close()
io.Copy(os.Stdout, resp.Body)
HttpResponse<String> resp = client.send(
    signedGet("/api/v2/trading/order/find?startMs=0"),
    HttpResponse.BodyHandlers.ofString());
const res = await fetch(`${BASE}/api/v2/trading/order/find?startMs=0`, {
  method: "GET",
  headers: signedHeadersQuery(params),
});
const data: OrderDetailsList = await res.json();
val request = signedGet("/api/v2/trading/order/find?startMs=0")
val response = client.send(request, HttpResponse.BodyHandlers.ofString())
println(response.body())
cpr::Response r = cpr::Get(
    cpr::Url{BASE + "/api/v2/trading/order/find?startMs=0"},
    signedHeadersQuery(params));
std::cout << r.text << std::endl;
const res = await fetch(`${BASE}/api/v2/trading/order/find?startMs=0`, {
  method: "GET",
  headers: signedHeadersQuery(params),
});
console.log(await res.json());

Response 200

{
  "orders": [
    {
      "order_id": 123456,
      "client_order_id": "xxx-yyy-zzz",
      "symbol": "string",
      "status": "PENDING_NEW",
      "asset_class": "SPOT",
      "exchange": "BINANCE",
      "strategy": "TWAP",
      "start_time": 0.0,
      "end_time": 0.0,
      "quantity": 6,
      "filled_quantity": 0,
      "leaves_quantity": 0,
      "progress": 0.1783,
      "side": "BUY",
      "last_quantity": 0,
      "last_price": 0,
      "average_price": 0,
      "limit_price": 0.0,
      "clip_size_type": "ABSOLUTE",
      "clip_size_val": 0.0,
      "target_value": 0.0,
      "params": {
        "duration_seconds": "120",
        "trading_style": "PASSIVE",
        "urgency": "LOW",
        "pov_ratio": 5,
        "pov_risk": "LOW",
        "randomize_amount": true,
        "would": {},
        "trigger": {},
        "placement_infos": {},
        "reduce_only": true,
        "start_ladder_price": "string",
        "end_ladder_price": "string",
        "ladder_direction": "string",
        "ladder_profile": "string",
        "size_skew": 0.0,
        "ob_imbalance_cancel": true,
        "ob_imbalance_threshold": "0.75",
        "price_lock_bps": "5",
        "limit_is_arrival": true,
        "limit_bps": "-10",
        "timer_iceberg_delay": 0.5,
        "timer_iceberg_delay_min": 0,
        "timer_iceberg_delay_max": 10,
        "randomize_iceberg_timer": true,
        "extend_duration": true
      },
      "trades": [
        {}
      ],
      "fees_infos": {}
    }
  ]
}