openai_struct/models/
usage_images_result.rs

1/*
2 * OpenAI API
3 *
4 * The OpenAI REST API. Please see pub https://platform.openai.com/docs/api-reference for more details.
5 *
6 * OpenAPI spec pub version: 2.3.0
7 *
8 * Generated pub by: https://github.com/swagger-api/swagger-codegen.git
9 */
10
11/// pub UsageImagesResult : The aggregated images usage details of the specific time bucket.
12
13#[allow(unused_imports)]
14use serde_json::Value;
15
16#[derive(Debug, Serialize, Deserialize)]
17pub struct UsageImagesResult {
18    /// When `group_by=api_key_id`, this field provides the API key ID of the grouped usage result.
19    #[serde(rename = "api_key_id")]
20    pub api_key_id: Option<String>,
21    /// The number of images processed.
22    #[serde(rename = "images")]
23    pub images: i32,
24    /// When `group_by=model`, this field provides the model name of the grouped usage result.
25    #[serde(rename = "model")]
26    pub model: Option<String>,
27    /// The count of requests made to the model.
28    #[serde(rename = "num_model_requests")]
29    pub num_model_requests: i32,
30    #[serde(rename = "object")]
31    pub object: String,
32    /// When `group_by=project_id`, this field provides the project ID of the grouped usage result.
33    #[serde(rename = "project_id")]
34    pub project_id: Option<String>,
35    /// When `group_by=size`, this field provides the image size of the grouped usage result.
36    #[serde(rename = "size")]
37    pub size: Option<String>,
38    /// When `group_by=source`, this field provides the source of the grouped usage result, possible values are `image.generation`, `image.edit`, `image.variation`.
39    #[serde(rename = "source")]
40    pub source: Option<String>,
41    /// When `group_by=user_id`, this field provides the user ID of the grouped usage result.
42    #[serde(rename = "user_id")]
43    pub user_id: Option<String>,
44}