Seedance 2.5

Seedance 2.5 supports text-to-video, multimodal image/video/audio references, and first/last-frame generation. The public model name is doubao-seedance-2.5; generation tasks are routed transparently through the configured upstream channels.

duration supports -1. When set to -1, the upstream determines output duration and a separate output duration cannot be set. The request may contain video input, but video is not required.

Capabilities

FeatureSupported range
Output duration4–30 seconds, or -1 for upstream-determined duration; default 5
Resolution480p, 720p, 1080p
Aspect ratioadaptive, 16:9, 4:3, 1:1, 3:4, 9:16, 21:9
Reference imagesUp to 30
Reference videosFixed-duration requests: up to 10 and 30 seconds total; with duration=-1, count and total duration are validated by the upstream
Reference audioUp to 10; 30 seconds total; audio-only input supported
Output formatmp4, mov

Pricing

  • Without video input: output duration × rate per second
  • With video input: (total input video duration + output duration) × rate per second
  • With duration=-1 and no video: actual output duration × no-video rate per second
  • With duration=-1 and video: (total input video duration + actual output duration) × video-input rate per second
ResolutionInput without videoInput with video
480p25.86 credits/s17.24 credits/s
720p58.17 credits/s38.78 credits/s
1080p103.68 credits/s69.12 credits/s

Examples:

  • 5-second 480p text-to-video: 5 × 25.86 = 129.30 credits
  • 5-second 720p text-to-video: 5 × 58.17 = 290.85 credits
  • 5-second 1080p text-to-video: 5 × 103.68 = 518.40 credits
  • 1080p with 5 seconds of input video and 5 seconds of output: (5 + 5) × 69.12 = 691.20 credits
  • 720p with 5 seconds of input video and 5 seconds of output: (5 + 5) × 38.78 = 387.80 credits
  • 720p with a 10-second input video, 9.6-second actual output, and duration=-1: (10 + 9.6) × 38.78 = 760.09 credits
  • 720p with no input video, 7.25-second actual output, and duration=-1: 7.25 × 58.17 = 421.73 credits

For duration=-1, the platform pre-charges up to 30 output seconds. If videos are present, it probes and adds their total duration to the pre-charge. After success, the platform uses the upstream output duration when available, otherwise probes the output video, and refunds the difference based on actual output duration. If output duration cannot be determined, the maximum pre-charge is retained without changing the successful task to failed. Failed or expired tasks receive a full refund.

Create a task

POST https://api.aivideoapi.ai/v1/videos/generations

Headers:

Authorization: Bearer sk-your-api-key
Content-Type: application/json

Request body

FieldTypeRequiredDescription
modelstringYesMust be doubao-seedance-2.5
inputobjectYesGeneration parameters
callback_urlstringNoPublic HTTP(S) endpoint that receives completion/failure POST callbacks

Input parameters

FieldTypeRequiredDefaultDescription
promptstringConditionalRequired for text-only generation; optional when any media input is present
generation_typestringNoomni_referenceomni_reference or first_and_last_frames
omni_reference_task_typestringNoMultimodal-reference task-type hint. The upstream currently supports auto, reference, edit, and extend; the platform does not validate or rewrite the value. It is forwarded only when supplied and otherwise omitted so the upstream uses auto
image_urlsstring[] | object[]NoUp to 30 reference images; 1–2 in first/last-frame mode
video_urlsstring[]NoFixed-duration requests support up to 10 reference videos and 30 seconds total; with duration=-1, count and total duration are validated by the upstream
audio_urlsstring[]NoUp to 10 reference audio clips, 30 seconds total; may be used alone
durationintegerNo54–30, or -1 to let the upstream determine output duration
aspect_ratiostringNoadaptiveOutput ratio; first/last-frame mode only supports adaptive
resolutionstringNo720p480p, 720p, or 1080p
generate_audiobooleanNotrueGenerate synchronized audio
watermarkbooleanNofalseAdd an AI watermark
return_last_framebooleanNofalseInclude the output video's last frame
web_searchbooleanNofalseAllow the model to search the web when needed
output_formatstringNomp4mp4 or mov

Generation modes

Multimodal reference

Omit generation_type or set it to omni_reference. Images, videos, and audio can be combined freely, and audio may be used alone. prompt is optional when media is present; a completely empty input is rejected.

First and last frames

Set generation_type to first_and_last_frames:

  • One image is used as the first frame.
  • With two images, the first is the first frame and the second is the last frame.
  • aspect_ratio must be omitted or set to adaptive.
  • video_urls and audio_urls cannot be combined with this mode.

Request examples

Text-to-video with MOV output

curl -X POST https://api.aivideoapi.ai/v1/videos/generations \
  -H "Authorization: Bearer sk-your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "doubao-seedance-2.5",
    "callback_url": "https://your-server.com/webhooks/video",
    "input": {
      "prompt": "A rain-soaked Tokyo street, slow dolly forward, neon reflections on the pavement",
      "duration": 5,
      "resolution": "720p",
      "aspect_ratio": "16:9",
      "generate_audio": true,
      "output_format": "mov",
      "return_last_frame": true
    }
  }'

Audio-only reference

curl -X POST https://api.aivideoapi.ai/v1/videos/generations \
  -H "Authorization: Bearer sk-your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "doubao-seedance-2.5",
    "input": {
      "audio_urls": ["https://example.com/music.mp3"],
      "duration": 8,
      "resolution": "480p"
    }
  }'

Image, video, and audio references

{
  "model": "doubao-seedance-2.5",
  "input": {
    "prompt": "Keep the character design, follow the reference camera rhythm, and use the audio for ambience",
    "image_urls": ["https://example.com/character.png"],
    "video_urls": ["https://example.com/camera-reference.mov"],
    "audio_urls": ["https://example.com/ambience.wav"],
    "omni_reference_task_type": "edit",
    "duration": 10,
    "resolution": "720p",
    "aspect_ratio": "adaptive"
  }
}

