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;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. While 'Delete' implies a destructive operation, the description doesn't specify whether this action is reversible, what permissions are required, whether it affects associated data (like chats or messages), or what happens on success/failure. This is a significant gap for a destructive tool with zero annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with zero waste. It's appropriately sized and front-loaded, directly stating the tool's purpose without unnecessary elaboration.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a destructive tool with no annotations and no output schema, the description is incomplete. It lacks critical context such as the consequences of deletion, error handling, or return values. Given the complexity of deletion operations and the absence of structured safety hints, more behavioral detail is needed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 100%, with the single parameter 'instanceName' clearly documented as 'Instance name to delete'. The description adds no additional meaning beyond what the schema provides, such as format examples or constraints. With high schema coverage, the baseline score of 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Delete') and the resource ('a WhatsApp instance'), providing specific verb+resource pairing. However, it doesn't differentiate from sibling tools like 'remove_participants' or 'delete_template', which also perform deletion operations on different resources.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. There's no mention of prerequisites (like needing an existing instance), exclusions, or comparison with similar tools such as 'remove_participants' (which removes participants from groups) or 'delete_template' (which deletes message templates).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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