seedance-1-5-pro-251215。
核心能力
- 文字生成影片 - 根據文字提示詞生成影片
- 圖片生成影片 - 使用圖片作為首幀或參考
- 非同步流程 - 提交任務後輪詢取得結果
- 影片參考 - 使用參考影片生成或編輯
輸出規格
| 屬性 | 取值 |
|---|---|
| 解析度 | 480p, 720p, 1080p |
| 長寬比 | 21:9, 16:9, 4:3, 1:1, 3:4, 9:16, adaptive |
| 時長 | 4-12 s, or -1 |
| 同步音訊 | 支援 |
| 格式 | mp4 |
| 幀率 | 24 fps |
呼叫流程
1. POST /v1/video/generations -> task_id
2. GET /v1/video/generations/{task_id} -> status
3. When the task succeeds -> read the video URL
呼叫範例
文字生成影片
- cURL
- Python
curl "https://api.mixroute.ai/v1/video/generations" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-1-5-pro-251215",
"prompt": "A red square gently pulses on a clean white background",
"asset": false,
"metadata": {
"duration": 4,
"resolution": "480p",
"ratio": "1:1",
"watermark": false,
"generate_audio": false
}
}'
import requests
response = requests.post(
"https://api.mixroute.ai/v1/video/generations",
headers={"Authorization": "Bearer YOUR_API_KEY"},
json={'model': 'seedance-1-5-pro-251215',
'prompt': 'A red square gently pulses on a clean white background',
'asset': False,
'metadata': {'duration': 4,
'resolution': '480p',
'ratio': '1:1',
'watermark': False,
'generate_audio': False}},
)
print(response.json())
圖片生成影片
curl "https://api.mixroute.ai/v1/video/generations" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-1-5-pro-251215",
"prompt": "The subject turns toward the camera with a gentle motion",
"asset": true,
"metadata": {
"duration": 4,
"resolution": "480p",
"ratio": "1:1",
"watermark": false,
"generate_audio": false,
"content": [
{
"type": "text",
"text": "The subject turns toward the camera with a gentle motion"
},
{
"type": "image_url",
"image_url": {
"url": "https://example.com/first-frame.png"
},
"role": "first_frame"
}
]
}
}'
影片生成影片
curl "https://api.mixroute.ai/v1/video/generations" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-1-5-pro-251215",
"prompt": "Make the reference video slightly warmer while preserving camera motion",
"asset": true,
"metadata": {
"duration": 4,
"resolution": "480p",
"ratio": "1:1",
"watermark": false,
"generate_audio": false,
"content": [
{
"type": "text",
"text": "Make the reference video slightly warmer while preserving camera motion"
},
{
"type": "video_url",
"video_url": {
"url": "https://example.com/reference.mp4"
},
"role": "reference_video"
}
]
}
}'
參數
| 參數 | 類型 | 必填 | 說明 |
|---|---|---|---|
model | string | 是 | 固定為 seedance-1-5-pro-251215。 |
prompt | string | 是 | 影片生成指令。 |
asset | boolean | 是 | metadata.content 包含圖片、影片或音訊參考時設為 true;純文字輸入設為 false。 |
metadata | object | 是 | 包含全部 Seedance 生成參數與參考內容。 |
metadata.content | array | 否 | text、image_url、video_url 與 audio_url 內容項。 |
metadata.duration | integer | 否 | 影片時長,單位為秒。 |
metadata.resolution | string | 否 | 輸出解析度。 |
metadata.ratio | string | 否 | 輸出長寬比。 |
metadata.generate_audio | boolean | 否 | 模型支援時生成同步音訊。 |
metadata.watermark | boolean | 否 | 加入 AI 生成浮水印。 |
metadata.content[].role | string | 否 | first_frame、last_frame、reference_image、reference_video 或 reference_audio。 |
輸入模式
| 模式 | 輸入 |
|---|---|
| 文字生成影片 | text |
| 圖片生成影片 | text + image_url |
| 影片生成影片 | text + video_url |