Skip to main content
Glama
appleton

Eufy RoboVac MCP Server

by appleton

robovac_connect

Connect to your Eufy RoboVac using device credentials for manual setup, enabling control through the MCP server.

Instructions

Connect to your RoboVac using device credentials (manual setup)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
deviceIdYesThe device ID of your Eufy RoboVac
localKeyYesThe local key for your Eufy RoboVac
ipNoThe IP address of your Eufy RoboVac (optional, defaults to 192.168.1.100)

Implementation Reference

  • Handler logic for the robovac_connect tool. Attempts connection with provided IP or falls back to auto-discovery and default IP, using the initializeRoboVac helper.
    case "robovac_connect":
      // Auto-discover best IP if not provided or if connection fails
      let connectTargetIP = args?.ip as string | undefined;
      let connectSuccess = false;
    
      if (connectTargetIP) {
        connectSuccess = await this.initializeRoboVac(
          args?.deviceId as string,
          args?.localKey as string,
          connectTargetIP
        );
      }
    
      if (!connectSuccess) {
        console.error(
          "[DEBUG] Manual connection failed or no IP provided, trying auto-discovery..."
        );
        const discoveredIP = await this.discoverBestRoboVacIP();
    
        if (discoveredIP) {
          connectTargetIP = discoveredIP;
          connectSuccess = await this.initializeRoboVac(
            args?.deviceId as string,
            args?.localKey as string,
            connectTargetIP
          );
        }
      }
    
      // Fallback to default IP if still not successful
      if (!connectSuccess && !connectTargetIP) {
        connectTargetIP = "192.168.1.100";
        connectSuccess = await this.initializeRoboVac(
          args?.deviceId as string,
          args?.localKey as string,
          connectTargetIP
        );
      }
    
      return {
        content: [
          {
            type: "text",
            text: connectSuccess
              ? `RoboVac connected successfully at ${connectTargetIP}!`
              : `Failed to connect to RoboVac. ${
                  connectTargetIP
                    ? `Tried ${connectTargetIP} but connection failed.`
                    : ""
                } Check your device ID, local key, and network connection.`,
          },
        ],
        isError: !connectSuccess,
      };
  • Input schema and description for the robovac_connect tool, defined in the listTools response.
      name: "robovac_connect",
      description:
        "Connect to your RoboVac using device credentials (manual setup)",
      inputSchema: {
        type: "object",
        properties: {
          deviceId: {
            type: "string",
            description: "The device ID of your Eufy RoboVac",
          },
          localKey: {
            type: "string",
            description: "The local key for your Eufy RoboVac",
          },
          ip: {
            type: "string",
            description:
              "The IP address of your Eufy RoboVac (optional, defaults to 192.168.1.100)",
          },
        },
        required: ["deviceId", "localKey"],
      },
    },
  • Helper method that creates a new RoboVac instance with the given credentials and attempts to connect. Returns success boolean.
    private async initializeRoboVac(
      deviceId: string,
      localKey: string,
      ip?: string
    ): Promise<boolean> {
      try {
        this.robovac = new RoboVac({
          deviceId: deviceId,
          localKey: localKey,
          ip: ip || "192.168.1.100",
        });
        await this.robovac.connect();
        return true;
      } catch (error) {
        console.error("Failed to initialize RoboVac:", error);
        return false;
      }
  • Helper method for auto-discovering the best IP for a RoboVac device on the network, used as fallback in the connect handler.
    private async discoverBestRoboVacIP(): Promise<string | null> {
      try {
        console.error("[DEBUG] Auto-discovering RoboVac devices...");
        const devices = await this.networkDiscovery.discoverDevices();
    
        if (devices.length === 0) {
          console.error("[DEBUG] No devices found during auto-discovery");
          return null;
        }
    
        // Filter for likely RoboVac devices
        const likelyRoboVacs = devices.filter((device) => device.isLikelyRoboVac);
    
        if (likelyRoboVacs.length > 0) {
          const bestDevice = likelyRoboVacs[0]; // Take the first likely device
          console.error(
            `[DEBUG] Found likely RoboVac at ${bestDevice.ip} (MAC: ${bestDevice.mac}, Vendor: ${bestDevice.vendor})`
          );
          return bestDevice.ip;
        }
    
        // If no likely RoboVacs, try devices with port 6668 open
        const devicesWithPort6668 = devices.filter((device) =>
          device.ports.includes(6668)
        );
    
        if (devicesWithPort6668.length > 0) {
          const potentialDevice = devicesWithPort6668[0];
          console.error(
            `[DEBUG] Found potential RoboVac at ${potentialDevice.ip} with port 6668 open`
          );
          return potentialDevice.ip;
        }
    
        console.error("[DEBUG] No suitable RoboVac candidates found");
        return null;
      } catch (error) {
        console.error(
          `[DEBUG] Auto-discovery failed: ${(error as Error).message}`
        );
        return null;
      }
    }
Behavior2/5

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

No annotations are provided, so the description carries full burden. It mentions 'Connect' but doesn't disclose behavioral traits such as what happens on successful/failed connection, whether this establishes a persistent session, authentication requirements beyond credentials, or potential side effects. The description is minimal and lacks crucial operational context.

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 that front-loads the key information ('Connect to your RoboVac') and adds necessary context ('using device credentials (manual setup)'). There is zero waste, and every word earns its place.

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?

Given the complexity (a connection tool with no annotations and no output schema), the description is incomplete. It doesn't explain what the tool returns, error conditions, or behavioral outcomes. For a tool that likely establishes a critical session for other operations, more context is needed to guide effective use.

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?

Schema description coverage is 100%, so the schema already documents all parameters (deviceId, localKey, ip) with their types and descriptions. The description adds no additional parameter semantics beyond what's in the schema, such as where to find these credentials or format details. Baseline 3 is appropriate when schema does the heavy lifting.

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 ('Connect') and resource ('your RoboVac'), and specifies it's for 'manual setup' using 'device credentials'. However, it doesn't explicitly differentiate from sibling tools like 'robovac_auto_initialize' or 'robovac_connect_discovered', which likely offer alternative connection methods.

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 usage context ('manual setup') but doesn't explicitly state when to use this tool versus alternatives like 'robovac_auto_initialize' or 'robovac_connect_discovered'. It provides some guidance by mentioning it's for manual connection, but lacks clear exclusions or named alternatives.

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/appleton/sam'

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