GPT Image 2.6 API (Flare / Sunburst)
OpenAI GPT Image 2.6 in two tiers: gpt-image-2.6-flare (default, fast) and gpt-image-2.6-sunburst (highest fidelity, slower). Both take the same parameters. New in 2.6: animated GIF, edits guided by a markup image, masks, up to 10 images per call and reasoning effort from low to max. Billed per token: image output $33 and image input $8.80 per 1M tokens, text $5.50 in and $11 out. Point the OpenAI SDK at our base_url and it works as-is.
Autenticação
Authorization: Bearer YOUR_API_KEYPricing: per token
Billing follows the way the model itself is metered — by the tokens the request actually used, with text and image priced separately and separate rates for input, cached input and output. Each request total is rounded up to $0.0001. An upper bound is held from your balance when the request is accepted; when the image is ready you are charged for the tokens used and the rest is released — credits in the task result is exactly what that request cost. Failed requests are not charged.
| Per 1M tokens | Entrada | Cached input | Output |
|---|---|---|---|
| Image | $8.80 | $2.20 | $33.00 |
| Text | $5.50 | $1.375 | $11.00 |
Flare and Sunburst share these prices. Quality, size, GIF frames, reference / mask / markup images and prompt length all change the token count, so there is no fixed price per image. Without a quality parameter apimodels.app renders at medium (the model's own default is high, which uses more image output tokens).
For reference: measured requests
5 November 2026, 16:9 text-to-image, one image — what each request actually cost, not a price per image.
| Resolution | low | medium |
|---|---|---|
| 1K (1360x768) | $0.0154 | $0.0281 |
| 2K (2720x1536) | $0.0312 | $0.0568 |
Option 1: OpenAI SDK (sync)
/v1/images/generations·POST/v1/images/editsAn OpenAI-style WxH size makes the call synchronous: the response carries the image (b64_json + url), matching images.generate() / images.edit(). Both dimensions must be multiples of 16 (1024x1024, 1536x1024 and 1024x1536 all work).
# Text-to-image, OpenAI Images API shape — a WxH size makes the call synchronous
curl -X POST https://api.apimodels.app/v1/images/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-image-2.6-flare",
"prompt": "a ceramic coffee cup on a linen tablecloth, morning window light",
"size": "1536x1024",
"quality": "medium"
}'
# → { "created": ..., "data": [{ "b64_json": "...", "url": "https://r2.apimodels.app/..." }] }
# Edit — multipart, OpenAI images.edit() shape
curl -X POST https://api.apimodels.app/v1/images/edits \
-H "Authorization: Bearer YOUR_API_KEY" \
-F "model=gpt-image-2.6-sunburst" \
-F "image=@product.png" \
-F "prompt=change only the label to green, keep everything else exactly the same" \
-F "size=1024x1024"Option 2: native async (every 2.6 parameter)
Without a WxH size the request follows the platform async contract: create returns a taskId, poll until completed and read resultUrls (one URL per image when you ask for several), or pass callback_url for a webhook. GIF, markup images, masks and num_images all go through this path.
# Animated GIF: 12 frames, 120 ms each
curl -X POST https://api.apimodels.app/v1/images/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-image-2.6-flare",
"prompt": "a paper boat bobbing on small waves, loopable",
"aspect_ratio": "1:1",
"resolution": "1K",
"output_format": "gif",
"frame_count": 12,
"frame_duration_ms": 120
}'
# → { "code": 200, "data": { "taskId": "..." } }
# Edit guided by a markup image (circles / arrows / notes on a transparent PNG)
curl -X POST https://api.apimodels.app/v1/images/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-image-2.6-sunburst",
"prompt": "apply the changes marked on the image, keep everything else",
"image_urls": ["https://example.com/room.png"],
"markup_image_url": "https://example.com/room-markup.png",
"reasoning_effort": "max"
}'
curl "https://api.apimodels.app/v1/images/generations?task_id=TASK_ID" -H "Authorization: Bearer YOUR_API_KEY"Parâmetros
| Field | Required | Type | Description |
|---|---|---|---|
| model | sim | string | gpt-image-2.6-flare / gpt-image-2.6-sunburst (gpt-image-2.6 = flare) |
| prompt | sim | string | Required, up to 32,000 characters |
| image / image_url / image_urls / images | não | string | string[] | Reference images, up to 16; any reference makes it an edit |
| mask_url / mask | não | string | Edit only: white = change, black = keep; cannot be combined with markup_image_url |
| markup_image_url / markup_image | não | string | Edit only: a transparent PNG with only circles, arrows or notes, the same size as the first reference |
| aspect_ratio + resolution | não | string | Ratio (up to 3:1) plus 1K / 2K / 4K; the server derives an exact size in multiples of 16. For edits, resolution alone follows the first reference's ratio |
| size | não | string | WxH (makes the call sync) or auto |
| image_size | não | string | object | Preset square_hd / square / portrait_4_3 / portrait_16_9 / landscape_4_3 / landscape_16_9 / auto, or {"width","height"} |
| quality | não | string | low / medium / high / auto, default medium |
| reasoning_effort | não | string | low / medium / high / xhigh / max — higher adds detail and time; omitted = model default (high) |
| output_format | não | string | png / jpeg / webp / gif. If omitted, opaque images are delivered as JPEG by platform default. svg is temporarily unavailable (see Notes) |
| output_compression | não | number | 0–100, jpeg / webp only |
| frame_count | não | number | gif only: 2–64, default 9; the frame size is reduced to fit the frame count (see Notes) |
| frame_duration_ms | não | number | gif only: milliseconds per frame, 20–2000, default 200 |
| background | não | string | auto / transparent / opaque |
| num_images / n | não | number | 1–10 |
| callback_url | não | string | Webhook for the async result |
Sizes
Exact sizes must have both sides in multiples of 16, a long edge of at most 3840, a ratio of at most 3:1 and 655,360 to 8,294,400 pixels in total. Anything else returns a 400 with the reason — the size is never changed silently. aspect_ratio + resolution examples:
| Ratio | 1K | 2K | 4K |
|---|---|---|---|
| 1:1 | 1024x1024 | 2048x2048 | 2880x2880 |
| 16:9 | 1360x768 | 2736x1536 | 3840x2160 |
| 9:16 | 768x1360 | 1536x2736 | 2160x3840 |
| 4:3 | 1152x864 | 2368x1776 | 3312x2480 |
| 3:2 | 1248x832 | 2496x1664 | 3504x2336 |
| 21:9 | 1568x672 | 3136x1344 | 3840x1648 |
With no size at all, text-to-image uses the model default landscape_4_3 and edits follow the input image (auto). aspect_ratio auto or size auto lets the model pick.
Notes and limits
- GIF: all frames are laid out on one sheet whose longest edge can be at most 3840 px (the frame count rounds up to a power of two and fills a grid — 6 frames use 4×2 or 2×4, 9 frames 4×4; a size fits if either layout does, so for 5–8 frames keep the short side at 960 or less and the long side at 1920 or less). With aspect_ratio + resolution (or no size) apimodels.app shrinks the frame size so the sheet fits — 6 frames at 1:1 1K come back at 960x960; with an exact size it is up to you, and 960x960 fits up to 16 frames. Measured on 5 November 2026: 6 frames at 832x832 low cost $0.034 per request, 6 frames at 976x672 low (fits only as 2×4) $0.0486, 9 frames at 960x960 low $0.092.
- SVG is temporarily unavailable: the model's documentation lists svg output, but every SVG request currently fails upstream, so apimodels.app returns a 400 for output_format: svg until it works.
- Markup image or mask, not both. On the previous generation (2.5) our tests showed masks acting as hints rather than hard boundaries; 2.6 has not been measured yet — for a strict local edit, name the region in the prompt as well, e.g. "change only the bottle label, keep everything else unchanged".
- Measured latency (5 November 2026, 16:9 text-to-image): 1K at reasoning low — about 6s on Flare, 8s on Sunburst; at the default high reasoning Sunburst took 11–14s at 1K and 14–16s at 2K. High quality, 4K, GIF and xhigh / max reasoning take longer; for sync calls set client timeouts to at least 240s.
- Not every request succeeds: moderation refusals and upstream errors happen, and failures are not charged. Result files are deleted after 30 days.
- Upload size: apimodels.app accepts about 4.5MB per request body; for large or many references use https://api.apimodels.app/v1 (same key, 100MB per request).
- If you need a fixed, predictable per-image price, use GPT Image 2.5 (fixed price by resolution × quality).
Perguntas frequentes
How is GPT Image 2.6 billed?
Per token, the way the model itself is metered: image output $33 per 1M tokens, image input $8.80 (cached $2.20), text input $5.50 (cached $1.375) and text output $11, each request rounded up to $0.0001. There is no fixed per-image price. For reference, measured requests on 5 November 2026 (16:9, one image) cost $0.0154 at 1K low, $0.0281 at 1K medium, $0.0312 at 2K low and $0.0568 at 2K medium. An upper bound is held when you submit and the rest is released when the image is ready; failed requests are not charged.
What can GPT Image 2.6 do that 2.5 cannot?
Animated GIF output (2–64 frames), edits guided by a markup image (circles, arrows and notes on a transparent PNG), masks where white marks the area to change, up to 10 images per call, reasoning effort from low to max, and exact pixel sizes up to 3840 on the long edge. SVG output is also listed by the model but currently fails upstream, so apimodels.app returns a 400 for it until it works.
What is the difference between gpt-image-2.6-flare and gpt-image-2.6-sunburst?
Same parameters, same token price list. Flare is the default, faster tier (about 6 seconds for 1K at reasoning low in our tests). Sunburst spends longer per image for finer detail and edits held tightly to the instruction (11–16 seconds at the default reasoning in our tests).