Skip to content

Cost and FinOpsBrief

AI API pricing explained: tokens, media units, and real cost

List price is only the start. Real inference cost depends on input/output mix, retries, context, cache behavior, media settings, and success rate.

By INFRO Editorial

Published

Updated

1 min read

Tokens, images, video frames, and audio waves flowing into one transparent AI cost meter

In short

AI API cost is the sum of workload units multiplied by model rates, plus retries and failed work. Text often bills input and output tokens separately; image, video, and audio use model-specific units such as generations, resolution, seconds, or characters.

Text pricing has two sides

Input includes system instructions, conversation history, retrieved context, tool schemas, and user content. Output includes visible text and, depending on the model contract, billed reasoning or tool-call tokens. Generation-heavy workloads are sensitive to output rates; RAG can be dominated by input.

Estimate with observed percentiles rather than one average prompt. Long-tail contexts can dominate the bill.

Media uses different units

Images may vary by model, count, resolution, quality, and editing inputs. Video commonly depends on duration, resolution, frames, or model tier. Audio can depend on characters, tokens, or seconds. Read the unit next to the rate before comparing providers.

Async job retries and abandoned results still matter if generation completed.

Price per unit is not cost per outcome

Add retries, malformed output, human correction, verification, and orchestration steps. For agents, sum the whole trajectory. For media, include the number of variants needed to produce one usable asset.

The winning model is the one with acceptable quality and the lowest cost per successful task, not necessarily the lowest rate card.

Build a living forecast

Track volume, input and output distributions, model mix, cache effects, retry and fallback rate, media settings, and growth. Recalculate when models, prompts, retrieval, or product behavior changes.

Keep assumptions beside the result so finance and engineering can challenge the same model.

From the team that builds it

Where this shows up in INFRO

INFRO is a control plane in front of the provider accounts you already hold. The capabilities below are the parts of it this article touches, each with the documentation that defines its behaviour.

INFRO accounts are self-serve. Provider usage is billed to you by your providers; INFRO charges a software subscription and takes 0% of model spend. See plans.

About this article

Last checked against its sources on . The next review is due by . No separate named reviewer is recorded for this article.

How articles are written, sourced and corrected is set out in the editorial standards.

Revision history

  1. Removed the promotional template sections and the generic FAQ, moved product context into the product section, and corrected product wording to the current BYOK model.