Usage
What one completion was billed.
Bills add up: NO_USAGE changes nothing when added, and the order
the parts were added in does not matter — the same shape as
Spent.
Two fields name a part of another field rather than a separate charge:
cached_input_tokens are input tokens served from the provider's cache,
and reasoning_tokens are output tokens spent thinking. Neither is added
into total_tokens a second time.
Attributes
attributeinput_tokensint= 0attributeoutput_tokensint= 0attributecached_input_tokensint= 0attributereasoning_tokensint= 0attributetotal_tokensintInput plus output; the parts-of fields are already inside those.
Functions
func__init__(self, input_tokens=0, output_tokens=0, cached_input_tokens=0, reasoning_tokens=0) -> Noneparaminput_tokensint= 0paramoutput_tokensint= 0paramcached_input_tokensint= 0paramreasoning_tokensint= 0Returns
None