Skip to content
On this page

Inference

Video

Create a video generation job, then poll its status for free.

Create a job

POST/v1/videosAPI key
curl -X POST https://api.relayrouter.org/v1/videos \
-H "Authorization: Bearer $RELAY_API_KEY" \
-H 'content-type: application/json' \
-d '{
"model": "video-model",
"prompt": "a slow pan across a quiet coastline",
"duration_seconds": 5
}'

Returns the upstream job JSON. Billing is per video second when the model defines video_sec_micro; otherwise the flat network fee applies.

Poll status

GET/v1/videos/{job}?model=<id>API key

The model id is required as a query parameter. Status polling is never billed.

curl "https://api.relayrouter.org/v1/videos/$JOB_ID?model=video-model" \
-H "Authorization: Bearer $RELAY_API_KEY"
/api/v1/videos and /api/v1/videos/{job} are aliases. Video generation can take minutes; poll with a backoff rather than a tight loop.