{"openapi":"3.1.0","info":{"title":"十方MAAS API","description":"Seedance 视频生成与视频超分 API 服务。","version":"1.0.0"},"paths":{"/v1/video-generations/estimate":{"post":{"tags":["Video API"],"summary":"预估本次 Seedance 视频生成费用（不扣款）","operationId":"estimate_generation_v1_video_generations_estimate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoGenerationCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceEstimate"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"400":{"description":"请求无效","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"408":{"description":"上传请求体超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"504":{"description":"媒体计量等待超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}},"/v1/video-upscales/estimate":{"post":{"tags":["Video API"],"summary":"预估本次视频超分费用（不扣款）","operationId":"estimate_upscale_v1_video_upscales_estimate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoUpscaleCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceEstimate"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"400":{"description":"请求无效","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"408":{"description":"上传请求体超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"504":{"description":"媒体计量等待超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}},"/v1/results/{job_id}":{"get":{"tags":["Video API"],"summary":"下载尚未过期的任务结果","operationId":"download_result_v1_results__job_id__get","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}},{"name":"expires","in":"query","required":true,"schema":{"type":"integer","title":"Expires"}},{"name":"token","in":"query","required":true,"schema":{"type":"string","title":"Token"}},{"name":"Range","in":"header","required":false,"description":"分段下载，例如 bytes=0-99；归档结果由跳转目标处理。","schema":{"type":"string"}}],"responses":{"200":{"description":"视频文件（MP4 或 MOV）","content":{"video/mp4":{"schema":{"type":"string","format":"binary"}},"video/quicktime":{"schema":{"type":"string","format":"binary"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"206":{"description":"按 Range 请求返回的视频片段","content":{"video/mp4":{"schema":{"type":"string","format":"binary"}},"video/quicktime":{"schema":{"type":"string","format":"binary"}}},"headers":{"Content-Range":{"schema":{"type":"string"}},"Accept-Ranges":{"schema":{"type":"string"}}}},"307":{"description":"已归档结果跳转至对象存储或 CDN；请跟随 Location 下载","headers":{"Location":{"schema":{"type":"string","format":"uri"}}}},"402":{"description":"余额不足或任务费用待补款","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"任务不存在、无权查看或结果不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"410":{"description":"结果签名无效或链接已过期","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"502":{"description":"结果暂时无法下载","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/video-generations":{"post":{"tags":["Video API"],"summary":"创建 Seedance 视频生成任务","description":"创建文本、首尾帧、多素材参考、视频编辑或视频延长任务。","operationId":"create_video_generation_v1_video_generations_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoGenerationCreate"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SeedanceCreated"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"400":{"description":"请求无效","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"402":{"description":"余额不足或任务费用待补款","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"408":{"description":"上传请求体超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"幂等参数冲突或当前任务状态不支持操作","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}},"/v1/video-upscales":{"post":{"tags":["Video API"],"summary":"创建视频超分任务","description":"使用公网 HTTPS MP4 URL 创建视频清晰度增强任务。","operationId":"create_video_upscale_v1_video_upscales_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VideoUpscaleCreate"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"400":{"description":"请求无效","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"402":{"description":"余额不足或任务费用待补款","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"408":{"description":"上传请求体超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"幂等参数冲突或当前任务状态不支持操作","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}},"/v1/tasks/{task_id}":{"get":{"tags":["Video API"],"summary":"查询任务","operationId":"get_task_v1_tasks__task_id__get","security":[{"HD API Key":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SeedanceTaskResponse"},{"$ref":"#/components/schemas/TaskResponse"}],"title":"Response Get Task V1 Tasks  Task Id  Get"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"任务不存在、无权查看或结果不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/tasks/{task_id}/cancel":{"post":{"tags":["Video API"],"summary":"申请取消任务；仅取消成功后返回 cancelled","operationId":"cancel_task_v1_tasks__task_id__cancel_post","security":[{"HD API Key":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SeedanceTaskResponse"},{"$ref":"#/components/schemas/TaskResponse"}],"title":"Response Cancel Task V1 Tasks  Task Id  Cancel Post"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"任务不存在、无权查看或结果不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"408":{"description":"上传请求体超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"幂等参数冲突或当前任务状态不支持操作","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/account":{"get":{"tags":["Video API"],"summary":"查询当前 Key 账户余额与额度","operationId":"get_account_v1_account_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}},"/v1/products":{"get":{"tags":["Video API"],"summary":"查询当前 Key 实际授权产品与价格","operationId":"get_products_v1_products_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}},"/v1/tasks/{task_id}/billing":{"get":{"tags":["Video API"],"summary":"查询本 Key 订单收费明细","operationId":"get_task_billing_v1_tasks__task_id__billing_get","security":[{"HD API Key":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"任务不存在、无权查看或结果不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/wan/video-generations/estimate":{"post":{"tags":["Video API"],"summary":"预估 Wan3.0 视频生成费用（不扣款）","operationId":"estimate_wan_v1_wan_video_generations_estimate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WanVideoGenerationCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceEstimate"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"400":{"description":"请求无效","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"408":{"description":"上传请求体超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"504":{"description":"媒体计量等待超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}},"/v1/wan/video-generations":{"post":{"tags":["Video API"],"summary":"创建 Wan3.0 视频生成任务","operationId":"create_wan_generation_v1_wan_video_generations_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WanVideoGenerationCreate"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"405":{"description":"请求方法不支持","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"请求体超过大小限制","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"请求参数或输入媒体校验失败","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"平台内部错误，请提供 request_id 联系平台","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"API Key 缺失、无效、过期或已禁用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"账户不可用或未授权所请求的 API 参数","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"请求频率、配额或容量受限","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"503":{"description":"服务或计价暂不可用","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"400":{"description":"请求无效","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"402":{"description":"余额不足或任务费用待补款","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"408":{"description":"上传请求体超时","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"幂等参数冲突或当前任务状态不支持操作","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"HD API Key":[]}]}}},"components":{"schemas":{"AudioContent":{"properties":{"type":{"type":"string","const":"audio_url","title":"Type"},"audio_url":{"$ref":"#/components/schemas/MediaURL"},"role":{"anyOf":[{"type":"string","const":"reference_audio"},{"type":"null"}],"title":"Role"}},"additionalProperties":false,"type":"object","required":["type","audio_url"],"title":"AudioContent"},"ErrorResponse":{"properties":{"error":{"$ref":"#/components/schemas/PublicError"}},"type":"object","required":["error"],"title":"ErrorResponse"},"FinalResolution":{"type":"string","enum":["480p","720p","1080p","2k","4k"],"title":"FinalResolution"},"ImageContent":{"properties":{"type":{"type":"string","const":"image_url","title":"Type"},"image_url":{"$ref":"#/components/schemas/MediaURL"},"role":{"anyOf":[{"type":"string","enum":["first_frame","last_frame","reference_image"]},{"type":"null"}],"title":"Role"}},"additionalProperties":false,"type":"object","required":["type","image_url"],"title":"ImageContent"},"MediaURL":{"properties":{"url":{"type":"string","title":"Url","description":"公网 HTTP/HTTPS URL、图片/音频 data URL，或 asset://素材ID"}},"additionalProperties":false,"type":"object","required":["url"],"title":"MediaURL"},"PriceEstimate":{"properties":{"api":{"type":"string","title":"Api","description":"估价对应的 API"},"currency":{"type":"string","title":"Currency","description":"金额币种 CNY"},"estimated_amount":{"type":"string","title":"Estimated Amount","description":"本次请求的预估金额；字符串十进制，最多 8 位小数"},"balance_sufficient":{"type":"boolean","title":"Balance Sufficient","description":"查询时余额是否足够；不代表任务已经受理"},"assumptions":{"items":{"type":"string"},"type":"array","title":"Assumptions","description":"影响估价的未确认信息与保守估算说明"},"description":{"type":"string","title":"Description","description":"估价与结算说明"}},"type":"object","required":["api","currency","estimated_amount","balance_sufficient","assumptions","description"],"title":"PriceEstimate"},"PublicError":{"properties":{"code":{"type":"string","title":"Code"},"message":{"type":"string","title":"Message"},"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"details":{"anyOf":[{},{"type":"null"}],"title":"Details"}},"type":"object","required":["code","message","request_id","details"],"title":"PublicError"},"SeedanceCreated":{"properties":{"id":{"type":"string","title":"Id","description":"平台任务 ID，用于查询和取消"}},"type":"object","required":["id"],"title":"SeedanceCreated"},"SeedanceModel":{"type":"string","enum":["doubao-seedance-2-5-260628","doubao-seedance-2-0-260128","doubao-seedance-2-0-fast-260128","doubao-seedance-2-0-mini-260615"],"title":"SeedanceModel"},"SeedanceOutput":{"properties":{"video_url":{"type":"string","title":"Video Url","description":"最终视频下载地址，有效期 24 小时；不返回中间产物和尾帧"}},"type":"object","required":["video_url"],"title":"SeedanceOutput"},"SeedanceResolution":{"type":"string","enum":["480p","720p","1080p","4k"],"title":"SeedanceResolution"},"SeedanceTaskResponse":{"properties":{"id":{"type":"string","title":"Id"},"model":{"type":"string","title":"Model"},"status":{"type":"string","title":"Status"},"content":{"anyOf":[{"$ref":"#/components/schemas/SeedanceOutput"},{"type":"null"}]},"created_at":{"type":"integer","title":"Created At","description":"Unix 时间戳，秒"},"updated_at":{"type":"integer","title":"Updated At","description":"Unix 时间戳，秒"},"error":{"anyOf":[{"$ref":"#/components/schemas/TaskError"},{"type":"null"}]},"resolution":{"type":"string","title":"Resolution","description":"最终交付分辨率"},"duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration"},"framespersecond":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Framespersecond"},"generate_audio":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Generate Audio"},"output_format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output Format"},"ratio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio"},"seed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seed"},"execution_expires_after":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Execution Expires After"},"safety_identifier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Safety Identifier"},"usage":{"anyOf":[{"$ref":"#/components/schemas/SeedanceUsage"},{"type":"null"}]},"tools":{"anyOf":[{"items":{"$ref":"#/components/schemas/VideoGenerationTool"},"type":"array"},{"type":"null"}],"title":"Tools"}},"type":"object","required":["id","model","status","created_at","updated_at","resolution"],"title":"SeedanceTaskResponse"},"SeedanceTool":{"properties":{"type":{"type":"string","const":"web_search","title":"Type"}},"additionalProperties":false,"type":"object","required":["type"],"title":"SeedanceTool"},"SeedanceToolUsage":{"properties":{"web_search":{"type":"integer","minimum":0.0,"title":"Web Search"}},"type":"object","required":["web_search"],"title":"SeedanceToolUsage"},"SeedanceUsage":{"properties":{"completion_tokens":{"type":"integer","minimum":0.0,"title":"Completion Tokens"},"total_tokens":{"type":"integer","minimum":0.0,"title":"Total Tokens"},"tool_usage":{"anyOf":[{"$ref":"#/components/schemas/SeedanceToolUsage"},{"type":"null"}]}},"type":"object","required":["completion_tokens","total_tokens"],"title":"SeedanceUsage"},"TaskError":{"properties":{"code":{"type":"string","title":"Code","description":"平台统一错误码；无法细分的处理异常为 provider_failed"},"message":{"type":"string","title":"Message","description":"平台统一失败原因与处理建议；不包含渠道原始诊断"}},"type":"object","required":["code","message"],"title":"TaskError"},"TaskOutput":{"properties":{"video_url":{"type":"string","title":"Video Url","description":"平台结果下载地址；默认有效 24 小时，请自行保存，实际期限见 expires_at"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"结果 URL 的失效时间，ISO 8601 UTC；无法确定时为 null"}},"type":"object","required":["video_url"],"title":"TaskOutput"},"TaskResponse":{"properties":{"id":{"type":"string","title":"Id","description":"平台任务 ID"},"type":{"type":"string","title":"Type","description":"video_generation、wan_video_generation 或 video_upscale"},"status":{"type":"string","title":"Status","description":"queued、running、cancelling、reviewing、succeeded、failed 或 cancelled"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model","description":"生成模型；超分任务为 null"},"resolution":{"type":"string","title":"Resolution","description":"请求的最终分辨率"},"output":{"anyOf":[{"$ref":"#/components/schemas/TaskOutput"},{"type":"null"}],"description":"成功结果；未成功、已过期或账单待补款时为 null，费用状态见任务账单接口"},"error":{"anyOf":[{"$ref":"#/components/schemas/TaskError"},{"type":"null"}],"description":"失败信息；未失败时为 null"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"任务创建时间，ISO 8601 UTC"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"任务最近更新时间，ISO 8601 UTC"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"任务终止时间；处理中为 null"}},"type":"object","required":["id","type","status","model","resolution","output","error","created_at","updated_at","completed_at"],"title":"TaskResponse"},"TextContent":{"properties":{"type":{"type":"string","const":"text","title":"Type"},"text":{"type":"string","minLength":1,"title":"Text","description":"文本提示词；保持原始文字和内容顺序"}},"additionalProperties":false,"type":"object","required":["type","text"],"title":"TextContent"},"ToolType":{"type":"string","enum":["web_search"],"title":"ToolType"},"UpscaleResolution":{"type":"string","enum":["720p","1080p","2k","4k"],"title":"UpscaleResolution"},"VideoContent":{"properties":{"type":{"type":"string","const":"video_url","title":"Type"},"video_url":{"$ref":"#/components/schemas/MediaURL"},"role":{"anyOf":[{"type":"string","const":"reference_video"},{"type":"null"}],"title":"Role"}},"additionalProperties":false,"type":"object","required":["type","video_url"],"title":"VideoContent"},"VideoGenerationCreate":{"properties":{"model":{"$ref":"#/components/schemas/SeedanceModel","description":"官方模型名称与版本；账户需开通对应模型"},"content":{"items":{"oneOf":[{"$ref":"#/components/schemas/TextContent"},{"$ref":"#/components/schemas/ImageContent"},{"$ref":"#/components/schemas/VideoContent"},{"$ref":"#/components/schemas/AudioContent"}],"discriminator":{"propertyName":"type","mapping":{"audio_url":"#/components/schemas/AudioContent","image_url":"#/components/schemas/ImageContent","text":"#/components/schemas/TextContent","video_url":"#/components/schemas/VideoContent"}}},"type":"array","minItems":1,"title":"Content","description":"官方内容数组：text、image_url、video_url、audio_url"},"resolution":{"$ref":"#/components/schemas/SeedanceResolution","description":"官方模型支持的输出分辨率；账户授权可进一步缩小范围","default":"720p"},"ratio":{"type":"string","enum":["16:9","4:3","1:1","3:4","9:16","21:9","adaptive"],"title":"Ratio","default":"adaptive"},"duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration","description":"2.5 默认 -1，支持 4～30 秒；2.0 系列支持 4～15 秒或 -1"},"generate_audio":{"type":"boolean","title":"Generate Audio","default":true},"watermark":{"type":"boolean","title":"Watermark","default":false},"output_format":{"anyOf":[{"type":"string","enum":["mp4","mov"]},{"type":"null"}],"title":"Output Format","description":"仅 2.5 支持，默认 mp4"},"omni_reference_task_type":{"anyOf":[{"type":"string","enum":["auto","reference","edit","extend"]},{"type":"null"}],"title":"Omni Reference Task Type","description":"仅 2.5 全模态参考任务支持，省略按 auto 处理"},"return_last_frame":{"type":"boolean","title":"Return Last Frame","description":"接受此官方参数，但当前服务不提供尾帧输出","default":false},"callback_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Callback Url","description":"任务终态通知地址；通知体与查询响应一致"},"execution_expires_after":{"type":"integer","maximum":259200.0,"minimum":3600.0,"title":"Execution Expires After","default":172800},"priority":{"type":"integer","maximum":9.0,"minimum":0.0,"title":"Priority","description":"生成执行优先级，0～9","default":0},"safety_identifier":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Safety Identifier","description":"终端用户固定英文标识，建议使用哈希值"},"tools":{"items":{"$ref":"#/components/schemas/SeedanceTool"},"type":"array","title":"Tools"}},"additionalProperties":false,"type":"object","required":["model","content"],"title":"VideoGenerationCreate"},"VideoGenerationTool":{"properties":{"type":{"$ref":"#/components/schemas/ToolType","description":"工具类型；当前支持 web_search"}},"additionalProperties":false,"type":"object","required":["type"],"title":"VideoGenerationTool"},"VideoUpscaleCreate":{"properties":{"video_url":{"type":"string","title":"Video Url","description":"支持 HTTP Range 的公网 HTTPS MP4 URL，最长 120 秒、最大 500 MB；平台自动读取时长"},"resolution":{"$ref":"#/components/schemas/UpscaleResolution","description":"目标分辨率：720p、1080p、2k 或 4k"},"callback_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Callback Url","description":"可选的终态 Webhook HTTPS 地址"}},"additionalProperties":false,"type":"object","required":["video_url","resolution"],"title":"VideoUpscaleCreate"},"WanModel":{"type":"string","enum":["wan-3.0","wan-3.0-pro","wan-3.0-turbo","wan-3.0-pro-turbo"],"title":"WanModel"},"WanVideoGenerationCreate":{"properties":{"model":{"$ref":"#/components/schemas/WanModel","description":"Wan3.0 视频生成模型"},"prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt","description":"视频提示词，建议不超过 20000 字符；超长内容由生成服务截断"},"first_frame":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Frame","description":"首帧图片 HTTPS URL 或 Base64"},"last_frame":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Frame","description":"尾帧图片 HTTPS URL 或 Base64"},"reference_images":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10},{"type":"null"}],"title":"Reference Images"},"reference_videos":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":5},{"type":"null"}],"title":"Reference Videos","description":"参考视频 HTTPS URL 数组，合计最多 15 秒"},"reference_audios":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":5},{"type":"null"}],"title":"Reference Audios","description":"参考音频 HTTPS URL 数组，合计最多 15 秒"},"file":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File","description":"参考文件 HTTPS URL，与网页、首尾帧互斥"},"link":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Link","description":"公开网页 HTTPS URL，与文件、首尾帧互斥"},"resolution":{"$ref":"#/components/schemas/FinalResolution","description":"对应型号支持的输出分辨率；账户方案不能扩展型号范围","default":"1080p"},"ratio":{"type":"string","enum":["adaptive","16:9","4:3","1:1","3:4","9:16"],"title":"Ratio","default":"adaptive"},"duration":{"type":"integer","title":"Duration","description":"2–30 秒或 -1 智能时长；输入与输出视频合计最多 30 秒","default":5},"audio":{"type":"boolean","title":"Audio","description":"生成音轨；关闭不降低费用","default":true},"prompt_extend":{"type":"boolean","title":"Prompt Extend","description":"自动扩写提示词","default":true},"seed":{"anyOf":[{"type":"integer","maximum":2147483647.0,"minimum":0.0},{"type":"null"}],"title":"Seed"},"callback_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Callback Url"}},"additionalProperties":false,"type":"object","required":["model"],"title":"WanVideoGenerationCreate"}},"securitySchemes":{"HD API Key":{"type":"http","scheme":"bearer"}}}}