Skip to main content
Section ID: DOC-API-MODEL-schema-po7orad6ac#overview

UsageByModel

Usage attributed to a single model within one generation run.

LLMGenerationCompletedEvent.usage is the run-level aggregate, summed across every model the run called. A tool-using turn routinely spans several models, and the rate card prices per model, so billing needs the breakdown alongside the aggregate rather than instead of it. One entry per distinct model.

Meaning and usage​

Section ID: DOC-API-MODEL-schema-po7orad6ac#meaning

See the definition above.

Usage profiles​

Section ID: DOC-API-MODEL-schema-po7orad6ac#fields

UsageFields and validation
In requestsView fields
In responsesView fields

In requests​

Section ID: DOC-API-MODEL-schema-po7orad6ac#request

API JSON uses JSON field names (camelCase).

FieldTypePresenceMeaning
Section ID: DOC-API-MODEL-schema-po7orad6ac#request-field-modelmodelstringOptionalModel identifier as recorded on the assistant message that produced it.
Section ID: DOC-API-MODEL-schema-po7orad6ac#request-field-callscallsstring (int64)OptionalProvider completions attributed to this model within the run. Pattern: ^-?\d+$.
Section ID: DOC-API-MODEL-schema-po7orad6ac#request-field-usageusageUsageOptionalSame shape as the run aggregate, scoped to this model.

In responses​

Section ID: DOC-API-MODEL-schema-po7orad6ac#response

API JSON uses JSON field names (camelCase).

FieldTypePresenceMeaning
Section ID: DOC-API-MODEL-schema-po7orad6ac#field-modelSection ID: DOC-API-MODEL-schema-po7orad6ac#response-field-modelmodelstringOptionalModel identifier as recorded on the assistant message that produced it.
Section ID: DOC-API-MODEL-schema-po7orad6ac#field-callsSection ID: DOC-API-MODEL-schema-po7orad6ac#response-field-callscallsstring (int64)OptionalProvider completions attributed to this model within the run. Pattern: ^-?\d+$.
Section ID: DOC-API-MODEL-schema-po7orad6ac#field-usageSection ID: DOC-API-MODEL-schema-po7orad6ac#response-field-usageusageUsageOptionalSame shape as the run aggregate, scoped to this model.

Where used​

Section ID: DOC-API-MODEL-schema-po7orad6ac#where-used

Models containing this value
ModelRelationship
LLMGenerationCompletedEventNested in model
LLMGenerationCompletedEventNested in model

Download the public reference contract.

Document ID: DOC-API-MODEL-schema-po7orad6ac