Documentation / Plans and billing
Pay-as-you-go billing
Understand model pricing units, input/output tokens, cache and media charges, and reconcile actual request costs in Usage.
Where to find current prices
- Find the model in the catalog and open its details. Confirm the model ID, endpoints, context and media capabilities. Open model catalog
- Select pay-as-you-go pricing and inspect input, output and cache units and the applicable group. If long-context tiers exist, check their thresholds.
- Check the key’s group and funding source in your account. A different group, billing method or old screenshot may not apply to the current request.
This article explains the calculation method; use current catalog prices applicable to your account and final usage records for amounts. A missing price does not mean $0 or free usage.
Check the unit before comparing prices
| Usage | Common unit | How to read it |
|---|---|---|
| Text input | USD / 1M tokens | Token cost of prompts, history, system instructions, tool information and other input. |
| Text output | USD / 1M tokens | Token cost of generated content; its rate commonly differs from input. |
| Cache | USD / 1M tokens | Separate cache-write and cache-hit rates may apply when supported. |
| Images | USD / image, or model-specific token units | Check the model, resolution, quality and quantity. |
| Video | USD / second, or model-specific task / token units | Check duration, resolution, audio and the model’s billing method. |
1M means 1,000,000. Tokens are neither characters nor message counts; language, context length, tool calls and generated content affect usage.
Input, output and cache billing
Multi-turn conversations often resend history, so equally long new messages can produce different input usage. Coding clients may also send files, tool results and system instructions.
- Ordinary input: charged at the applicable input rate.
- Cache writes and reads: priced separately when supported and actually used. Repeated prompts do not guarantee a cache hit.
- Output: charged at the applicable output rate. Some models report reasoning or other subcategories; reconcile these with model-specific billing and usage records.
Cache accounting differs across APIs. If total input includes cached tokens, separate the categories before calculating so the same tokens are not charged twice in your estimate.
Cost calculation examples
The hypothetical rates below demonstrate the formula; they are not a current quote for any model. Replace them with applicable prices before estimating real usage.
| Item | Usage | Hypothetical rate | Calculation |
|---|---|---|---|
| Input | 10,000 tokens | $2 / 1M tokens | 10,000 ÷ 1,000,000 × $2 = $0.02 |
| Output | 2,000 tokens | $8 / 1M tokens | 2,000 ÷ 1,000,000 × $8 = $0.016 |
| Total | — | — | $0.036 USD |
Text cost = ordinary input tokens ÷ 1M × input rate
+ output tokens ÷ 1M × output rate
+ applicable cache write and read costsSeparate input when caching applies
Suppose 10,000 total input tokens contain 8,000 cached tokens and 2,000 ordinary tokens. At $2 / 1M ordinary input, $0.20 / 1M cache reads and the same 2,000 output tokens at $8 / 1M, the total is $0.004 + $0.0016 + $0.016 = $0.0216. This example excludes cache writes, tiers and other charges.
Using pay-as-you-go rates gives wallet consumption; using official API rates for the all-model preview gives credit consumption. Keep those calculations separate.
Image and video billing
Image generation
Check whether the model charges per image or per token. Per-image prices can vary by size or quality; token-priced models require their own input/output rates and cannot be reduced to one universal per-image price.
For a hypothetical per-image model priced at $0.05 per image, four images cost 4 × $0.05 = $0.20. This is an illustrative rate only.
Video generation
For per-second models, multiply the billable duration by the rate for the selected specification. Other models may charge per task or token. A rate for one resolution or silent video does not apply to every parameter combination.
At a hypothetical $0.10 per second, eight billable seconds cost 8 × $0.10 = $0.80. Check duration, resolution, audio and model before generation, then reconcile the final task state and usage record.
How to reconcile usage and billing
- Open Usage, select the request’s time range and check the displayed timezone. Open usage records
- Locate the request by model or API key and verify its time, model, status and request identifier.
- Reconcile input, output, cache, image count or video seconds, then check cost and the actual funding source.
- Funding and API usage are separate records. Use payment history for payments and Usage for consumption; a balance change alone does not identify one request’s cost.
For assistance, provide the time and timezone, model ID, request identifier and error. Do not share full API keys, card details or sensitive request content.
Balance and request errors
| Issue | Check first |
|---|---|
| Cannot call despite a positive balance | The key’s funding source, product/group, model permissions and account status. Total balance is not proof that every route is eligible. |
| 401 / 403 | Whether the key is valid, belongs to this account and permits the model and endpoint. |
| 429 | Account/key rate, concurrency, model restrictions and allowance; read the response body for the cause. |
| Client retry or interruption | Reconcile usage by request identifier. A client error alone proves neither zero model consumption nor duplicate billing. |
| Estimate differs from the record | The model/group, units, cache accounting, context tiers and media specifications used in the estimate. |
Start with one short request and verify both the API response and usage record before increasing workload.
curl --fail-with-body https://api.openoxai.com/v1/models -H "Authorization: Bearer $OPENOX_API_KEY"A model-list request checks connectivity and authentication; it is not a generation test or a guarantee that every listed model is available to the key.
