Balance
GET
/api/trading/accounts/{account_id}/balance
const url = 'https://example.com/api/trading/accounts/1/balance';const options = { method: 'GET', headers: { 'INF-ACCESS-KEY': '<INF-ACCESS-KEY>', 'INF-ACCESS-TIMESTAMP': '<INF-ACCESS-TIMESTAMP>', 'INF-ACCESS-SIGNATURE': '<INF-ACCESS-SIGNATURE>' }};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/api/trading/accounts/1/balance \ --header 'INF-ACCESS-KEY: <INF-ACCESS-KEY>' \ --header 'INF-ACCESS-SIGNATURE: <INF-ACCESS-SIGNATURE>' \ --header 'INF-ACCESS-TIMESTAMP: <INF-ACCESS-TIMESTAMP>'Cash, what resting orders and pending withdrawals hold, and worst-case equity.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”account_id
required
Account Id
integer
Responses
Section titled “Responses”Successful Response
Media typeapplication/json
Balance
object
account_id
required
Account Id
integer
cash
required
Cash
integer
balance
required
Balance
Cash less what resting orders and pending withdrawals hold.
integer
held_collateral
required
Held Collateral
integer
held_for_withdrawals
required
Held For Withdrawals
Cash the vault may still pay out for pending withdrawals. No order can use it.
integer
equity
required
Equity
Worst-case equity less what is held for withdrawals.
integer
deposited
required
Deposited
integer
Examplegenerated
{ "account_id": 1, "cash": 1, "balance": 1, "held_collateral": 1, "held_for_withdrawals": 1, "equity": 1, "deposited": 1}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Examplegenerated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}