GPT Image 2.5 mask edit: does the mask need an alpha channel?
OpenAI's API says the mask must contain an alpha channel. Sume's docs list a public HTTPS mask_url for GPT Image 2.5 edits but state no mask format rule.

For OpenAI's own API, yes: its guide says "The mask image must also contain an alpha channel" and that image and mask must match in format and size. Sume's docs list an optional public HTTPS mask_url for ChatGPT Image 2.5 edits but say nothing about alpha.
Sume's page does not state the alpha rule or any mask format rule, so whether Sume applies OpenAI's rule to mask_url is not documented. Preparing the mask to OpenAI's rule is a cautious choice, not a documented Sume requirement. Both pages were read 2026-09-30.
What does OpenAI require of the mask?
From OpenAI's image generation guide: the image and the mask must match in format and size (under 50MB), and the mask must contain an alpha channel. That rule is for OpenAI's API; this post does not claim Sume enforces it.
What does Sume accept?
On POST /v1/images, ChatGPT Image 2.5 (openai/gpt-image-2.5 and openai/gpt-image-2.5-sunburst) takes up to 16 image references, an optional mask_url, and background: auto|transparent|opaque. Reference and mask URLs must be public HTTPS; localhost, private-network and non-HTTPS URLs are rejected before submission.
| Item | Rule | Source |
|---|---|---|
| Mask alpha channel | Required by OpenAI's API; not stated in Sume docs | OpenAI |
| Image and mask | Same format and size (OpenAI's API) | OpenAI |
| Mask location on Sume | mask_url, public HTTPS | Sume |
| Reference images | Up to 16, public HTTPS | Sume |
What does the request look like?
Reference the source image in input_references and point mask_url at your mask (prepared to OpenAI's rule as a precaution).
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": "Replace the masked area with a ceramic mug, keep everything else",
"input_references": [
{ "type": "image_url",
"image_url": { "url": "https://media.sume.com/artifacts/artf_demo/photo.png" } }
],
"mask_url": "https://media.sume.com/artifacts/artf_demo/mask.png"
}'What can go wrong?
OpenAI's guide says the image and mask must match in format and size; Sume's docs say URLs must be public HTTPS and are rejected before submission otherwise. Slow edits can degrade to a 202 job envelope; read the result from GET /v1/jobs/{id}/result in that case. Failed generations are not billed.
How do I check this myself?
Test the mask on one low-cost call before a batch. If the edit ignores your mask, open it in an image tool and confirm the alpha channel exists and that its dimensions equal the source image, the two conditions OpenAI names for its own API. The linked docs pages and the catalog endpoint show the current values, and this post reflects them as of 2026-09-30.
Sources
Related posts
More in Developers
- GPT Image edit with a mask and several images: which is masked?
OpenAI applies the mask to the first of several input images. Sume forwards input_references in order with mask_url, so put the image to edit first.
- GPT Image 2.5 moderation low: can you send it through Sume?
OpenAI lists a moderation parameter (auto or low) for GPT Image 2.5. Sume's request table does not list it, so check the catalog before sending it.
- GPT Image resolution above 2560x1440: experimental, and Sume's cap
OpenAI marks GPT Image sizes above 2560x1440 as experimental. Sume's 2.5 custom pixels accept up to a 3840 edge, so check the five size rules before you send.
- gpt-image-2 transparent background: OpenAI preview vs Sume
OpenAI put transparent backgrounds for gpt-image-2 in preview (png or webp). On Sume, the background parameter is listed for ChatGPT Image 2.5, not gpt-image-2.
Written by Sume