Responses

Create and retrieve video generations via the OpenAI Responses-compatible API.

Pipevideo uses an OpenAI Responses-compatible API for video generation. Send input (and optional instructions); responses return typed output items with video URLs instead of text.

Create generation

POST /v1/responses

Authentication: API key required

Request body

ParameterTypeRequiredDescription
modelstringYesOrchestration LLM id (e.g. moonshotai/kimi-k2.5). Not an engine slug.
inputstring | arrayYesPrompt text or conversation input items.
instructionsstringNoSystem-level guidance, separate from conversation input.
enginestringNohyperframes, lottie, or auto. Default: hyperframes.
expand_promptbooleanNoImprove the prompt with the engine's prompting guide first.
widthnumberNoCanvas width in pixels. Default 1080.
heightnumberNoCanvas height in pixels. Default 1920.
aspectRatiostringNoAspect ratio hint (e.g. 16:9).
providerobjectNoProvider routing. See Provider routing.

Example

curl -X POST https://api.pipevideo.co/v1/responses \
  -H "Authorization: Bearer pv_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "moonshotai/kimi-k2.5",
    "input": "A cat walking on a beach at sunset",
    "provider": { "order": ["framerate"] }
  }'

For multimodal prompts, pass input as an array of message items:

{
  "model": "moonshotai/kimi-k2.5",
  "instructions": "You are a motion designer.",
  "input": [
    {
      "role": "user",
      "content": [
        { "type": "input_text", "text": "Animate this logo with a smooth fade-in" },
        { "type": "input_image", "image_url": { "url": "https://example.com/logo.png" } }
      ]
    }
  ]
}

Create response

{
  "id": "gen_abc123xyz",
  "object": "response",
  "status": "queued",
  "model": "moonshotai/kimi-k2.5",
  "engine": "hyperframes",
  "provider": "framerate",
  "created_at": 1709827200,
  "output": [
    {
      "type": "message",
      "id": "gen_abc123xyz_msg",
      "role": "assistant",
      "status": "in_progress",
      "content": []
    }
  ],
  "output_video_url": null,
  "usage": null
}

Get generation

GET /v1/responses/{id}

Authentication: API key required

Retrieve the current status and result of a generation. Poll until status is completed or failed.

Response fields

FieldTypeDescription
idstringGeneration ID
objectstringAlways response
statusstringqueued, in_progress, completed, failed, cancelled, or incomplete
modelstringOrchestration model id
enginestringRendering engine (e.g. hyperframes)
providerstring | nullVideo orchestration provider slug
outputarrayTyped output items — video URL in output_video content parts when completed
output_video_urlstring | nullConvenience URL for the generated video (like OpenAI's output_text)
usageobject | nullToken usage and cost_usd when available
latency_msnumber | nullEnd-to-end latency when completed
errorobject | null{ code, message } when failed
created_atnumberUnix timestamp (seconds)
completed_atnumber | nullCompletion timestamp (milliseconds)
artifact_urlobject | nullNative engine artifact URL (e.g. Lottie JSON) when produced
artifact_typestring | nullMedia type of artifact_url

Completed response example

{
  "id": "gen_abc123xyz",
  "object": "response",
  "status": "completed",
  "model": "moonshotai/kimi-k2.5",
  "engine": "hyperframes",
  "provider": "framerate",
  "created_at": 1709827200,
  "completed_at": 1709827260000,
  "output": [
    {
      "type": "message",
      "id": "gen_abc123xyz_msg",
      "role": "assistant",
      "status": "completed",
      "content": [
        {
          "type": "output_video",
          "video_url": {
            "url": "https://storage.example.com/videos/abc123.mp4",
            "expires_at": 1709913660
          }
        }
      ]
    }
  ],
  "output_video_url": "https://storage.example.com/videos/abc123.mp4",
  "usage": {
    "input_tokens": 1200,
    "output_tokens": 3400,
    "total_tokens": 4600,
    "cost_usd": 0.12
  },
  "latency_ms": 58000
}

Cancel generation

DELETE /v1/responses/{id}

Authentication: API key required

Cancel an in-flight generation. Returns { "id": "...", "cancelled": true }.

Status transitions

queued → in_progress → completed
                    → failed

Transitions are one-way. Poll every 2–5 seconds. For production, prefer webhooks.