Create an agent task
Creates a model task. Provide text or image inputs to generate text or JSON outputs. Have the model call your own custom code or use built-in tools like web search or file search to use your own data as input for the model's task.
| Request Body — REQUIRED | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
user_message_content — REQUIRED消息内容,字符串或内容项数组,工具协议兼容的 message_content(保留字段)。 | ||||||||||||||||||||||||
stream boolean — REQUIRED是否启用流式(SSE)返回;true 则以 text/event-stream 推送 Task 事件。 | ||||||||||||||||||||||||
structured_output object期望的结构化输出 JSON Schema;仅非流式模式有效,流式模式下将被忽略。 | ||||||||||||||||||||||||
client_id string调用方客户端标识(如 AIME)。 | ||||||||||||||||||||||||
request_id string请求链路唯一 ID;便于将复杂调用串联在一起。 | ||||||||||||||||||||||||
session_id string会话 ID;用于跨多轮交互复用上下文。 | ||||||||||||||||||||||||
task_id string任务 ID;用于区分主任务与子任务。 | ||||||||||||||||||||||||
user_id string终端用户 ID。 | ||||||||||||||||||||||||
agent_config objectThe Agent configuration used by the server.
| ||||||||||||||||||||||||
allowed_tools string[]允许使用的工具白名单;为 null 允许全部,空数组表示禁止所有。 | ||||||||||||||||||||||||
disallowed_tools string[]禁用的工具黑名单;为 null 或空数组不生效。 | ||||||||||||||||||||||||
allowed_subagents string[]允许使用的子代理白名单;为 null 允许全部,空数组禁止所有。 | ||||||||||||||||||||||||
stop_tools string[]命中则停止代理循环的工具名列表;为 null 或空数组不生效。 | ||||||||||||||||||||||||
client_tools object[]客户端自带工具定义;命中后会停止由服务端执行,等待客户端完成。
| ||||||||||||||||||||||||
history_messages object[]历史对话消息,用于提供上下文。 | ||||||||||||||||||||||||
thought_messages object[]隐藏的助手思考内容(不可见思考轨迹),如有将并入上下文。 | ||||||||||||||||||||||||
inference_args object推理参数覆盖项(如温度、最大 tokens 等),具体字段由后端实现决定。 | ||||||||||||||||||||||||
workspace_dir string文件系统工作目录;供文件工具与代码解释器使用。 | ||||||||||||||||||||||||
env objectAgent 的运行时环境变量键值对。 | ||||||||||||||||||||||||
log_dir string日志输出目录。 | ||||||||||||||||||||||||
rollout_save_dir string回溯(rollout)结果保存目录。 | ||||||||||||||||||||||||
return_rollout boolean是否在最终结果中返回 rollout 事件集合。 | ||||||||||||||||||||||||
include_compress_model_rollout boolean是否包含上下文压缩模型的 rollout 结果。 | ||||||||||||||||||||||||
include_subagent_rollout boolean是否包含子 Agent 的 rollout 结果。 |
| Responses | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
200OK
|