image_size or aspect_ratio on Sume: which wins and who accepts it
On Sume's Images API image_size takes priority over aspect_ratio. Custom pixels work on GPT, Seedream, Flux, Qwen and Recraft; size rejects WxH.

If you send both, image_size wins and aspect_ratio is ignored on models that take custom pixels. Sume's Image API says this field has priority over aspect_ratio. Send one of them per request, so a reader of your code can tell what the output size is meant to be.
size is a third field and a different thing. It is tier shorthand only (for example 2K) and rejects WxH with 400 unsupported_parameter. Custom pixels go on image_size.
Which field does what
| Field | Takes | Notes |
|---|---|---|
| aspect_ratio | A ratio from the model's catalog list | Per-model native list. Use auto on edits to match the reference; omitting it is not the same as auto |
| image_size | Named preset, or {width, height} | Custom pixels on GPT, Seedream, Flux, Qwen and Recraft. Takes priority over aspect_ratio |
| size | Tier shorthand such as 2K | Rejects WxH with 400 unsupported_parameter |
| resolution | 512, 1K, 2K or 4K (0.5K alias for 512) | Only on models whose row lists resolutions, such as Nano Banana |
GPT Image 2.5 pixel rules
For ChatGPT Image 2.5, custom pixels follow the OpenAI limits that Sume mirrors: both edges multiples of 16, longest edge at most 3840, aspect ratio at most 3:1, and 655,360 to 8,294,400 total pixels. OpenAI's own guide lists the same custom-size rule and notes that sizes above 2560x1440 are experimental (OpenAI guide, read 2026-10-07).
That is why Instagram portrait is not 1080x1350 on GPT: 1080 is not a multiple of 16. Ask for 4:5, or send 1024x1280.
Nano Banana is different
Nano Banana has no free-form pixels. A 1080x1350 value on image_size becomes aspect_ratio: "4:5" plus a job target_pixels hint. The native output is close to 928x1152 at 1K, and the exact 1080x1350 is a documented post-step, so plan a resize.
A request that is clear to read
Pick the ratio for models with a fixed list, and the pixels for models with custom sizes. Here is a Shorts-style cover on GPT, with pixels only:
{
"model": "openai/gpt-image-2.5",
"prompt": "bold title card, one subject, high contrast",
"image_size": { "width": 1088, "height": 1920 },
"quality": "medium"
}Failure cases to expect
sizetakes a tier shorthand and rejects a WxH value. Move the pixels toimage_size.- GPT custom pixels that break the multiple-of-16 rule, the 3:1 limit or the pixel window are rejected before submission, so keep a small validator next to your sizes.
- If both
image_sizeandaspect_ratioarrive,image_sizewins, so a staleaspect_ratioleft in a template does not error and does not apply.
Check before you pin
The model's catalog row is the authority. GET /v1/images/models shows the aspect_ratio enum and whether the row accepts image_size. A parameter a model does not list is rejected, not dropped. See the Image API page for the full request table.
Sources
Related posts
More in Developers
- Image-to-video not starting on my photo: frame_images vs references
Your photo is a reference, not a first frame, when it goes in input_references. Use frame_images with first_frame on Sume /v1/videos to pin the opening shot.
- imagen-4.0-ultra-generate-001 ended Aug 17: the Sume images request
Google shut down three imagen-4.0 ids on Aug 17, 2026. A curl call to POST /v1/images that branches on 200 or 202, with an Idempotency-Key and a catalog check.
- Japanese speech to text API: Sume STT with language_code ja
Transcribe Japanese audio with Sume STT: send language_code ja, read word times, and test a sample first. $0.01 per audio minute, 10 minute jobs.
- Java HttpClient: POST /v1/images on Sume with a 40-second timeout
A single-file Java program that calls Sume's image API with java.net.http, branches on 200, 202 and errors, and sets a timeout longer than the 30-second wait.
Written by Sume