仓位管理 (Positions)
查询和管理交易仓位。
获取仓位列表
接口信息
- Method:
GET - Path:
/api/v1/positions - Authentication: 需要身份验证
响应示例
{
"positions": [
{
"position_id": "550e8400-e29b-41d4-a716-446655440000",
"symbol": "BTCUSDT",
"side": "long",
"status": "open",
"size_in_usd": "6500.00",
"size_in_tokens": "0.1",
"collateral_amount": "650.00",
"entry_price": "65000.00",
"mark_price": "65500.00",
"liquidation_price": "60000.00",
"leverage": 10,
"margin_ratio": "0.10",
"unrealized_pnl": "50.00",
"unrealized_pnl_percent": "7.69",
"realized_pnl": "0.00",
"accumulated_funding_fee": "0.50",
"accumulated_borrowing_fee": "0.10",
"net_value": "649.40",
"created_at": "2024-01-01T00:00:00Z",
"updated_at": "2024-01-01T01:00:00Z"
}
],
"total_unrealized_pnl": "50.00",
"total_collateral": "650.00"
}
响应字段说明
| 字段 | 类型 | 描述 |
|---|---|---|
| positions | array | 仓位列表 |
| total_unrealized_pnl | string | 总未实现盈亏 |
| total_collateral | string | 总抵押品数量 |