Skip to content

Envoy AI Gateway becomes Agent Router and joins the Agentic AI Foundation

Learn more

Claude API Spend Governance: The Complete Guide to Budgeting, Chargeback, and Cost Control at Scale

TL;DR: Anthropic’s spend limits stop requests once an organization or workspace reaches its monthly cap, but every limit sits at the organization, workspace, or Claude Code user level. Agents and projects that share a workspace share its cap. Tetrate Agent Router Enterprise uses token brokering to enforce token limits per team or agent in the request path, so a looping agent stops at its own limit. Chargeback needs spend attributed to each team, agent, and project, which the gateway records on every request. Agent Router Enterprise is licensed at a flat rate by feature set, deployment footprint, and support tier, so the gateway’s own cost does not rise with inference spend.

When a CFO asks which team drove last month’s Claude token spend, the answer is missing if every team shares one API key. Anthropic’s tools show what an organization or workspace spent and can cap that spend. Cost attribution below the workspace, to each agent or project, needs a gateway layer in the request path.

This guide explains how Claude API billing works and where Anthropic’s own controls stop. It then shows how an enterprise AI gateway adds per-team attribution, request-path enforcement, and chargeback reporting.

How Claude API billing works

Anthropic charges per million tokens, with separate rates for input and output. The model a team picks and the length of its responses both shape the bill.

Breaking down costs by Claude model tier

Anthropic publishes per-million-token pricing for each model. Output tokens cost five times the input rate on every current Claude model, as of this writing. The Fable models are the most expensive tier, above Opus.

Model tierRelative costTypical use case
HaikuLowestHigh-volume, lightweight tasks (classification, extraction, routing)
SonnetMid-rangeGeneral-purpose agent and coding workloads
OpusHigher, below the Fable modelsComplex reasoning, multi-step analysis, and in-depth code generation

A task on Haiku produces a different cost profile than the same task on Opus. Matching each workload to the cheapest tier that handles it well is the first cost decision a team makes.

Controlling cache usage at scale

Prompt caching stores frequently reused prompt content so later requests read it from the cache instead of reprocessing the full input. Cache reads bill at 10% of the base input price on most Claude models, 5% on Claude Opus 5.5 and Sonnet 5.5, and 2.5% on Claude Fable 5.1 and Mythos 5.1, as of this writing. A five-minute cache write costs 1.25 times the base input price, and a one-hour write costs twice the base price.

Anthropic sets a minimum cacheable prompt length, and shorter prompts are not cached even with the cache_control marker set. The minimum is 512 tokens on Claude Opus 5.5, Opus 5, Sonnet 5.5, Haiku 5.5, and the Fable and Mythos models. Other models need between 1,024 and 4,096 tokens. Check the current figure for each model before designing prompts around it, because the minimum differs by model.

Teams that use caching well reduce cost. Teams that misconfigure it pay the write premium without the read savings.

Tracking Claude API costs in the Console

Every budget conversation starts with cost attribution: tracing each dollar of Claude API spend to an internal cost center. The Claude Console’s Cost page breaks spend down by workspace and model, with a daily chart for each month. Anthropic’s Usage and Cost API groups token usage by API key, workspace, and model. Cost groups only by workspace or model.

Anthropic’s spend limits reset each calendar month. The Usage and Cost API reports token usage in 1-minute, 1-hour, or 1-day buckets, and it reports cost in daily buckets only. Neither report lists individual requests.

Anthropic supports cost allocation by workspace, which works when each team has its own workspace. Agents and projects inside one workspace still show up as one number. Mapping workspaces to cost centers remains your job.

The hidden risks of governance without enforcement

Visibility without enforcement leaves a FinOps team with a reporting tool. A team that can see spend in a dashboard but cannot stop a runaway agent mid-request finds out about overspend after it happens. Governance needs enforcement in the request path.

A looping agent that keeps calling a frontier model can run up charges for days before anyone notices, because the only limit in its path is a monthly cap shared by its whole workspace or organization.

How shared API access hides team costs

A common attribution failure starts with a single API key shared across teams. When every team calls Claude through the same key, all spend lands on one line item. No dashboard can reconstruct which team spent what after the fact, because the key carries no team identity. Without per-team keys or identity on every request, nobody can answer the CFO’s question about last month’s spend.

