APIMaster.ai

Seedance 2.5 Flash API tạo video

Tạo video bất đồng bộ từ văn bản và tham chiếu hình ảnh, video hoặc âm thanh. Dùng ID công khai `seedance-2.5-flash` với mức giá và giới hạn riêng.

Seedance 2.5 Flash API tạo video

Tạo video bất đồng bộ từ văn bản và tham chiếu hình ảnh, video hoặc âm thanh. Dùng ID công khai seedance-2.5-flash với mức giá và giới hạn riêng.

Khả năng và giới hạn

Đầu ra 480p / 720p, thời lượng nguyên 4–30 giây, mặc định 5. duration: -1 chọn thời lượng tự động. Không hỗ trợ 1080p, 4K hoặc Draft.

Tối đa 10 ảnh, 5 video và 5 âm thanh. Mỗi video/âm thanh dài 2–30 giây; tổng video và tổng âm thanh riêng biệt không quá 30 giây. Giới hạn tệp: ảnh 30 MB, video 200 MB, âm thanh 15 MB. Dùng tài liệu có quyền sử dụng và URL truy cập được.

Tham số

Tham số Kiểu Giá trị / giới hạn
model string seedance-2.5-flash
prompt string Text
resolution string 480p / 720p; default 720p
duration integer 4–30, -1; default 5
seconds integer / string Alias: duration
aspect_ratio string 16:9, 4:3, 1:1, 3:4, 9:16, 21:9, adaptive; default adaptive
ratio string Alias: aspect_ratio
size string Alias: resolution / pixel size; no conflicting resolution or ratio
generate_audio boolean default true
audio boolean Alias: generate_audio
watermark boolean default false
return_last_frame boolean default false
seed integer 0 is preserved
output_format string mp4 / mov; default mp4
omni_reference_task_type string auto, reference, edit, extend
image_urls string[] 10
image_with_roles object[] url, role: first_frame, last_frame, reference_image; images total ≤10
video_urls string[] 5
audio_urls string[] 5
content object[] Native text, image_url, video_url, audio_url references
metadata object Optional wrapper for generation fields
draft boolean true: unsupported
draft_task_id string unsupported

Giữ adaptive cho khung đầu/cuối, chỉnh sửa và kéo dài. Tỷ lệ đầu ra theo tham chiếu. Chỉnh sửa cần video nguồn 4–30 giây và duration: -1. Có thể chỉ dùng tham chiếu âm thanh. MOV phụ thuộc tuyến tạo video.

Gửi và tải xuống

Lưu ID tác vụ công khai, kiểm tra đến khi hoàn tất rồi tải xuống. HTTP 200 chỉ nghĩa là đã tiếp nhận. Đọc lỗi trước khi tạo tác vụ mới; chỉ dùng lại Idempotency-Key cho yêu cầu giống hệt.

curl "https://apimaster.ai/v1/v1/videos" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: flash-text-unique-001" \
  -d '{"model":"seedance-2.5-flash","prompt":"A red paper boat floating on calm water at sunrise","duration":4,"resolution":"720p","aspect_ratio":"16:9","generate_audio":true,"watermark":false}'
curl "https://apimaster.ai/v1/v1/videos/TASK_ID" -H "Authorization: Bearer YOUR_API_KEY"
curl -L "https://apimaster.ai/v1/v1/videos/TASK_ID/content" -H "Authorization: Bearer YOUR_API_KEY" -o video.mp4
curl "https://apimaster.ai/v1/v1/videos/TASK_ID/billing" -H "Authorization: Bearer YOUR_API_KEY"

Tham chiếu, chỉnh sửa và kéo dài

{
  "model": "seedance-2.5-flash",
  "prompt": "The paper boat passes under a wooden bridge",
  "duration": 4,
  "resolution": "480p",
  "aspect_ratio": "adaptive",
  "generate_audio": false,
  "image_with_roles": [
    {
      "url": "https://example.com/authorized-first-frame.png",
      "role": "first_frame"
    }
  ]
}
{
  "model": "seedance-2.5-flash",
  "prompt": "Change the lighting to warm sunset",
  "resolution": "720p",
  "duration": -1,
  "aspect_ratio": "adaptive",
  "omni_reference_task_type": "edit",
  "video_urls": [
    "https://example.com/authorized-source.mp4"
  ]
}

omni_reference_task_type: "extend" + duration: 4 + aspect_ratio: "adaptive".

Thanh toán

Giá cơ bản theo đơn giá token chính thức quốc tế. Phí thực tế còn phụ thuộc kênh, nhóm và tài khoản; xem thẻ mô hình và biên nhận. Chỉ có ảnh: giây đầu ra. Tham chiếu video: giây đầu vào đo được cộng đầu ra. Mức token tối thiểu chính thức có thể khác ước tính theo giây.

Độ phân giải USD / giây USD / giây có video
480p 0.0672525 0.04131225
720p 0.1512 0.09288

Khắc phục sự cố

Kiểm tra ID công khai, độ phân giải và số lượng tài liệu. Gửi rõ boolean như false. Thiếu cơ sở dấu vân tay không có nghĩa là tạo thất bại. Tải kết quả sớm; không lưu trữ lâu dài bằng URL tạm.