EndTime int64
Object Bucket
Results []AdminOrganizationUsageAudioTranscriptionsResponseDataResultUnion
One of the following:
type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageCompletionsResult struct{…}

The aggregated completions usage details of the specific time bucket.

InputTokens int64

The aggregated number of input tokens used, including cached and cache-write tokens. This includes text, audio, and image tokens. For customers subscribed to Scale Tier, this includes Scale Tier tokens.

NumModelRequests int64

The count of requests made to the model.

Object OrganizationUsageCompletionsResult
OutputTokens int64

The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens.

APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

APISource string
Optional

When grouped by api_source, agents_api identifies attributed Agents API activity and unlabeled includes all records without published source attribution, including historical and unknown origins. Unlabeled does not imply direct API usage. Without source grouping, this field is null.

One of the following:
const AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageCompletionsResultAPISourceAgentsAPI AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageCompletionsResultAPISource = "agents_api"
const AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageCompletionsResultAPISourceUnlabeled AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageCompletionsResultAPISource = "unlabeled"
Batch bool
Optional

When group_by=batch, this field tells whether the grouped usage result is batch or not.

InputAudioTokens int64
Optional

The aggregated number of uncached audio input tokens used.

InputCacheWrite12hTokens int64
Optional

The aggregated number of input tokens written to the cache with a 12-hour retention period.

InputCacheWrite30mTokens int64
Optional

The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses.

InputCacheWriteTokens int64
Optional

The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods.

InputCachedAudioTokens int64
Optional

The aggregated number of cached audio input tokens used.

InputCachedImageTokens int64
Optional

The aggregated number of cached image input tokens used.

InputCachedTextTokens int64
Optional

The aggregated number of cached text input tokens used.

InputCachedTokens int64
Optional

The aggregated number of cached input tokens used across text, audio, and image inputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens.

InputImageTokens int64
Optional

The aggregated number of uncached image input tokens used.

InputTextTokens int64
Optional

The aggregated number of uncached text input tokens used, excluding cache-write tokens.

InputUncachedTokens int64
Optional

The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens.

Model string
Optional

When group_by=model, this field provides the model name of the grouped usage result.

OutputAudioTokens int64
Optional

The aggregated number of audio output tokens used.

OutputImageTokens int64
Optional

The aggregated number of image output tokens used.

OutputTextTokens int64
Optional

The aggregated number of text output tokens used.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

ServiceTier string
Optional

When group_by=service_tier, this field provides the service tier of the grouped usage result.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageEmbeddingsResult struct{…}

The aggregated embeddings usage details of the specific time bucket.

InputTokens int64

The aggregated number of input tokens used.

NumModelRequests int64

The count of requests made to the model.

Object OrganizationUsageEmbeddingsResult
APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

Model string
Optional

When group_by=model, this field provides the model name of the grouped usage result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageModerationsResult struct{…}

The aggregated moderations usage details of the specific time bucket.

InputTokens int64

The aggregated number of input tokens used.

NumModelRequests int64

The count of requests made to the model.

Object OrganizationUsageModerationsResult
APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

Model string
Optional

When group_by=model, this field provides the model name of the grouped usage result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageImagesResult struct{…}

The aggregated images usage details of the specific time bucket.

Images int64

The number of images processed.

NumModelRequests int64

The count of requests made to the model.

Object OrganizationUsageImagesResult
APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

Model string
Optional

When group_by=model, this field provides the model name of the grouped usage result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

Size string
Optional

When group_by=size, this field provides the image size of the grouped usage result.

Source string
Optional

When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageAudioSpeechesResult struct{…}

The aggregated audio speeches usage details of the specific time bucket.

Characters int64

The number of characters processed.

NumModelRequests int64

The count of requests made to the model.

Object OrganizationUsageAudioSpeechesResult
APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

Model string
Optional

When group_by=model, this field provides the model name of the grouped usage result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageAudioTranscriptionsResult struct{…}

The aggregated audio transcriptions usage details of the specific time bucket.

NumModelRequests int64

The count of requests made to the model.

Object OrganizationUsageAudioTranscriptionsResult
Seconds int64

