Export fields
Main amount/token columns in the log-export CSV: prompt tokens, input tokens (non-cache normal input), cache-hit tokens, cache-write tokens (5 min), cache-write-1h tokens (1 hour), output tokens (including reasoning), reasoning tokens, input/output/cache-hit/cache-write/cache-write-1h/reasoning unit prices (CNY per million tokens), search count and search unit price (CNY per call, Claude Web Search only), image input tokens and image input price, cached image tokens and cached image price.Validation relations
- Plain text:
prompt tokens = input tokens + cache-hit tokens + cache-write tokens + cache-write-1h tokens - With image input:
prompt tokens = input tokens + image input tokens + cache-hit tokens + cached image tokens + cache-write tokens + cache-write-1h tokens
ceil).
Claude family
input_tokens→input, output_tokens→output, cache_read_input_tokens→cache-hit, cache_creation_input_tokens→total cache-write (validation), cache_creation.ephemeral_5m_input_tokens→cache-write, cache_creation.ephemeral_1h_input_tokens→cache-write-1h, server_tool_use.web_search_requests→search count (when no bucket exists, treated as 5-minute cache-write; for OpenAI-compatible responses, cache-hit maps to usage.prompt_tokens_details.cached_tokens).
GPT-5 family
prompt_tokens / completion_tokens / prompt_tokens_details.cached_tokens / completion_tokens_details.reasoning_tokens correspond to Responses input_tokens / output_tokens / input_tokens_details.cached_tokens / output_tokens_details.reasoning_tokens. cached_tokens is a sub-item of the input total; input tokens = prompt tokens − cache-hit; reasoning tokens are already included in output tokens.
GPT-Image family
input_image_tokens / input_image_price / cached_image_tokens / cached_image_price. input_tokens_details.{text_tokens,image_tokens,cached_tokens}; cached_tokens mixes text and images, split by cached × image/(text+image).
Gemini family
Plain text / reasoning uses the same formula as GPT-5, plus a cache-write item. Gemini no-image failure reconciliation: error responses carryusage (error.code=no_image_generated, type=one_hub_error), usage.input_tokens→prompt tokens, input_tokens_details.image_tokens→image input tokens, output_tokens=0; only settled failures return usage.