Skip to main content

Interface: RegisterToolFromSchemaParams

Defined in: index.ts:386

Parameters accepted by registerToolFromSchema.

Properties

description?

optional description?: string

Defined in: index.ts:390

Human-readable description shown to the AI client.


handler

handler: (args) => {[key: string]: unknown; } | Promise<{[key: string]: unknown; }>

Defined in: index.ts:403

Tool handler invoked when the AI client calls the tool. Receives the raw request arguments as a plain object (no Zod validation is applied, so the shape matches whatever the client sends).

Parameters

ParameterType
argsRecord<string, unknown>

Returns

{[key: string]: unknown; } | Promise<{[key: string]: unknown; }>


inputSchema?

optional inputSchema?: JsonObjectSchema

Defined in: index.ts:397

Plain JSON Schema that describes the tool's input object. This schema is forwarded verbatim over the MCP wire protocol, so any JSON Schema feature (anyOf, $ref, pattern, …) is preserved without loss. Defaults to { type: 'object', properties: {} } when omitted.


name

name: string

Defined in: index.ts:388

Unique tool name.