Deserialised response from OpenAI's Image Generation endpoint (POST /v1/images/generations), returned by OpenAiClient.getImageGeneration. Wraps the generated images and the request settings that produced them, and is used by OpenAiImageProvider to build images on behalf of the platform's AI features.
Properties
| Property | Returns | Description |
|---|---|---|
| background | String | Background setting used to generate the images, such as transparent or opaque. |
| created | long | Unix timestamp, in seconds, of when OpenAI created the images. |
| data | List<ImageLocation> | Generated images, each returned as either a URL or inline base64 data. |
| outputFormat | String | File format of the generated images, such as png or jpeg. |
| quality | String | Quality level used to generate the images, such as standard or hd. |
| size | String | Pixel dimensions of the generated images, such as 1024x1024. |
| usage | Map<String,Object> | Raw token usage details OpenAI returned for the image generation request, as an untyped map of the JSON OpenAI sent back. |
Methods
getCreated()
Returns: long
Unix timestamp, in seconds, of when OpenAI created the images.
getOutputFormat()
Returns: String
File format of the generated images, such as png or jpeg.
getBackground()
Returns: String
Background setting used to generate the images, such as transparent or opaque.
getQuality()
Returns: String
Quality level used to generate the images, such as standard or hd.
getSize()
Returns: String
Pixel dimensions of the generated images, such as 1024x1024.
getData()
Returns: List<ImageLocation>
Generated images, each returned as either a URL or inline base64 data.
getUsage()
Returns: Map<String,Object>
Raw token usage details OpenAI returned for the image generation request, as an untyped map of the JSON OpenAI sent back.