Anthropic::Usage
Inherits JSON::Serializable < Struct < Value < Object
Token usage statistics for API requests
Tracks input and output tokens, as well as prompt caching statistics when applicable.
Constructors
new(pull : JSON::PullParser)
Sourcenew(*, __pull_for_json_serializable pull : JSON::PullParser)
SourceInstance methods
iterations
Per-hop usage when a fallback chain ran. Each entry is either a declined
(type: "message") or serving (type: "fallback_message") hop. Present
only on responses that exercised server-side fallbacks.