数字人
更新时间:2026-11-04
POST
根据人物图片和音频生成数字人视频。
使用 TE 北京地域 API Key 鉴权。模型能力、调用约定见 Kling 接口概览。
BearerAuthheader
AuthorizationBearer <token>TE 北京地域 API Key,填写后自动添加 Bearer 前缀。
application/json- body
image*string数字人参考图,URL 或 Base64(不带 data: 前缀);jpg/jpeg/png,≤ 10MB,宽高 ≥ 300px,宽高比 1:2.5~2.5:1
sound_file?string音频 URL 或 Base64;mp3/wav/m4a/aac,≤ 5MB,2~300s;与 audio_id 二选一
prompt?string动作、情绪、运镜,≤ 2500 字符
mode?stringstd(默认)、pro
watermark_info?{"enabled": true} 同时生成含水印结果;不支持自定义水印
成功;具体状态及结果见响应字段。
application/json- response
taskId?string任务 ID
requestId?string请求 ID,用于排查
code?string错误码,异常时返回
message?string错误信息,异常时返回
curl -X POST 'https://vod.bj.baidubce.com/v3/aigc/kl/videos/avatar/image2video' \ -H 'Content-Type: application/json' \ -d '{ "image": "https://example.com/avatar.png", "sound_file": "https://example.com/speech.mp3", "mode": "std"}'响应示例200
{ "taskId": "tsk-xxxxxxxxxxxxxxxx", "requestId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"}
