docs/user-manual/en/4-proxy/4.4-usage.md
The usage statistics feature records and analyzes API request data, helping you:
Starting from v3.13.0, usage data comes from two sources:
| Data Source | Coverage | Proxy Interception Required? |
|---|---|---|
| Proxy request log | All requests forwarded through the proxy | Yes |
| CLI session log (new in v3.13) | Claude / Codex / Gemini session history | No |
Depending on which data source you use, the prerequisites differ:
Proxy request log (covers all apps and all proxy requests):
CLI session log (new in v3.13, no proxy required):
Settings > Usage Tab
Key metrics displayed at the top of the page:
| Metric | Description |
|---|---|
| Total Requests | Total number of requests in the time period |
| Real Total Tokens | Cache-normalized total of input + output + cache creation + cache read tokens |
| Cache Hit Rate | Cache read tokens as a share of cacheable input |
| Estimated Cost | Cost calculated based on pricing configuration |
| Success Rate | Percentage of successful requests |
Starting from v3.15.0, the top of the Usage page uses a filter-driven Hero card. When you change the date range, app, provider, or model filters, the Hero's real total tokens, cache hit rate, request count, and cost update together and stay aligned with the logs and stats below.
Note: v3.15.0 normalizes cache reads, cache creation, and OpenAI-style cache reporting. Historical token and cost numbers may differ from older estimates; the current numbers follow the normalized rules.
Select the time range for statistics:
| Option | Range |
|---|---|
| Today | From 00:00 today to now |
| Last 7 Days | Past 7 days |
| Last 30 Days | Past 30 days |
Line chart showing the trend of request counts:
Shows token usage trends:
Cache Token explanation: Anthropic API supports Prompt Caching. Creating cache incurs a higher fee (typically 1.25x input price), but subsequent cache hits only charge 0.1x, significantly reducing costs for repeated requests.
Three data tabs at the bottom of the page:
Detailed record of each request:
| Field | Description |
|---|---|
| Time | Request time |
| Provider | Provider name used |
| Model | Requested model (billing model) |
| Input Tokens | Number of input tokens |
| Output Tokens | Number of output tokens |
| Cache Read | Cache hit token count |
| Cache Creation | Cache creation token count |
| Total Cost | Estimated cost (USD) |
| Timing Info | Request duration, time to first token, streaming/non-streaming |
| Status | HTTP status code |
The timing info column displays multiple badges:
| Badge | Description | Color Rules |
|---|---|---|
| Total Duration | Total request time (seconds) | <=5s green, <=120s orange, >120s red |
| First Token | Time to first token in streaming requests | <=5s green, <=120s orange, >120s red |
| Stream/Non-stream | Request type | Streaming blue, non-streaming purple |
Click a request row to view detailed information:
Supports filtering by the following criteria:
| Filter | Options |
|---|---|
| App Type | All / Claude / Codex / Gemini |
| Status Code | All / 200 / 400 / 401 / 429 / 500 |
| Provider | Text search |
| Model | Text search |
| Time Range | Start time - End time (datetime picker) |
Action buttons:
Statistics grouped by provider:
| Field | Description |
|---|---|
| Provider | Provider name |
| Requests | Total requests for this provider |
| Successes | Number of successful requests |
| Failures | Number of failed requests |
| Success Rate | Success percentage |
| Total Tokens | Total token usage |
| Estimated Cost | Cost for this provider |
Statistics grouped by model:
| Field | Description |
|---|---|
| Model | Model name |
| Requests | Total requests for this model |
| Input Tokens | Total input tokens |
| Output Tokens | Total output tokens |
| Avg Latency | Average response time |
| Estimated Cost | Cost for this model |
Settings > Advanced > Pricing Configuration
Set prices for each model (per million tokens):
| Field | Description |
|---|---|
| Model ID | Model identifier (e.g., claude-3-sonnet) |
| Display Name | Custom display name |
| Input Price | Price per million input tokens |
| Output Price | Price per million output tokens |
| Cache Read Price | Price per million cache hit tokens |
| Cache Creation Price | Price per million cache creation tokens |
Before matching pricing, CC Switch normalizes the requested model ID:
/:@ with -When adding pricing entries, enter the normalized Model ID rather than the full raw model name from the request.
| Raw model name | Model ID to enter | Note |
|---|---|---|
stepfun-ai/step-3.5-flash | step-3.5-flash | Removes the provider prefix |
moonshotai/kimi-k2-0905:exa | kimi-k2-0905 | Removes the prefix and the : suffix |
gpt-5.2-codex@low | gpt-5.2-codex-low | Replaces @ with - |
CC Switch includes preset official prices for common models (per million tokens). v3.13.0 corrects CNY → USD pricing for several models and adds previously missing model definitions; it also fixes MiniMax plan quota math and the 0% → 100% usage progress display, making cost estimates and plan progress more accurate.
Claude Series (USD):
| Model | Input | Output | Cache Read | Cache Creation |
|---|---|---|---|---|
| Claude 4.8 Series | ||||
| claude-opus-4-8 | $5 | $25 | $0.50 | $6.25 |
| Claude 4.5 Series | ||||
| claude-opus-4-5 | $5 | $25 | $0.50 | $6.25 |
| claude-sonnet-4-5 | $3 | $15 | $0.30 | $3.75 |
| claude-haiku-4-5 | $1 | $5 | $0.10 | $1.25 |
| Claude 4 Series | ||||
| claude-opus-4 | $15 | $75 | $1.50 | $18.75 |
| claude-opus-4-1 | $15 | $75 | $1.50 | $18.75 |
| claude-sonnet-4 | $3 | $15 | $0.30 | $3.75 |
| Claude 3.5 Series | ||||
| claude-3-5-sonnet | $3 | $15 | $0.30 | $3.75 |
| claude-3-5-haiku | $0.80 | $4 | $0.08 | $1.00 |
OpenAI Series / Codex (USD):
| Model | Input | Output | Cache Read |
|---|---|---|---|
| GPT-5.2 Series | |||
| gpt-5.2 | $1.75 | $14 | $0.175 |
| GPT-5.1 Series | |||
| gpt-5.1 | $1.25 | $10 | $0.125 |
| GPT-5 Series | |||
| gpt-5 | $1.25 | $10 | $0.125 |
Note: Codex presets include low/medium/high variants with prices identical to the base model.
Gemini Series (USD):
| Model | Input | Output | Cache Read |
|---|---|---|---|
| Gemini 3 Series | |||
| gemini-3-pro-preview | $2 | $12 | $0.20 |
| gemini-3-flash-preview | $0.50 | $3 | $0.05 |
| Gemini 2.5 Series | |||
| gemini-2.5-pro | $1.25 | $10 | $0.125 |
| gemini-2.5-flash | $0.30 | $2.50 | $0.03 |
Chinese Provider Models:
Note: Currency follows each provider's official pricing page. StepFun is currently listed in USD.
DeepSeek compatibility: Legacy model IDs
deepseek-chat/deepseek-reasonernow alias todeepseek-v4-flash(non-thinking / thinking modes) and are billed at v4-flash rates.
| Model | Input | Output | Cache Read |
|---|---|---|---|
| StepFun | |||
| step-3.5-flash | $0.10 | $0.30 | $0.02 |
| DeepSeek | |||
| deepseek-v4-flash | ¥1.00 | ¥2.00 | ¥0.20 |
| deepseek-v4-pro | ¥12.00 | ¥24.00 | ¥1.00 |
| Kimi (Moonshot) | |||
| kimi-k2-thinking | ¥4.00 | ¥16.00 | ¥1.00 |
| kimi-k2 | ¥4.00 | ¥16.00 | ¥1.00 |
| kimi-k2-turbo | ¥8.00 | ¥58.00 | ¥1.00 |
| MiniMax | |||
| minimax-m2.1 | ¥2.10 | ¥8.40 | ¥0.21 |
| minimax-m2.1-lightning | ¥2.10 | ¥16.80 | ¥0.21 |
| Others | |||
| glm-4.7 | ¥2.00 | ¥8.00 | ¥0.40 |
| doubao-seed-code | ¥1.20 | ¥8.00 | ¥0.24 |
| mimo-v2-flash | Free | Free | - |
If using proxy services, prices may differ:
Check:
Possible causes:
Solutions:
CC Switch uses its own method to estimate token counts, which may slightly differ from the provider's calculation. Refer to the provider's invoice for authoritative numbers.