Structuring Agent Spend Rollups so Finance and Engineering Agree on the Same Numbers

A shared taxonomy links invoices to engineers, teams, and outcomes.

· 9 min read
Cover illustration for “Structuring Agent Spend Rollups so Finance and Engineering Agree on the Same Numbers”
Cloud Agent Licensing · November 14, 2026 · 9 min read · 1,914 words

Per-run agent cost attribution requires a tagged identity on every agent request, a record of session usage, and a link from that session to its work product. Finance and engineering can agree on agent spend when those records map to a shared taxonomy before the month closes. The rollup must connect vendor charges to engineers, teams, projects, and outcomes, rather than treating either invoices or usage logs as the complete account.

Why finance and engineering see different agent spend numbers

Finance sees seats, invoices, and vendor contracts, while engineering sees API keys, token volumes, and compute minutes. Neither view is inherently wrong. The disagreement arises because a vendor charge does not identify the engineer responsible for a session, and a token count does not establish which cost center should pay. Reconciliation requires a mapping between those records.

The split in who owns the expense makes it harder to map those records. DoiT survey data shows that technology and finance share responsibility almost evenly, with neither clearly in charge. That leaves a gap between responsibility for consumption and responsibility for the budget. Engineering can explain how the tools were used without being in charge of the financial close, while finance can reconcile an invoice without knowing which tasks led to the charges. Neither account resolves the other's missing detail.

Meanwhile, billing changed faster than procurement could keep up. Across the major agents, the transition away from pricing that obscured token consumption took place inside roughly a year. Cursor moved from request-based to credit-based pricing in June 2025. OpenAI moved Codex from per-message to token-based pricing in April 2026, and GitHub Copilot completed its shift to token-based AI Credits on 1 June 2026. A seat count now tells finance little about actual consumption because the bill also depends on how the tool is used.

How token costs actually accumulate inside an agent loop

Input tokens dominate the cost of an agentic coding session, rather than the output tokens that contain the generated code. Every turn re-sends the accumulated conversation, so the input grows as the session continues, regardless of how much new work gets done. The visible prompt is only a small part of the activity being billed, and code volume is a poor proxy for that activity.

Instruction files such as CLAUDE.md add another recurring input because they are re-injected on every turn. Automatic prompt caching substantially reduces that cost when the file is unchanged, but the text remains part of the loop's input structure. Parallel sub-agents add more of those streams through fan-out. Agentic coding consequently consumes orders of magnitude more tokens than single-turn chat, with an extremely high ratio of input to output tokens. The rollup must capture the session's accumulated consumption.

What happens when neither side owns the number — the Uber and Microsoft cases

When the tools work and engineers use them more, spending rises with their sessions against a fixed licence budget. This requires only a budget built around a fixed expense and an operating model in which engineering behavior determines the actual charge.

Uber rolled out Claude Code to engineers in December 2025. Its CTO said in April 2026 that the company had exhausted its entire planned 2026 AI coding budget in four months. Uber also ran internal leaderboards that ranked engineers by Claude Code activity, which encouraged more use and, with token pricing, more spending. The company responded by capping token spend each month for each employee on each AI coding tool. That response put an enforceable limit at the point where consumption could be attributed to an individual.

Microsoft followed a similar path by moving engineers to GitHub Copilot CLI, a tool it owns and for which it can negotiate internal economics and standardize controls. The control mechanism differed from Uber's spending cap. Flat licence budgets can remain fixed while actual spend tracks engineering behavior, leaving the mismatch invisible until quarterly reconciliation. The missing connection is a shared accounting structure that makes consumption attributable before the budget review.

The common taxonomy that makes a shared rollup possible

The fix begins with a taxonomy. Both functions need to agree on how each agent's raw billing units become line items attributable to a cost center before the month closes. A dashboard can display that mapping, but it cannot supply agreement about what a line item represents. The taxonomy bridges three layers, namely the invoice layer, the attribution layer, and the outcome layer. Each answers a different question about the same spending.

The invoice layer records what the vendor bills, including API keys, credit consumption, and seat counts in the vendor's units. It establishes the financial starting point. The attribution layer then identifies the engineer, team, project, and repository associated with that usage, mapping the API key or virtual key to a cost center. This is the bridge between a vendor's account structure and the organization's own allocation structure. Without it, a valid invoice can still be unusable for team-level cost accounting.

The outcome layer connects spending to work product. It identifies which tickets the sessions addressed, which pull requests merged cleanly, and which required revision or were reverted. Finance needs the invoice and attribution layers to reconcile charges and allocate cost, while engineering needs attribution and outcomes to assess productivity. Their views overlap at attribution. That overlap is why both functions must sign off, rather than asking one to accept a report assembled entirely by the other.

