/** * MCP Tool Factory * Creates MCP tools from Evolution API endpoint definitions */ import { z } from 'zod'; import { ToolInfo, ToolFactory, ToolFactoryConfig, ToolHandler } from './types'; import { EndpointInfo, ControllerType } from '../registry/types'; /** * Implementation of the MCP tool factory */ export declare class McpToolFactory implements ToolFactory { private config; constructor(config?: ToolFactoryConfig); /** * Create tools for all endpoints in a controller */ createToolsForController(controller: ControllerType, config?: ToolFactoryConfig): ToolInfo[]; /** * Create a single tool from an endpoint definition */ createToolForEndpoint(endpoint: EndpointInfo, config?: ToolFactoryConfig): ToolInfo; /** * Generate Zod schema for tool parameters based on endpoint definition */ generateSchema(endpoint: EndpointInfo): z.ZodSchema; /** * Create a tool handler for an endpoint */ createHandler(endpoint: EndpointInfo, config?: ToolFactoryConfig): ToolHandler; /** * Generate a tool name from endpoint information */ private generateToolName; /** * Generate a tool description from endpoint information */ private generateToolDescription; /** * Generate examples for a tool */ private generateExamples; /** * Generate example value for a parameter */ private generateExampleValue; /** * Create Zod field schema from parameter definition */ private createZodFieldFromParameter; /** * Transform parameters for API request */ private transformParameters; /** * Make API request using the HTTP client */ private makeApiRequest; /** * Default error handler */ private defaultErrorHandler; /** * Default parameter validator */ private defaultValidator; } export declare const mcpToolFactory: McpToolFactory;