The problem grows with each new team that joins the shared key, or sets up its own keys and billing with no shared policy. Scaling governance means creating one enforcement point where every team’s requests pass through the same policy layer.

How to stop overspend in real time

Anthropic’s spend limits cap monthly spend for the organization and for individual workspaces. Rate limits cap requests, input tokens, and output tokens per minute. When an organization reaches its tier’s spend cap, the API returns a rate limit error with no retry-after header. The SDK’s automatic retries keep failing until access resumes. A spend limit you set yourself returns an invalid request error instead.

These caps stop requests, but each one covers a whole organization or workspace. The Claude Code workspace is the only workspace with per-user spend limits, and the Default Workspace cannot be limited at all. Agents and projects that share a workspace share its cap, so one looping agent can use up the allocation of every other agent in that workspace.

Token brokering is the alternative. The gateway checks every request against policy before it routes the request, as described in our token brokering announcement. With token brokering, token limits apply to each team or agent separately.

Automating chargeback for AI project spend

Chargeback requires attribution, which in turn requires a mechanism that ties every request to the team, agent, or project that sent it. Without that mechanism, chargeback is a manual reconciliation exercise that arrives too late to inform decisions.

Implementing showback vs. chargeback models

In FinOps practice, chargeback posts costs to each P&L owner’s budget, while showback reports costs to the teams responsible. Both depend on the same attribution data. The difference is whether the cost lands on a team’s budget.

AttributeShowbackChargeback
DefinitionReports consumption to the teams responsiblePosts consumption to P&L budgets
Financial impactInformationalDirect budget impact
When to useWhen teams need to see their costs but budgets stay centralWhen accounting policy assigns AI spend to team budgets
What it requiresPer-team or per-project attribution dataPer-team attribution plus finance system integration

Structuring Claude spend for chargebacks

The structural prerequisite for chargeback is mapping every Claude API request to a cost center. Two approaches work. One is a separate API key for each team or project. The other is short-lived tokens from your identity provider, such as Okta or Microsoft Entra ID, so every request carries a team identity without individual keys to manage.

Agent Router Enterprise supports both patterns, accepting identity provider tokens or a project-scoped gateway API key. Each key carries its own routing chain and policies. Agent Router Enterprise attributes each request to a project and team from the key it carries, so developers add no tags in code. The AI cost visibility page covers how this attribution works in practice.

Mapping API costs to cost centers

Mapping connects technical identities, such as API keys or agent IDs, to the organization’s cost centers and P&L budgets. This mapping is the step that turns gateway telemetry into a chargeback report.

The attribution data comes from the gateway’s per-request telemetry. The mapping itself is a FinOps responsibility, because it reflects the organization’s own accounting structure, which the gateway cannot infer. Once the mapping exists, the telemetry feeds chargeback reports in your finance or FinOps tooling, broken down by cost center. The budget guide describes how to set a budget for a whole team, each teammate, or one API key.

Allocating Claude API spend by agent and project

Agent-level attribution matters because agents behave differently from human users. A looping agent can use up a team’s monthly allocation long before the invoice arrives. Without per-agent tracking, the team’s total shows the spike but not which agent caused it.

The project is the unit that makes ROI analysis possible. A team might run three projects on Claude: a customer support agent, a code review assistant, and an internal knowledge base. Without project-level attribution, all three collapse into the team’s total. With per-request attribution through the gateway, each project’s spend appears separately, so the FinOps team can compare cost to outcome for each one.

Showback and chargeback dashboards in Agent Router Enterprise replace the single lump-sum line item with a breakdown of who spent what, on which model, for which project.

Enforcing Claude API budgets in the request path

The request path is where a limit can stop one agent’s request before its tokens are consumed. Dashboards, alerts, and monthly reports all operate after the spend has occurred.

This changes the FinOps question from “how much did we spend” to “how much can we spend.” With limits enforced in the request path, the answer to the second question is a number the gateway enforces.

Stopping runaway agents with token brokering

Static budgets describe how much a team should spend, while token limits stop usage when a team reaches its limit. Agent Router Enterprise implements this through token brokering. The administrator sets policy in the management plane, and the gateways enforce it on every request.

