Skip to content

ProcessTokenTotals

A run’s token usage, totalled into five kinds. Each total adds up the run’s recorded token counts of the types named below.

Kind: an object, used in responses.

Every field is present in a response; empty ones are null.

FieldTypeDescription
inputintegerFresh (non-cached) input tokens: type input.
outputintegerOutput tokens: type output.
cacheReadintegerInput tokens served from the provider’s cache: type cache_read.
cacheWriteintegerInput tokens written to the provider’s cache: types cache_creation, cache_creation_5m and cache_creation_1h.
reasoningintegerReasoning tokens: type reasoning (part of output, on providers that report it).
{
"input": 0,
"output": 0,
"cacheRead": 0,
"cacheWrite": 0,
"reasoning": 0
}