pub struct ImagesResponse {
pub created: i64,
pub data: Option<Vec<Image>>,
pub background: Option<Background>,
pub output_format: Option<OutputFormat>,
pub size: Option<Size>,
pub quality: Option<Quality>,
pub usage: Option<ImageGenUsage>,
}Expand description
The response from the image generation endpoint.
Fields§
§created: i64The Unix timestamp (in seconds) of when the image was created.
data: Option<Vec<Image>>The list of generated images.
background: Option<Background>The background parameter used for the image generation. Either transparent or opaque.
output_format: Option<OutputFormat>The output format of the image generation. Either png, webp, or jpeg.
size: Option<Size>The size of the image generated. Either 1024x1024, 1024x1536, or 1536x1024.
quality: Option<Quality>The quality of the image generated. Either low, medium, or high.
usage: Option<ImageGenUsage>Implementations§
Source§impl ImagesResponse
impl ImagesResponse
Sourcepub fn builder() -> ImagesResponseBuilder<((), (), (), (), (), (), ())>
pub fn builder() -> ImagesResponseBuilder<((), (), (), (), (), (), ())>
Create a builder for building ImagesResponse.
On the builder, call .created(...), .data(...)(optional), .background(...)(optional), .output_format(...)(optional), .size(...)(optional), .quality(...)(optional), .usage(...)(optional) to set the values of the fields.
Finally, call .build() to create the instance of ImagesResponse.
Trait Implementations§
Source§impl Clone for ImagesResponse
impl Clone for ImagesResponse
Source§fn clone(&self) -> ImagesResponse
fn clone(&self) -> ImagesResponse
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more