UNPKG

@ria-sys/mcp

Version:

MCP Server para integração com WhatsApp

72 lines (64 loc) 1.42 kB
export interface IMessageService { sendMessage(phones: string[], message: string, sessionName: string): Promise<MessageResponse>; } export interface WhatsAppApiResponse { success: boolean; data: { id?: string; status: string; message: string; timestamp?: string; queue_number?: number; phone?: string; }; } export interface MessageResponse { success: boolean; data: WhatsAppApiResponse['data']; } export interface SendMessageRequest { phones: string[]; message: string; session_name: string; } export interface MCPToolParameter { $schema?: string; type: string; description?: string; properties: { [key: string]: { type: string; description: string; items?: { type: string; }; default?: any; enum?: string[]; }; }; required: string[]; additionalProperties: boolean; } export interface MCPTool { name: string; description: string; parameters: MCPToolParameter; } export interface Tool { name: string; description?: string; inputSchema: { type: 'object'; properties?: { [key: string]: unknown; }; required?: string[]; }; } export interface MCPToolsResponse { tools: Tool[]; } export interface MessageService { sendMessage(phones: string[], message: string, sessionName: string): Promise<void>; formatPhone(phones: string[], removeNinthDigit?: boolean): string[]; }