An agent is not creatable without a budget. A null cap would mean no limit and no per-agent spend record at all.
Money is integer micro-USD on the wire. Every amount is carried and stored as an integer number of micro-USD (
1 USD = 1,000,000 micro-USD), in fields suffixed _micro_usd (cap_micro_usd, max_task_micro_usd, consumed_micro_usd). Clients display dollars for humans but convert before sending: the CLI --budget-usd accepts a decimal and converts client-side, and the SDK takes whole-micro-USD strings (never a bare number, to avoid float rounding).Creating an agent with a budget
A budget is set at agent-creation time — a period cap, a per-task ceiling, and the reset period.How pre-flight pricing works
Before each model call or priced tool call, Vetta computes a quote — an upper bound on what the call will cost at the session’s completion window. The quote is checked against, in order:- The organization balance — is there money? See Credits & billing.
- The agent period cap (
cap_micro_usd) minus what it has already spent this period. - The task ceiling (
max_task_micro_usd) minus what this session has already spent. - Any session budget you set explicitly.
budget.exceeded event is emitted. The agent is told, in-band, that it is out of budget, so it can wrap up cleanly rather than crash.
Session budgets
Beyond the agent budget, a session can carry its own cap. Work pauses at the cap and resumes when you raise or remove it.- A replacement cap must be strictly greater than the session’s already-consumed cost.
- Removal is one-way: you cannot re-add a cap to a session that had one removed, or add one to a session created without it.
- Raising or removing a cap automatically resumes work that paused at it.
Reading spend
Everything is metered against real backend cost in integer micro-USD and attributed per component and per session. Model spend is metered across the five-tier token ledger —input, cache_write, cache_read, output, and reasoning — the same tiers the model router prices each call against.
CLI
11902000 is $11.902. The model component decomposes into the five token tiers above; the other components are computer, search (web tools) and media (generation). A component with no spend is absent, not zero.
Configuration reference
An agent budget has three required fields:integer
required
The total the agent may spend within its period, in integer micro-USD. The CLI
--budget-usd and SDK helpers convert dollars to this before sending.integer
required
The ceiling for a single task, in integer micro-USD. A session cannot exceed this even if the period cap has room.
string
required
The reset window:
day, week, or month.Next: durable runtime
Waiting costs storage, not compute.