The number of seconds processed.

formatint64
APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

Model string
Optional

When group_by=model, this field provides the model name of the grouped usage result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageVectorStoresResult struct{…}

The aggregated vector stores usage details of the specific time bucket.

Object OrganizationUsageVectorStoresResult
UsageBytes int64

The vector stores usage in bytes.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageCodeInterpreterSessionsResult struct{…}

The aggregated code interpreter sessions usage details of the specific time bucket.

NumSessions int64

The number of code interpreter sessions.

Object OrganizationUsageCodeInterpreterSessionsResult
ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageFileSearchesResult struct{…}

The aggregated file search calls usage details of the specific time bucket.

NumRequests int64

The count of file search calls.

Object OrganizationUsageFileSearchesResult
APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

VectorStoreID string
Optional

When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageWebSearchesResult struct{…}

The aggregated web search calls usage details of the specific time bucket.

NumModelRequests int64

The count of model requests.

NumRequests int64

The count of web search calls.

Object OrganizationUsageWebSearchesResult
APIKeyID string
Optional

When group_by=api_key_id, this field provides the API key ID of the grouped usage result.

APISource string
Optional

When grouped by api_source, agents_api identifies attributed Agents API activity and unlabeled includes all records without published source attribution, including historical and unknown origins. Unlabeled does not imply direct API usage. Without source grouping, this field is null.

One of the following:
const AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageWebSearchesResultAPISourceAgentsAPI AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageWebSearchesResultAPISource = "agents_api"
const AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageWebSearchesResultAPISourceUnlabeled AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationUsageWebSearchesResultAPISource = "unlabeled"
ContextLevel string
Optional

When group_by=context_level, this field provides the search context size of the grouped usage result.

Model string
Optional

When group_by=model, this field provides the model name of the grouped usage result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped usage result.

UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped usage result.

type AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationCostsResult struct{…}

The aggregated costs details of the specific time bucket.

Object OrganizationCostsResult
Amount AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationCostsResultAmount
Optional

The monetary value in its associated currency.

Currency string
Optional

Lowercase ISO-4217 currency e.g. “usd”

Value float64
Optional

The numeric value of the cost.

APIKeyID string
Optional

When group_by=api_key_id, this field provides the API Key ID of the grouped costs result.

APISource string
Optional

When grouped by api_source, agents_api identifies attributed Agents API activity and unlabeled includes all records without published source attribution, including historical and unknown origins. Unlabeled does not imply direct API usage. Without source grouping, this field is null.

One of the following:
const AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationCostsResultAPISourceAgentsAPI AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationCostsResultAPISource = "agents_api"
const AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationCostsResultAPISourceUnlabeled AdminOrganizationUsageAudioTranscriptionsResponseDataResultOrganizationCostsResultAPISource = "unlabeled"
LineItem string
Optional

When group_by=line_item, this field provides the line item of the grouped costs result.

ProjectID string
Optional

When group_by=project_id, this field provides the project ID of the grouped costs result.

Quantity float64
Optional

When group_by=line_item, this field provides the quantity of the grouped costs result.

QuantityUnit CostQuantityUnit
Optional

The unit of the quantity value. If no single supported unit applies to the result, this field is null.

One of the following:
string
type CostQuantityUnit string

The unit of the quantity value. If no single supported unit applies to the result, this field is null.

One of the following:
const CostQuantityUnitTokens CostQuantityUnit = "tokens"
const CostQuantityUnit1000Tokens CostQuantityUnit = "1000_tokens"
const CostQuantityUnitDurationSeconds CostQuantityUnit = "duration_seconds"
const CostQuantityUnitDurationMinutes CostQuantityUnit = "duration_minutes"
const CostQuantityUnitDurationHours CostQuantityUnit = "duration_hours"
const CostQuantityUnitGibibyteHours CostQuantityUnit = "gibibyte_hours"
const CostQuantityUnitImages CostQuantityUnit = "images"
const CostQuantityUnitCharacters CostQuantityUnit = "characters"
UserID string
Optional

When group_by=user_id, this field provides the user ID of the grouped costs result.

StartTime int64