Skip to main content
POST
Chọn một giá trị WxH được ghi trong tài liệu từ bảng bên dưới cho trường size.

Sử dụng ảnh tham chiếu

Chỉ các mô hình Seedance 2.0 mới chấp nhận input_reference. Thêm một tệp input_reference để tạo nội dung có hướng dẫn bằng ảnh. Đối với các Prompt nhiều ảnh tham chiếu nâng cao, hãy lặp lại cùng một trường multipart theo thứ tự tải lên. Seedance 2.0 nhạy với cách Prompt liên kết từng ảnh tham chiếu với cảnh. Hãy tham chiếu đến các tệp đã tải lên theo thứ tự, chẳng hạn [Image 1], [Image 2][Image 3], rồi gán cho mỗi ảnh một vai trò rõ ràng:
  • Dùng [Image 1] cho chủ thể chính, nhân vật hoặc sản phẩm.
  • Dùng [Image 2] cho chủ thể phụ, đạo cụ hoặc bạn đồng hành.
  • Dùng [Image 3] cho nền, bối cảnh, ánh sáng hoặc phong cách.
Mô tả những gì cần vẫn dễ nhận biết, những gì có thể thay đổi, hành động, chuyển động máy quay, phong cách hình ảnh và cảnh. Một Prompt mơ hồ có thể khiến video được tạo trông như thể ảnh tham chiếu không được sử dụng, ngay cả khi tệp tải lên đã được chấp nhận. Cấu trúc Prompt này đáng tin cậy hơn việc chỉ liệt kê ảnh:

Thời lượng theo mô hình

Nếu bỏ qua seconds, CometAPI sẽ yêu cầu một clip dài 5 giây. Gửi seconds dưới dạng chuỗi khi bạn cần thời lượng cụ thể.

Hỗ trợ kích thước theo model

Bảng dưới đây tuân theo ánh xạ độ phân giải Seedance chính thức và tập hợp các giá trị kích thước đã công bố tại một nơi. Đối với 1080p, cột ngoài cùng bên phải liệt kê các giá trị Seedance 1.5 ProSeedance 2.0 đã được ghi nhận. Seedance 2.0 Fast không được liệt kê trong bảng 1080p chính thức đó. Các mục 4K chỉ áp dụng cho doubao-seedance-2-0. Bạn có thể dùng chúng cho yêu cầu chuyển văn bản thành video hoặc chuyển hình ảnh thành video có bao gồm input_reference. Chúng không áp dụng cho doubao-seedance-2-0-fast. Hãy truyền chính xác giá trị WxH hiển thị trong bảng. Chọn giá trị WxH đã được ghi nhận cho model đích. Hỗ trợ WxH chính xác vẫn phụ thuộc vào model, vì vậy hãy kiểm tra media đã hoàn tất trước khi dựa vào một kích thước chưa được ghi nhận.

Ủy quyền

Authorization
string
header
bắt buộc

Bearer token authentication. Use your CometAPI key.

Nội dung

multipart/form-data
prompt
string
bắt buộc

Text prompt that describes the video. Required. When using reference images, describe what each uploaded image should control, such as the subject from [Image 1], the secondary object from [Image 2], and the background or style from [Image 3]. Also state the action, camera motion, visual style, and scene.

Ví dụ:

"A slow cinematic camera push across a coastal landscape at sunrise."

model
enum<string>
bắt buộc

Seedance model id. Only the two 2.0 models accept input_reference.

Tùy chọn có sẵn:
doubao-seedance-2-0,
doubao-seedance-2-0-fast,
doubao-seedance-1-5-pro,
doubao-seedance-1-0-pro
Ví dụ:

"doubao-seedance-2-0"

seconds
integer
mặc định:5

Video duration in seconds. The accepted range depends on the model: doubao-seedance-2-0 and doubao-seedance-2-0-fast accept 4 to 15, doubao-seedance-1-5-pro accepts 4 to 12, and doubao-seedance-1-0-pro accepts 2 to 10. The default is 5 for every model.

Phạm vi bắt buộc: 2 <= x <= 15
Ví dụ:

5

size
string

Output size as an exact WxH value, such as 1280x720. For doubao-seedance-2-0 4K output, use 3840x2160, 3326x2494, 2880x2880, 2494x3326, 2160x3840, or 4398x1886. These 4K values work for text-to-video and requests with input_reference, but they do not apply to doubao-seedance-2-0-fast. Exact WxH support remains model-dependent, and an undocumented value can normalize to another size or fail.

Pattern: ^[1-9]\d{2,3}x[1-9]\d{2,3}$
Ví dụ:

"1280x720"

"1920x1080"

"3840x2160"

"3326x2494"

"2880x2880"

"2494x3326"

"2160x3840"

"4398x1886"

"1112x834"

"960x960"

"834x1112"

"720x1280"

"1080x1920"

"1470x630"

input_reference
file

Optional reference image uploaded as a multipart file. Repeat this field to send multiple reference images; the order of repeated fields is the order you should reference in the prompt as [Image 1], [Image 2], and so on. Use JPEG or PNG files for best compatibility. Only doubao-seedance-2-0 and doubao-seedance-2-0-fast accept this field; sending it with a 1.0 Pro or 1.5 Pro model returns HTTP 400.

Phản hồi

Task created. Save the returned id and poll GET /v1/videos/{id}.

id
string
bắt buộc

Task id. Use it as the path parameter for GET /v1/videos/{id}.

object
string
bắt buộc

Object type, always video.

model
string
bắt buộc

Echo of the requested model id.

status
enum<string>
bắt buộc

Initial task status. Newly created tasks are returned as queued.

Tùy chọn có sẵn:
queued,
in_progress,
completed,
failed,
error
progress
integer
bắt buộc

Completion percentage. 0 at creation.

Phạm vi bắt buộc: 0 <= x <= 100
created_at
integer
bắt buộc

Task creation time as a Unix timestamp in seconds.

task_id
string

Alias of id returned for compatibility. The value matches id.