Skip to main content

Documentation Index

Fetch the complete documentation index at: https://apixo.ai/docs/llms.txt

Use this file to discover all available pages before exploring further.

Overview

Seedance 2.0 is a ByteDance video generation model for prompt-only video, first-and-last-frame animation, and multimodal reference workflows. Use this page when you are ready to call the API after trying the model in the APIXO playground.
CapabilityValue
Model IDseedance-2-0
Modestext-to-video, first_and_last_frames, omni_reference
PromptRequired non-empty string
Resolutions480p, 720p, 1080p
DurationsAny integer from 4 through 15 seconds
Aspect ratiosauto, 16:9, 4:3, 1:1, 3:4, 9:16, 21:9
Reference images1-2 URLs for first_and_last_frames; 1-9 URLs for omni_reference
Reference video/audio1-3 URLs each for omni_reference; each file 2-15 seconds, total max 15 seconds per media type
OutputMP4 video URL array in resultJson.resultUrls

Endpoint and authentication

Base URL:
https://api.apixo.ai/api/v1
MethodEndpointPurpose
POST/generateTask/seedance-2-0Submit a generation task
GET/statusTask/seedance-2-0?taskId={taskId}Poll task status and retrieve results
All requests require your APIXO API key:
Authorization: Bearer YOUR_API_KEY
Submit requests also require:
Content-Type: application/json

Copy-paste async quickstart

This minimal request submits a text-to-video task and returns a taskId.
curl -X POST "https://api.apixo.ai/api/v1/generateTask/seedance-2-0" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "request_type": "async",
    "input": {
      "mode": "text-to-video",
      "prompt": "a cinematic tracking shot through a rainy neon street",
      "resolution": "720p",
      "duration": 5,
      "aspect_ratio": "16:9",
      "sound": true,
      "web_search": false
    }
  }'
Successful response:
{
  "code": 200,
  "message": "success",
  "data": {
    "taskId": "task_12345678"
  }
}
Save the taskId; you need it to poll for the final result.

Poll for result

curl -X GET "https://api.apixo.ai/api/v1/statusTask/seedance-2-0?taskId=task_12345678" \
  -H "Authorization: Bearer YOUR_API_KEY"
Processing response:
{
  "code": 200,
  "message": "success",
  "data": {
    "taskId": "task_12345678",
    "state": "processing",
    "createTime": 1767965610929
  }
}
Success response:
{
  "code": 200,
  "message": "success",
  "data": {
    "taskId": "task_12345678",
    "state": "success",
    "resultJson": "{\"resultUrls\":[\"https://r2.apixo.ai/video.mp4\"]}",
    "createTime": 1767965610929,
    "completeTime": 1767965890929,
    "costTime": 280000
  }
}
Failed response:
{
  "code": 200,
  "message": "success",
  "data": {
    "taskId": "task_12345678",
    "state": "failed",
    "failCode": "UPSTREAM_ERROR",
    "failMsg": "Upstream error",
    "createTime": 1767965610929,
    "completeTime": 1767965620132
  }
}
Parse resultJson after state becomes success:
const payload = JSON.parse(data.resultJson);
const videoUrls = payload.resultUrls;

Request body

Text-to-video

{
  "request_type": "async",
  "input": {
    "mode": "text-to-video",
    "prompt": "a slow tracking shot through a foggy pine forest at dawn",
    "resolution": "1080p",
    "duration": 10,
    "aspect_ratio": "16:9",
    "sound": true,
    "web_search": false
  }
}

First-and-last-frames

{
  "request_type": "async",
  "input": {
    "mode": "first_and_last_frames",
    "prompt": "turn the still frames into a smooth cinematic camera move",
    "image_urls": [
      "https://example.com/frame-start.png",
      "https://example.com/frame-end.png"
    ],
    "resolution": "720p",
    "duration": 5,
    "aspect_ratio": "9:16",
    "sound": true,
    "web_search": false
  }
}

Omni-reference

{
  "request_type": "async",
  "input": {
    "mode": "omni_reference",
    "prompt": "create a stylish product ad using the visual references and voice rhythm",
    "image_urls": [
      "https://example.com/product-shot.png"
    ],
    "video_urls": [
      "https://example.com/ref-motion.mp4"
    ],
    "audio_urls": [
      "https://example.com/ref-audio.mp3"
    ],
    "resolution": "720p",
    "duration": 6,
    "aspect_ratio": "auto",
    "sound": true,
    "web_search": false
  }
}

Parameters

request_type
string
default:"async"
Result delivery mode. Omit this field or use async for polling with statusTask, or use callback for webhook delivery.
callback_url
string
Required when request_type is callback. Must be a public HTTPS URL that can receive the final task payload. See Webhooks.
input
object
required
Seedance 2.0 input parameters.
ModeRequired mediaOptional mediaBilling note
text-to-videoNoneNoneUses the no-video-reference rate.
first_and_last_framesimage_urls with 1-2 imagesNoneUses the no-video-reference rate.
omni_referenceNone by validation, unless audio_urls is suppliedimage_urls, video_urls, audio_urlsUses video-reference billing when video_urls is provided.
In omni_reference, audio-only requests are rejected. If you provide audio_urls, include at least one image or video reference as well.
Use public, directly accessible URLs for all reference media. Video and audio durations are checked before the task is submitted.
image_urls examples use URL strings. The backend also accepts object items with a non-empty url field and normalizes them to URL strings.

Response format

Submit task response

