Skip to main content
Base URL: https://router.flatkey.ai Flatkey generates video through one asynchronous endpoint. You submit a task, poll it until it finishes, then download the MP4. This page covers what is shared across every video model. For a model’s own options, continue to Seedance or MiniMax H3.

One async workflow

Create the task with POST /v1/videos, poll it with GET /v1/videos/{task_id}, and download the MP4 from metadata.url.

Two request shapes

Some models take a content array, others take a prompt string. Sending the wrong one returns 400.
Use this authorization header on every request on this page, including the download:

Find a video model

List every model and keep the ones whose type is video:
/v1/models ignores query parameters. Filtering happens in your own code, as in the jq example above.
You can also browse the same list with pricing on the model directory.

Pick the right request shape

The endpoint accepts two different shapes, and each model takes exactly one of them. Sending a content array to a prompt model returns:

The content shape

The array also carries images. Add an image_url entry to interpolate between frames or supply a reference. Field names differ by model, so follow the model’s own guide.

The prompt shape

Resolutions differ by model

There is no shared set of resolution values. Sending an unsupported one returns 400 before the task is created.
Check the model’s own guide before choosing a resolution. 1080p is rejected by seedance-2.5, and 720p is rejected by MiniMax-H3.

Request parameters

aspect_ratio and seed are accepted without an error but do not change the output on every model. On grok-imagine-video, requesting 9:16 still returns an 848x480 landscape clip, and the same seed produces a different file each time. Where a model supports orientation, it is documented on that model’s own page. Do not rely on these two fields for cross-model behavior.

Poll the task

A successful submission returns a task immediately:
Poll with the task id until the status is terminal:
Poll about every 15 seconds. A five-second clip usually finishes in two to four minutes.

Download the MP4

The download URL arrives in metadata.url, and it needs the same authorization header:

End-to-end example

Troubleshooting

prompt is required You sent a content array to a model that expects prompt. Check the table in Pick the right request shape. unsupported resolution or resolution must be 768P or 2K The value is valid for a different model. See Resolutions differ by model. No available channel for model ... The model is not routable right now. Pick another video model rather than retrying — this error does not clear on its own. Check the model directory for current availability. duration must be between 4 and 15 MiniMax-H3 requires a duration in that range. Send one explicitly. The task stays queued Video generation takes minutes, not seconds. Keep polling at a 15-second interval before treating it as stuck.

Model guides

Seedance

Text-to-video plus the virtual and real-person asset library.

MiniMax H3

First and last frame control, reference media, and task settings.