coderClaw

Group messages (WhatsApp web channel)

Goal: let CoderClaw sit in WhatsApp groups, wake up only when pinged, and keep that thread separate from the personal DM session.

Note: agents.list[].groupChat.mentionPatterns is now used by Telegram/Discord/Slack/iMessage as well; this doc focuses on WhatsApp-specific behavior. For multi-agent setups, set agents.list[].groupChat.mentionPatterns per agent (or use messages.groupChat.mentionPatterns as a global fallback).

What’s implemented (2025-12-03)

Config example (WhatsApp)

Add a groupChat block to ~/.coderclaw/coderclaw.json so display-name pings work even when WhatsApp strips the visual @ in the text body:

{
  channels: {
    whatsapp: {
      groups: {
        "*": { requireMention: true },
      },
    },
  },
  agents: {
    list: [
      {
        id: "main",
        groupChat: {
          historyLimit: 50,
          mentionPatterns: ["@?coderclaw", "\\+?15555550123"],
        },
      },
    ],
  },
}

Notes:

Activation command (owner-only)

Use the group chat command:

Only the owner number (from channels.whatsapp.allowFrom, or the bot’s own E.164 when unset) can change this. Send /status as a standalone message in the group to see the current activation mode.

How to use

  1. Add your WhatsApp account (the one running CoderClaw) to the group.
  2. Say @coderclaw … (or include the number). Only allowlisted senders can trigger it unless you set groupPolicy: "open".
  3. The agent prompt will include recent group context plus the trailing [from: …] marker so it can address the right person.
  4. Session-level directives (/verbose on, /think high, /new or /reset, /compact) apply only to that group’s session; send them as standalone messages so they register. Your personal DM session remains independent.

Testing / verification

Known considerations