AI Usage Attribution

Quick definition

AI usage attribution is the practice of linking each AI model request, and its cost, to the person, team, course, customer or deal that caused it. It turns a single provider invoice into a breakdown of what each program, cohort or evaluation consumed, so AI costs can be reported, compared and planned.

AI & agents
Also known as
AI cost attribution, AI chargeback, AI showback, AI spend attribution, per-user AI usage tracking
5
min read
October 17, 2026

What is AI usage attribution?

AI usage attribution answers a question that a provider invoice cannot: who used this, and for what? An AI provider bills an account. Inside that account, usage from a training course, a sales evaluation, an internal tool and a hackathon all looks the same unless something recorded the context of each request at the time it was made.

Attribution is that record. Each request is associated with dimensions the business cares about, such as the user, the environment, the course or cohort, the customer, or the sales opportunity. Cost can then be grouped by any of those dimensions after the fact.

The key insight is that attribution has to be designed in at the point of issue. It is very hard to reconstruct who did what from a shared key's bill, but trivial to group usage that was already tagged when it happened.

Attribution is increasingly a question leaders ask directly. Training managers are asked what a program costs to deliver, sales leaders want to know what it costs to win a deal, and finance wants AI spend explained in the same terms as every other cost. Without attribution, the honest answer to all three is an estimate.

Why does AI usage attribution matter?

AI usage attribution matters because a cost you cannot break down is a cost you cannot manage or justify.

  • Program costing: you can say what a course, workshop or POC costs in AI and what it will cost to run again.
  • Model decisions: you can see whether switching models made a program cheaper without hurting outcomes.
  • Deal economics: sales teams can tie evaluation spend to the opportunity it supported.
  • Chargeback and showback: costs can be recharged to, or simply reported to, the team or customer responsible.
  • Anomaly detection: unusual usage is traced to a specific user or environment instead of a whole account.

How does AI usage attribution work?

AI usage attribution works by giving every request an identity and context, then recording usage against it.

Identity through keys

The most reliable method is issuing a separate key per user or per environment, typically a virtual API key. Every request made with that key is automatically attributed to its holder, with no extra effort from the user.

Context through metadata

Keys or requests can carry metadata such as course, cohort, customer or opportunity. An AI gateway or lab platform records this alongside each request.

Metering

Token counts reported by the provider are priced per model and stored against the key and its metadata, ideally in real time.

Reporting

Because usage is already attributed, reporting is grouping and summing: cost per learner, per cohort, per course, per customer or per deal. The same data can feed finance systems, CRM records or dashboards, so AI cost sits next to the other measures each team already tracks.

AI usage attribution vs AI spend management

AI usage attribution explains where money went; AI spend management decides where it is allowed to go. Attribution is one input to spend management, not a replacement for it.

  • Purpose: attribution is about visibility and accountability; spend management is about control and optimization.
  • Timing: attribution is recorded during and after usage; spend limits are set before it.
  • Outputs: attribution produces reports and recharges; spend management produces budgets, model rules and policies.
  • Dependency: limits without attribution cap cost but do not explain it; attribution without limits explains overspend after it happens.

Why do shared API keys break attribution?

Shared API keys break attribution because every request looks identical to the provider. When a whole class, every demo or several teams use one key, the result is one undifferentiated bill. You can tell AI costs something, but not which program is expensive or which user caused a spike. Rotating that key also breaks every lab using it at once. Per-user keys solve attribution as a side effect of solving security, and make a per-seat AI budget possible as well.

Common use cases for AI usage attribution

  • Training programs: reporting AI cost per cohort and per course, alongside other training ROI measures.
  • Sales POCs: recording AI spend against each sales opportunity.
  • Partner programs: showing what each partner's enablement consumed.
  • Internal platforms: showback of AI usage to the teams that generated it.
  • Model comparisons: running the same course on two models and comparing attributed cost per learner.

Best practices for AI usage attribution

  • Issue keys per user or per environment from the start; retrofitting attribution is hard.
  • Decide the reporting dimensions you need, such as course, customer or deal, before launching.
  • Keep sales evaluation spend separate from employees' own AI use.
  • Review attributed spend after every cohort or POC, not only at month end.
  • Look at the spread between users, not just the average; a wide spread often points to unclear instructions or a missing model restriction.

How Heropa helps

With Heropa's AI Lab Keys, every user and every evaluation gets its own key, so usage is attributed from the moment the lab launches. Usage for every environment updates in Heropa in real time, spend is recorded against the lab that used it so you can report the AI cost of every class, demo and POC, and in sales evaluations spend is recorded against each sales opportunity. POC keys draw on your Heropa AI balance, kept separate from the AI your sales engineers use for their own work.

For the wider picture of activity, engagement and resource use, see Reporting and Analytics.

Frequently asked questions

Can I see what AI spend a training cohort used?

Only if spend was issued per session or per user in the first place. A shared key produces one provider invoice with no breakdown, so cohort cost has to be estimated. When each session has its own key, usage is already attributed to the environment, course and person, and reporting is just grouping.

How do I track AI API usage per user?

Give each user their own key, usually a virtual key issued by a gateway or platform, and record the tokens and cost reported for every request against that key. Adding metadata such as course, customer or opportunity lets you group usage in whichever way your reports need.

What is the difference between chargeback and showback for AI costs?

Showback reports attributed AI costs to the team or customer responsible without billing them. Chargeback goes further and actually recharges the cost. Both depend on accurate AI usage attribution, so the data needs to exist before either model can work.

See it in action

Give every learner and buyer a real, hands-on lab

Spin up real software environments for training, demos and POCs, right in the browser.