add_tool
Add custom tools or functions to the MCP server by specifying name, description, programming language, and code. New tools become available to clients for execution.
Instructions
Add a new custom tool/function to the server
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | The name of the tool (must be unique) | |
| description | Yes | A description of what the tool does | |
| language | Yes | The programming language the function is written in | |
| code | No | The function code (inline). Must define a function named "main". Mutually exclusive with codePath | |
| codePath | No | Path to file containing the function code. Mutually exclusive with code | |
| parameters | Yes | JSON Schema defining the input parameters for the function | |
| returns | No | Optional description of what the function returns | |
| dependencies | No | Optional list of dependencies (e.g., Python packages) | |
| timeout | No | Optional timeout in milliseconds (max 300000ms = 5 minutes) |