Skip to main content
Glama
billyfranklim1

mcp-evolution

Restart Instance

restart_instance

Restart a pinned WhatsApp instance to reconnect without logging out.

Instructions

Restart the pinned WhatsApp instance (reconnects without logging out).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The full handler implementation for the 'restart_instance' tool. Registers the tool with no input schema, and on invocation calls POST /instance/restart/{instanceName} via the EvolutionClient.
    export function registerRestartInstance(server: McpServer, client: EvolutionClient): void {
      server.registerTool(
        "restart_instance",
        {
          title: "Restart Instance",
          description: "Restart the pinned WhatsApp instance (reconnects without logging out).",
          inputSchema: {},
        },
        async () => {
          try {
            const data = await client.post(`/instance/restart/${client.instanceName}`, {});
            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;
          }
        }
      );
  • Registration call that wires up the restart_instance tool to the MCP server and Evolution client.
    registerRestartInstance(server, client);
  • Import of the registerRestartInstance function from the restart-instance module.
    import { registerRestartInstance } from "./restart-instance.js";
  • The getter 'instanceName' on EvolutionClient used in the restart handler to build the API path.
    get instanceName(): string {
      return this.instance;
    }
  • The 'post' method on EvolutionClient used by the restart_instance handler to call the Evolution API.
    async post<T = unknown>(path: string, body: unknown): Promise<T> {
      return this.request<T>("POST", path, body);
    }
Behavior3/5

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

Discloses the key behavior (reconnects without logging out) but lacks details on prerequisites, side effects (e.g., chat state preservation), or error conditions. With no annotations, more behavioral context is needed.

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?

Single sentence, front-loaded with action, no redundant words. Every part contributes value.

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 no output schema or annotations, the description is minimal. It covers the core purpose but lacks completeness on implications (e.g., effect on ongoing operations, error handling).

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

Parameters4/5

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

No parameters exist, and schema coverage is 100%. Description adds no parameter info, which is acceptable. Baseline score for zero-parameter tool is 4.

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?

Clearly states the action ('Restart'), the resource ('pinned WhatsApp instance'), and a key behavioral distinction ('reconnects without logging out'). Differentiates from sibling tools like logout_instance.

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?

Implies usage for reconnecting without full logout, but no explicit guidance on when to use versus alternatives like connection_state or logout_instance.

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