Page summary

Review routed requests, tokens, cache hits, cost, and quota statistics.

Key takeaways
  • Track requests, tokens, cache hits, costs, and quota in one local view.
  • Use usage data to choose the right provider for each workflow.
  • Review this page when debugging unexpected quota or billing changes.

4.4 Usage Statistics

Overview

The usage statistics feature records and analyzes API request data, helping you:

Starting from v3.13.0, usage data comes from two sources:

Data SourceCoverageProxy Interception Required?
Proxy request logAll requests forwarded through the proxyYes
CLI session log (new in v3.13)Claude / Codex / Gemini session historyNo

Prerequisites

Depending on which data source you use, the prerequisites differ:

Proxy request log (covers all apps and all proxy requests):

  1. Proxy service started
  2. App takeover enabled
  3. Log recording enabled

CLI session log (new in v3.13, no proxy required):

  1. The corresponding app (Claude / Codex / Gemini) is enabled in CC Switch
  2. The corresponding CLI has session history files
  3. CC Switch periodically scans session directories and imports usage data

Open Usage Statistics

Settings > Usage Tab

Statistics Overview

Summary Cards

Key metrics displayed at the top of the page:

MetricDescription
Total RequestsTotal number of requests in the time period
Real Total TokensCache-normalized total of input + output + cache creation + cache read tokens
Cache Hit RateCache read tokens as a share of cacheable input
Estimated CostCost calculated based on pricing configuration
Success RatePercentage 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.

Time Range

Select the time range for statistics:

OptionRange
TodayFrom 00:00 today to now
Last 7 DaysPast 7 days
Last 30 DaysPast 30 days

Image: image-20260108011730105

Trend Charts

Request Trend

Line chart showing the trend of request counts:

Token Trend

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.

Time Granularity

Image: image-20260108011742847

Detailed Data

Three data tabs at the bottom of the page:

Request Logs

Detailed record of each request:

FieldDescription
TimeRequest time
ProviderProvider name used
ModelRequested model (billing model)
Input TokensNumber of input tokens
Output TokensNumber of output tokens
Cache ReadCache hit token count
Cache CreationCache creation token count
Total CostEstimated cost (USD)
Timing InfoRequest duration, time to first token, streaming/non-streaming
StatusHTTP status code

Timing Information

The timing info column displays multiple badges:

BadgeDescriptionColor Rules
Total DurationTotal request time (seconds)<=5s green, <=120s orange, >120s red
First TokenTime to first token in streaming requests<=5s green, <=120s orange, >120s red
Stream/Non-streamRequest typeStreaming blue, non-streaming purple

View Details

Click a request row to view detailed information:

Filter Logs

Supports filtering by the following criteria:

FilterOptions
App TypeAll / Claude / Codex / Gemini
Status CodeAll / 200 / 400 / 401 / 429 / 500
ProviderText search
ModelText search
Time RangeStart time - End time (datetime picker)

Action buttons:

Image: image-20260108011859974

Provider Statistics

Statistics grouped by provider:

FieldDescription
ProviderProvider name
RequestsTotal requests for this provider
SuccessesNumber of successful requests
FailuresNumber of failed requests
Success RateSuccess percentage
Total TokensTotal token usage
Estimated CostCost for this provider

Image: image-20260108011907928

Model Statistics

Statistics grouped by model:

FieldDescription
ModelModel name
RequestsTotal requests for this model
Input TokensTotal input tokens
Output TokensTotal output tokens
Avg LatencyAverage response time
Estimated CostCost for this model

Image: image-20260108011915381

Pricing Configuration

Open Pricing Configuration

Settings > Advanced > Pricing Configuration

Configure Model Prices

Set prices for each model (per million tokens):

FieldDescription
Model IDModel identifier (e.g., claude-3-sonnet)
Display NameCustom display name
Input PricePrice per million input tokens
Output PricePrice per million output tokens
Cache Read PricePrice per million cache hit tokens
Cache Creation PricePrice per million cache creation tokens

Model ID Normalization Rules

Before matching pricing, CC Switch normalizes the requested model ID:

When adding pricing entries, enter the normalized Model ID rather than the full raw model name from the request.

Raw model nameModel ID to enterNote
stepfun-ai/step-3.5-flashstep-3.5-flashRemoves the provider prefix
moonshotai/kimi-k2-0905:exakimi-k2-0905Removes the prefix and the : suffix
gpt-5.2-codex@lowgpt-5.2-codex-lowReplaces @ with -
OpenAI/GPT-5.5-2026-05-14gpt-5.5Removes the prefix and date suffix
anthropic/claude-opus-4.8claude-opus-4-8Removes the prefix and matches dotted format
global.anthropic.claude-opus-4-8-v1:0claude-opus-4-8Removes wrapper prefix, version suffix, and : suffix
claude-haiku-4-5claude-haiku-4-5-20251001Matches a short ID to versioned pricing

Operations

Image: image-20260108011933565

Preset Prices

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):

ModelInputOutputCache ReadCache 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):

ModelInputOutputCache 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):

ModelInputOutputCache 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-reasoner now alias to deepseek-v4-flash (non-thinking / thinking modes) and are billed at v4-flash rates.

ModelInputOutputCache 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-flashFreeFree-

Custom Prices

If using proxy services, prices may differ:

  1. Click the "Edit" button
  2. Modify prices
  3. Save

FAQ

Statistics Data Is Empty

Check:

Cost Estimates Are Inaccurate

Possible causes:

Solutions:

Token Count Differs from Provider

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.