跳转到主要内容
GET
/
kling
/
v1
/
videos
/
omni-video
/
{task_id}
Omni Query
curl --request GET \
  --url https://api.cometapi.com/kling/v1/videos/omni-video/{task_id} \
  --header 'Authorization: Bearer <token>'
{
  "code": 0,
  "message": "success",
  "request_id": "878106484537192522",
  "data": {
    "task_id": "878106484537192522",
    "task_info": {},
    "created_at": 1777385419126,
    "updated_at": 1777385430317,
    "task_result": {},
    "task_status": "processing"
  }
}

Documentation Index

Fetch the complete documentation index at: https://apidoc.cometapi.com/llms.txt

Use this file to discover all available pages before exploring further.

在你创建 Kling Omni 任务后使用此端点。任务成功时,它会返回任务状态以及最终的视频 URL。

先检查这些字段

  • 用于确认查询请求的 codemessagerequest_id
  • 用于查看任务状态的 data.task_status,例如 submittedprocessingsucceedfailed
  • 用于获取最终 MP4 URL 的 data.task_result.videos[0].url

轮询模式

1

先创建任务

先从 Omni Video 开始,并保存返回的 task_id
2

轮询直到任务结束

持续查询,直到 data.task_status 变为 succeedfailed
3

使用返回的 MP4 URL

任务成功后,及时下载或复制最终视频 URL。

授权

Authorization
string
header
必填

Bearer token authentication. Use your CometAPI key.

路径参数

task_id
string
必填

Task id returned by the Omni Video endpoint.

响应

200 - application/json

Current Kling task state.

code
integer
必填

Kling response code. 0 indicates the query was accepted.

message
string
必填

Kling response message.

request_id
string
必填

Identifier for this query request.

data
object
必填