Skip to main content

Orders Detail

Orders Detail

Query order details by order ID or client order ID. Supports batch queries (up to 5 per request).

Request URL

POST /deepcoin/v2/trade/orders-detail

Request Parameters

Field NameRequiredTypeDescription
orderstruearrayQuery list, maximum 5 per request

orders[] item fields:

Field NameRequiredTypeDescription
instIdtruestringProduct ID
ordIdfalsestringOrder ID. Either ordId or clOrdId is required. If both are provided, ordId takes priority
clOrdIdfalsestringClient order ID. Either ordId or clOrdId is required

Request Example

// Single query
{
"orders": [
{
"instId": "BTC-USDT-SWAP",
"ordId": "1000597586292096"
}
]
}

// Batch query
{
"orders": [
{
"instId": "BTC-USDT-SWAP",
"ordId": "1001"
},
{
"instId": "ETH-USDT-SWAP",
"ordId": "1002"
}
]
}

Response Parameters

Returns an array. Each item structure:

Field NameTypeDescription
ordIdstringOrder ID
codestringResult code, 0 means success, 60024 means not found
msgstringResult message
dataobjectOrder detail, see OrderV2 fields below

data (OrderV2) fields:

Field NameTypeDescription
instTypestringProduct type
instIdstringProduct ID
tgtCcystringMarket order quantity type
ccystringMargin currency
ordIdstringOrder ID
clOrdIdstringClient order ID
pxstringOrder price
szstringOrder size
pnlstringProfit and loss
ordTypestringOrder type
sidestringOrder side
Buy: buy
Sell: sell
posSidestringPosition side
Long: long
Short: short
tdModestringTrading mode
Cross: cross
Isolated: isolated
Cash: cash
accFillSzstringAccumulated fill size
fillPxstringLatest fill price
tradeIdstringLatest trade ID
fillSzstringLatest fill size
fillTimestringLatest fill time, Unix timestamp in milliseconds
avgPxstringAverage fill price
statestringOrder state
Pending: live
Partially filled: partially_filled
Filled: filled
Cancelled: canceled
leverstringLeverage
tpTriggerPxstringTake-profit trigger price
tpTriggerPxTypestringTake-profit trigger price type
Last price: last
Index price: index
Mark price: mark
tpOrdPxstringTake-profit order price
slTriggerPxstringStop-loss trigger price
slTriggerPxTypestringStop-loss trigger price type
Last price: last
Index price: index
Mark price: mark
slOrdPxstringStop-loss order price
feeCcystringFee currency
feestringTrading fee
rebateCcystringRebate currency
sourcestringOrder source
reduceOnlystringWhether reduce-only
rebatestringRebate amount
categorystringOrder category
uTimestringUpdate time, Unix timestamp in milliseconds
cTimestringCreation time, Unix timestamp in milliseconds

Response Example

[
{
"ordId": "1000597586292096",
"code": "0",
"msg": "",
"data": {
"instType": "SWAP",
"instId": "BTC-USDT-SWAP",
"ordId": "1000597586292096",
"px": "65000",
"sz": "1",
"ordType": "limit",
"side": "buy",
"posSide": "long",
"tdMode": "cross",
"state": "live",
"lever": "10",
"uTime": "1739263130000",
"cTime": "1739263130000"
}
}
]