POST /generateTask/seedance-2-0 returns a task ID when the task is accepted:
code
integer
API status code. 200 means the task was accepted.
message
string
Human-readable status message.
data.taskId
string
Unique task identifier used with the status endpoint.

Status response fields

taskId
string
Unique task identifier.
state
string
Current task state: pending, processing, success, or failed.
resultJson
string
JSON string containing generated video URLs in resultUrls. Present when state is success.
failCode
string
Machine-readable failure code. Present when state is failed.
failMsg
string
Human-readable failure message. Present when state is failed.
createTime
integer
Task creation timestamp in Unix milliseconds.
completeTime
integer
Task completion timestamp in Unix milliseconds. Present after completion.
costTime
integer
Processing duration in milliseconds. Present after completion when timing data is available.

Webhook callback mode

Use callback mode when your backend should receive the final result automatically instead of polling.
curl -X POST "https://api.apixo.ai/api/v1/generateTask/seedance-2-0" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "request_type": "callback",
    "callback_url": "https://your-server.com/webhooks/apixo",
    "input": {
      "mode": "first_and_last_frames",
      "prompt": "turn the still frames into a smooth cinematic camera move",
      "image_urls": [
        "https://example.com/frame-start.png",
        "https://example.com/frame-end.png"
      ],
      "resolution": "720p",
      "duration": 5,
      "aspect_ratio": "9:16",
      "sound": true,
      "web_search": false
    }
  }'
The callback payload uses the same top-level shape as status polling with code, message, and data. Successful callbacks include the final state and resultJson. See Webhooks for delivery requirements and retry behavior.

Billing

Seedance 2.0 is billed per second. The selected resolution and whether omni_reference includes video_urls determine the per-second unit price.
ConfigurationAPIXO price
480p, without video reference$0.091 / second
480p, with video reference$0.055 / second
720p, without video reference$0.192 / second
720p, with video reference$0.115 / second
1080p, without video reference$0.49 / second
1080p, with video reference$0.29 / second
Formula without video reference:
total cost = output duration * unit price
Formula with video reference:
total cost = (output duration + total reference video duration) * unit price
text-to-video and first_and_last_frames always use the without-video-reference rate. omni_reference uses the with-video-reference rate only when video_urls is provided. For current route and market comparison pricing, see Pricing.

Latency and polling

Video generation is long-running. The user manual lists typical Seedance 2.0 generation time at about 4-8 minutes. Actual latency may vary by prompt complexity, duration, resolution, reference media accessibility, route queue load, and storage transfer time.
WorkloadTypical generation timeRecommended first pollPoll interval
Text-to-video or first-and-last-frames4-8 minutes300s after task creation10s-20s
Omni-reference with image/video/audio inputs4-8 minutes or longer300s-400s after task creation10s-20s
For production workloads, use callback mode to avoid frequent polling while video tasks run.
Result URLs are temporary. Download and store important outputs promptly after task completion. Rate limits and concurrency can vary by account, API key, and route. If you receive 429, slow down requests and retry with backoff. For account-level details, see System APIs.

Errors and troubleshooting

HTTP errors

CodeMeaningWhat to do
400Invalid request body, missing input, unsupported mode, missing prompt, invalid resolution, invalid duration, invalid aspect_ratio, invalid boolean value, or invalid media arrayFix the request before retrying
401Missing or invalid API keyCheck the Authorization header
402Insufficient balance or quotaAdd balance or switch account/key
403Key or route cannot access the modelCheck permissions and route strategy
404Task not found when pollingCheck the taskId
429Rate limit or concurrency limit reachedRetry with exponential backoff
500Server error or unknown task failureRetry with backoff
502Upstream errorRetry with backoff
504Upstream timeoutRetry or use callback mode for long-running jobs

Validation notes

ConditionBackend behavior
Missing inputRequest fails before task creation.
Missing, non-string, or empty promptRequest fails before task creation.
Missing modeRequest fails before task creation.
Unsupported modeRequest fails before task creation. Supported values are text-to-video, first_and_last_frames, and omni_reference.
Missing resolutionDefaults to 720p.
Unsupported resolutionRequest fails before task creation. Supported values are 480p, 720p, and 1080p.
Missing durationDefaults to 5.
duration outside 4 through 15Request fails before task creation.
Missing aspect_ratioDefaults to auto.
Unsupported aspect_ratioRequest fails before task creation.
sound or web_search is not a booleanRequest fails before task creation.
first_and_last_frames without image_urlsRequest fails before task creation.
first_and_last_frames with more than 2 imagesRequest fails before task creation.
omni_reference with more than 9 images, 3 videos, or 3 audio filesRequest fails before task creation.
omni_reference with only audio_urlsRequest fails before task creation.
Reference video or audio shorter than 2 seconds or longer than 15 secondsRequest fails before task creation.
Total reference video duration or total reference audio duration over 15 secondsRequest fails before task creation.

Task failure codes

failCode is generated from APIXO’s mapped upstream error. Common values include:
Fail codeMeaningWhat to do
SensitiveContentPrompt or input/output content was rejected by safety checksChange the prompt or reference media
PromptInvalidPrompt was invalid or rejected upstreamRewrite the prompt and retry
ImageFormatIncorrectReference image format could not be processedUse a public, direct image URL in a common image format
RateLimitedUpstream rate limit was reachedRetry with exponential backoff
TimeoutUpstream timeoutRetry later or use callback mode
StreamErrorUpstream returned a 500-class generation errorRetry with backoff
Unknown errorUpstream returned an unmapped failureRetry with backoff or contact support with the taskId
See Error Codes for the full error reference.