ClawPhone - Job Queue MCP Server for OpenClaw Agents

ClawPhone is a centralized job queue MCP (Model Context Protocol) server for OpenClaw agents. It enables multiple isolated OpenClaw instances running on different machines to communicate and delegate jobs to each other seamlessly.

The Problem

If you run multiple OpenClaw instances on different machines (like I do - Lisa on my main workstation, Nimpho on a server, Postino on another box), you might want them to share work. Each agent can handle local tasks, but how do you delegate jobs to other agents?

That's where ClawPhone comes in.

Architecture

ClawPhone implements a centralized architecture:

┌─────────────┐     ┌─────────────────┐     ┌─────────────┐
│ OpenClaw    │     │  MCP Server    │     │ OpenClaw    │
│ Lisa   ─────┼────►│  (Central)      │◄────┼─   Nimpho   │
│             │ MCP │                 │◄────┤             │
└─────────────┘     └────────┬────────┘     └─────────────┘
                             │
                    Webhook (HTTPS)

How It Works

  • One central MCP server - Can run on any server (one of the instances or a dedicated box)
  • All OpenClaw instances connect to this MCP server via MCP protocol
  • Jobs are posted from any instance to any other instance via MCP
  • Notifications are sent via HTTPS webhooks with verify=False

Features

Central Job Queue

A single MCP server handles job requests from all connected OpenClaw instances. Jobs can be targeted to specific agents or any available agent.

Agent Registry

Each OpenClaw instance registers with ClawPhone, providing its webhook URL for receiving job notifications. This allows dynamic job routing based on agent availability.

HTTPS Webhooks

When a job is assigned, ClawPhone notifies the target agent via HTTPS webhook. The webhook includes all job details, allowing the receiving agent to process the job immediately.

Bearer Token Authentication

Secure communication between all components with bearer token authentication. Each agent has its own token, and optionally a global API token for server administration.

Auto-Retry Mechanism

Unclaimed jobs are automatically retried at increasing intervals: 1 minute → 2 minutes → 5 minutes → 10 minutes. This ensures jobs eventually get processed even if an agent is temporarily unavailable.

SQLite Storage

Simple and reliable persistent queue storage using SQLite. No external database dependencies required.

Installation

# Clone the repository
git clone https://git.nexlab.net/lisa/clawphone.git /opt/clawphone

# Install dependencies
pip install fastapi uvicorn aiosqlite httpx cryptography

# Configure agents
cp agents.json.example agents.json
# Edit agents.json with your instance URLs and tokens

Configuration

Create agents.json with your agent configurations:

{
  "lisa": {
    "hook": "https://lisa.nexlab.net/hooks/agent",
    "token": "your-openclaw-hook-token"
  },
  "nimpho": {
    "hook": "https://nimpho.nexlab.net/hooks/agent", 
    "token": "your-openclaw-hook-token"
  },
  "postino": {
    "hook": "https://postino.nexlab.net/hooks/agent",
    "token": "your-openclaw-hook-token"
  }
}

Optionally set a global API token in .env:

CLAWPHONE_TOKEN=your_global_token

Running

# Manual start
python3 /opt/clawphone/mcp_server.py

# Or with the init script
sudo /etc/init.d/clawphone start

Use Cases

  • Distributed Processing: Run heavy tasks on more powerful machines
  • Geographic Distribution: Agents in different locations can collaborate
  • Redundancy: If one agent goes down, others can pick up its work
  • Specialization: Different agents can specialize in different tasks

Example Workflow

Imagine you have three agents:

  • Lisa (main workstation) - General purpose
  • Nimpho (server) - GPU-heavy tasks
  • Postino (another server) - Web scraping

When Lisa needs to generate a video, she can post a job to Nimpho. When Nimpho needs to fetch data from a website, it can delegate to Postino. All through the centralized ClawPhone MCP server!

Conclusion

ClawPhone enables a truly distributed AI agent ecosystem. By allowing multiple OpenClaw instances to communicate and share work, it opens up possibilities for scalable, resilient AI agent deployments.

Check out the project on GitLab: https://git.nexlab.net/lisa/clawphone