跳到主要内容

查询历史订单

响应示例

{
"success": true,
"code": 0,
"data": [
{
"orderId": "739211854408619008",
"symbol": "DOGE_USDT",
"positionId": 1110417836,
"price": 0.18695,
"priceStr": "0.186950000000000000",
"vol": 1,
"leverage": 20,
"side": 3,
"category": 1,
"orderType": 5,
"dealAvgPrice": 0.18695,
"dealAvgPriceStr": "0.186950000000000000",
"dealVol": 1,
"orderMargin": 0.93475,
"takerFee": 0,
"makerFee": 0,
"profit": 0,
"feeCurrency": "USDT",
"openType": 1,
"state": 3,
"externalOid": "test00002",
"errorCode": 0,
"usedMargin": 0.93475,
"createTime": 1761912240000,
"updateTime": 1761912240000,
"positionMode": 1,
"version": 2,
"showCancelReason": 1,
"showProfitRateShare": 0,
"bboTypeNum": 0,
"totalFee": 0,
"zeroSaveTotalFeeBinance": 0,
"zeroTradeTotalFeeBinance": 0
}
]
}
  • GET /api/v1/private/order/list/close_orders

需要权限: 读取订单信息

请求参数:

参数名类型是否必填说明
symbolstringtrue交易对
start_timelongfalse开始时间(Unix毫秒时间戳)
end_timelongfalse结束时间(Unix毫秒时间戳)
page_numintfalse查询的页数;默认为1
page_sizeintfalse每页大小;默认为20;最大值不能超过1000

响应参数:

参数名类型说明
pageSizeint每页大小
totalCountint总条数
totalPageint总页数
currentPageint当前页
orderIdlong订单ID号
symbolstring合约名
positionIdlong持仓id
pricedecimal委托价格
voldecimal委托数量
leveragelong杠杆倍数
sideint订单方向;1:开多,2:平空,3:开空,4:平多
categoryint订单类别;1:限价委托,2:强平代管委托,3:代管平仓委托,4:ADL减仓;5:交割订单;6:强平对冲
dealAvgPricedecimal成交均价
dealVoldecimal成交数量
orderMargindecimal委托保证金
takerFeedecimal买单手续费
makerFeedecimal卖单手续费
profitdecimal平仓盈亏
feeCurrencystring收费币种
openTypeint开仓类型,1:逐仓,2:全仓
stateint订单状态,1:待报,2:未完成,3:已完成,4:已撤销,5:无效
externalOidstring外部订单号
createTimedate创建时间
updateTimedate修改时间
bboTypeNumint限价订单类型-BBO类型订单; 0:不是BBO订单;1:对手价1;2:对手价5;3:同向价1;4:同向价5;
lossTrendint止损价格类型;1:最新价;2:合理价;3:指数价
profitTrendint止盈价格类型;
takeProfitPricedecimal止盈价
stopLossPricedecimal止损价
priceProtectint价差保护 1:开启;0:关闭
positionModeint仓位模式;1:双向持仓;2:单向持仓