Tools
Delete Tool
Retrieve Tool
Modify Tool
List Tools
Create Tool
Upsert Tool
Upsert Base Tools
ModelsExpand Collapse
NpmRequirement = object { name, version }
name: string
Name of the npm package.
version: optional string
Optional version of the package, following semantic versioning.
PipRequirement = object { name, version }
name: string
Name of the pip package.
version: optional string
Optional version of the package, following semantic versioning.
Tool = object { id, args_json_schema, created_by_id, 14 more }
Representation of a tool, which is a function that can be called by the agent.
id: string
The human-friendly ID of the Tool
args_json_schema: optional map[unknown]
The args JSON schema of the function.
created_by_id: optional string
The id of the user that made this Tool.
default_requires_approval: optional boolean
Default value for whether or not executing this tool requires approval.
description: optional string
The description of the tool.
enable_parallel_execution: optional boolean
If set to True, then this tool will potentially be executed concurrently with other tools. Default False.
json_schema: optional map[unknown]
The JSON schema of the function.
last_updated_by_id: optional string
The id of the user that made this Tool.
metadata_: optional map[unknown]
A dictionary of additional metadata for the tool.
name: optional string
The name of the function.
Optional list of npm packages required by this tool.
name: string
Name of the npm package.
version: optional string
Optional version of the package, following semantic versioning.
Optional list of pip packages required by this tool.
name: string
Name of the pip package.
version: optional string
Optional version of the package, following semantic versioning.
return_char_limit: optional number
The maximum number of characters in the response.
source_code: optional string
The source code of the function.
source_type: optional string
The type of the source code.
tags: optional array of string
Metadata tags.
The type of the tool.
ToolCreate = object { source_code, args_json_schema, default_requires_approval, 8 more }
source_code: string
The source code of the function.
args_json_schema: optional map[unknown]
The args JSON schema of the function.
default_requires_approval: optional boolean
Whether or not to require approval before executing this tool.
description: optional string
The description of the tool.
enable_parallel_execution: optional boolean
If set to True, then this tool will potentially be executed concurrently with other tools. Default False.
json_schema: optional map[unknown]
The JSON schema of the function (auto-generated from source_code if not provided)
Optional list of npm packages required by this tool.
name: string
Name of the npm package.
version: optional string
Optional version of the package, following semantic versioning.
Optional list of pip packages required by this tool.
name: string
Name of the pip package.
version: optional string
Optional version of the package, following semantic versioning.
return_char_limit: optional number
The maximum number of characters in the response.
source_type: optional string
The source type of the function.
tags: optional array of string
Metadata tags.
ToolReturnMessage = object { id, date, status, 13 more }
A message representing the return value of a tool call (generated by Letta executing the requested tool).
Args: id (str): The ID of the message date (datetime): The date the message was created in ISO format name (Optional[str]): The name of the sender of the message tool_return (str): The return value of the tool (deprecated, use tool_returns) status (Literal["success", "error"]): The status of the tool call (deprecated, use tool_returns) tool_call_id (str): A unique identifier for the tool call that generated this message (deprecated, use tool_returns) stdout (Optional[List(str)]): Captured stdout (e.g. prints, logs) from the tool invocation (deprecated, use tool_returns) stderr (Optional[List(str)]): Captured stderr from the tool invocation (deprecated, use tool_returns) tool_returns (Optional[List[ToolReturn]]): List of tool returns for multi-tool support
Deprecatedstatus: "success" or "error"
message_type: optional "tool_return_message"
The type of the message.
status: "success" or "error"
type: optional "tool"
The message type to be created.