Tools
Register Tool
Create and register a new tool with an agent
POST
Register Tool
Path Parameters
| Parameter | Type | Description |
|---|---|---|
agent_id | string | The agent’s unique identifier |
Request Body
Send aToolRegistrationRequest with the tool code and any registration options. function_code may define a sync or async Python function; async functions are awaited by the runtime. In the Python SDK, use client.agents.tools.create(agent_id, ...) for this source-backed registration contract.
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Tool name used by agents and direct execution |
description | string | yes | Human-readable tool description |
function_code | string | yes | Python function source for the tool |
parameters | object | no | Optional parameter metadata |
tags | string[] | no | Tool tags for filtering and display |
group | string | no | UI grouping label |
icon, icon_type, icon_color, icon_variant | string | no | Optional visual metadata |
require_approval | boolean | no | Require approval before execution |
args_schema | object | no | JSON schema for tool arguments |
param_descriptions | object | no | Per-parameter descriptions |
secure_execution | boolean | no | Run the tool in secure execution mode; defaults to true |
execution_timeout | number | no | Tool timeout in seconds |
target_sub_agent_id | string | no | Also attach the tool to a sub-agent |
target_agent_ids | string[] | no | Also attach the tool to additional agents |
llm_usage | object | no | Optional LLM usage configuration for the tool |
credentials | object | no | Optional credential configuration |
Response
Returns200 OK with the persisted tool identifiers.
tool_id is the canonical persisted identifier. Use it for updates, deletes, approval configuration, and direct execution; name-based lookup remains supported for compatibility.Register Tool

