Skip to main content

Seedance Series

Official Byte protocol reference: Create Video Generation Task.

This page covers Seedance models starting with the 2.0 series. Use the General Video API for text, first and last frames, and multimodal references.

Preparation​

Examples use seedance-2-0-fast. Query the video models available to your API Key and replace this ID with the actual model ID. Supported parameters and input combinations vary by version.

BASE_URL="https://api.ope.ai"
API_KEY="YOUR_API_KEY"

curl "$BASE_URL/v1/models?output_modalities=video" \
-H "Authorization: Bearer $API_KEY"

Put prompts in text elements inside content. Use integer duration for seconds, and resolution and ratio for output dimensions. When using the General Video API, put extension parameters in extra_parameters.

Optional extension parameters​

The table below lists the extension parameters currently accepted by the API. All are optional. Supported fields and values vary by Seedance version, so check the selected model. Omit parameters you do not need instead of sending null.

FieldTypePurpose
framesintegerOutput frame count; requires a model that supports frame-based duration control
seedintegerRandom seed
camera_fixedbooleanWhether to keep the camera fixed
draftbooleanWhether to generate a draft; requires a model supporting drafts
service_tierstringService tier, such as default or flex
output_formatstringVideo format, such as mp4 or mov; only available on Seedance 2.5 models supporting this parameter
omni_reference_task_typestringTask type guidance for Seedance 2.5: auto, reference, edit, or extend
execution_expires_afterintegerTime allowed for queuing and execution, in seconds; separate from the 24-hour result access period
priorityintegerTask queue priority
safety_identifierstringEnd-user identifier
toolsobject[]Tool declarations, such as [{"type":"web_search"}]; type is a string

curl examples​

Text to video​

curl "$BASE_URL/v1/contents/generations/tasks" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
--data '{
"model": "seedance-2-0-fast",
"content": [{"type": "text", "text": "An orange cat walks along a street after rain, with a slow tracking shot."}],
"duration": 5,
"resolution": "720p",
"ratio": "16:9",
"generate_audio": false,
"extra_parameters": {"seed": 42}
}'

Image to video: first and last frames​

This request specifies both frames. For a first-frame-only request, remove the entire element with role: "last_frame". Replace the example URLs with publicly accessible image URLs.

curl "$BASE_URL/v1/contents/generations/tasks" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
--data '{
"model": "seedance-2-0-fast",
"content": [
{"type": "text", "text": "Transition naturally from the first frame to the last with smooth camera movement."},
{"type": "image_url", "role": "first_frame", "image_url": {"url": "https://example.com/first.jpg"}},
{"type": "image_url", "role": "last_frame", "image_url": {"url": "https://example.com/last.jpg"}}
],
"duration": 5,
"resolution": "720p",
"ratio": "16:9",
"return_last_frame": true
}'

Multimodal references: image, video, and audio​

curl "$BASE_URL/v1/contents/generations/tasks" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
--data '{
"model": "seedance-2-0-fast",
"content": [
{"type": "text", "text": "Create a product showcase using the reference image, the reference video camera movement, and the reference audio rhythm."},
{"type": "image_url", "role": "reference_image", "image_url": {"url": "https://example.com/product.jpg"}},
{"type": "video_url", "role": "reference_video", "video_url": {"url": "https://example.com/motion.mp4"}},
{"type": "audio_url", "role": "reference_audio", "audio_url": {"url": "https://example.com/rhythm.mp3"}}
],
"duration": 8,
"resolution": "720p",
"ratio": "9:16",
"generate_audio": true
}'

Seedance 2.0 input guidance:

  • Organize first-frame, first-and-last-frame, and multimodal-reference requests separately. Do not mix frame roles with reference roles.
  • A single first frame may use first_frame or omit the role. Two-frame input requires first_frame and last_frame respectively.
  • Use reference_image for reference images and reference_video for reference videos. Reference video can be used alone.
  • Use reference_audio for audio references and include at least one image or video. Audio alone, or text plus audio, does not satisfy Seedance 2.0 input requirements.
  • Multimodal references allow up to 9 images, 3 videos, and 3 audio clips. Check the selected version for media specifications.

Query and retrieve results​

The creation requests above return HTTP 200 with a task ID:

{"id":"cgt_386cb55a950c4e4380fbe740762500a3"}

Query with that ID:

TASK_ID="cgt_386cb55a950c4e4380fbe740762500a3"
curl "$BASE_URL/v1/contents/generations/tasks/$TASK_ID" \
-H "Authorization: Bearer $API_KEY"

Continue querying during queued or running. On succeeded, read content.video_url and, when available, content.last_frame_url. On failed, inspect error. Media access lasts 24 hours; use media_expires_at for the deadline. Expired results have status expired and no media URLs. See the General Video API for response fields and errors.

Byte native-field endpoint​

For requests using Byte native fields, use these endpoints with your platform API Key and model ID. Confirm that your selected model supports this endpoint.

ItemGeneral platform endpointByte native-field endpoint
CreatePOST /v1/contents/generations/tasksPOST /api/v3/contents/generations/tasks
QueryGET /v1/contents/generations/tasks/{id}GET /api/v3/contents/generations/tasks/{id}
Extension parameter locationInside extra_parameters, such as "extra_parameters": {"seed": 42}At the top level, such as "seed": 42
Task IDPlatform task IDTop-level id is also a platform task ID
Query resultPlatform fields and statusesNative fields, actual model name, and statuses including cancelled and expired
Media expirationHTTP 200, status: "expired"HTTP 410, TaskMediaExpired, without the task body

The callback_url parameter is not supported.

The following example creates a text-to-video task through the native endpoint for the Seedance 2.0 series:

curl "$BASE_URL/api/v3/contents/generations/tasks" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
--data '{
"model": "seedance-2-0-fast",
"content": [{"type": "text", "text": "The sea at sunrise, with a slow camera push forward."}],
"duration": 5,
"resolution": "720p",
"ratio": "16:9",
"seed": 42
}'

NATIVE_TASK_ID="ID_FROM_NATIVE_CREATE_RESPONSE"
curl "$BASE_URL/api/v3/contents/generations/tasks/$NATIVE_TASK_ID" \
-H "Authorization: Bearer $API_KEY"

Replace NATIVE_TASK_ID with the id returned by this native creation before querying. The native endpoint does not return media_expires_at; video and last-frame access still lasts 24 hours. Native status expired may indicate task execution expiration; media access expiration uses HTTP 410. Both endpoints omit cancellation and callbacks. References in content using draft_task.id also require your own platform draft task ID.