Video generations
Async text-to-video. Submit a job, poll for completion, retrieve the video URL when ready.
Submit a job
POST https://api.ecohash.com/v1/video/generations
Request body
| Field | Type | Required | Notes |
|---|---|---|---|
model | string | yes | Video model ID (e.g. wan21-t2v-1-3b) |
prompt | string | yes | Text prompt |
num_frames | integer | no | Number of frames. Default 33 (≈ 2s at 16 fps) |
fps | integer | no | Playback rate, default 16 |
num_inference_steps | integer | no | Diffusion steps, default 50 |
guidance_scale | number | no | How strictly to follow the prompt, default 5.0 |
seed | integer | no | Deterministic output |
Response
{
"id": "vid_abc123",
"object": "video.job",
"status": "queued",
"created": 1776391234,
"model": "wan21-t2v-1-3b"
}
Poll for completion
GET https://api.ecohash.com/v1/video/generations/{id}
Response progression
// status: queued → processing → completed (or failed)
{
"id": "vid_abc123",
"status": "completed",
"video_url": "https://ecolink-videos.s3.us-west-1.amazonaws.com/vid_abc123.mp4",
"duration_seconds": 2.0625,
"created": 1776391234,
"completed_at": 1776391312
}
video_url expires after 24 hours. Download and store the bytes if you need them longer.
On failure: status: "failed" with an error field describing the cause.
Timing
Typical end-to-end: 1–3 minutes. Queue wait 30–60s, GPU time 60–120s.
Limits
- Max concurrent jobs per account: 5
- Max
num_frames: 81 (≈5s at 16 fps) - Text-to-video only — no image-to-video input in v1
Errors
See Errors. Common: 401, 402, 404, 429. The async job itself can also fail with status: "failed" mid-generation (prompt too adversarial, internal error) — retry or adjust parameters.