Skip to main content

Get Position Info

info
  • Need authentication. Up to 10 requests per second.
  • Query your active positions. Requires Earn permission on the API key.

HTTP Request

GET/v5/earn/advance/position

Request Parameters

ParameterRequiredTypeComments
categorytruestringProduct type. SmartLeverage
productIdfalsestringProduct ID
coinfalsestringUnderlying asset to filter by, e.g. BTC, ETH
limitfalseintNumber of items per page. Default: 20, Max: 20
cursorfalsestringPagination cursor. Use nextPageCursor from previous response

Response Parameters

ParameterTypeComments
categorystringProduct category
nextPageCursorstringCursor for the next page. Empty string if no more data
listarrayObject
> positionIdstringPosition ID
> productIdstringProduct ID
> categorystringProduct category
> investCoinstringInvestment coin
> amountstringPosition amount, unit is investCoin
> durationstringProduct term, e.g. 1d, 2d, 3d
> settlementTimestringSettlement time, unix timestamp in ms
> accountTypestringStaking account: FUND, UNIFIED
> orderIdstringStaking order ID
> underlyingAssetstringUnderlying asset, e.g. BTC, ETH
> directionstringLong, Short
> leveragestringFixed leverage multiplier, e.g. 3, 5
> breakevenPricestringBreakeven price (precision-adjusted)
> initialPricestringUnderlying asset price at position creation (precision-adjusted)
> statusstringActive: Staking, Redeeming: Redeeming, Settled: Settled
> createdTimestringPosition creation time, unix timestamp in ms
> redeemableboolWhether the position can be redeemed now. false if: global redemption is disabled, a pending redeem order exists, or less than 60 minutes remain until settlement
> orderLinkIdstringUser customised order ID

Request Example

GET /v5/earn/advance/position?category=SmartLeverage&productId=12959 HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: XXXXX
X-BAPI-API-KEY: xxxxxxxxxxxxxxxxxx
X-BAPI-TIMESTAMP: 1672280218882
X-BAPI-RECV-WINDOW: 5000

Response Example

{
"retCode": 0,
"retMsg": "",
"result": {
"category": "SmartLeverage",
"list": [
{
"positionId": "1252",
"productId": "12959",
"category": "SmartLeverage",
"investCoin": "USDT",
"underlyingAsset": "BTC",
"direction": "Long",
"leverage": "50",
"amount": "1000",
"breakevenPrice": "67367.16",
"initialPrice": "67243.31",
"duration": "1d",
"settlementTime": "1774944000000",
"createdTime": "1774838832000",
"status": "Active",
"redeemable": false,
"accountType": "FUND",
"orderLinkId": "",
"orderId": "d7be0f06-af7b-4ae8-bd2f-37000d67edf2"
}
],
"nextPageCursor": ""
},
"retExtInfo": {},
"time": 1775038447882
}