Check video model limits before you submit: GET /v1/videos/models
Models differ on length, resolution and references. Read GET /v1/videos/models and validate a request before a paid submit, with a Python preflight.

Call GET /v1/videos/models and check your duration, resolution, aspect_ratio, and reference types against the model's entry before you submit. Limits are not shared across models: on Sume seedance-2.5 accepts 4-30 seconds, wan-3.0 accepts 2-30 seconds, and most other catalog models stop at 15 seconds or less, with gemini-omni-flash-1.1 at 3-10.
The endpoint returns a data array, each entry with supported_durations, supported_resolutions, supported_aspect_ratios, supported_input_references, generate_audio, and pricing_skus.
Why validate first
Limits differ per model, so a request that is valid for one model can be invalid for another. Reading the catalog also keeps you from hard-coding a model id that is no longer listed.
The vendors announce longer clips (Seedance 2.5, Wan3.0) before an API serves them everywhere. The catalog shows what your workspace can call today.
| Field | What to compare |
|---|---|
| supported_durations | Your duration in whole seconds |
| supported_resolutions | Your resolution |
| supported_aspect_ratios | Your aspect ratio |
| supported_input_references | image_url, video_url, audio_url as needed |
| generate_audio | Whether an audio track is available |
| pricing_skus | Price information per SKU |
A preflight function
The check below raises a clear error instead of a failed paid call. It does not replace server validation, which stays the final word.
import os, requests
H = {"Authorization": f"Bearer {os.environ['SUME_API_KEY']}"}
catalog = requests.get("https://api.sume.com/v1/videos/models",
headers=H, timeout=30).json()["data"]
by_id = {m["id"]: m for m in catalog}
def preflight(model: str, duration: int, resolution: str) -> None:
m = by_id.get(model)
if m is None:
raise ValueError(f"{model} is not in the catalog: {sorted(by_id)}")
if duration not in m["supported_durations"]:
raise ValueError(f"{model} durations: {m['supported_durations']}")
if resolution not in m["supported_resolutions"]:
raise ValueError(f"{model} resolutions: {m['supported_resolutions']}")
preflight("seedance-2.5", 30, "720p")
print("ok")Cache it, but not forever
Fetch the list at startup and refresh it on an interval, say hourly. A new model appears in the response without a code change on your side.
Sources
Related posts
More in Developers
- Check GET /v1/videos/models before you pay: a Python validator
Read GET /v1/videos/models and reject bad duration, resolution or audio flags in Python before POST /v1/videos. Fewer 400s, no paid retries.
- Claude Code allowedMcpServers: the serverUrl rule for mcp.sume.com
Allow only Sume's hosted MCP endpoint in Claude Code managed settings with an allowedMcpServers serverUrl entry, and what the rule does not control.
- claude mcp add --header Bearer: a Sume API key for CI runs
For unattended Claude Code runs, pass a Sume API key as a Bearer header. That session sees every tool, so cap spend and send idempotency keys.
- Claude Code MCP scope: local, project or user for the Sume server
Use project scope for a shared .mcp.json with the Sume URL only, user scope for your own machine, and keep API keys out of shared files.
Written by Sume