Pre-flight an Omni Flash request against the Sume model catalog
A short Python check that reads supported durations, resolutions and aspect ratios for gemini-omni-flash-1.1 via /v1/videos/models.

GET /v1/videos/models returns each model's supported_durations, supported_resolutions and supported_aspect_ratios. Check your request against those lists before you submit and you catch a 2-second or 1:1 request on Gemini Omni Flash 1.1 on your side, instead of in an error.
Per the docs the model takes 3 to 10 seconds at 360p, 720p, 1080p and 4K in 16:9 or 9:16.
Script
import os, requests
H = {"Authorization": "Bearer " + os.environ["SUME_API_KEY"]}
models = requests.get("https://api.sume.com/v1/videos/models", headers=H, timeout=30).json()["data"]
m = next(x for x in models if x["id"] == "gemini-omni-flash-1.1")
def problems(req):
out = []
if req["duration"] not in m["supported_durations"]:
out.append("duration must be one of %s" % m["supported_durations"])
if req["resolution"] not in m["supported_resolutions"]:
out.append("resolution must be one of %s" % m["supported_resolutions"])
if req["aspect_ratio"] not in m["supported_aspect_ratios"]:
out.append("aspect_ratio must be one of %s" % m["supported_aspect_ratios"])
return out
print(problems({"duration": 2, "resolution": "480p", "aspect_ratio": "1:1"}))
print(problems({"duration": 5, "resolution": "720p", "aspect_ratio": "9:16"}))What the two calls print
The first call lists three problems; the second prints an empty list. Take the lists from the live catalog rather than hard-coding them, because catalog data can change.
Cost of skipping it
A bad request is rejected before generation, so the cost of skipping the check is time and noise, not money. A valid request is not free: the cheapest legal Omni job is $0.1125, and a 4K 10 second one is $3.75.
- Run the check in CI against a fixture of your batch file.
- Fail the batch on any problem, not just warn.
References and frames
The same catalog row lists supported_input_references and supported_frame_images. For Omni the references are image and video, with no audio, so check "audio_url" in m["supported_input_references"] before you send an audio reference. A model accepts a reference type only if the field lists it.
Sources
Related posts
More in Developers
- Preflight a 3-minute Short with Timeline plan before you pay
POST /v1/timeline-1.0/plan compiles a Short without a job or a reserve and returns billable minutes and the estimate. A runnable Python check for six slots.
- A Preview video model in production: pin a Sume id or use sume/auto?
Vidu calls Q4 a Preview. On Sume, pin a model id for a repeatable look, or use sume/auto, which hides the family and defaults to 720p and 8 seconds.
- Check probe.has_audio before paying $0.20 for Short captions
A silent clip makes speech-based captions fail with caption_no_speech. A probe-only Video inspect with frames false shows has_audio first. Captions are $0.20.
- Promise.allSettled for many Sume job statuses: isolate one failure
Check many Sume job statuses at once with Promise.allSettled so one 429 or network error is reported on its own row and does not hide the other results.
Written by Sume