Attribution
Every model call through Nexus carries who made it and what it was for, so spend can be read by person, team, model or product.
| Recorded | From |
|---|---|
| Person | The token that made the call, or the person who started the product run |
| Team | The team named on the call, else the person's default team, else none ("Unassigned") |
| Product and capability | The product that made the call (for example robustness › review), chat for chats, agents › claude or agents › codex for coding agents, or core for direct API calls. A cloud machine's running time is cloud › compute |
| Session | For nexus claude and nexus codex, the session the call belongs to |
Choosing the team
The team is, in order:
- the one the caller names: the
x-nexus-teamheader, or ateamfield in the request. The caller must be in that team (else403not_in_team); an unknown team is404. - else the caller's default team;
- else none, shown as "Unassigned".
From the CLI, --team <slug> or NEXUS_TEAM names the team for product runs and coding-agent sessions:
NEXUS_TEAM=platform nexus claudeEach spend record keeps the team's id and its slug at the time, so a renamed or deleted team's history still reads.
Reading it back
nexus spend # budget and spend by product and capability
nexus analytics --by team --days 7 # usage by team, person, model, product or day
nexus analytics --by team --depth 1 # each top-level team with everything under it
nexus analytics --by team --under engineeringBy team, spend rolls up the tree: each group counts its own spend and that of every team under it, and spend on a
parent team itself appears as its own "(direct)" row. The API is
GET /v1/analytics/usage.
Owners and admins see the whole organization. Everyone else sees their own calls and those of the teams they are in and every team under those; grouped by person, other people in those teams appear as one "Others in your teams" row.