Attribution is also where the structure most often breaks. An API key is usually a shared organization credential. It can establish where the vendor should send the bill without establishing who generated each charge. A tagged virtual key or identity must therefore travel through every agent request. That identity gives session usage a cost-center mapping instead of leaving finance to infer ownership from a shared credential after the fact.

How do you track which engineer or team owns each agent run and its cost?

Per-session instrumentation supplies the detail that monthly invoices cannot recover. For teams putting the taxonomy into practice, the starting point is to record session usage with the tagged identity that connects it to an engineer and team. Tool-call activity needs to be in that record because sessions usually have far more calls than the visible prompt suggests. Those calls are where token accumulation happens. Skipping this detail forces teams to reconstruct attribution from invoice totals and loses the task-level connection needed for outcome reporting.

At the harness layer, teams should track what each agent loaded at session start, including instruction files, MCP tool definitions, and skills. These inputs recur across turns and can account for avoidable recurring cost that the invoice will not explain. Their configuration belongs beside the execution record. This distinguishes the cost of a session's setup from the work product it eventually produces without assuming that a higher bill necessarily means more useful work.

At the outcome layer, session cost should join to the Linear ticket or GitHub issue addressed and the pull request produced. The record should also capture whether that pull request merged cleanly, required revision, and how much review time it consumed. Acceptance is the link to a usable unit cost. It lets finance compare cost per accepted ticket across months rather than compare only the price or volume of tokens.

Running agents on a cloud platform rather than developer laptops makes these inputs accessible from one place. Execution traces, harness configuration, and pull request outputs become infrastructure that teams can see and audit, instead of records spread across machines with no audit trail. This supports all three layers of the taxonomy. The platform provides access to the evidence, while the agreed identity mapping determines how that evidence enters the financial rollup.

How to structure the rollup itself — from raw usage units to joint sign-off

To turn those inputs into a repeatable close, finance and engineering should first define the reporting cadence, the fixed fields, and the sign-off step. The fields need to link vendor usage to the engineer, team, project, and cost center, and then to the outcome of that work. Cadence makes the process repeatable. Sign-off establishes when the record is accepted by both functions, rather than allowing separate versions to persist after the month closes.

Next, each agent's native billing unit should become a common internal dollar amount before aggregation. For seat-based tools, that means mapping seat counts and usage intensity, including credits consumed or AI Credit spend, to dollars by cost center. For token-based tools such as Claude Code and Codex, API key spend must go through the attribution layer to link it to an engineer, team, and project before it is rolled up. The sequence is important. Aggregating shared-key spending first obscures the ownership detail that the rollup is meant to preserve.

Finance then needs three numbers, both per team and in aggregate. Spend to date against budget establishes the current position. A forecast to month-end at the current run rate shows where that position is heading, with session-level data providing a stronger basis than invoice extrapolation. Cost per accepted ticket supplies the unit cost for comparing months and detecting drift before it becomes an overrun. Together, these measures connect the budget to current consumption and accepted work without treating token volume as a productivity measure.

Engineering's contribution to sign-off is the outcome record. Engineering should confirm which tickets the spending closed, mark sessions that led to reverted pull requests as rework cost, and note how much review they needed. Finance cannot get those facts from invoices alone. Its financial reconciliation and engineering's outcome confirmation therefore belong in the same close process, so that acceptance of the total also means acceptance of its allocation and work-product mapping.

Governance controls that keep the rollup honest after it goes live

New agents, engineers, and API keys can weaken attribution unless controls enforce the agreed structure as adoption expands. Governance therefore has a direct accounting role. It keeps incoming usage attached to the same identities and allocation rules that finance and engineering approved, rather than letting unassigned spending accumulate outside the reporting process.

Hard team-level budget caps are the minimum spending control. Uber's monthly cap for each employee and each tool shows how to enforce a limit before spending breaks the budget. Credential governance is the corresponding prerequisite for attribution integrity. Every session should run through a tagged virtual key or identity rather than relying on a shared organization API key as its identifier. If the engineer and team cannot be identified when the session runs, accurate reconciliation afterward is not dependable.

Isolated cloud VMs can apply several of these controls in one place. Audit logs become infrastructure rather than an opt-in practice, recording sessions, tool calls, and pull requests in one place. Credentials and sensitive data are kept off unmanaged devices. Network controls and data residency requirements can also be configured at the environment level instead of depending on individual laptop configurations. SOC 2, SCIM provisioning, and self-hosting options help meet the requirements for enterprise procurement and legal sign-off within the operating environment.

The rollup and its controls then reinforce each other. Attributed spending reveals which teams are approaching their caps before the month closes, while hard limits prevent consumption from moving faster than the reporting process can track. Documented methodology gives both functions a stable basis for sign-off. Finance receives a number with its ownership intact, and engineering can explain the work behind it without rebuilding the account from individual machines. Agreement becomes part of the close.

More in Cloud Agent Licensing