GPT Image 2
How TheRouter serves this differently from the vendor
OpenAI serves direct gpt-image-2 calls on /v1/images/generations and /v1/images/edits; its model page marks /v1/responses and /v1/chat/completions as not supported for the model ID itself.
TheRouter exposes the same image generation and image edit surfaces under https://api.therouter.ai/v1 with the routed model id openai/gpt-image-2. Examples therefore keep the OpenAI SDK shape but change baseURL, API key, and model slug.
Media Generation Capabilities
- sizes
- 1024x1024
- 1024x1536
- 1536x1024
- qualities
- low
- medium
- high
- max_outputs_per_request
- 4
- output_formats
- png
- jpeg
- webp
- defaults
- size
- 1024x1024
- quality
- medium
- sizes
- 1024x1024
- 1024x1536
- 1536x1024
- qualities
- low
- medium
- high
- max_reference_images
- 4
- output_formats
- png
- jpeg
- webp
- defaults
- size
- 1024x1024
- quality
- medium
API guide
Image generation
Generate images from text prompts using the standard OpenAI Images API. Supports 2K resolution, quality tiers, output format selection, transparent backgrounds, and up to 8 images per batch.
curl https://api.therouter.ai/v1/images/generations \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-image-2",
"prompt": "A serene mountain landscape at sunset, photorealistic style",
"n": 1,
"size": "2048x2048",
"quality": "medium",
"output_format": "png"
}'Image editing
Edit existing images using text prompts and reference images. Supports high-fidelity image inputs, masked editing, and multi-image composition.
curl https://api.therouter.ai/v1/images/edits \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-F "model=openai/gpt-image-2" \
-F "image=@input.png" \
-F "prompt=Replace the sky with a starry night sky, keep the foreground unchanged" \
-F "size=2048x2048"Recent coverage
Fact ledger β every claim on this page traces here
| source | URL | retrieved | |
|---|---|---|---|
| Release date | openai.com β | 2026-05-29 | verified |
| Max resolution | developers.openai.com β | 2026-08-04 | verified |
| Aspect ratios | developers.openai.com β | 2026-08-04 | verified |
| Output formats | developers.openai.com β | 2026-08-04 | verified |
| Knowledge cutoff | developers.openai.com β | 2026-08-04 | unknown |
| Thinking mode | openai.com β | 2026-05-29 | verified |
| Images per prompt | developers.openai.com β | 2026-08-04 | unknown |
| License | β | β | verified |
| Image Arena β Text-to-Image (overall) | arena.ai β | 2026-08-04 | verified |
| Image Arena β Single-Image Edit | arena.ai β | 2026-08-04 | verified |
| Image Arena β Multi-Image Edit | arena.ai β | 2026-08-04 | verified |
| Image Arena β Text Rendering sub-category | arena.ai β | 2026-08-04 | verified |
| Image Arena β Product, Branding & Commercial Design | arena.ai β | 2026-08-04 | verified |
| Image Arena β Portraits sub-category | arena.ai β | 2026-08-04 | verified |
| OpenAI launches ChatGPT Images 2.0 with gpt-image-2 β reasoning-powered image generation | openai.com β | 2026-05-29 | verified |
| How is gpt-image-2 different from gpt-image-1.5? | openai.com β | 2026-05-29 | to verify |
| What resolution and aspect ratios does gpt-image-2 support? | felloai.com β | 2026-05-29 | to verify |
| Is gpt-image-2 compatible with the existing DALLΒ·E 3 integration I already have? | gptimage2.design β | 2026-05-29 | to verify |