Upstream-determined output duration

duration=-1 does not require video input. With video, the platform probes and sums all input-video durations and bills “total input-video duration + actual output duration.” Without video, only actual output duration is billed. The upstream validates the media combination and determines output duration, so no separate output duration can be set.

{
  "model": "doubao-seedance-2.5",
  "input": {
    "prompt": "Keep the original camera rhythm and replace the character's outfit",
    "video_urls": ["https://example.com/input-video.mp4"],
    "duration": -1,
    "resolution": "720p",
    "aspect_ratio": "adaptive"
  }
}

First and last frames

{
  "model": "doubao-seedance-2.5",
  "input": {
    "generation_type": "first_and_last_frames",
    "prompt": "Transition naturally from day to night while keeping the building structure consistent",
    "image_urls": [
      "https://example.com/first-frame.png",
      "https://example.com/last-frame.png"
    ],
    "duration": 6,
    "resolution": "720p",
    "aspect_ratio": "adaptive"
  }
}

Create response

{
  "code": 200,
  "msg": "success",
  "data": {
    "taskId": "cbf6b69d-4f03-4817-8ed7-94c0292184a8"
  }
}

Query a task

curl https://api.aivideoapi.ai/v1/tasks/{taskId} \
  -H "Authorization: Bearer sk-your-api-key"

The normal state flow is pendingprocessingcompleted; failed tasks use failed.

Completed response example:

{
  "id": "cbf6b69d-4f03-4817-8ed7-94c0292184a8",
  "status": "completed",
  "model": "doubao-seedance-2.5",
  "credits_consumed": 290.85,
  "created_at": 1786093200,
  "completed_at": 1786093500,
  "output": {
    "urls": ["https://file.aivideoapi.ai/videos/example.mov"],
    "last_frame_url": "https://file.aivideoapi.ai/images/example-last-frame.png",
    "metadata": {
      "duration": 5,
      "ratio": "16:9",
      "resolution": "720p",
      "framespersecond": 24,
      "generate_audio": true,
      "output_format": "mov"
    }
  }
}

Completed media is mirrored to platform storage when enabled for the account. When callback_url is supplied, completion and failure payloads are POSTed to that endpoint using the same structure.

credits_consumed reports the task's actual credit charge in both task-query and callback payloads. It is 0 while a task is in progress and after a failed task has been refunded.

Media requirements

TypeFormatsPer-item requirementsCount and total duration
ImageJPEG, PNG, WebP, BMP, TIFF, GIF, HEIC, HEIFAspect ratio 0.4–2.5; each side 300–6000 px; under 30 MBUp to 30 images
VideoMP4, MOV2–30 seconds; aspect ratio 0.4–2.5; each side 300–6000 px; 409,600–8,295,044 pixels; under 200 MB; 24–60 FPSFixed-duration requests: up to 10 and 30 seconds total; duration=-1 is validated upstream
AudioWAV, MP32–30 seconds; under 15 MBUp to 10 clips, 30 seconds total

Media URLs must be downloadable by the API service and the selected upstream channel. Reference video duration is probed before task creation; an inaccessible URL or a file that cannot be recognized as MP4/MOV causes a synchronous request error.

Important limitations

  • 4k is not supported.
  • duration=-1 supports requests with no video or with one or more videos. The platform does not restrict video count, combination, or total duration; the upstream validates support.
  • /v1/estimate returns the maximum pre-charge: 30 output seconds without video, or total input-video duration plus 30 output seconds with video.
  • Seedance 2.5 determines reference, extension, and editing task types from the prompt and media. Some task-specific restrictions can only be classified asynchronously by the upstream service and may therefore result in an asynchronous failure.
  • First/last-frame mode only supports adaptive; extension/edit intent involving videos may also be required by the upstream service to use adaptive.
  • Failed or expired tasks automatically refund the full pre-charge.

Error Codes

When a request fails, the API returns a JSON error response:

{
  "error": {
    "code": "insufficient_credits",
    "message": "Your credit balance is too low. Please top up.",
    "type": "billing_error"
  }
}

Error Reference

HTTP StatusCodeTypeDescription
400invalid_requestinvalid_request_errorMissing or invalid parameters
401invalid_api_keyauthentication_errorAPI key is invalid, disabled, or deleted
402insufficient_creditsbilling_errorCredit balance too low, please top up
403ip_not_allowedpermission_errorRequest IP not in the key's allowlist
404model_not_foundinvalid_request_errorModel does not exist or is inactive
404task_not_foundinvalid_request_errorTask ID does not exist
429rate_limit_exceededrate_limit_errorToo many requests, please slow down
429spend_limit_exceededbilling_errorKey spend limit reached (hourly/daily/total)
500internal_errorapi_errorUnexpected server error
503upstream_errorupstream_errorUpstream AI provider returned an error

Common Scenarios

invalid_request (400)

Returned when required fields are missing or invalid.

{
  "error": {
    "code": "invalid_request",
    "message": "'model' is required.",
    "type": "invalid_request_error"
  }
}

insufficient_credits (402)

Your balance is too low. Check your balance with GET /v1/credits and top up in Dashboard > Billing.

invalid_api_key (401)

Possible causes:

  • The key does not start with sk-
  • The key has been disabled or deleted
  • The user account has been banned

upstream_error (503)

The upstream AI provider returned an error. This may happen when:

  • The input contains sensitive or prohibited content
  • The provider is temporarily unavailable
  • The request parameters are not supported by the provider

Credits are automatically refunded when a task fails due to upstream errors.