Anthropic returns this metadata for token usage which includes cache creation token usage as well.
anthropic: { cacheCreationInputTokens: 46209, container: null, stopSequence: null, usage: { cache_creation: { ephemeral_1h_input_tokens: 0, ephemeral_5m_input_tokens: 46209, }, cache_creation_input_tokens: 46209, cache_read_input_tokens: 0, input_tokens: 337, output_tokens: 342, service_tier: "standard", }, },
But this data is not available in usageHandler.