Skip to main content
Glama
billyfranklim1

mcp-evolution

Accept Invite

accept_invite

Accept a WhatsApp group invite by providing the invite code from the invitation link.

Instructions

Accept a WhatsApp group invite by invite code via the pinned instance.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inviteCodeYesGroup invite code (the part after https://chat.whatsapp.com/)

Implementation Reference

  • The main handler function that registers and implements the accept_invite tool. It calls the Evolution API endpoint /group/acceptInviteCode/{instanceName}?inviteCode={inviteCode} to accept a WhatsApp group invite.
    export function registerAcceptInvite(server: McpServer, client: EvolutionClient): void {
      server.registerTool(
        "accept_invite",
        {
          title: "Accept Invite",
          description: "Accept a WhatsApp group invite by invite code via the pinned instance.",
          inputSchema: schema,
        },
        async (args) => {
          try {
            const data = await client.get(
              `/group/acceptInviteCode/${client.instanceName}?inviteCode=${encodeURIComponent(args.inviteCode)}`
            );
            return { content: [{ type: "text" as const, text: JSON.stringify(data, null, 2) }] };
          } catch (e) {
            if (e instanceof McpError) return { isError: true, content: [{ type: "text" as const, text: e.message }] };
            throw e;
          }
        }
      );
    }
  • Input schema for accept_invite: requires a single 'inviteCode' string parameter (the part after https://chat.whatsapp.com/).
    const schema = {
      inviteCode: z.string().min(1).describe("Group invite code (the part after https://chat.whatsapp.com/)"),
    };
  • Registration call: registerAcceptInvite(server, client) is invoked from registerAllTools() to wire the tool into the MCP server.
      registerAcceptInvite(server, client);
      registerSendGroupInvite(server, client);
      registerUpdateParticipants(server, client);
      registerUpdateGroupSetting(server, client);
      registerLeaveGroup(server, client);
      registerFindGroupByInvite(server, client);
    
      // Instance
      registerConnectionState(server, client);
      registerRestartInstance(server, client);
      registerLogoutInstance(server, client);
      registerGetSettings(server, client);
      registerSetSettings(server, client);
    
      // Webhook
      registerFindWebhook(server, client);
      registerSetWebhook(server, client);
    
      // Label
      registerFindLabels(server, client);
      registerHandleLabel(server, client);
    
      // Block & Misc
      registerUpdateBlockStatus(server, client);
      registerCheckNumber(server, client);
    }
  • Import statement for the registerAcceptInvite function in the tools barrel index.
    import { registerAcceptInvite } from "./accept-invite.js";
Behavior2/5

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

No annotations are provided. The description does not disclose if the operation is destructive, requires authentication, has rate limits, or what the result is. The mention of 'pinned instance' is vague.

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

Conciseness4/5

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

The description is a single, front-loaded sentence with no wasted words. It is concise but could include one more sentence for clarity without becoming verbose.

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

Completeness3/5

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

Given the simple tool with one parameter and no output schema, the description is partially complete. It lacks behavioral context (e.g., return value, side effects) that would help an agent anticipate outcomes.

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 input schema fully describes the inviteCode parameter with 100% coverage. The tool description adds no extra meaning beyond what the schema already provides, so baseline score is appropriate.

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

Purpose5/5

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

The description clearly states the verb 'Accept', resource 'WhatsApp group invite', and method 'by invite code via the pinned instance'. It distinguishes from sibling tools like send_group_invite, revoke_invite_code, and find_group_by_invite.

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

Usage Guidelines3/5

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

The description implies when to use (accepting an invite) but provides no explicit guidance on when not to use, prerequisites, or alternatives. The context of 'pinned instance' is mentioned but not explained.

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/billyfranklim1/mcp-evolution'

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