视频模型 · ByteDance
ByteDance Seedance 2.5 API:价格与接入
seedance-2.5用一个 BoostRail Key 生成 ByteDance Seedance 2.5 视频:提交任务、轮询、下载 MP4。按视频秒数以美元计费,失败的任务不收费。
厂商ByteDance
起价$0.2195 / 秒
单段时长5 或 10 秒
画幅16:9 · 9:16 · 1:1 · 4:3 · 3:4 · 21:9
声音随视频一起生成
每秒价格
每个规格一个价,按你请求的秒数计费。价格随目录实时更新。
| 规格 | 每秒价格 |
|---|---|
| 720p | $0.2195 / 秒 |
| 1080p | $0.5401 / 秒 |
接口接受什么
- 输入:文字提示词(文生视频),图片(图生视频)
- 参考图:接受
- 单段时长:5 或 10 秒
- 做竖屏短剧,在 upstream_options 里把 aspect_ratio 设为 9:16。
提交、轮询、下载
视频接口是异步的。提交后拿到任务 id,轮询到状态为 succeeded,再从 data[0].url 的签名链接下载 MP4,链接 10 分钟内有效。
# 1. Submit the task
curl https://api.boostrail.com/v1/videos \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"seedance-2.5","prompt":"A woman in a red coat stops in the rain, turns to the camera and smiles","seconds":5,"size":"720p","upstream_options":{"aspect_ratio":"9:16"}}'
# 2. Poll every 10 seconds until status is succeeded, failed, cancelled or expired
curl https://api.boostrail.com/v1/videos/TASK_ID \
-H "Authorization: Bearer YOUR_API_KEY"
# 3. Download from data[0].url (a signed link, valid for 10 minutes)
curl -L -o clip.mp4 "SIGNED_URL"import time, requests
API = "https://api.boostrail.com/v1"
HEADERS = {"Authorization": "Bearer YOUR_API_KEY"}
task = requests.post(f"{API}/videos", headers=HEADERS, json={
"model": "seedance-2.5",
"prompt": "A woman in a red coat stops in the rain, turns to the camera and smiles",
"seconds": 5,
"size": "720p",
"upstream_options": {"aspect_ratio": "9:16"},
}).json()
while True:
status = requests.get(f"{API}/videos/{task['id']}", headers=HEADERS).json()
if status["status"] in ("succeeded", "failed", "cancelled", "expired"):
break
time.sleep(10)
if status["status"] == "succeeded":
video = requests.get(status["data"][0]["url"]) # signed link, valid for 10 minutes
with open("clip.mp4", "wb") as f:
f.write(video.content)
else:
print(status["error"]) # failed tasks are not charged使用须知
- 失败、取消和过期的任务都不收费。
- 出片后请尽快下载:生成的视频文件保留约 24 小时。
关于 ByteDance Seedance 2.5 的常见问题
ByteDance Seedance 2.5 在 BoostRail 怎么收费?
seedance-2.5 按视频秒数计费:720p $0.2195,1080p $0.5401。失败的任务不收费。
ByteDance Seedance 2.5 单段视频能多长?
每次请求 5 或 10 秒。更长的场景在剪辑时把几段拼起来。
ByteDance Seedance 2.5 能生成 9:16 竖屏视频吗?
可以。在 upstream_options 里把 aspect_ratio 设为 9:16。可选画幅:16:9,9:16,1:1,4:3,3:4,21:9。
ByteDance Seedance 2.5 接受参考图吗?
接受。在 input_reference 里传最多 4 个公开的 https 图片链接,每张至少 300 × 300 像素。模型从图里取主体和风格,开头画面不会锁定为原图。价格与文生视频相同;图片太小被拒的请求不扣费。
ByteDance Seedance 2.5 会生成声音吗?
会。MP4 带一条随视频生成的音轨。音乐和字幕放到剪辑时再加,更好控制。
ByteDance Seedance 2.5 任务失败了怎么算?
失败、取消和过期的任务都不收费,提交时冻结的金额会退回余额。
ByteDance Seedance 2.5 出片后多久内能下载?
data[0].url 的签名链接 10 分钟内有效,过期了再轮询一次任务就有新链接。任务返回里的 content_expires_at 写明文件能保留到什么时候。 生成的视频文件保留约 24 小时,请尽快下载。