GPT Image 2 Text-to-Image
Image Generation - GPT Image 2
GPT Image 2 Text-to-Image
Generate images from text using GPT Image 2 model (async)
POST
GPT Image 2 Text-to-Image
Generate images from text using OpenAI’s GPT Image 2 model.
Key Features:
- Long Prompts - Supports prompts up to 20000 characters
- Multiple Aspect Ratios - Auto, 1:1, 5:4, 9:16, 21:9, 16:9, 4:3, 3:2, 4:5, 3:4, 2:3
- High Resolution - Supports 1K / 2K / 4K output
- NSFW Filter - Optional NSFW content check (enabled by default)
Authorizations
Please use your API Token for authentication
Body
application/json
Task parameters
Prompt (required, max 20000 characters)
Required string length:
1 - 20000Example:
"A cute robot sitting in a field of flowers, digital art style"
Aspect ratio (optional, default auto)
Available options:
auto, 1:1, 5:4, 9:16, 21:9, 16:9, 4:3, 3:2, 4:5, 3:4, 2:3 Example:
"auto"
NSFW check (optional, default true)
Example:
true
Resolution (optional, default 1K)
Available options:
1K, 2K, 4K Example:
"1K"
Response
OK
Task ID
Example:
"01234567-89ab-cdef-0123-456789abcdef"