Start with the billing unit
A token is a model-specific unit of text, not always a word. 1K means one thousand tokens and 1M means one million. The same Georgian sentence may produce different token counts across models.
Some models charge per request or another unit. Do not compare two numbers without checking that the units, currency and conditions match.
An estimate is not a live price
For simple per-million-token billing: estimated cost = input tokens ÷ 1,000,000 × input price + output tokens ÷ 1,000,000 × output price. This is a method, not a quoted AIAPI tariff.
Caching, long-context tiers, group rates, tools, media and dynamic expressions may change the result. The catalog, model details and your usage records are the place to check actual conditions.
Control the total workflow cost
Measure the whole task, including retries, prompt length, output length and human review. A cheaper token rate can be more expensive overall if the task needs repeated attempts.
- Start with a small representative test and an explicit spending limit.
- Avoid sending unrelated context and request only the output you need.
- Compare the response, usage and charge for the same request.