Documentation

Video API

LLMPool exposes asynchronous video protocols for MiniMax, Doubao, the Doubao Extended Protocol, and Alibaba Cloud video models. The extended protocol currently provides H3 capabilities under /marslab/v1; Alibaba routes use /aliyun/v1.

Authentication and models

Use an account API key created in Board:

Authorization: Bearer YOUR_API_KEY
Content-Type: application/json

The examples use https://<LLMPOOL_HOST> as the LLMPool service root. Video APIs do not use the OpenAI /openai/v1 path. Set model to a model ID shown on the Models page.

Video generation is asynchronous. After creation returns a task_id, poll the task every 5-10 seconds until it succeeds or fails. Task detail and list responses may also include submitted_at, generation_started_at, completed_at, and result_available_at Unix-second lifecycle timestamps; fields that were not observed are omitted.

Protocol capabilities

CapabilityMiniMaxDoubaoDoubao Extended ProtocolAlibaba
CreatePOST /minimax/v2/video_generationPOST /doubao/v1/video/generationsPOST /marslab/v1/video/generationsPOST /aliyun/v1/video_generation
RetrieveGET /minimax/v2/video_generation/{task_id}GET /doubao/v1/video/generations/{task_id}GET /marslab/v1/video/generations/{task_id}GET /aliyun/v1/video_generation/{task_id}
ListGET /minimax/v2/video_generationGET /doubao/v1/video/generationsGET /marslab/v1/video/generationsGET /aliyun/v1/video_generation
CancelQueued tasks onlyNot currently supportedSupportedNot currently supported

MiniMax create

curl -X POST "https://<LLMPOOL_HOST>/minimax/v2/video_generation" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: minimax-demo-001" \
  -d '{
    "model":"MiniMax-H3",
    "content":[{"type":"text","text":"A red sports car driving through a neon city"}],
    "resolution":"768P",
    "duration":5,
    "ratio":"16:9",
    "seed":42,
    "aigc_watermark":false
  }'

A successful request returns {"task_id":"video_xxx"}.

MiniMax currently accepts 768P, a duration of 4-15 seconds, and text-mode ratios 16:9, 4:3, or 1:1. Image mode accepts one image_url content item with role: "first_frame" and uses the adaptive ratio. The image can be a public HTTPS URL or an image data URL. callback_url is unsupported and aigc_watermark must be false.

MiniMax retrieve, list, and cancel

curl "https://<LLMPOOL_HOST>/minimax/v2/video_generation/video_xxx" \
  -H "Authorization: Bearer YOUR_API_KEY"

curl "https://<LLMPOOL_HOST>/minimax/v2/video_generation?limit=20" \
  -H "Authorization: Bearer YOUR_API_KEY"

curl -X DELETE "https://<LLMPOOL_HOST>/minimax/v2/video_generation/video_xxx" \
  -H "Authorization: Bearer YOUR_API_KEY"

Each list accepts limit (1-100), the after cursor, and optional source=api|playground, and returns tasks for its own protocol only.

Only an upstream queued task can be cancelled. An in_progress task returns task_not_cancellable. For a terminal task, DELETE removes the task instead of cancelling generation.

Doubao create

curl -X POST "https://<LLMPOOL_HOST>/doubao/v1/video/generations" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: doubao-demo-001" \
  -d '{
    "model":"DOUBAO_MODEL_FROM_MODELS_PAGE",
    "prompt":"A red sports car driving through a neon city",
    "images":[],
    "metadata":{
      "resolution":"720p",
      "ratio":"16:9",
      "duration":5,
      "generate_audio":true,
      "seed":42,
      "watermark":false
    }
  }'

A successful response contains task_id, model, status: "queued", and progress: 0.

Doubao requires a non-empty prompt of at most 7,000 characters. images accepts up to four image data URLs or credential-free HTTPS URLs. reference_videos accepts up to four MP4/MOV data URLs or credential-free HTTPS URLs, with a 64 MB limit per video. Duration is 4-15 seconds and defaults to 5. The Playground offers the model-dependent union of 480p, 720p, 1080p, and 4k, with 16:9, 4:3, 3:4, 9:16, 1:1, 21:9, and adaptive ratios. generate_audio accepts either boolean value and defaults to true; seed must be at least -1; watermark=true is rejected. Unsupported model and resolution combinations are rejected by the price quote and create APIs.

