Usage
Audio speeches
GET
/organization/usage/audio_speechesAudio transcriptions
GET
/organization/usage/audio_transcriptionsCode interpreter sessions
GET
/organization/usage/code_interpreter_sessionsCompletions
GET
/organization/usage/completionsCosts
GET
/organization/costsDecisions
GET
/organization/usage/decisionsEmbeddings
GET
/organization/usage/embeddingsFile search calls
GET
/organization/usage/file_search_callsImages
GET
/organization/usage/imagesModerations
GET
/organization/usage/moderationsVector stores
GET
/organization/usage/vector_storesWeb search calls
GET
/organization/usage/web_search_callsModels
CostQuantityUnit = string or "tokens" or "1000_tokens" or "duration_seconds" or 5 moreThe unit of the quantity value. If no single supported unit applies to the result, this field is null.
CostQuantityUnit = string or "tokens" or "1000_tokens" or "duration_seconds" or 5 more
The unit of the quantity value. If no single supported unit applies to the result, this field is null.
One of the following: string "tokens" or "1000_tokens" or "duration_seconds" or 5 more The unit of the quantity value. If no single supported unit applies to the result, this field is null. One of the following: "tokens" "1000_tokens" "duration_seconds" "duration_minutes" "duration_hours" "gibibyte_hours" "images" "characters"
UsageAudioSpeechesResponse object { data, has_more, next_page, object }
UsageAudioSpeechesResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageAudioTranscriptionsResponse object { data, has_more, next_page, object }
UsageAudioTranscriptionsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageCodeInterpreterSessionsResponse object { data, has_more, next_page, object }
UsageCodeInterpreterSessionsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageCompletionsResponse object { data, has_more, next_page, object }
UsageCompletionsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageCostsResponse object { data, has_more, next_page, object }
UsageCostsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageDecisionsResponse object { data, has_more, next_page, object }
UsageDecisionsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" (default: "bucket") results: array of { input_tokens, num_model_requests, object, 22 more } input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.decisions.result" (default: "organization.usage.decisions.result") output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer or null The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. input_cache_write_tokens: optional integer or null The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer or null The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer or null The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer or null The aggregated number of cached text input tokens used. input_cached_tokens: optional integer or null 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. input_image_tokens: optional integer or null The aggregated number of uncached image input tokens used. input_text_tokens: optional integer or null The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer or null The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer or null The aggregated number of audio output tokens used. output_image_tokens: optional integer or null The aggregated number of image output tokens used. output_text_tokens: optional integer or null The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. start_time: integer has_more: boolean next_page: string or null object: "page" (default: "page")
UsageEmbeddingsResponse object { data, has_more, next_page, object }
UsageEmbeddingsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageFileSearchCallsResponse object { data, has_more, next_page, object }
UsageFileSearchCallsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageImagesResponse object { data, has_more, next_page, object }
UsageImagesResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageModerationsResponse object { data, has_more, next_page, object }
UsageModerationsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageVectorStoresResponse object { data, has_more, next_page, object }
UsageVectorStoresResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"
UsageWebSearchCallsResponse object { data, has_more, next_page, object }
UsageWebSearchCallsResponse object { data, has_more, next_page, object }
data: array of { end_time, object, results, start_time } end_time: integer object: "bucket" results: array of OrganizationUsageCompletionsResult or OrganizationUsageEmbeddingsResult or OrganizationUsageModerationsResult or 8 more One of the following: OrganizationUsageCompletionsResult { input_tokens, num_model_requests, object, 22 more } The aggregated completions usage details of the specific time bucket. input_tokens: integer 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. num_model_requests: integer The count of requests made to the model. object: "organization.usage.completions.result" output_tokens: integer The aggregated number of output tokens used across text, audio, and image outputs. For customers subscribed to Scale Tier, this includes Scale Tier tokens. api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" batch: optional boolean or null When group_by=batch, this field tells whether the grouped usage result is batch or not. input_audio_tokens: optional integer The aggregated number of uncached audio input tokens used. input_cache_write_12h_tokens: optional integer The aggregated number of input tokens written to the cache with a 12-hour retention period. input_cache_write_30m_tokens: optional integer or null The aggregated number of input tokens written to the cache with a 30-minute retention period. May be absent or null for older responses. input_cache_write_tokens: optional integer The aggregated number of input tokens written to the cache across 30-minute and 12-hour retention periods. input_cached_audio_tokens: optional integer The aggregated number of cached audio input tokens used. input_cached_image_tokens: optional integer The aggregated number of cached image input tokens used. input_cached_text_tokens: optional integer The aggregated number of cached text input tokens used. input_cached_tokens: optional integer 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. input_image_tokens: optional integer The aggregated number of uncached image input tokens used. input_text_tokens: optional integer The aggregated number of uncached text input tokens used, excluding cache-write tokens. input_uncached_tokens: optional integer The aggregated number of uncached input tokens used across text, audio, and image inputs, excluding cache-write tokens. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. output_audio_tokens: optional integer The aggregated number of audio output tokens used. output_image_tokens: optional integer The aggregated number of image output tokens used. output_text_tokens: optional integer The aggregated number of text output tokens used. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. service_tier: optional string or null When group_by=service_tier, this field provides the service tier of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageEmbeddingsResult { input_tokens, num_model_requests, object, 4 more } The aggregated embeddings usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.embeddings.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageModerationsResult { input_tokens, num_model_requests, object, 4 more } The aggregated moderations usage details of the specific time bucket. input_tokens: integer The aggregated number of input tokens used. num_model_requests: integer The count of requests made to the model. object: "organization.usage.moderations.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageImagesResult { images, num_model_requests, object, 6 more } The aggregated images usage details of the specific time bucket. images: integer The number of images processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.images.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. size: optional string or null When group_by=size, this field provides the image size of the grouped usage result. source: optional string or null When group_by=source, this field provides the source of the grouped usage result, possible values are image.generation, image.edit, image.variation. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioSpeechesResult { characters, num_model_requests, object, 4 more } The aggregated audio speeches usage details of the specific time bucket. characters: integer The number of characters processed. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_speeches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageAudioTranscriptionsResult { num_model_requests, object, seconds, 4 more } The aggregated audio transcriptions usage details of the specific time bucket. num_model_requests: integer The count of requests made to the model. object: "organization.usage.audio_transcriptions.result" seconds: integer The number of seconds processed. formatint64 api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationUsageVectorStoresResult { object, usage_bytes, project_id } The aggregated vector stores usage details of the specific time bucket. object: "organization.usage.vector_stores.result" usage_bytes: integer The vector stores usage in bytes. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageCodeInterpreterSessionsResult { num_sessions, object, project_id } The aggregated code interpreter sessions usage details of the specific time bucket. num_sessions: integer The number of code interpreter sessions. object: "organization.usage.code_interpreter_sessions.result" project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. OrganizationUsageFileSearchesResult { num_requests, object, api_key_id, 3 more } The aggregated file search calls usage details of the specific time bucket. num_requests: integer The count of file search calls. object: "organization.usage.file_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. vector_store_id: optional string or null When group_by=vector_store_id, this field provides the vector store ID of the grouped usage result. OrganizationUsageWebSearchesResult { num_model_requests, num_requests, object, 6 more } The aggregated web search calls usage details of the specific time bucket. num_model_requests: integer The count of model requests. num_requests: integer The count of web search calls. object: "organization.usage.web_searches.result" api_key_id: optional string or null When group_by=api_key_id, this field provides the API key ID of the grouped usage result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" context_level: optional string or null When group_by=context_level, this field provides the search context size of the grouped usage result. model: optional string or null When group_by=model, this field provides the model name of the grouped usage result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped usage result. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped usage result. OrganizationCostsResult { object, amount, api_key_id, 6 more } The aggregated costs details of the specific time bucket. object: "organization.costs.result" amount: optional { currency, value } The monetary value in its associated currency. currency: optional string Lowercase ISO-4217 currency e.g. “usd” value: optional number The numeric value of the cost. api_key_id: optional string or null When group_by=api_key_id, this field provides the API Key ID of the grouped costs result. api_source: optional "agents_api" or "unlabeled" or null 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: "agents_api" "unlabeled" line_item: optional string or null When group_by=line_item, this field provides the line item of the grouped costs result. project_id: optional string or null When group_by=project_id, this field provides the project ID of the grouped costs result. quantity: optional number or null When group_by=line_item, this field provides the quantity of the grouped costs result. quantity_unit: optional CostQuantityUnit or null The unit of the quantity value. If no single supported unit applies to the result, this field is null. user_id: optional string or null When group_by=user_id, this field provides the user ID of the grouped costs result. start_time: integer has_more: boolean next_page: string or null object: "page"