Get wallets
GET/accounts
This endpoint returns key information relating to all your accounts which may either be cash accounts or margin accounts. This includes digital asset balances, instrument balances, margin requirements, margin trigger estimates and auxiliary information such as available funds, PnL of open positions and portfolio value.
Responses
- 200
- application/json
- Schema
- success
Schema
- Success Response
- ErrorResponse
- Unrealised Funding Rate) * Haircut - Conversion Fee]`.
accountInactive
: The Futures account the request refers to is inactiveapiLimitExceeded
: The API limit for the calling IP address has been exceededauthenticationError
: The request could not be authenticatedinsufficientFunds
: The amount requested for transfer is below the amount of funds availableinvalidAccount
: The Futures account the transfer request refers to is invalidinvalidAmount
: The amount the transfer request refers to is invalidinvalidArgument
: One or more arguments provided are invalidinvalidUnit
: The unit the transfer request refers to is invalidJson Parse Error
: The request failed to pass valid JSON as an argumentmarketUnavailable
: The market is currently unavailablenonceBelowThreshold
: The provided nonce is below the thresholdnonceDuplicate
: The provided nonce is a duplicate as it has been used in a previous requestnotFound
: The requested information could not be foundrequiredArgumentMissing
: One or more required arguments are missingServer Error
: There was an error processing the requestUnavailable
: The endpoint being called is unavailableunknownError
: An unknown error has occurred
accounts object
A structure containing structures with account-related information for all margin and cash accounts.
cash object
Possible values: [cashAccount
]
The type of the account (always cashAccount)
balances object
A structure containing account balances.
flex object
Structure showing multi-collateral wallet details.
Possible values: [multiCollateralMarginAccount
]
The type of the account (always multiCollateralMarginAccount)
currencies object
Structure with collateral currency details.
property name* FlexCurrencySummary
Quantity of asset.
USD value of asset.
USD value of the asset usable for margin (Asset Value * Haircut).
Margin (in base currency) available for trading.
Total initial margin held for open positions (USD).
Total initial margin held for open positions and open orders (USD).
Total maintenance margin held for open positions (USD).
USD value of all collateral in multi-collateral wallet.
Balance value plus unrealised PnL in USD.
USD value of balances in account usable for margin (Balance Value * Haircut).
Unrealised PnL in USD.
Unrealised funding from funding rate (USD).
Total USD value of unrealised funding and unrealised PnL.
Unrealised pnl and unrealised funding that is usable as margin `[(Unrealised Profit/Loss
Margin Equity - Total Initial Margin.
[Balance Value in USD * (1-Haircut)] + (Total Unrealised Profit/Loss as Margin in USD)
property name* MarginAccount
Possible values: [marginAccount
]
The type of the account (always marginAccount)
The currency of the account. All figures shown in auxiliary and marginRequirements are in this currency.
balances object
A structure containing account balances.
auxiliary object
A structure containing auxiliary account information.
The portfolio value of the account, in currency.
The PnL of current open positions of the account, in currency.
The available funds of the account, in currency.
marginRequirements object
A structure containing the account's margin requirements.
The initial margin requirement of the account.
The maintenance margin requirement of the account.
The liquidation threshold of the account.
The termination threshold of the account
triggerEstimates object
A structure containing the account's margin trigger estimates.
The initial margin requirement of the account.
The maintenance margin requirement of the account.
The liquidation threshold of the account.
The termination threshold of the account
Possible values: [success
]
Server time in Coordinated Universal Time (UTC)
Possible values: [accountInactive
, apiLimitExceeded
, authenticationError
, insufficientFunds
, invalidAccount
, invalidAmount
, invalidArgument
, invalidUnit
, Json Parse Error
, marketUnavailable
, nonceBelowThreshold
, nonceDuplicate
, notFound
, requiredArgumentMissing
, Server Error
, Unavailable
, unknownError
]
Possible values: [accountInactive
, apiLimitExceeded
, authenticationError
, insufficientFunds
, invalidAccount
, invalidAmount
, invalidArgument
, invalidUnit
, Json Parse Error
, marketUnavailable
, nonceBelowThreshold
, nonceDuplicate
, notFound
, requiredArgumentMissing
, Server Error
, Unavailable
, unknownError
]
Error description.
Possible values: [error
]
Server time in Coordinated Universal Time (UTC)
{
"result": "success",
"serverTime": "2016-02-25T09:45:53.818Z",
"accounts": {
"cash": {
"type": "cashAccount",
"balances": {
"xbt": 141.31756797,
"xrp": 52465.1254
}
},
"fi_xbtusd": {
"type": "marginAccount",
"currency": "xbt",
"balances": {
"FI_XBTUSD_171215": 50000,
"FI_XBTUSD_180615": -15000,
"xbt": 141.31756797,
"xrp": 0
},
"auxiliary": {
"af": 100.73891563,
"pnl": 12.42134766,
"pv": 153.73891563
},
"marginRequirements": {
"im": 52.8,
"mm": 23.76,
"lt": 39.6,
"tt": 15.84
},
"triggerEstimates": {
"im": 3110,
"mm": 3000,
"lt": 2890,
"tt": 2830
}
},
"flex": {
"type": "multiCollateralMarginAccount",
"currencies": {
"XBT": {
"quantity": 0.1185308247,
"value": 4998.721054420551,
"collateral": 4886.49976674881,
"available": 0.1185308247
},
"USD": {
"quantity": 5000,
"value": 5000,
"collateral": 5000,
"available": 5000
},
"EUR": {
"quantity": 4540.5837374453,
"value": 4999.137289089901,
"collateral": 4886.906656949836,
"available": 4540.5837374453
}
},
"balanceValue": 34995.52,
"portfolioValue": 34995.52,
"collateralValue": 34122.66,
"initialMargin": 0,
"initialMarginWithOrders": 0,
"maintenanceMargin": 0,
"pnl": 0,
"unrealizedFunding": 0,
"totalUnrealized": 0,
"totalUnrealizedAsMargin": 0,
"marginEquity": 34122.66,
"availableMargin": 34122.66
}
}
}