API Reference
智能剪辑-任务查询
REQUEST
smartclip-task-query
ID 46
通过任务 ID 查询智能剪辑任务状态与结果。任务未完成时可轮询。查询不扣费。支持 GET / POST。
REQUEST
https://apis.xiaobao.ink/api/smartclip/task_query
鉴权
请求需携带平台 API Key(查询参数 key 或 JSON 字段 key,以本接口说明为准)。在控制台 API Key 管理 创建密钥。
REQUEST https://apis.xiaobao.ink/api/smartclip/task_query
Content-Type: application/json
{
"key": "YOUR_API_KEY"
}
请求示例
https://apis.xiaobao.ink/api/smartclip/task_query?task_id=task_xxxxxxxxxxxx&key=你的密钥
详细说明
接口说明:
配合真人口播、口播混剪、新闻混剪创建接口使用。创建后用返回的 task_id 查询结果。任务未完成时可轮询本接口。查询不扣费。
请求方法:支持 GET 与 POST(表单或 JSON Body 均可传 task_id)。
请求HEADER:
| 名称 | 值 |
|---|---|
| Content-Type | application/json 或 application/x-www-form-urlencoded(POST 时) |
请求参数说明:
| 名称 | 必填 | 类型 | 示例值 | 说明 |
|---|---|---|---|---|
| task_id | 是 | string | task_xxxxxxxxxxxx | 创建接口返回的任务ID;GET 查询参数,或 POST 表单/JSON |
返回参数说明:
| 名称 | 类型 | 说明 |
|---|---|---|
| task_id | string | 任务ID |
| api_type | string | realman_broadcast / broadcast_mixcut / news_mixcut |
| type | string | 固定 app |
| call_type | string | 固定 async |
| status | string | pending / processing / completed / failed |
| progress | int | 进度 0-100 |
| video_url | string | 成片地址(本站可访问),完成时有值 |
| created_at | string | 创建时间 ISO 8601 |
| completed_at | string | 完成时间 ISO 8601 |
| result | object | 仅完成时返回;含 video_url,可能含 cover_url、duration |
| power_cost | number | 创建该任务时本平台实际扣除的点数,与请求日志点数计费一致 |
| error | object | 失败时返回 code、message |
| fail_reason | string | 失败原因 |
| local_status | int | 1处理中 2完成 3失败 |
建议提交后约 2 秒开始轮询,间隔 2~5 秒;status 为 completed / failed 时停止。
返回示例
{"code":200,"msg":"查询成功","data":{"task_id":"task_xxxxxxxxxxxx","api_type":"realman_broadcast","type":"app","call_type":"async","status":"completed","progress":100,"video_url":"https://apis.xiaobao.ink/upload/smartclip/2026/09/19/demo.mp4","created_at":"2026-08-01T10:00:00+08:00","completed_at":"2026-08-01T10:01:20+08:00","result":{"video_url":"https://apis.xiaobao.ink/upload/smartclip/2026/09/19/demo.mp4"},"fail_reason":"","local_status":2,"power_cost":30}}
错误码
| HTTP 响应状态码 | 说明 |
|---|---|
| 200 | 查询成功 |
| 400 | 缺少 task_id 等参数错误 |
| 403 | 无权查看该任务 |
| 404 | 任务不存在 |
完整控制台文档(含调试台):/doc/46