Token brokering checks every request against the remaining allocation for its team or agent before forwarding it to the model provider. When a team or agent reaches its token limit, usage stops. The token brokering launch describes the mechanism: Agent Router Enterprise sits between developers or agents and the models they call, tying every request to approved spend policy before routing.

Budget reporting lags live traffic by a few minutes. Token limits are the hard cap, and budgets track spend against a plan.

Applying granular API spend limits

Agent Router Enterprise attributes spend by team, by teammate, and by API key. Token limits cap each team or agent in the request path.

A team might have a monthly budget. Within that team, the customer support agent and the code review agent each run on their own API key, with their own token limit. The API key limits guide describes how to configure these limits on an API key.

This separation keeps one agent’s overconsumption from using up the allocation another agent needs. It also gives FinOps teams a clear answer when a specific agent exceeds its allocation, because the gateway logs show which agent consumed the tokens.

Comparing gateway limits and provider spend caps

The difference between gateway limits and Anthropic’s caps is scope: Anthropic’s caps stop requests for a whole organization or workspace, while gateway token limits stop requests for one team or agent.

AttributeGateway token limits (token brokering)Provider caps and dashboards
TriggerThe team’s or agent’s token limitThe organization’s or workspace’s monthly cap
What it stopsToken limits reject requests over the ceiling before they reach the modelAnthropic’s limits reject requests once the organization or workspace cap is reached
ScopeEach team or agentThe organization, a workspace, or a Claude Code user
What it reportsEnforcement events with request-level telemetryUsage data in minute, hour, or day buckets, cost data in daily buckets
RequirementA gateway in the request pathThe provider’s own tooling, with no gateway required

Gateway limits need infrastructure in the request path. Anthropic’s tooling works without a gateway.

Preventing overspend with Claude API alerts

Alerts give a FinOps team awareness, but an alert that fires after unplanned spend has occurred cannot prevent the next incident. Agent Router Enterprise budgets raise an alert when spend passes the limit, which tells the FinOps team when a team or key has gone past its plan. Token brokering provides the enforcement layer that stops runaway spend before it compounds. The budget alerts video demonstrates how budget alerts and cost visibility work in practice.

Inline controls for Claude API costs

Inline controls are policies evaluated on every request before it reaches the model. They include token limits, which set the hard cap, and routing rules, which decide which model serves which request. Model aliases separate the specific model version from the calling application.

The API call cost page covers how API pricing structures work and where cost decisions sit. Inline controls move those decisions out of each developer’s code and into central policy, so the platform team applies them consistently across teams.

Automated guardrails for API spend

Automated guardrails run inline in the data path and enforce policy on every request. For spend governance, the guardrails include token limits through token brokering and model access control, which decides which models each team’s key can reach. Model access control matters for FinOps because an unapproved model can carry an unbudgeted cost, such as a team running a higher-tier model on a production workload without updating its allocation.

Agent Router Enterprise also runs PII redaction, policy enforcement, and prompt controls inline, so PII is caught before a prompt reaches a model provider. The guardrails documentation describes how these controls are configured and monitored.

Quantifying AI ROI through granular attribution

AI ROI is unanswerable without attribution. The ROI calculation needs a numerator, the business value produced, and a denominator, the spend attributable to the project that produced it. Without attribution, the denominator is unknown.

In an anonymized deployment at a large fintech company with thousands of developers, consolidating every AI tool into one governed path gave the customer full consumption telemetry. AI ROI became trackable for the first time.

Connecting token usage to ROI takes two steps. First, attribute all Claude API spend to projects using the gateway’s per-request telemetry. Second, compare each project’s spend to its measurable business outcome over time, such as tickets resolved, code reviews completed, or documents processed.

Agent Router Enterprise reports spend by project, team, key, and model a few minutes behind live traffic. The FinOps team can review per-project spend each month without a manual reconciliation exercise. The gateway answers “who spent what on which project.” The FinOps team answers “was it worth it.”

Agent Router Enterprise

Tetrate Agent Router Enterprise routes AI agent traffic across providers and your own models, with policy, cost controls, and audit on every request — in cloud, on-prem, or edge.

