POST
/
v1
/
tools
/

Authorizations

Authorization
string
headerrequired

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

Headers

user_id
string | null

Query Parameters

update
boolean
default: false

Body

application/json
source_code
string
required

The source code of the function.

description
string | null

The description of the tool.

source_type
string | null

The type of the source code.

module
string | null

The module of the function.

user_id
string | null

The unique identifier of the user associated with the function.

id
string | null

The unique identifier of the tool. If this is not provided, it will be autogenerated.

name
string | null

The name of the function (auto-generated from source_code if not provided).

tags
string[]

Metadata tags.

json_schema
object | null

The JSON schema of the function (auto-generated from source_code if not provided)

terminal
boolean | null

Whether the tool is a terminal tool (allow requesting heartbeats).

Response

200 - application/json

Representation of a tool, which is a function that can be called by the agent.

Parameters: id (str): The unique identifier of the tool. name (str): The name of the function. tags (List[str]): Metadata tags. source_code (str): The source code of the function. json_schema (Dict): The JSON schema of the function.

name
string
required

The name of the function.

tags
string[]
required

Metadata tags.

source_code
string
required

The source code of the function.

description
string | null

The description of the tool.

source_type
string | null

The type of the source code.

module
string | null

The module of the function.

user_id
string | null

The unique identifier of the user associated with the function.

id
string

The human-friendly ID of the Tool

json_schema
object

The JSON schema of the function.