Skip to main content
Glama
luiso2

Evolution API WhatsApp MCP Server

by luiso2

remove_participants

Remove specified participants from a WhatsApp group using their phone numbers to manage group membership and maintain appropriate conversation environments.

Instructions

Remove participants from a group

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
groupJidYesGroup JID
instanceNameYesInstance name
participantsYesPhone numbers to remove

Implementation Reference

  • The MCP tool handler function that executes the remove_participants logic by calling the EvolutionAPI service.
    private async handleRemoveParticipants(args: any) { const result = await evolutionAPI.removeGroupParticipants(args.instanceName, { groupJid: args.groupJid, participants: args.participants }); return { content: [ { type: 'text', text: JSON.stringify(result, null, 2) } ] }; }
  • Input schema definition for the remove_participants tool.
    { name: 'remove_participants', description: 'Remove participants from a group', inputSchema: { type: 'object', properties: { instanceName: { type: 'string', description: 'Instance name' }, groupJid: { type: 'string', description: 'Group JID' }, participants: { type: 'array', items: { type: 'string' }, description: 'Phone numbers to remove' } }, required: ['instanceName', 'groupJid', 'participants'] }
  • src/index.ts:536-537 (registration)
    Registration of the tool handler in the MCP call tool request switch statement.
    case 'remove_participants': return await this.handleRemoveParticipants(args);
  • Helper method in EvolutionAPI service that makes the HTTP POST request to remove group participants.
    async removeGroupParticipants(instanceName: string, data: { groupJid: string; participants: string[]; }): Promise<any> { const response = await this.client.post(`/group/removeParticipants/${instanceName}`, data); 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