Learn more

Closing the governance gap between Anthropic and your chargeback report

Anthropic provides token counts, cost reports, and spend caps for the organization or individual workspaces. Spend governance also needs enforcement below the workspace. Chargeback needs attribution to each team, agent, and project. Agent Router Enterprise adds both, with token limits per team or agent in the request path. Pricing is flat, based on feature set, deployment footprint, and support tier, so procurement can predict cost up front instead of absorbing a percentage-based markup on inference spend.

Tetrate Agent Router Enterprise is built on the Agent Router project (formerly Envoy AI Gateway), an open source data plane at the Agentic AI Foundation (AAIF) that runs on the Envoy proxy. Agent Router Enterprise runs gateways in any cloud, region, on-premises site, or edge location, and manages all of the gateways from one management plane.

Start a fast-track evaluation: first routed request under five minutes, nothing to install. See per-team token limits and spend attribution on your own traffic.

FAQs

How do you govern Claude API spend at scale?

Anthropic enforces monthly spend limits for the organization and for individual workspaces. Its Usage and Cost API reports spend by workspace. An enterprise AI gateway such as Tetrate Agent Router Enterprise adds token limits per team or agent in the request path, plus attribution by team, agent, and project.

Can you enforce Claude API budgets before overspend happens?

Yes. Tetrate Agent Router Enterprise uses token brokering to check every request against its token limit before forwarding it to the model. Token limits are the hard cap, while budgets track spend against a plan.

How do you attribute Claude API costs by team?

Give each team its own API key or short-lived identity provider token, then route all requests through a gateway that attributes each call to its team, agent, and project. Anthropic’s Usage and Cost API groups cost by workspace or model, so it cannot separate teams that share a workspace.

What’s the difference between token limits and budgets?

In Agent Router Enterprise, token limits are enforced in the request path and stop usage when the limit is reached. Budgets track spend against a plan and update a few minutes behind live traffic. Use token limits for hard caps and budgets for planning.

Does Anthropic provide built-in chargeback reporting?

Partly. Anthropic’s Usage and Cost API can allocate cost by workspace, which works for chargeback when each team has its own workspace. It cannot split spend between agents or projects that share a workspace.

Key terms glossary

Token brokering: A mechanism in Tetrate Agent Router Enterprise that checks every AI request against policy before routing it to a model. The gateway enforces a token limit per team or agent and stops requests at the limit.

Token limits: Per-team or per-agent caps on token use, enforced in the request path. A request over the limit is rejected before it reaches the model.

Spend limits: Anthropic’s monthly caps on API spend for an organization or an individual workspace. Requests fail with an error once a cap is reached.

Showback: Reporting that shows each team the AI consumption it is responsible for, without posting it to the team’s budget. Every FinOps practice uses showback, whether or not it also runs chargeback.

Chargeback: An allocation practice that posts actual AI consumption to the P&L budgets of specific business units. Chargeback makes teams directly accountable for their spend.

Request path enforcement: Policy evaluation inside the request path, before a request reaches the model provider. Enforcement at this point stops overspend before it happens, while a report only describes it afterward.

Prompt caching: A Claude API feature that stores frequently reused prompt content so later requests read it from the cache. Cached reads cost 10% of the standard input price on most Claude models, 5% on Claude Opus 5.5 and Sonnet 5.5, and 2.5% on Claude Fable 5.1 and Mythos 5.1, as of this writing. Five-minute cache writes cost 25% more than standard input.

Workspace: A subdivision of an Anthropic organization used to group API keys, set spend limits, and report usage. Agents and projects inside one workspace share its spend cap. The Default Workspace cannot be given a spend limit. Spend attribution below the workspace level requires a gateway layer.

Claude Code user: A developer using Claude Code whose spend is tracked and capped at the individual user level within the Claude Code workspace. The Claude Code workspace is the only workspace where Anthropic enforces per-user spend limits.


Learn more about Tetrate Agent Router Enterprise — enterprise AI agent routing with policy, cost controls, and audit across every gateway.

Decorative CTA background pattern background background
Tetrate logo in the CTA section Tetrate logo in the CTA section for mobile

Ready to enhance your
network

with more
intelligence?