Nova Canvas inpainting mask rules vs a Sume reference edit
Nova Canvas inpainting wants a pure black and white mask, same size as the input. What to build, and how Sume's edit call differs.

If you built an inpainting step on Amazon Nova Canvas, the mask is where it breaks. Amazon's user guide sets strict rules for the mask image, and a mask that looks right in an editor can still fail them. This page lists those rules, then shows the Sume side: what an edit call takes instead.
Facts about Nova Canvas are from Amazon's docs, read 2026-10-06. Facts about Sume are from the image models docs.
What Nova Canvas requires of an inpainting mask
Nova Canvas has an INPAINTING task type. For inpainting, pure black marks the pixels that are edited and pure white marks the pixels that are kept. Outpainting uses the reverse convention, which is a common source of inverted results.
- Only pure black and pure white pixels are allowed. Gray anti-aliased edges are not.
- A JPEG mask must be saved at 100% quality, because lossy compression creates gray pixels.
- The mask must be the same size as the input image.
- You can send a maskPrompt (text that names the region) instead of a maskImage, but not both.
What a Sume edit call takes instead
Sume's Image API is POST /v1/images. You pass the source as input_references (a public HTTPS URL) and describe the change in prompt. Most edit-capable models take no mask at all. Only the two ChatGPT Image 2.5 variants advertise mask_url, and the API rejects mask_url on any model whose catalog row does not list it.
The Sume docs do not state which colour marks the edited area for mask_url, so do not carry Nova's black-means-edit rule across. Run one test edit and diff the result against the source before you trust a mask. The post on checking that an edit stayed inside the mask has the numpy check.
| Question | Nova Canvas | Sume /v1/images |
|---|---|---|
| How do I mark the region? | maskImage (pure black/white) or maskPrompt | mask_url on GPT Image 2.5 only; otherwise describe it in prompt |
| Mask size | Same as the input | Check with a test edit |
| Source image | Sent in the request | Public HTTPS URL in input_references |
| Wrong parameter | Request error | 400 unsupported_parameter |
A minimal Sume edit with no mask
This call edits one region by naming it. It prints the status code, the billed cost and the first image URL. A slow edit can return 202 instead of 200, so branch on the status.
import os, requests
r = requests.post(
"https://api.sume.com/v1/images",
headers={"Authorization": f"Bearer {os.environ['SUME_API_KEY']}"},
json={
"model": "ideogram/ideogram-v4.5",
"prompt": "Replace only the red mug on the desk with a white mug. Keep everything else.",
"input_references": [{"type": "image_url", "image_url": {"url": "https://example.com/desk.jpg"}}],
},
timeout=60,
)
print(r.status_code)
body = r.json()
if r.status_code == 200:
print(body["usage"]["cost"], body["data"][0]["url"])
else:
print(body)When to keep a mask
If the region must not move by a single pixel, use a model that takes mask_url and verify. If a prompt-only edit is close enough, skip the mask and save the step. Either way, measure the pixels outside the region once per model before you rely on it.
Sources
Related posts
More in Comparisons
- Nova Canvas maskPrompt: edit by naming the region, and the Sume way
Nova Canvas accepts a maskPrompt in place of a maskImage. Sume edits work from the prompt alone on most models. How to word the region and test the result.
- Nova Canvas outpainting DEFAULT vs PRECISE, and a Sume ratio edit
Nova Canvas outPaintingMode DEFAULT can leave a halo; PRECISE follows the mask. Here is how to extend a photo on Sume, and how to test the seam.
- Nova Canvas virtual try-on mergeStyle: BALANCED, SEAMLESS, DETAILED
Nova Canvas try-on has three mergeStyle values with different trade-offs. What each protects, and the closest Sume route with a pixel diff to check it.
- Sora API ended: which Sume route replaces a talking presenter clip?
OpenAI's Sora API ended 2026-09-24. For a presenter who says exact words, the replacement is a still-plus-audio or avatar route, not a video model.
Written by Sume