Skip to main content

Documentation Index

Fetch the complete documentation index at: https://developer.wooxpro.com/llms.txt

Use this file to discover all available pages before exploring further.

Get Order History (KEYED)

Applicable for querying contract order history

Request URL

GET https://cloud-api.wooxpro.com/contract/private/order-history

Request Limit

See Detailed Rate Limit

Request Parameter

Request
curl -H 'X-BM-KEY:{{AccessKey}}'
https://cloud-api.wooxpro.com/contract/private/order-history?symbol=BTCUSDT&start_time=1662368173&end_time=1662368179
FieldTypeRequired?Description
symbolStringYesSymbol of the contract(like BTCUSDT)
order_idStringNoOrder ID
client_order_idStringNoClient-defined OrderId
accountStringNoTrading account
-futures
-copy_trading
start_timeLongNoStart time(Timestamp in Seconds)
end_timeLongNoEnd time(Timestamp in Seconds)
Note
  • If the time range start_time and end_time are not filled in, the default query is the data of the last 7 days
  • If the time range is filled in, end_time must be greater than the value of start_time, and the maximum query interval of start_time and end_time is 90 days
  • Each request returns a maximum of 200 records, and any records exceeding that will not be returned.

Response Data

Response
{
  "code": 1000,
  "message": "Ok",
  "data": [
    {
      "order_id": "3000101684062644",
      "client_order_id": "PLAN_3000097492004577",
      "price": "0",
      "trigger_price": "0",
      "execution_price": "0",
      "size": "1",
      "symbol": "BTCUSDT",
      "state": 4,
      "side": 2,
      "type": "market",
      "account": "futures",
      "position_mode": "hedge_mode",
      "leverage": "20",
      "open_type": "cross",
      "deal_avg_price": "84802",
      "deal_size": "1",
      "create_time": 1743160485193,
      "update_time": 1743160485258,
      "activation_price_type": 1,
      "activation_price": "0",
      "callback_rate": "0",
      "preset_take_profit_price_type": 0,
      "preset_stop_loss_price_type": 0,
      "preset_take_profit_price": "",
      "preset_stop_loss_price": ""
    }
  ],
  "trace": "b15f261868b540889e57f826e0420621.80.17434162457898722"
}
FieldTypeDescription
symbolStringSymbol of the contract
order_idStringOrder ID
client_order_idStringClient-defined OrderId (If the field is not defined, a empty string is returned)
sideIntOrder side
hedge mode
-1=buy_open_long
-2=buy_close_short
-3=sell_close_long
-4=sell_open_short
oneway mode
-1=buy
-2=buy(reduce only)
-3=sell(reduce only)
-4=sell
typeStringOrder type
-limit
- market
- liquidate
- bankruptcy
- adl
- trailing
- planorder
accountStringTrading account
-futures
-copy_trading
position_modeStringPosition mode
-hedge_mode
-one_way_mode
leverageStringLeverage order multipliers
open_typeStringOpen type
-cross
-isolated
deal_avg_priceStringAverage deal price
deal_sizeStringDeal amount
priceStringConsignment price
trigger_priceStringTrigger price,returned at plan order
execution_priceStringExecutive price,returned at plan order only
-Market price=If the execution price is a market price, return to Market
-Limit price=If the execution price is a limit price, return the set limit price
stateIntOrder status
-2=status_check
-4=status_finish
activation_priceStringActivation price, returned at trailing order
callback_rateStringCallback rate, returned at trailing order
activation_price_typeIntActivation price type, returned at trailing order
-1=last_price
-2=fair_price
executive_order_idStringActivation Execute Order ID
preset_take_profit_price_typeIntPre-set TP price type
-0=unset
-1=last_price
-2=fair_price
preset_stop_loss_price_typeIntPre-set SL price type
-0=unset
-1=last_price
-2=fair_price
preset_take_profit_priceStringPre-set TP price
preset_stop_loss_priceStringPre-set SL price
create_timeLongOrder created timestamp (ms)
update_timeLongOrder updated timestamp (ms)