OpenAI images.generate to Sume /v1/images: field by field map
Move a gpt-image-1 images.generate call to Sume POST /v1/images: which fields carry over, which return 400, and why size becomes image_size. Python mapper.

Most images.generate fields carry over to POST /v1/images with the same name. Four do not: size becomes image_size, response_format and base64 output go away because Sume returns a hosted URL, and output_compression, moderation, partial_images and stream are not accepted. Sume returns 400 unsupported_parameter for a field the chosen model does not list, so a leftover argument fails loudly.
The table is built from OpenAI's image guide and Sume's image docs, both read on 2026-10-06.
Field map
| OpenAI field | On Sume | Note |
|---|---|---|
| model | model | Use openai/gpt-image-2.5-sunburst, not a retired id |
| prompt | prompt | Same |
| n | n | Per-model ceiling in the catalog; request cap is 10 |
| size: 1536x1024 | image_size: {width, height} | Sume's size field is a tier shorthand and rejects WxH |
| quality | quality | auto, low, medium, high; xhigh and max on ChatGPT Image 2.5 |
| output_format | output_format | png, jpeg, webp |
| output_compression | not accepted | 400 unsupported_parameter |
| background | background | auto, transparent, opaque; ChatGPT Image 2.5 only |
| moderation, partial_images, stream | not accepted | stream returns 400 streaming_not_supported |
| image / mask files | input_references, mask_url | Public HTTPS URLs, up to 16 references on 2.5 |
| b64_json | data[].url | Sume returns a hosted URL |
A mapper you can run
The function builds a Sume body from the kwargs of an old call and returns the fields it had to drop, so you can log them once and delete them from the caller.
def to_sume(oa):
body = {"model": "openai/gpt-image-2.5-sunburst", "prompt": oa["prompt"]}
for key in ("n", "quality", "output_format", "background"):
if key in oa:
body[key] = oa[key]
size = oa.get("size", "auto")
if size != "auto":
width, height = (int(v) for v in size.split("x"))
body["image_size"] = {"width": width, "height": height}
gone = ("output_compression", "moderation", "partial_images", "stream",
"response_format")
return body, [k for k in gone if k in oa]
if __name__ == "__main__":
old = {"prompt": "a red kettle", "size": "1536x1024", "quality": "high",
"output_compression": 80, "moderation": "low"}
print(to_sume(old))Custom sizes on Sume
Custom GPT sizes must be multiples of 16, no edge above 3840, an aspect ratio of at most 3:1, and between 655,360 and 8,294,400 pixels. 1536x1024 passes all four. Read the full migration notes for the date and the id.
Sources
Related posts
More in Developers
- opencode remote MCP entry for Sume: env syntax and a longer timeout
The hosted Sume server in opencode.json: type remote, a bearer header from an env variable, a timeout above jobs_wait's 55 s cap. Checked by a script.
- Fade out the end of a Short: Timeline fade_out_seconds limits
Sume Timeline fades video and audio at the ends with output.fade_in_seconds and fade_out_seconds, 0 to 5 each, summing to at most the length. Setup for Shorts.
- Pin the image model id on the queue row so a swap can't break old jobs
Store the Sume model id on each queued render row at enqueue time, then re-point only rows still carrying a retired id. Python sqlite3 sample for gpt-image-1.
- Poll many transcription jobs without a 429: next_poll_after_seconds
Poll Sume job status with the next_poll_after_seconds the API sends, back off on 429 with retry-after, and stop on a terminal status.
Written by Sume