Generate videos
Make videos from a prompt, a first and last frame, or reference images, and chain shots together.
Needs generations:submit to create and generations:read to poll.
From a prompt
curl https://api.remagica.com/api/v1/generations/videos \
-H "x-api-key: $REMAGICA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "bytedance/seedance-2.0",
"prompt": "Slow dolly in on a neon-lit ramen stall in the rain",
"aspectRatio": "9:16",
"duration": 5
}'Only model and prompt are required. duration is in seconds, or "auto" to let the model choose. Video models have kind: "video" in GET /models, and their capabilities list the durations, resolutions and aspect ratios each one takes.
Check the price first with POST /generations/estimate: video costs more than images and scales with length and resolution.
From frames and references
firstFrameandlastFramepin the opening and closing frames. Each is{ "key": "…" }, a file in your storage.referenceImages,referenceVideosandreferenceAudiosguide the look, motion or sound, if the model supports them.- A registered character works as a frame or reference too:
{ "asset": "<character id>" }fromGET /characters.
{
"model": "bytedance/seedance-2.0",
"prompt": "She turns to the camera and smiles",
"firstFrame": { "key": "uploads/…/portrait.png" },
"duration": 5
}Chain shots
A finished video's outputs include its final frame, with role: "last_frame". Pass that output's key as the next video's firstFrame and the two shots join up.
Get the result
Video takes minutes. Poll GET /generations/{generationId} every 5–10 seconds, or listen for the generation.succeeded webhook. The finished video is the output with role: "output"; its durationSeconds, width and height describe it, and url downloads it.