# Get account balance

> Your balance and fee summary as a point-in-time snapshot, the same object the balances:{user_id} WebSocket channel publishes, so a REST read and a channel update delta are interchangeable.

Source: https://docs.stxapp.io/api/rest/account/get-account-balance/

Your balance and fee summary as a point-in-time snapshot, the same object the `balances:{user_id}` WebSocket channel publishes, so a REST read and a channel `update` delta are interchangeable. `available_balance` is rounded down to the cent and the three liabilities up, in both signs, so they need not reconcile to the cent; treat each as authoritative on its own.

```http
GET /api/v1/account/balance
```

Send it with your own demo key: [Try it](/quick-start/?op=account_balance_get#try-it).

## Responses

| Status | Description | Schema |
|---|---|---|
| `200` | Success | object |
| `401` | Missing, malformed or unrecognized signature, or a timestamp outside the 30-second window. Body: &#123;"error":"Missing or invalid API key credentials"&#125; | Error |
| `403` | The account behind this key is not active, for example it is pending approval or suspended. Body: &#123;"error":"Your account is suspended. Contact support."&#125;, the message naming the account's status. | Error |

## Example

Request:

```bash
curl --request GET \
  --url 'https://demo.stxapp.io/api/v1/account/balance' \
  --header 'X-STX-ACCESS-KEY: <key-id>' \
  --header 'X-STX-ACCESS-TIMESTAMP: <unix-ms>' \
  --header 'X-STX-ACCESS-SIGNATURE: <base64-ed25519>'
```

Response `200`:

```json
{
  "balance": {
    "account_balance": "0.6700",
    "account_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
    "available_balance": "0.6700",
    "base_fee_percent": null,
    "buy_order_liability": "0.6700",
    "escrow": "0.6700",
    "fee_schedule": "fixed_percent",
    "loyalty_tier": "rookie",
    "maker_factor": null,
    "points": null,
    "position_premium_liability": "0.6700",
    "sell_order_liability": "0.6700",
    "taker_factor": null,
    "total_adjustments": "0.6700",
    "total_deposits": "0.6700",
    "total_fees": "0.6700",
    "total_settlement_pnl": "0.6700",
    "total_trade_count": 0,
    "total_traded": "0.6700",
    "total_withdrawals": "0.6700",
    "user_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
  }
}
```

### Response fields

| Field | Type | Description |
|---|---|---|
| `account_balance` | decimal | The account's cash balance. Unaffected by placing an order, but not all of it may be available. In dollars. |
| `account_id` | uuid | The account this balance is for. |
| `available_balance` | decimal | The balance available to withdraw or place further orders with. Rounded **down** to the cent, so it never overstates what is spendable. In dollars. |
| `base_fee_percent` | number | The fee percentage on the `fixed_percent` schedule; `null` for any other schedule. A number, not a money string. |
| `buy_order_liability` | decimal | Total liability from buy orders, including the potential trade-fee reserve. Rounded **up** to the cent. In dollars. |
| `escrow` | decimal | The account's escrow balance. In dollars. |
| `fee_schedule` | string | The account's fee schedule. |
| `loyalty_tier` | string | The account's loyalty tier. Every account has one; new accounts start at `rookie`. |
| `maker_factor` | number | Per-trade maker fee factor, present only on the `on_trade` and `loyalty_tier_on_trade` schedules; `null` otherwise. A number, not a money string. |
| `points` | integer | Loyalty points the account has accumulated. A whole number, not a money string. |
| `position_premium_liability` | decimal | Total liability from position premiums. Routinely negative. Rounded **up** to the cent in both signs. In dollars. |
| `sell_order_liability` | decimal | Total liability from sell orders, including the potential trade-fee reserve. Rounded **up** to the cent. In dollars. |
| `taker_factor` | number | Per-trade taker fee factor, present only on the `on_trade` and `loyalty_tier_on_trade` schedules; `null` otherwise. A number, not a money string. |
| `total_adjustments` | decimal | Lifetime total balance adjustments. In dollars. |
| `total_deposits` | decimal | Lifetime total deposits. In dollars. |
| `total_fees` | decimal | Total fees from all settlements and other fees. In dollars. |
| `total_settlement_pnl` | decimal | Total gross profit and loss from all settlements. In dollars. |
| `total_trade_count` | integer | The number of trades the account has made across every market. |
| `total_traded` | decimal | The risk the account has committed across every market. In dollars. |
| `total_withdrawals` | decimal | Lifetime total withdrawals. In dollars. |
| `user_id` | uuid | The user that owns the account. |
