openai/gpt-image-2
OpenAI's state-of-the-art image generation model. Create and edit images from text with strong instruction following, sharp text rendering, and detailed editing.
Capabilities
Cost
Community model (estimated from hardware time)
Input Parameters
| Name | Type | Description | Default | Constraints |
|---|---|---|---|---|
prompt * | string | A text description of the desired image | — | — |
aspect_ratio | string | The size of the generated image. Use 'auto' to let the model pick. Sizes above 2560x1440 are experimental and may give more variable results. | "1:1" | 1:1 3:2 2:3 16:9 9:16 auto 1024x1024 1536x1024 1024x1536 2048x2048 2048x1152 1152x2048 3840x2160 2160x3840 |
background | string | Set whether the background is transparent or opaque or choose automatically | "auto" | auto transparent opaque |
input_images | array | A list of images to use as input for the generation | — | — |
moderation | string | Content moderation level | "auto" | auto low |
number_of_images | integer | Number of images to generate (1-10) | 1 | min: 1, max: 10 |
openai_api_key | string (password) | Your OpenAI API key (optional - uses proxy if not provided) | — | — |
output_compression | integer | Compression level (0-100%) | 90 | min: 0, max: 100 |
output_format | string | Output format | "webp" | png jpeg webp |
quality | string | The quality of the generated image | "auto" | low medium high auto |
user_id | string | An optional unique identifier representing your end-user. This helps OpenAI monitor and detect abuse. | — | — |
prompt required string A text description of the desired image
aspect_ratio string The size of the generated image. Use 'auto' to let the model pick. Sizes above 2560x1440 are experimental and may give more variable results.
"1:1" background string Set whether the background is transparent or opaque or choose automatically
"auto" input_images array A list of images to use as input for the generation
moderation string Content moderation level
"auto" number_of_images integer Number of images to generate (1-10)
1 min: 1, max: 10 openai_api_key string Your OpenAI API key (optional - uses proxy if not provided)
output_compression integer Compression level (0-100%)
90 min: 0, max: 100 output_format string Output format
"webp" quality string The quality of the generated image
"auto" user_id string An optional unique identifier representing your end-user. This helps OpenAI monitor and detect abuse.
cf6d59680126 Updated: 6/26/2026 9.6M runs
cinemasetfree.com