跳转到主要内容

认证方式

所有需要认证的API接口(如创建视频生成任务、查询任务等)都需要在请求头中包含有效的Token。

HTTP Authentication Scheme

  • Scheme: Bearer
  • Header: Authorization
  • 格式: Authorization: Bearer <token>

Token说明

  • Token是一个64字符的十六进制字符串
  • Token必须包含在 Authorization 头中,格式为 Bearer <token>,注意 Bearer 和Token之间有一个空格
  • 获取或更新Token,请联系技术支持

错误响应

当Token无效或缺失时,API会返回以下错误: 401 Unauthorized
{
  "code": 401,
  "msg": "Authorization header is required",
  "request_id": "xxx"
}
{
  "code": 401,
  "msg": "Invalid token or token not mapped to account",
  "request_id": "xxx"
}