Skip to main content
GET
cURL
在你创建 Kling Omni 图像任务后,使用此端点。传入创建请求返回的 data.task_id,并持续轮询,直到 data.task_status 变为 succeedfailed
CometAPI 的公开查询路由是 GET /kling/v1/images/omni-image/{task_id}。不要使用 GET /v1/images/omni-image;该路由不是 CometAPI 用于 Kling Omni Image 任务的公开查询端点。

轮询行为

  • 使用创建该任务的同一个 CometAPI 账户
  • 每 20-30 秒轮询一次,直到 task_statussucceedfailed
  • 当任务成功时,从 data.task_result.images 读取生成图像的 URL
  • 如果你需要持久访问,请将完成的图像存储到你自己的存储中
来自其他账户的任务、已过期的记录或未知 ID 会返回 task_not_exist

结果字段

成功的查询响应会在 data.task_result.images 下返回生成图像。每个条目可能包含: 生成资源的 URL 可能会过期,或被提供方服务清除。当你的工作流需要长期保留时,请将完成的图像存储到你自己的存储层中。

授权

Authorization
string
header
必填

Bearer token authentication. Use your CometAPI API key.

路径参数

task_id
string
必填

Task ID returned by POST /kling/v1/images/omni-image.

响应

Task status or result.

code
integer
必填

Response code. 0 means the task was found and the status payload was returned.

message
string
必填

Response message.

data
object
必填
request_id
string

Request identifier returned by CometAPI when present.