Token Based Pricing — Reading the Bill
A demo of Tripmate costs less than a rupee. Then a thousand users each plan a trip, every plan takes a dozen model calls, and the monthly bill arrives with an extra zero. Knowing how model pricing works lets you predict that bill before it surprises you.
The rule
You pay per token, both ways — and agents resend the past every step.
Hosted models are usually priced per million tokens, with two separate rates:
- Input tokens — everything you send: instructions, tools, history, tool results.
- Output tokens — everything the model writes. This rate is typically several times higher than the input rate.
Take a made-up model priced at $1 per million input tokens and $4 per million output tokens. One Tripmate call that sends 5,000 tokens and gets back 500 costs:
input: 5,000 ÷ 1,000,000 × $1 = $0.005
output: 500 ÷ 1,000,000 × $4 = $0.002
total = $0.007Bigger, more capable models usually charge more per token than small, fast ones, and models that "think" before answering may bill that hidden reasoning as output tokens too. Real prices differ between models and change often, so always check the current price sheet. The method does not change.
The shortcut
An agent is not one call — it is a loop of calls, and each call resends the growing history. So estimate a whole run, not a single call: add up the input of every step, then the output of every step.
List the steps
The plan takes 6 model calls: understand the request, search trains, check weather, compare, book, confirm.
Notice that input dominates here, even though its rate is lower. That is typical for agents: the resent history is the real cost. Trimming bulky tool results, summarising old turns, and using a smaller model for easy steps are the usual levers. Some providers also discount input they have seen recently (often called caching), which rewards keeping the fixed start of your prompt identical between calls.
Drills
Answer fast — trust the rule.
At $1 per million input tokens, what does sending 20,000 input tokens cost?
At $4 per million output tokens, what do 2,500 output tokens cost?
Why does a 10-step agent run cost far more than ten times a single short call?
Which change most directly cuts Tripmate's input-token bill?
Remember
- You pay per token, input and output at different rates; output is usually pricier per token.
- Shortcut: price the whole loop — sum every step's input, then every step's output.
- Trap: pricing one call and forgetting that history is resent each step.
