GPT Image 2.5 image editing API: edit a photo with a prompt
Edit a photo with GPT Image 2.5 on Sume: send the image in input_references, describe the change, and set aspect_ratio to auto. Up to 16 references per call.

To edit a photo with the GPT Image 2.5 API on Sume, send POST /v1/images with the source picture as an input_references item, a prompt that says only what to change, and aspect_ratio: "auto" so the output keeps the source's shape. There is no separate edit route: the same call generates from text when you send no references and edits when you send some.
OpenAI lists image edit (v1/images/edits) as a supported endpoint for both models; Sume's Image API docs describe the single-route form. Read 2026-09-29.
What does an edit request look like?
The image URL must be public HTTPS. Localhost, private-network and non-HTTPS URLs are rejected before submission.
curl -X POST "https://api.sume.com/v1/images" \
-H "Authorization: Bearer $SUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-image-2.5",
"prompt": "Change the sofa to dark green velvet. Keep the room, light and camera angle.",
"input_references": [
{ "type": "image_url", "image_url": { "url": "https://example.com/living-room.jpg" } }
],
"aspect_ratio": "auto"
}'Why set aspect_ratio to auto?
The docs say that on edit and image-to-image calls you should prefer auto to match the reference, and that omitting the field is not the same as sending auto. Without it the output may not follow the source's shape.
How many reference images can I send?
Up to 16 on the two 2.5 ids. OpenAI's guide specifies no maximum, so treat 16 as Sume's catalog limit. Use extra references for a second subject, a style or a product shot, and say in the prompt which image plays which role.
| Model | References per request | Mask |
|---|---|---|
openai/gpt-image-2.5 | Up to 16 | mask_url optional |
openai/gpt-image-2.5-sunburst | Up to 16 | mask_url optional |
Can I limit the edit to one region?
Yes, with mask_url; see GPT Image mask edit API. OpenAI describes masks as guidance, not a hard boundary, so verify the result. Prompt-only edits work too: name what must stay unchanged, as the example does.
Sources
Related posts
More in Developers
- GPT Image 2.5 request returned 202: how to get the image from the job
When GPT Image 2.5 takes longer than 30 seconds on Sume, POST /v1/images returns 202 with a job. Poll the status URL, then read the result, or use a webhook.
- GPT Image 2.5: how many images can I generate per request?
On Sume, GPT Image 2.5 takes n from 1 to 4 images per request, billed per image. How to ask for several versions and what a 202 means for a larger n.
- GPT Image 2.5 API: OpenAI's two endpoints versus Sume's one route
OpenAI serves GPT Image 2.5 on images/generations and images/edits. On Sume both become POST /v1/images. How the fields map and what returns instead of base64.
- GPT Image 2.5 output format: png, jpeg or webp on Sume
GPT Image 2.5 on Sume returns png, jpeg or webp through output_format. Which to pick for transparency and speed, and what output_compression does on Sume today.
Written by Sume