Parameters
| Parameter | Type | Description |
|---|---|---|
name | string | The name of the tool |
description | string | A description of what the tool does |
inputSchema | Schema extends AnyZodRawShape | Zod schema defining the tool's input parameters (supports both Zod 3 and Zod 4) |
handler | (args, extra) => Promise<CallToolResult> | Async function that executes the tool logic |
extras | \{ annotations?: ToolAnnotations; searchHint?: string; alwaysLoad?: boolean \} | Optional extras. annotations provides MCP behavioral hints to clients. searchHint is a one-line capability phrase shown in the deferred-tool list when tool search is active. alwaysLoad: true keeps this tool's full schema in the initial prompt instead of deferring it |