> For the complete documentation index, see [llms.txt](https://docs.allnodes.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.allnodes.com/endpoints/account.md).

# Account

## Get account balance

<mark style="color:blue;">`GET`</mark> `https://www.allnodes.com/api/v1/account/balance`

This endpoint returns the total and currently available account balances in USD.

The available balance excludes funds reserved for upcoming charges.

#### Headers

| Name                                            | Type   | Description  |
| ----------------------------------------------- | ------ | ------------ |
| Authorization<mark style="color:red;">\*</mark> | string | Bearer TOKEN |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
  totalBalance: number;
  availableBalance: number;
  balanceRunsOutAt: string | null;
}
```

{% endtab %}
{% endtabs %}

## Get all invoices

<mark style="color:blue;">`GET`</mark> `https://www.allnodes.com/api/v1/account/invoices`

This endpoint returns all invoices issued for your account.

Invoices are returned from newest to oldest. The invoice amount is represented as a positive USD value.

#### Headers

| Name                                            | Type   | Description  |
| ----------------------------------------------- | ------ | ------------ |
| Authorization<mark style="color:red;">\*</mark> | string | Bearer TOKEN |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
  invoices: [
    {
      id: number;
      name: string;
      amountUSD: number;
      timestamp: string;
    }
  ]
}
```

{% endtab %}
{% endtabs %}

## Get an invoice as CSV

<mark style="color:blue;">`GET`</mark> `https://www.allnodes.com/api/v1/account/invoices/:id/csv`

This endpoint returns the specified invoice in CSV format.

#### Path Parameters

| Name                                 | Type   | Description                                            |
| ------------------------------------ | ------ | ------------------------------------------------------ |
| id<mark style="color:red;">\*</mark> | number | Invoice ID returned by the "Get all invoices" endpoint |

#### Headers

| Name                                            | Type   | Description  |
| ----------------------------------------------- | ------ | ------------ |
| Authorization<mark style="color:red;">\*</mark> | string | Bearer TOKEN |

{% tabs %}
{% tab title="200: OK " %}

```javascript
Invoice Number,Category,Name,Description,Start,End,Duration,Amount (USD)
260812345,Advanced plan charges,Validator 1,0x1234...,01.08.2026 00:00,01.09.2026 00:00,744 hours,25.00
260812345,Total,-,-,-,-,-,25.00
```

{% endtab %}
{% endtabs %}
