GPT Image models

This page covers how to call each GPT Image model ID and how it is billed. The shared protocol is described in Image generation API.

Model ID Endpoint Max images per request Price
gpt-image-2.6 POST /v1/images/generations 10 $0.0370 / image
gpt-image-2.6-flare POST /v1/images/generations 10 $0.0370 / image
gpt-image-2.6-sunburst POST /v1/images/generations 10 $0.0370 / image

The console model page is authoritative for prices.

Request parameters

One complete parameter table per model ID. Pick a model in Model ID at the top to see only its parameters.

  • size, quality and other OpenAI Images parameters are passed through to the model unchanged; allowed values are whatever the model supports, and unsupported values are rejected by the model.
  • These 3 models are billed per image; the price does not depend on size or quality.
  • stream is not supported, and /v1/images/edits is not available.

gpt-image-2.6

Parameter Type Required Default Allowed values Description
model string Yes — gpt-image-2.6 Model ID
prompt string Yes — 1–32000 characters Image description; must not be empty
n integer No 1 1–10 Number of images; billed on images actually returned
size string No Model default e.g. 1024x1024 / 1536x1024 / 1024x1536 Output size, passed through to the model. Does not affect price
quality string No Model default e.g. low / medium / high Quality, passed through to the model. Does not affect price
stream boolean No false false only Streaming is not supported; true returns 400

gpt-image-2.6-flare

Parameter Type Required Default Allowed values Description
model string Yes — gpt-image-2.6-flare Model ID
prompt string Yes — 1–32000 characters Image description; must not be empty
n integer No 1 1–10 Number of images; billed on images actually returned
size string No Model default e.g. 1024x1024 / 1536x1024 / 1024x1536 Output size, passed through to the model. Does not affect price
quality string No Model default e.g. low / medium / high Quality, passed through to the model. Does not affect price
stream boolean No false false only Streaming is not supported; true returns 400

gpt-image-2.6-sunburst

Parameter Type Required Default Allowed values Description
model string Yes — gpt-image-2.6-sunburst Model ID
prompt string Yes — 1–32000 characters Image description; must not be empty
n integer No 1 1–10 Number of images; billed on images actually returned
size string No Model default e.g. 1024x1024 / 1536x1024 / 1024x1536 Output size, passed through to the model. Does not affect price
quality string No Model default e.g. low / medium / high Quality, passed through to the model. Does not affect price
stream boolean No false false only Streaming is not supported; true returns 400

Billing

  • We hold "n × price per image" at submission.
  • We settle on the number of images actually returned (no more than n) and release the rest.
  • Failed generations are not charged.

Example: gpt-image-2.6 generating 2 images costs 2 × $0.0370 = $0.0740.

Example

curl https://api.admesh.ai/v1/images/generations \
  -H "Authorization: Bearer $ADMESH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-image-2.6",
    "prompt": "A watercolor lighthouse on a cliff at dawn",
    "n": 2,
    "size": "1024x1024"
  }'

Response:

{
  "created": 1762650000,
  "data": [
    { "b64_json": "iVBORw0KGgo…" },
    { "b64_json": "iVBORw0KGgo…" }
  ]
}

Each item may be b64_json or url; handle both.