Filter the Sume video catalog in Python for 1080p and audio references
Instead of guessing which video model takes what, read GET /v1/videos/models and filter it. This Python script lists models with 1080p and audio_url references.

Call GET /v1/videos/models, read the data array and filter on supported_resolutions and supported_input_references. The script below keeps models that list 1080p and accept audio_url references, and prints each one's id and durations.
This beats a hard-coded table, because the catalog is what validation uses. A value the catalog does not list gets a 400, so the catalog is the one source of truth about what you can send.
What each catalog row carries
Each VideoModel has id, supported_resolutions, supported_aspect_ratios, supported_durations, supported_frame_images, supported_input_references, generate_audio and pricing_skus. supported_input_references is the one Sume adds on top of the OpenRouter shape, because some models reject references that others accept.
pricing_skus maps each SKU to a price string, and the SKU unit differs by model (for example per 1,000 video tokens), so compare like with like.
| Field | Type | Use it to |
|---|---|---|
| supported_resolutions | list of strings | check 720p, 1080p or 4K before you submit |
| supported_durations | list of integers | check that your length is allowed |
| supported_input_references | list of image_url, video_url, audio_url | know whether audio or video references work |
| supported_frame_images | first_frame, last_frame | check image-to-video support |
| generate_audio | boolean | know if audio is generated |
The script
It uses only the standard library. Change the two filter lines to ask a different question, such as models that accept video_url references or a 15-second duration.
import json, os, urllib.request
req = urllib.request.Request(
"https://api.sume.com/v1/videos/models",
headers={"Authorization": "Bearer " + os.environ["SUME_API_KEY"]},
)
with urllib.request.urlopen(req, timeout=30) as r:
models = json.load(r)["data"]
for m in models:
refs = m.get("supported_input_references") or []
if "1080p" in (m.get("supported_resolutions") or []) and "audio_url" in refs:
durs = m.get("supported_durations") or []
print(m["id"], min(durs, default=None), max(durs, default=None), m.get("pricing_skus"))Reading the result
The output has one line for each model that passes both tests. A model that is absent either lacks 1080p or rejects audio references. sume/auto is never in the list, because it is not a model, but the guide documents it.
If a row has a null or empty list for a field, the script treats it as not supported. That is the safe reading, since a value the catalog does not advertise returns a 400.
Use it in a pre-flight check
Run the filter on startup in a service that picks models for users. Cache the result for a few minutes, and pick from it, instead of shipping a table that ages. When a model is added, the filter picks it up with no code change.
Pair it with the pricing field to compare the models that pass, within the same SKU unit.
- Fail early with a clear message when no model passes the filter.
- Log the catalog's model ids with each job so a later review can see what was offered.
- Do not send a field the row does not list, because it will be a 400, not a silent drop.
Related posts
More in Developers
- Find gpt-image-1 in your repo before Oct 23: a Python scan
OpenAI shuts gpt-image-1 down on 2026-10-23, five weeks before the other GPT Image ids. A Python scan splits them by date and maps each hit to a Sume model id.
- Find video models with 1:1, 9:16 and 16:9: filter the Sume catalog
One Python call to GET /v1/videos/models lists which Sume video models cover square, vertical and widescreen, so one prompt can feed Feed, Reels and in-stream.
- Firebase allows 1-hour HTTP functions; don't hold a Sume job open
Firebase HTTP functions can run up to an hour and Cloud Tasks covers longer work. Even so, submit Sume jobs async and take the result by webhook or status poll.
- 'first_frame_url must match image_url': two names, one value
image_url and first_frame_url are aliases on Video Router. Send both only if the strings are identical, same for end_image_url and last_frame_url, or get a 400.
Written by Sume