GPT Image 2.6 is OpenAI's image model for generating and editing from text and reference images. It shipped on 4 November 2026 as two versions: Flare for fast iteration, and Sunburst for detailed work. OpenAI's current recommendation for new integrations is the 2.6 pair, not the older GPT Image models. That account is from OpenAI's image generation guide and the Flare and Sunburst model pages, read on 29 November 2026.
On Kerox each version has two billing modes, so the "GPT Image 2 API" is four model IDs on one endpoint. A usage-based Flare image at low quality and 1K is $0.0210 for the output tokens alone. The walkthrough below uses that ID, then shows when to switch. Samples and the switcher live on the GPT Image 2.6 model page. Field-by-field docs: Flare API docs.
Four IDs, one request shape
| Model ID | Use it when |
|---|---|
openai/gpt-image-2.6-flare-economy | Flare, fixed price by resolution, one PNG. You know the cost before you start. |
openai/gpt-image-2.6-sunburst-economy | Sunburst, same fixed price shape, one PNG. |
openai/gpt-image-2.6-flare | Flare, billed on tokens. Up to 4 images, WebP or JPEG, transparent backgrounds, and the complexity control. |
openai/gpt-image-2.6-sunburst | Sunburst, billed on tokens, with the same extra controls. |
The per-image IDs are the ones to start with if you are porting a script that used to call a single "image" endpoint and you want a predictable bill. The usage-based IDs are the ones that match OpenAI's token meter, including quality levels from low through max and the complexity setting OpenAI added in 2.6. GPT Image 2.5 Flare and Sunburst already include xhigh and max; 2.6 keeps them. See size and quality options. Output goes up to 4K, within about 8.3 million pixels, which is OpenAI's stated ceiling on the pages linked above.
OpenAI also lists limits that still apply: precise text placement can fail, a character or logo may drift between generations, and a tightly specified layout is hard to hit exactly. Raise complexity on the usage-based models when the prompt is dense with text or with relationships between objects. The per-image models do not take complexity.
Create a key
Sign in at API keys, create a key, and put funds in the wallet. The minimum top-up is $5. Export the secret as KEROX_API_KEY and send Authorization: Bearer <your-api-key> from your server. Authentication covers rotation and per-key spend limits. The quickstart is the same loop with a different model ID.
Submit, poll, and save the PNG
POST https://api.kerox.ai/v1/tasks returns HTTP 201 and a task ID. Image tasks finish faster than video, but the contract is the same: poll GET /v1/tasks/{id} until succeeded or failed, then download outputs[0].url. The scripts wait up to 10 minutes. Files expire 7 days after the task finishes. Tasks documents the object.
# Needs curl and jq. KEROX_API_KEY is your key.
set -euo pipefail
API=https://api.kerox.ai/v1
AUTH="Authorization: Bearer $KEROX_API_KEY"
BODY='{
"model": "openai/gpt-image-2.6-flare",
"input": {
"prompt": "Editorial still life of a brass microscope on a walnut desk, morning side light, 35mm film",
"resolution": "1K",
"aspect_ratio": "1:1",
"quality": "high"
}
}'
TASK_ID=$(curl -sS --fail-with-body -X POST "$API/tasks" \
-H "$AUTH" -H "Content-Type: application/json" -d "$BODY" | jq -r .id)
echo "Submitted $TASK_ID"
DEADLINE=$(( $(date +%s) + 600 ))
STATUS=processing
while [ "$STATUS" = "processing" ] && [ "$(date +%s)" -lt "$DEADLINE" ]; do
sleep 3
TASK=$(curl -sS --fail-with-body "$API/tasks/$TASK_ID" -H "$AUTH")
STATUS=$(echo "$TASK" | jq -r .status)
done
if [ "$STATUS" != "succeeded" ]; then
echo "Task $TASK_ID is $STATUS: $(echo "$TASK" | jq -c .error)"
exit 1
fi
curl -sS --fail-with-body -o result.png "$(echo "$TASK" | jq -r '.outputs[0].url')"
echo "Saved result.png"
# pip install requests
import os
import time
import requests
API = "https://api.kerox.ai/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['KEROX_API_KEY']}"}
resp = requests.post(
f"{API}/tasks",
headers=HEADERS,
json={
"model": "openai/gpt-image-2.6-flare",
"input": {
"prompt": "Editorial still life of a brass microscope on a walnut desk, morning side light, 35mm film",
"resolution": "1K",
"aspect_ratio": "1:1",
"quality": "high",
},
},
timeout=60,
)
if resp.status_code != 201:
raise SystemExit(f"HTTP {resp.status_code}: {resp.json()['error']}")
task = resp.json()
print("Submitted", task["id"])
deadline = time.time() + 600
while task["status"] == "processing" and time.time() < deadline:
time.sleep(3)
task = requests.get(
f"{API}/tasks/{task['id']}", headers=HEADERS, timeout=30
).json()
if task["status"] != "succeeded":
raise SystemExit(f"Task {task['id']} is {task['status']}: {task.get('error')}")
file = requests.get(task["outputs"][0]["url"], timeout=120)
file.raise_for_status()
open("result.png", "wb").write(file.content)
print("Saved result.png")
// Node.js 18 or later. Save as generate.mjs and run: node generate.mjs
import fs from 'node:fs/promises';
const API = 'https://api.kerox.ai/v1';
const headers = { Authorization: `Bearer ${process.env.KEROX_API_KEY}` };
const res = await fetch(`${API}/tasks`, {
method: 'POST',
headers: { ...headers, 'Content-Type': 'application/json' },
body: JSON.stringify({
model: 'openai/gpt-image-2.6-flare',
input: {
prompt:
'Editorial still life of a brass microscope on a walnut desk, morning side light, 35mm film',
resolution: '1K',
aspect_ratio: '1:1',
quality: 'high',
},
}),
});
let task = await res.json();
if (res.status !== 201)
throw new Error(`HTTP ${res.status}: ${task.error.message}`);
console.log('Submitted', task.id);
const deadline = Date.now() + 10 * 60 * 1000;
while (task.status === 'processing' && Date.now() < deadline) {
await new Promise((resolve) => setTimeout(resolve, 3000));
const poll = await fetch(`${API}/tasks/${task.id}`, { headers });
if (!poll.ok) throw new Error(`HTTP ${poll.status}`);
task = await poll.json();
}
if (task.status !== 'succeeded') {
throw new Error(
`Task ${task.id} is ${task.status}: ${JSON.stringify(task.error)}`
);
}
const file = await fetch(task.outputs[0].url);
if (!file.ok) throw new Error(`Download failed: HTTP ${file.status}`);
await fs.writeFile('result.png', Buffer.from(await file.arrayBuffer()));
console.log('Saved result.png');
To edit instead of generating from scratch, add images with up to 16 URLs and describe the change in the prompt. Upload local files first and pass the returned URLs: Files. A public sample you can point at while testing is the lighthouse sample.
Pass webhook_url if you do not want to poll. When the task reaches succeeded or failed, Kerox creates one notification and delivers it to a public https:// address. A failed delivery is retried, up to 12 attempts. Deduplicate on the webhook-id header. The console stores the signing secret, not this address. Webhooks.
{
"model": "openai/gpt-image-2.6-flare-economy",
"input": {
"prompt": "Editorial still life of a brass microscope on a walnut desk, morning side light",
"resolution": "2K",
"aspect_ratio": "4:5",
"quality": "high"
},
"webhook_url": "https://example.com/webhooks/kerox"
}
Idempotency-Key makes a retry safe: the same key and body within 24 hours return the original task and do not charge twice. Idempotency.
Parameters
Shared by all four IDs:
prompt. Required. 1 to 32,000 characters, and it cannot be only whitespace.images. Optional. One URL, or an array of up to 16. HTTPS, or a data URL for PNG, JPEG, WebP, GIF, or BMP.resolution.1K(default),2K, or4K.aspect_ratio.1:1(default),3:2,2:3,4:3,3:4,16:9,9:16,21:9, orauto. The per-image models also accept5:4and4:5.quality.auto,low,medium,high,xhigh, ormax.
Only the usage-based IDs (-flare and -sunburst without -economy):
n. 1 to 4 images. Default 1. The per-image IDs rejectn.output_format.png(default),webp, orjpeg.background.auto(default),opaque, ortransparent. Transparent requires PNG or WebP.complexity.low,medium, orhigh(defaulthigh). This is the 2.6 planning control. It is not on the per-image IDs.
Rules that produce 400 if you miss them:
aspect_ratio: "auto"cannot sit next toresolution. Omitresolutionand let the model size the image, or pick a concrete ratio and a resolution.- Do not send OpenAI's
sizestring such as1024x1024. This API usesresolutionplusaspect_ratio.size,mask,moderation,stream, andresponse_formatare not accepted. - Per-image calls are one PNG. Asking the economy ID for
output_formatornis an unknown parameter. Switch IDs if you need those. - Transparent JPEG fails. Set
output_formattopngorwebpwhenbackgroundistransparent. - Quality changes the usage bill, not the per-image bill. On the economy IDs the price tier is the resolution. On the usage IDs,
lowat 1K andmaxat 4K are different output-token counts. Read the table before you loopmax.
POST /v1/estimate quotes the hold for the exact body. Studio shows it before you generate.
What it costs
Two meters, both read from the catalog rather than typed here.
Usage-based Flare and Sunburst follow OpenAI's token rates: text input, cached text, image input, cached image input, and image output. The table is only the image-output portion at that quality and size, before the public discount. A long prompt and any reference image are extra, and the task settles on the measured usage. The official column is the maker rate as stored in the catalog. The OpenAI pages linked above were read on 29 November 2026.
| Model | Official price | Kerox | You save |
|---|---|---|---|
| GPT Image 2.6 Flare1 image · low · 1K | $0.0210 | 15% | |
| GPT Image 2.6 Flare1 image · high · 2K | $0.0910 | 14% | |
| GPT Image 2.6 Flare1 image · max · 4K | $0.6048 | 15% | |
| GPT Image 2.6 Sunburst1 image · low · 1K | $0.0210 | 15% | |
| GPT Image 2.6 Sunburst1 image · high · 2K | $0.0910 | 14% | |
| GPT Image 2.6 Sunburst1 image · max · 4K | $0.6048 | 15% |
Per-image Flare and Sunburst are a fixed Kerox price for one PNG at 1K, 2K, or 4K. The catalog does not publish a separate maker list price for these two IDs, so there is no official column. Reference images on this meter are included in the way the per-image rule is written; confirm the line you care about with POST /v1/estimate before a large batch.
| Model | Kerox |
|---|---|
| GPT Image 2.6 Flare Economy1 image · 1K | $0.0150 |
| GPT Image 2.6 Flare Economy1 image · 2K | $0.0450 |
| GPT Image 2.6 Flare Economy1 image · 4K | $0.0600 |
| GPT Image 2.6 Sunburst Economy1 image · 1K | $0.0150 |
| GPT Image 2.6 Sunburst Economy1 image · 2K | $0.0450 |
| GPT Image 2.6 Sunburst Economy1 image · 4K | $0.0600 |
A failed task is refunded in full. The hold is taken when you submit and settled when the image is done. Pricing and billing.
When to change the ID
Stay on one ID per pipeline so retries and cost alerts stay comparable.
- Drafts and tight loops:
openai/gpt-image-2.6-flare-economyat 1K, then move the keeper to 2K or 4K. - Posters, small text, or a layout with several objects:
openai/gpt-image-2.6-sunburstwithcomplexityathighandqualityathighor above. - A cutout: usage-based ID,
backgroundtransparent,output_formatpng. - Four variations in one call: usage-based ID,
n4. That is four output images on the token meter.
If the job is video, this model will not do it. Seedance 2.5 and Kling 4.0 are the video calls on the same key. For a different still model, the model list includes Seedream and Qwen Image.
Errors
| You got | What to do |
|---|---|
HTTP 400 with param | The named field is wrong. Typical cases: resolution together with aspect_ratio auto, n on an economy ID, transparent JPEG, an empty prompt. Fix and send a new body. |
HTTP 401 | Missing or revoked API key. |
HTTP 402 | Balance or key spend limit. Top up, or lower quality / resolution / n. |
HTTP 413 | The body or an inline file is too large. Upload with the files API and pass URLs. |
HTTP 429 | Respect retry-after when it is present. Otherwise wait for an in-progress task to finish. |
status: "failed" | Refunded. A content failure will fail again if you resubmit the same prompt unchanged. |
Every code is listed in Errors. Include the x-request-id header if you write to hi@kerox.ai.
GPT Image 2.6, in one pass
Pick the ID for the meter you want, send a prompt plus resolution and aspect ratio, and poll the task. Use the economy IDs when the price must be known up front, and the usage-based IDs when you need n, file format, transparency, or complexity. The model page switches versions without a second account, and the API docs show a body for each mode.


