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.
- Prompting Omni Flash with sound: write the audio as its own line
Gemini Omni Flash 1.1 always generates audio. A prompt layout that separates picture from sound, three example prompts, and the request on Sume.
- Python: submit, poll and download one Omni Flash clip (v1/videos)
A short Python script that submits a Gemini Omni Flash 1.1 request to Sume's /v1/videos, polls the job until it completes and saves the MP4.
- Railway closes idle HTTP at 5 minutes: why Sume sync waits 30 s
Railway keeps a request open up to 15 minutes only while data moves. Sume sync mode caps the wait at 30 seconds, so long video jobs need async or a webhook.
Written by Sume