Skip to main content
POST
JavaScript

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

task_id
string
required

The ID of the task to cancel

Response

Successful Response

The task object returned in JSON-RPC result.

object
enum<string>
required

固定为 task。

Available options:
task
id
string
required

任务 ID。

session_id
string
required

会话 ID。

user_id
string
required

用户 ID。

status
enum<string>
required

任务状态。

Available options:
created,
queued,
working,
input-required,
paused,
completed,
canceled,
expired,
failed
created_at
integer
required

任务创建时间(Unix 秒)。

output
OutputItem · object[]
required

模型/代理生成的输出条目集合(多类型)。

An output item produced by the agent/model.

usage
object

token 用量统计信息。

error
object

错误信息(失败时)。

input_required
object

若任务等待外部输入,则给出需要执行的工具调用(如等待用户参数)。

metadata
object

扩展元数据。

previous_task_id
string

前置任务 ID(用于续写/衔接)。

rollouts
object[]

任务推演/回溯事件集合(可选)。