Skip to main content
Glama
luiso2

Evolution API WhatsApp MCP Server

by luiso2

delete_instance

Remove a WhatsApp Business instance to manage messaging resources and maintain clean API environments.

Instructions

Delete a WhatsApp instance

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
instanceNameYesInstance name to delete

Implementation Reference

  • The main MCP tool handler for 'delete_instance'. Extracts instanceName from input arguments, delegates to evolutionAPI.deleteInstance, and returns the result as MCP-formatted text content (JSON string).
    private async handleDeleteInstance(args: any) { const result = await evolutionAPI.deleteInstance(args.instanceName); return { content: [ { type: 'text', text: JSON.stringify(result, null, 2) } ] }; }
  • src/index.ts:86-96 (registration)
    Tool registration definition in the global tools array. Includes name, description, and input schema. This array is provided to the MCP ListToolsRequestHandler.
    { name: 'delete_instance', description: 'Delete a WhatsApp instance', inputSchema: { type: 'object', properties: { instanceName: { type: 'string', description: 'Instance name to delete' } }, required: ['instanceName'] } },
  • JSON schema for input validation: requires 'instanceName' string.
    inputSchema: { type: 'object', properties: { instanceName: { type: 'string', description: 'Instance name to delete' } }, required: ['instanceName'] }
  • Helper method in EvolutionAPI class that makes the HTTP DELETE request to the backend Evolution API endpoint `/instance/delete/{instanceName}` and returns the response.
    async deleteInstance(instanceName: string): Promise<{ status: string }> { const response = await this.client.delete(`/instance/delete/${instanceName}`); return response.data; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/luiso2/mcp-evolution-api'

If you have feedback or need assistance with the MCP directory API, please join our Discord server