Skip to main content

Get Historical Order by ID

Get Historical Order by ID

Get historical order information by ID

Request frequency limit: 1/1s

Request URL

GET /deepcoin/trade/finishOrderByID

Request Parameters

Field NameRequiredTypeDescription
instIdtruestringProduct ID
ordIdtruestringOrder ID

Response Parameters

Field NameTypeDescription
instTypestringProduct type
instIdstringProduct ID
tgtCcystringMarket order quantity type
Base currency: base_ccy
Quote currency: quote_ccy, only applicable to spot orders
ccystringMargin currency, only applicable to cross margin orders in single-currency margin mode
ordIdstringOrder ID
clOrdIdstringCustom order ID
tagstringOrder tag
pxstringOrder price
szstringOrder size
pnlstringProfit and loss
ordTypestringOrder type
Market order: market
Limit order: limit
Post only: post_only
sidestringOrder side
Buy: buy
Sell: sell
posSidestringPosition side
tdModestringTrading mode
accFillSzstringAccumulated fill size
fillPxstringLatest fill price
tradeIdstringLatest trade ID
fillSzstringLatest fill size
fillTimestringLatest fill time
avgPxstringAverage fill price
statestringOrder state
Pending: live
Partially filled: partially_filled
leverstringLeverage between 0.01 and 125, only applicable to margin/futures/perpetual trading
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
Web: web
Mobile: app
API: api
System: system
rebatestringRebate amount. Platform pays maker rebates to users who reach specified trading levels. Empty string if no rebate. Positive number for fee rebate, e.g., 0.01
categorystringOrder category, normal: Normal order
uTimestringOrder update time, Unix timestamp in milliseconds
cTimestringOrder creation time, Unix timestamp in milliseconds

Response Example

{
"code": "0",
"msg": "",
"data": [
{
"instType": "SWAP",
"instId": "BTC-USDT-SWAP",
"tgtCcy": "",
"ccy": "",
"ordId": "1000587866272245",
"clOrdId": "",
"tag": "",
"px": "1.000000",
"sz": "95000.000000",
"pnl": "0.000000",
"ordType": "limit",
"side": "buy",
"posSide": "long",
"tdMode": "cross",
"accFillSz": "0.000000",
"fillPx": "",
"tradeId": "",
"fillSz": "0.000000",
"fillTime": "1739261771000",
"avgPx": "",
"state": "canceled",
"lever": "1.000000",
"tpTriggerPx": "",
"tpTriggerPxType": "",
"tpOrdPx": "",
"slTriggerPx": "",
"slTriggerPxType": "",
"slOrdPx": "",
"feeCcy": "USDT",
"fee": "0.000000",
"rebateCcy": "",
"source": "",
"rebate": "",
"category": "normal",
"uTime": "1739261771000",
"cTime": "1739261762000"
}
]
}