> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.astropods.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.astropods.com/_mcp/server.

# ast billing

Read the active account's plan, spend, remaining credit, spend controls, and invoices. Set the account's spend warning and limit.

```bash
ast billing <subcommand>
```

## billing get

Get the plan, spend, remaining credit, and spend controls.

```bash
ast billing get [--json]
```

## billing status

Get the billing gating status for the active account.

```bash
ast billing status [--json]
```

## billing invoices

List the account's invoices, newest first.

```bash
ast billing invoices [--limit <n>] [--json]
```

`--limit` sets how many invoices to show. The default is 12.

## billing agents

Break down the account's compute spend by agent.

```bash
ast billing agents [--json]
```

## billing models

Break down the account's [AI Gateway](/ai-gateway) spend by model, or one model's spend by agent.

```bash
ast billing models [<model>] [--json]
ast billing models --features [<feature>] [--json]
```

Pass a model name to see which agents spent on it. With `--features`, the command breaks down the AI Gateway spend that Astropods features make on the account's behalf, such as the eval judge, the governance agent, and local development. Pass a feature name to see that feature's spend by model.

## billing set

Set the account's own spend controls. The warning notifies. The limit suspends the account's agents. Both measure against usage spend for the period, before credit is drawn down.

```bash
ast billing set [--warning <amount>] [--limit <amount>] [--clear-warning] [--clear-limit]
ast billing set --metric compute|gateway [--warning <amount>] [--limit <amount>]
```

A control you do not name keeps its current value. `--clear-warning` and `--clear-limit` remove one.

| Flag                        | Description                                     |
| --------------------------- | ----------------------------------------------- |
| `--warning <amount>`        | Spend amount that notifies                      |
| `--limit <amount>`          | Spend amount that suspends the account's agents |
| `--clear-warning`           | Remove the spend warning                        |
| `--clear-limit`             | Remove the spend limit                          |
| `--metric compute\|gateway` | Cap a metered quantity instead of spend         |

With `--metric`, the numbers cap a metered quantity instead of money. This is the only control that works on a plan billed at zero, where spend never moves. The `compute` metric counts CU-hours. The `gateway` metric counts US dollars of model usage.

## Next steps

* [Usage limits](/usage-limits): warn yourself before an account spends too much, and stop it before it spends more
* [Usage](/usage): see what an account has spent and created this period
* [AI Gateway](/ai-gateway): the model access that `billing models` reports on