Architecture

How EasyClaw orchestrates OpenClaw, ClawdBot, and MoltBot on your machine.

Overview

EasyClaw is a desktop wrapper that manages the OpenClaw stack as local services. It handles process lifecycle, configuration, and provides a dashboard UI — all without requiring any cloud infrastructure.

Messaging Apps
WhatsApp · Signal · iMessage
MoltBot (channel bridges)
↓ WebSocket v3
OpenClaw Gateway (router + auth)
ClawdBot (AI agent)
AI Provider APIs
Anthropic · OpenAI · Google · OpenRouter

Components

OpenClaw Gateway

The central router. Listens on a local port (default 3777), authenticates connections via bearer tokens, and routes messages between bots and channels. Exposes a WebSocket v3 endpoint.

ClawdBot

The AI agent. Connects to OpenClaw via WebSocket, receives messages, calls AI provider APIs, and streams responses back. Manages skills (Notes, Reminders, etc.) as tool calls.

MoltBot

The channel bridge. Connects messaging platforms (WhatsApp, Signal, iMessage) to OpenClaw. Each channel runs as a separate adapter within MoltBot.

EasyClaw (this app)

The desktop wrapper. Installs dependencies, manages process lifecycle (start, stop, restart), persists configuration, and provides a dashboard UI via Tauri.

WebSocket v3 Protocol

All communication between bots and the OpenClaw gateway uses WebSocket frames with a JSON envelope. The v3 protocol supports streaming via delta events.

Sending a message

{
  "type": "chat.send",
  "channel": "whatsapp",
  "to": "user-id",
  "content": "Hello from ClawdBot!",
  "metadata": { "stream": true }
}

Receiving a stream

When stream: true, the gateway sends incremental delta frames followed by a final frame:

// Delta frame (partial)
{
  "type": "chat.delta",
  "id": "msg-abc",
  "content": "Here's what"
}

// Final frame (complete)
{
  "type": "chat.final",
  "id": "msg-abc",
  "content": "Here's what I found in your notes..."
}

Authentication

Bots authenticate to the gateway with a bearer token set in openclaw.json. The token is generated during setup and stored locally.

// WebSocket connection header
Authorization: Bearer <gateway-token>

Process Management

EasyClaw spawns each component as a child process and monitors health via heartbeat pings. If a process crashes, EasyClaw restarts it automatically. The dashboard shows real-time status for each service.