Ask a team what their agent costs to run and you will usually get a monthly total. Ask what a single task costs (one research request, one document processed, one voice interaction) and you get silence. That per-task number is the one that matters: it is what decides your margin, your pricing page, and whether “let the agent retry harder” is a feature or a leak. Here is the audit process I use, with real numbers from our catalog.
Why per-task, not per-month
A monthly bill tells you spend happened; it cannot tell you whether spend was proportionate. Agents make the gap worse than normal software does, because an agent decides at runtime how many tool calls a task takes. Two identical-looking requests can cost wildly different amounts depending on how many searches the model decided to run, whether a scrape failed and retried, and which provider tier served each call. Without per-task accounting, a 3x cost regression hides comfortably inside month-over-month growth.
The unit-economics question is always the same: cost per task, times tasks per month, versus value per task. Everything in the audit serves that division.
Step 1: define the task unit
Pick the unit your business thinks in: one answered research question, one parsed contract, one minute of conversation. If your agent does several jobs, audit them separately; averaging a cheap task with an expensive one produces a number that describes neither.
Step 2: instrument per-call prices
You need the actual price of every tool call, attached to the task that triggered it. This is where most audits die, because most provider dashboards give you daily aggregates per API key, which is the wrong join key. You want a task ID on every call.
This is a design principle I feel strongly enough about to have built around: every response from route.tools includes the exact price of that call and the full routing.attempted chain, so per-task cost is a sum over responses you already have, not a reconciliation project across five dashboards. If you are calling providers directly, you can approximate with unit prices from their pricing pages times your own call counts, which is exactly the worksheet below.
Step 3: the worksheet
Here is a worked example for a typical research-agent task, using routed prices from our catalog (provider list plus 20%, per /docs/pricing):
| Tool call | Unit price (routed) | Calls per task | Cost per task |
|---|---|---|---|
| Search (Serper, $1.20/1k) | $0.0012 | 6 | $0.0072 |
| Scrape (Firecrawl, $1.92/1k) | $0.00192 | 4 | $0.00768 |
| Parse (LlamaParse, $1.50/1k) | $0.0015 | 2 | $0.0030 |
| Embed (OpenAI 3-small, $0.024/1M tok) | ~$0.00048 (20k tokens) | 1 | $0.00048 |
| Total tool spend per task | ~$0.0184 |
Call it two cents of tool spend per task. At 10,000 tasks a month, that is roughly $184. Your model spend goes on top and usually dwarfs it, which is itself a finding: for many agents, tools are 10-30% of task cost, and people routinely optimize the wrong line.
Now run the same worksheet with your P95 task instead of your median. Agents have fat tails: the task where the model looped, searched fourteen times, and hit the expensive provider on every failover. If your P95 task costs 10x your median, your margin story depends on how often the tail fires.
Step 4: hunt the mismatches
With per-task numbers in hand, the savings almost always live in three places:
- Quality-tier mismatch. Navigational search queries running on Exa at $8.40 per 1k when Serper at $1.20 would return the same link is a 7x overpay per call. The audit question for every tool: does this call’s difficulty justify this call’s tier? I covered the arbitrage patterns in how tool routing cuts agent costs.
- Retry and failover waste. Attempt chains show you calls that failed, retried, and succeeded on the third provider. Occasional failover is the system working; a chain that always starts with a failing provider is money and latency you can reclaim by reordering.
- Calls that should not exist. The most common finding of all: the agent searches for things already in its context, or re-scrapes a page it fetched two steps ago. No provider optimization beats deleting a call.
Step 5: make it a habit, then a guardrail
A one-time audit decays in weeks, because prompts change and models get updated and call patterns drift. Track cost-per-task as a metric next to latency, alert on regressions, and re-run the tier-mismatch hunt quarterly.
Then cap the downside: per-task accounting tells you what spend should be, and spend caps make sure a runaway agent cannot exceed it by orders of magnitude while you sleep. I wrote up the cap design patterns in spend caps for AI agents.
If you want the per-call prices handed to you on every response instead of reconstructed from dashboards, one key with $2 of free credits is enough to run this whole worksheet on live traffic.