Your own personal AI assistant. Any OS. Any Platform. The lobster way. 🦞
Go to file
Arne Moor a9f3527c4c feat: add cross-provider Claude session sharing
Implements identity mapping to allow linking WhatsApp, Telegram, and Twilio
identities for shared Claude conversation sessions across providers.

Core Features:
- Identity mapping storage in ~/.clawdis/identity-map.json
- Session ID normalization for unified sessions
- CLI commands for managing identity mappings
- Full backwards compatibility (opt-in feature)

New Identity Module (src/identity/):
- types.ts: Type definitions for identity mappings
- storage.ts: CRUD operations for identity persistence
- normalize.ts: Session ID normalization logic
- Comprehensive test coverage (29 tests passing)

CLI Commands (src/commands/identity.ts):
- identity link: Link multiple provider identities
- identity list: Show all identity mappings
- identity show: Display specific mapping details
- identity unlink: Remove identity mapping
- Input validation for E.164 phone numbers and Telegram usernames
- JSON output support for list/show commands

Session Integration:
- Made deriveSessionKey() async to support identity lookups
- Updated all callers: auto-reply, agent command, web provider
- Group conversations excluded from identity mapping
- Provider detection based on ID format

Documentation:
- docs/session-sharing.md: Comprehensive user documentation
- Architecture overview and use cases
- CLI usage examples and troubleshooting guide

Test Coverage:
- src/identity/normalize.test.ts: 11 tests for normalization
- src/identity/storage.test.ts: 18 tests for storage operations
- 100% coverage of identity module functionality

Files Changed:
- 10 new files (identity module, CLI, docs, tests)
- 5 modified files (sessions, CLI integration, auto-reply)

Build Status:
- All tests passing (29/29)
- Zero TypeScript errors
- Ready for production use
2025-12-05 23:02:01 +01:00
.github/workflows ci: fix node path and lint warnings 2025-11-25 12:08:08 +01:00
bin feat: same-phone mode with echo detection and configurable marker 2025-11-29 04:52:21 +00:00
docs feat: add cross-provider Claude session sharing 2025-12-05 23:02:01 +01:00
src feat: add cross-provider Claude session sharing 2025-12-05 23:02:01 +01:00
test/mocks web: send read receipts for inbound messages 2025-11-25 06:36:22 +01:00
.env.example Add warelay CLI with Twilio webhook support 2025-11-24 11:23:15 +01:00
.gitignore Ignore .pnpm-store 2025-11-25 12:11:39 +01:00
.npmrc chore: approve build scripts 2025-11-25 20:11:36 +01:00
AGENTS.md branding: default to clawdis paths and launchd label 2025-12-04 18:01:30 +00:00
biome.json chore: format to 2-space and bump changelog 2025-11-26 00:53:53 +01:00
CHANGELOG.md branding: default to clawdis paths and launchd label 2025-12-04 18:01:30 +00:00
CLAUDE.md Document exclamation mark escaping workaround for Claude Code 2025-12-02 06:52:56 +00:00
LICENSE Initial commit 2025-11-24 11:16:47 +01:00
package.json feat: add telegram provider with CLI integration 2025-12-05 18:59:38 +01:00
pnpm-workspace.yaml chore: approve build scripts 2025-11-25 20:11:36 +01:00
README-header.png docs: add README header image 2025-11-25 14:29:21 +01:00
README.md CLI: add agent command for direct agent runs 2025-12-04 17:54:20 +00:00
tsconfig.json web: add heartbeat and bounded reconnect tuning 2025-11-26 02:34:43 +01:00

🦞 CLAWDIS — WhatsApp Gateway for AI Agents

CLAWDIS

EXFOLIATE! EXFOLIATE!

CI status npm version MIT License

CLAWDIS (formerly Warelay) is a WhatsApp-to-AI gateway. Send a message, get an AI response. It's like having a genius lobster in your pocket 24/7.

┌─────────────┐      ┌──────────┐      ┌─────────────┐
│  WhatsApp   │ ───▶ │ CLAWDIS  │ ───▶ │  AI Agent   │
│  (You)      │ ◀─── │  🦞⏱️💙   │ ◀─── │ (Tau/Claude)│
└─────────────┘      └──────────┘      └─────────────┘

Why "CLAWDIS"?

CLAWDIS = CLAW + TARDIS

Because every space lobster needs a time-and-space machine. The Doctor has a TARDIS. Clawd has a CLAWDIS. Both are blue. Both are chaotic. Both are loved.

Features

  • 📱 WhatsApp Integration — Personal WhatsApp Web or Twilio
  • 🤖 AI Agent Gateway — Works with Tau/Pi, Claude CLI, Codex, Gemini
  • 💬 Session Management — Per-sender conversation context
  • 🔔 Heartbeats — Periodic check-ins for proactive AI
  • 👥 Group Chat Support — Mention-based triggering
  • 📎 Media Support — Images, audio, documents, voice notes
  • 🎤 Voice Transcription — Whisper integration
  • 🔧 Tool Streaming — Real-time display (💻📄✍️📝)

Quick Start

# Install
npm install -g warelay  # (still warelay on npm for now)

# Link your WhatsApp
clawdis login

# Send a message
clawdis send --to +1234567890 --message "Hello from the CLAWDIS!"

# Talk directly to the agent (no WhatsApp send)
clawdis agent --to +1234567890 --message "Ship checklist" --thinking high

# Start the relay
clawdis relay --verbose

Configuration

Create ~/.clawdis/clawdis.json:

{
  inbound: {
    allowFrom: ["+1234567890"],
    reply: {
      mode: "command",
      command: ["tau", "--mode", "json", "{{BodyStripped}}"],
      session: {
        scope: "per-sender",
        idleMinutes: 1440
      },
      heartbeatMinutes: 10
    }
  }
}

Documentation

Clawd

CLAWDIS was built for Clawd, a space lobster AI assistant. See the full setup in docs/clawd.md.

Providers

clawdis login      # Scan QR code
clawdis relay      # Start listening

Twilio

# Set environment variables
export TWILIO_ACCOUNT_SID=...
export TWILIO_AUTH_TOKEN=...
export TWILIO_WHATSAPP_FROM=whatsapp:+1234567890

clawdis relay --provider twilio

Commands

Command Description
clawdis login Link WhatsApp Web via QR
clawdis send Send a message
clawdis agent Talk directly to the agent (no WhatsApp send)
clawdis relay Start auto-reply loop
clawdis status Show recent messages
clawdis heartbeat Trigger a heartbeat

Credits

  • Peter Steinberger (@steipete) — Creator
  • Mario Zechner (@badlogicgames) — Tau/Pi, security testing
  • Clawd 🦞 — The space lobster who demanded a better name

License

MIT — Free as a lobster in the ocean.


"We're all just playing with our own prompts."

🦞💙