仓位
数据示例
{
"channel": "push.personal.position",
"data": {
"positionId": 123456789,
"symbol": "BTC_USDT",
"holdVol": 10,
"positionType": 1,
"openType": 1,
"state": 1,
"frozenVol": 0,
"closeVol": 0,
"holdAvgPrice": 45000.5,
"holdAvgPriceFullyScale": "45000.500000000000000000",
"closeAvgPrice": 0,
"openAvgPrice": 45000.5,
"openAvgPriceFullyScale": "45000.500000000000000000",
"liquidatePrice": 40000.0,
"oim": 2250.025,
"adlLevel": 1,
"im": 2250.025,
"holdFee": 0,
"realised": 0,
"leverage": 20,
"autoAddIm": false,
"pnl": 100.5,
"marginRatio": 0.2,
"newOpenAvgPrice": 45000.5,
"newCloseAvgPrice": 0,
"closeProfitLoss": 0,
"fee": 0,
"deductFeeList": [
{
"currency": "USDT",
"deductFee": 0.1125,
"convertSettleFee": 0.1125
}
],
"makerFeeRate": 0.0002,
"takerFeeRate": 0.0004,
"createTime": 1760942212000,
"updateTime": 1760942212000,
"version": 1
},
"ts": 1760942212000
}
channel = push.personal.position
响应参数:
| 参数名 | 类型 | 说明 |
|---|---|---|
| positionId | long | 持仓 id |
| symbol | string | 合约名 |
| holdVol | decimal | 持仓数量 |
| positionType | int | 仓位类型, 1 多 2 空 |
| openType | int | 开仓类型, 1 逐仓 2 全仓 |
| state | int | 仓位状态,1 持仓中 2 系统代持 3 已平仓 |
| frozenVol | decimal | 冻结量 |
| closeVol | decimal | 平仓量 |
| holdAvgPrice | decimal | 持仓均价 |
| holdAvgPriceFullyScale | string | 全精度持仓均价 |
| closeAvgPrice | decimal | 平仓均价 |
| openAvgPrice | decimal | 开仓均价 |
| openAvgPriceFullyScale | string | 全精度开仓均价 |
| liquidatePrice | decimal | 逐仓时的爆仓价 |
| oim | decimal | 原始初始保证金 |
| adlLevel | int | adl 减仓等级 |
| im | decimal | 初始保证金, 逐仓时可以加减此项以调节爆仓价 |
| holdFee | decimal | 资金费, 正数表示得到,负数表示支出 |
| realised | decimal | 已实现盈亏 |
| leverage | int | 杠杆倍数 |
| autoAddIm | boolean | 是否自动追加保证金 |
| pnl | decimal | 浮动盈亏 |
| marginRatio | decimal | 保证金率 |
| newOpenAvgPrice | decimal | 开仓均价 |
| newCloseAvgPrice | decimal | 平仓均价 |
| closeProfitLoss | decimal | 平仓盈亏 |
| fee | decimal | 手续费 |
| deductFeeList | array | 抵扣信息 |
| makerFeeRate | decimal | maker 手续费率 |
| takerFeeRate | decimal | taker 手续费率 |
| createTime | long | 创建时间 |
| updateTime | long | 修改时间 |
| version | long | 版本号 |