pub struct UsageCompletionsResult {Show 21 fields
pub object: String,
pub input_tokens: u64,
pub output_tokens: u64,
pub input_cached_tokens: Option<u64>,
pub input_uncached_tokens: Option<u64>,
pub input_text_tokens: Option<u64>,
pub output_text_tokens: Option<u64>,
pub input_cached_text_tokens: Option<u64>,
pub input_audio_tokens: Option<u64>,
pub input_cached_audio_tokens: Option<u64>,
pub output_audio_tokens: Option<u64>,
pub input_image_tokens: Option<u64>,
pub input_cached_image_tokens: Option<u64>,
pub output_image_tokens: Option<u64>,
pub num_model_requests: u64,
pub project_id: Option<String>,
pub user_id: Option<String>,
pub api_key_id: Option<String>,
pub model: Option<String>,
pub batch: Option<bool>,
pub service_tier: Option<String>,
}Expand description
The aggregated completions usage details of the specific time bucket.
Fields§
§object: StringThe object type, which is always organization.usage.completions.result.
input_tokens: u64The aggregated number of text input tokens used, including cached tokens. For customers subscribe to scale tier, this includes scale tier tokens.
output_tokens: u64The aggregated number of text output tokens used. For customers subscribe to scale tier, this includes scale tier tokens.
input_cached_tokens: Option<u64>The aggregated number of text input tokens that has been cached from previous requests. For customers subscribe to scale tier, this includes scale tier tokens.
input_uncached_tokens: Option<u64>The aggregated number of uncached input tokens.
input_text_tokens: Option<u64>The aggregated number of text input tokens used.
output_text_tokens: Option<u64>The aggregated number of text output tokens used.
input_cached_text_tokens: Option<u64>The aggregated number of cached text input tokens.
input_audio_tokens: Option<u64>The aggregated number of audio input tokens used, including cached tokens.
input_cached_audio_tokens: Option<u64>The aggregated number of cached audio input tokens.
output_audio_tokens: Option<u64>The aggregated number of audio output tokens used.
input_image_tokens: Option<u64>The aggregated number of image input tokens used.
input_cached_image_tokens: Option<u64>The aggregated number of cached image input tokens.
output_image_tokens: Option<u64>The aggregated number of image output tokens used.
num_model_requests: u64The count of requests made to the model.
project_id: Option<String>When group_by=project_id, this field provides the project ID of the grouped usage result.
user_id: Option<String>When group_by=user_id, this field provides the user ID of the grouped usage result.
api_key_id: Option<String>When group_by=api_key_id, this field provides the API key ID of the grouped usage result.
model: Option<String>When group_by=model, this field provides the model name of the grouped usage result.
batch: Option<bool>When group_by=batch, this field tells whether the grouped usage result is batch or not.
service_tier: Option<String>When group_by=service_tier, this field provides the service tier of the grouped usage result.
Trait Implementations§
Source§impl Clone for UsageCompletionsResult
impl Clone for UsageCompletionsResult
Source§fn clone(&self) -> UsageCompletionsResult
fn clone(&self) -> UsageCompletionsResult
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more