GPT Image 2.5 API
ReachAPI exposes GPT Image 2.5 Flare and Sunburst through both the synchronous OpenAI-compatible Image API and the asynchronous ReachAPI task API. Both products are currently in Internal Preview.
- Use
gpt-image-2.5-flarefor fast, high-quality everyday image generation. - Use
gpt-image-2.5-sunburstwhen maximum capability and editing precision matter most.
1. Choose an Interface
- Synchronous generation:
POST https://direct.reachapi.ai/v1/images/generations - Synchronous editing:
POST https://direct.reachapi.ai/v1/images/edits - Asynchronous task:
POST https://direct.reachapi.ai/v1/images/create - Query asynchronous task:
GET https://direct.reachapi.ai/v1/tasks/{task_id}
Use the synchronous Image API when the caller can wait for the complete response and wants the native OpenAI request and response shape. Use the asynchronous task API for long-running jobs, URL-based reference images, polling, callbacks, and hosted results in data[].url.
All interfaces use the same model codes and authentication:
Authorization: Bearer YOUR_REACH_API_KEY2. Synchronous Image API
The synchronous endpoints follow the OpenAI Image API contract. Image generation accepts JSON. Image editing accepts the native multipart form request with one or more image files.
Generate an image
curl -X POST "https://direct.reachapi.ai/v1/images/generations" \
-H "Authorization: Bearer YOUR_REACH_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-image-2.5-flare",
"prompt": "A precise editorial product photograph of a silver watch on slate, soft studio lighting",
"size": "1536x1024",
"quality": "high",
"background": "auto",
"moderation": "auto",
"output_format": "png"
}'Edit an image
curl -X POST "https://direct.reachapi.ai/v1/images/edits" \
-H "Authorization: Bearer YOUR_REACH_API_KEY" \
-F "model=gpt-image-2.5-sunburst" \
-F "prompt=Preserve the watch geometry and replace only the background with dark brushed metal" \
-F "image[]=@/path/to/watch.png" \
-F "size=1536x1024" \
-F "quality=xhigh" \
-F "output_format=png"Do not set the multipart boundary manually. The client, SDK, or curl -F generates it.
Synchronous contract
- Use flat OpenAI fields such as
model,prompt,size,quality,background,moderation, andoutput_format; do not wrap them ininput. - Use
POST /v1/images/generationsfor text-to-image andPOST /v1/images/editsfor file-based image editing. - The synchronous endpoints return the native OpenAI Images response. They do not return a ReachAPI
task_idand do not support task polling orcallback_url. - Follow the OpenAI-compatible endpoint for the complete parameter and response contract, including masks and supported multi-image edits.
3. Asynchronous Task API
The asynchronous endpoint uses a nested { "model": "...", "input": { ... } } request and immediately returns a task ID.
curl -X POST "https://direct.reachapi.ai/v1/images/create" \
-H "Authorization: Bearer YOUR_REACH_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-image-2.5-flare",
"callback_url": "https://example.com/reachapi/callback",
"input": {
"prompt": "A precise editorial product photograph of a silver watch on slate, soft studio lighting",
"resolution": "2k",
"aspect_ratio": "3:2",
"quality": "high",
"background": "auto",
"moderation": "auto",
"output_format": "png"
}
}'Top-level parameters
| Field | Type | Required | Description |
|---|---|---|---|
model | string | Yes | gpt-image-2.5-flare or gpt-image-2.5-sunburst |
callback_url | string | No | HTTPS callback for terminal status; maximum length 2048; local and private-network targets are rejected |
input | object | Yes | Image generation or editing parameters |
input parameters
| Field | Type | Required | Description |
|---|---|---|---|
prompt | string | Yes | Prompt for image generation or editing |
image_urls | array<string> | No | Up to 14 server-accessible HTTPS reference images; omit for text-to-image |
size | string | No | Exact upstream size; takes priority over resolution + aspect_ratio |
resolution | string | No | 1k, 2k, or 4k; defaults to 1k |
aspect_ratio | string | No | 1:1, 3:2, or 2:3; defaults to 1:1 |
quality | string | No | low, medium, high, xhigh, max, or auto; defaults to auto |
background | string | No | auto, opaque, or transparent |
moderation | string | No | auto or low |
output_format | string | No | png, jpeg, or webp |
background=transparent cannot be combined with output_format=jpeg.
Standard size mapping
resolution + aspect_ratio | Output size |
|---|---|
1k + 1:1 | 1024x1024 |
1k + 3:2 | 1536x1024 |
1k + 2:3 | 1024x1536 |
2k + 1:1 | 2048x2048 |
2k + 3:2 | 2048x1152 |
4k + 3:2 | 3840x2160 |
4k + 2:3 | 2160x3840 |
Use input.size when the desired combination is not in this table.
Asynchronous image editing
Include input.image_urls to edit or transform reference images:
{
"model": "gpt-image-2.5-sunburst",
"input": {
"prompt": "Preserve the watch geometry and replace only the background with dark brushed metal",
"image_urls": ["https://cdn.example.com/watch.png"],
"resolution": "2k",
"aspect_ratio": "3:2",
"quality": "xhigh",
"output_format": "png"
}
}Task results and callbacks
A successful submission returns a task ID:
{
"code": 200,
"msg": "",
"status": "queued",
"task_id": "task_xxx",
"data": []
}Poll GET /v1/tasks/{task_id} until the status is success or failed. A successful task returns the generated image in data[].url and may also include size and revised_prompt.
When callback_url is supplied, ReachAPI sends the terminal task response to that HTTPS URL. Callback delivery has a 10-second timeout and is retried up to two times after the first attempt.
Asynchronous constraints
promptis required and cannot be blank.image_urlsaccepts up to 14 HTTPS URLs; base64 image input is not supported.n > 1, masks,output_compression, anduserare not exposed by this async endpoint.- Without
size,resolution + aspect_ratiomust match the standard mapping table.
4. Pricing
Both interfaces use the same GPT Image 2.5 Standard token rates. ReachAPI bills only these three metrics:
| Usage metric | Standard price |
|---|---|
| Text input | $5 / 1M tokens |
| Image input | $8 / 1M tokens |
| Image output | $30 / 1M tokens |
Flare and Sunburst use the same token rates. Actual cost per image varies because model choice, quality, dimensions, prompt, and reference images can change token consumption.
5. Availability and References
The two GPT Image 2.5 model codes are Internal Preview products and may not appear in GET /v1/models.