metadata.mode is optional. Omit it to preserve the legacy behavior where images are reference images. Explicit modes are t2v (no material), i2v_first_frame (one image), i2v_first_last_frame (two ordered images), multi_ref (one to four images), and multi_ref_vid (at least one image or reference video). Reference videos are probed before charging and their durations are included in the Token estimate.

Doubao list and retrieve

List the current account's Doubao tasks:

curl "https://<LLMPOOL_HOST>/doubao/v1/video/generations?limit=20" \
  -H "Authorization: Bearer YOUR_API_KEY"

The Doubao list also accepts limit, after, and optional source=api|playground, and returns Doubao tasks only. Doubao does not currently expose task cancellation.

Retrieve one task:

curl "https://<LLMPOOL_HOST>/doubao/v1/video/generations/video_xxx" \
  -H "Authorization: Bearer YOUR_API_KEY"

data.status is QUEUED, IN_PROGRESS, SUCCESS, or FAILURE. On success, the video appears in both data.result_url and data.data.content.video_url. Result URLs are short-lived; retrieve the task again to obtain a fresh URL.

Doubao Extended Protocol

The extended protocol currently provides H3 video generation with Seedance-style prompt, images, and metadata fields. Zero images selects text-to-video, one image selects first-frame-to-video, and multiple images select reference-image-to-video.

curl -X POST "https://<LLMPOOL_HOST>/marslab/v1/video/generations" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: doubao-extended-demo-001" \
  -d '{"model":"H3_MODEL_FROM_MODELS_PAGE","prompt":"Ocean waves at sunrise with natural sound","images":[],"metadata":{"resolution":"768P","ratio":"16:9","duration":5,"seed":42,"watermark":false}}'

It supports 4-15 seconds, 768P, 16:9, 9:16, or 1:1, and up to four images. Native audio is always generated; omit metadata.generate_audio; false is rejected. Advanced API callers can add vela with generation_preset, generation_count (1-16), sampling, and client_metadata.

curl "https://<LLMPOOL_HOST>/marslab/v1/video/generations/video_xxx" -H "Authorization: Bearer YOUR_API_KEY"
curl "https://<LLMPOOL_HOST>/marslab/v1/video/generations?limit=20" -H "Authorization: Bearer YOUR_API_KEY"
curl -X POST "https://<LLMPOOL_HOST>/marslab/v1/video/generations/video_xxx/cancel" -H "Authorization: Bearer YOUR_API_KEY"

For multi-video tasks, data.data.usage.results contains every result URL. Compatibility fields contain the first result. Billing uses duration multiplied by generation_count.

Alibaba Cloud video

curl -X POST "https://<LLMPOOL_HOST>/aliyun/v1/video_generation" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: aliyun-demo-001" \
  -d '{"model":"ALIYUN_MODEL_FROM_MODELS_PAGE","prompt":"Ocean waves at sunrise","images":[],"metadata":{"resolution":"720P","ratio":"16:9","duration":5,"generate_audio":true,"seed":42,"watermark":false}}'

Alibaba supports text-to-video, first-frame, and reference-image inputs according to the selected upstream model. Supported durations range from 2-30 seconds; image count and the exact duration range are model-specific. metadata.image_mode can be first_frame or reference_image for models that support both. metadata.generate_audio accepts either boolean value and defaults to true.

curl "https://<LLMPOOL_HOST>/aliyun/v1/video_generation/video_xxx" -H "Authorization: Bearer YOUR_API_KEY"
curl "https://<LLMPOOL_HOST>/aliyun/v1/video_generation?limit=20" -H "Authorization: Bearer YOUR_API_KEY"

Alibaba task cancellation and deletion are not currently exposed.

Idempotency, billing, and errors

Send a unique Idempotency-Key with every create request. Retrying the same body with the same key returns the original task; reusing the key with different parameters returns a conflict.

The platform precharges the wallet using the protocol billing unit and configured price rules. Native Doubao Seedance estimates video.output/token from resolution, ratio, 24 FPS, and duration, then settles against upstream actual output tokens. A lower actual amount is refunded and a higher amount produces a supplemental debit; failed or cancelled tasks receive a full refund. Other video protocols currently use duration precharges. An insufficient balance returns insufficient_credit without creating a task, and asynchronous settlement can make usage or balance records appear later.

Common errors include invalid_parameter, unsupported_parameter, model_not_found, rate_limit_exceeded, insufficient_credit, and task_not_cancellable. See Error Responses and Troubleshooting.

GraphQL videoPriceQuote estimates price only; it does not create or retrieve video tasks.