跳到主要内容

获取止盈止损订单列表

响应示例

{
"success": false,
"code": 0,
"message": "",
"data": [{
"id": 0,
"orderId": 0,
"symbol": "",
"positionId": 0,
"stopLossPrice": 0.0,
"takeProfitPrice": 0.0,
"state": 0,
"triggerSide": 0,
"positionType": 0,
"vol": 0.0,
"realityVol": 0.0,
"placeOrderId": 0,
"errorCode": 0,
"version": 0,
"isFinished": 0,
"createTime": "",
"updateTime": ""
}]
}
  • GET /api/v1/private/stoporder/list/orders

需要权限: 读取订单信息

请求参数:

参数名类型是否必填说明
symbolstringfalse合约名
is_finishedintfalse终态标识:0:未完成,1:已完成
stateintfalse状态:1未触发2已取消3已执行4已失效5执行失败
typeintfalse仓位类型,1:多仓,2:空仓
start_timelongfalse开始时间(Unix毫秒时间戳)
end_timelongfalse结束时间(Unix毫秒时间戳)
page_numinttrue当前页数,默认为1
page_sizeinttrue每页大小,默认20,最大100

响应参数:

参数名类型说明
idlong止盈止损委托单id
symbolstring合约名
orderIdlong限价订单id,如果是根据仓位下的,该值为0
positionIdlong仓位id
lossTrendint止损类型:1最新价2合理价3指数价
profitTrendint止盈类型:1最新价2合理价3指数价
stopLossPricedecimal止损价
takeProfitPricedecimal止盈价
stateint状态,1:未触发,2:已取消,3:已执行,4:已失效,5:执行失败
triggerSideint触发方向,0:未触发,1:止盈,2:止损
positionTypeint仓位类型,1:多仓,2:空仓
voldecimal委托数量
realityVoldecimal实际下单数量
placeOrderIdlong委托成功后订单id
errorCodeint错误码,0:正常,其他见错误码详情
isFinishedint订单状态是否为终态标识(用于查询),0.非终态,1.终态
versionint版本号
priceProtectint触发保护:"1","0"
profitLossVolTypestring止盈止损数量类型(SAME: 数量相同;SEPARATE:数量不同)
takeProfitVoldecimal止盈数量 (profitLossVolType == SEPARATE时处理)
stopLossVoldecimal止损数量 (profitLossVolType == SEPARATE时处理)
createTimelong创建时间
updateTimelong修改时间
volTypeint数量类型1、分批止盈止损2、仓位止盈止
takeProfitReverseint止盈反手:1是2否
stopLossReverseint止损反手:1是2否
takeProfitTypeint止盈类型 0-市价止盈 1-限价止盈
takeProfitOrderPricedecimal限价止盈委托价格
stopLossTypelong止损类型 0-市价止损 1-限价止损
stopLossOrderPricedecimal限价止损 委托价格