Skip to main content

Get Generation Status

GET /api/generations/:id
Returns the current status of a video generation. Poll this endpoint to check if your video is ready.

Path parameters

ParameterTypeDescription
idstringThe generation ID returned from the generate endpoint

Request

curl "https://prismvideos.com/api/generations/gen_abc123" \
  -H "Authorization: Bearer prism_sk_your_key_here"

Response (generating)

{
  "id": "gen_abc123",
  "status": "generating",
  "template_id": "abc123",
  "video_url": null,
  "created_at": "2026-02-26T12:00:00.000Z",
  "completed_at": null,
  "error": null
}

Response (completed)

{
  "id": "gen_abc123",
  "status": "completed",
  "template_id": "abc123",
  "video_url": "https://presigned-s3-url...",
  "created_at": "2026-02-26T12:00:00.000Z",
  "completed_at": "2026-02-26T12:02:30.000Z",
  "error": null
}

Response (failed)

{
  "id": "gen_abc123",
  "status": "failed",
  "template_id": "abc123",
  "video_url": null,
  "created_at": "2026-02-26T12:00:00.000Z",
  "completed_at": null,
  "error": "Generation timed out"
}

Response fields

FieldTypeDescription
idstringThe generation ID
statusstring"generating", "completed", or "failed"
template_idstring or nullThe template ID (if generated from a template)
video_urlstring or nullPresigned URL to download the video (1 hour expiry). Only present when status is "completed".
created_atstring or nullISO 8601 timestamp when generation was submitted
completed_atstring or nullISO 8601 timestamp when generation finished. Only present when status is "completed".
errorstring or nullError message. Only present when status is "failed".

Polling strategy

Video generation typically takes 30 seconds to 3 minutes depending on the model and duration. A recommended polling approach:
  1. Wait 5 seconds after submitting.
  2. Poll every 5 seconds.
  3. Stop after status is "completed" or "failed".
  4. Alternatively, use webhook_url in the generate request to receive a callback instead of polling.

Errors

StatusErrorWhen
401unauthorizedMissing or invalid API key
403forbiddenAPI key lacks templates:read scope
404not_foundGeneration not found or not owned by this API key’s user
See Errors for the full error reference.