add-whatsapp
Add WhatsApp channel via native Baileys adapter. Direct connection — no Chat SDK bridge. Uses QR code or pairing code for authentication.
npx skills add nanocoai/nanoclaw --skill add-whatsapp --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
What it does
Adds a WhatsApp channel via the native Baileys adapter, establishing a direct WhatsApp Web connection without a Chat SDK bridge. It copies the adapter and related tests from the channels branch, registers the adapter in the channel index, installs exact-version dependencies, builds and runs tests, and provides an authentication flow using either a QR code or a pairing code. It enforces a number safety check before installation and adjusts environment variables (ASSISTANT_HAS_OWN_NUMBER) according to the chosen mode (dedicated or shared).
How it works
- Performs a required number safety check: if the user indicates a shared/personal number, it shows a warning and requires explicit confirmation to continue with a shared number; otherwise it asks which WhatsApp number to use (dedicated or shared).
- Under Apply, copies the adapter and its registration test from the channels branch, and copies the whatsapp-formatting container skill and related files.
- Registers the adapter by appending a single import line to src/channels/index.ts: "import './whatsapp.js';".
- Installs exact versions for dependencies: @whiskeysockets/baileys@7.0.0-rc.9, qrcode@1.5.4, @types/qrcode@1.5.6, pino@9.6.0.
- Builds the adapter and runs the integration test: "pnpm run build" and "pnpm exec vitest run src/channels/whatsapp-registration.test.ts". End-to-end verification is manual once service runs.
- Authenticate via linked-device method: choose between "qr" or "pairing-code"; provide the phone number when pairing-code; follow on-screen instructions to link. It streams the live QR or code, reports the linked number as bot_phone, and requires re-link if timeout or failure occurs.
- Writes ASSISTANT_HAS_OWN_NUMBER in .env to reflect the chosen mode (true for dedicated, false for shared). It also updates ASSISTANT_NAME if prompted and persists it in .env.
- Handles dedicated vs shared number behavior differences by adjusting messaging behavior and related environment flags accordingly.
- Includes troubleshooting guidance for expired handshakes, failed imports, or missing credentials, and provides procedures to fix or re-run steps.
When to use it
Use when you want to add a WhatsApp channel via the native Baileys adapter, with QR or pairing-code authentication, and you need explicit safety checks for number usage and environment configuration.
What it can touch
- src/channels/index.ts (appended import)
- package dependencies with exact versions:
- @whiskeysockets/baileys@7.0.0-rc.9
- qrcode@1.5.4
- @types/qrcode@1.5.6
- pino@9.6.0
- store/auth/creds.json (read to determine linked number; write to env as part of mode handling)
- .env (ASSISTANT_HAS_OWN_NUMBER and ASSISTANT_NAME)
- container/skills/whatsapp-formatting (copied for formatting rules)
Caveats
- Requires manual verification for end-to-end delivery with a real WhatsApp number after service runs.
- The authentication flow relies on linked-device pairing and may expire if QR/pairing-code times out.
- The skill copies artifacts from a separate channels branch; ensure branch access and branch integrity.
- The safety check warns about using a shared/personal number due to potential WhatsApp suspension risk; explicit confirmation is required to continue with shared mode.
- The workflow is designed to be idempotent; re-running applies idempotent directives and safe guards.
# Add WhatsApp Channel Adds WhatsApp support via the native Baileys adapter — a direct WhatsApp Web connection, no Chat SDK bridge. NanoClaw doesn't ship channels in trunk — this skill copies the WhatsApp adapter in from the `channels` branch. The mechanical steps under **Apply** carry `nc:` directive fences: an agent reads the prose and applies them, and a parser can apply them deterministically from the same document. Every directive is idempotent, so the whole skill is safe to re-run; anything a parser can't apply falls back to the prose beside it. ## Number safety check (required) Complete this check before running any install or authentication command. If the user already said they want to use their **shared**, **personal**, **main**, **existing**, or **everyday** WhatsApp number, treat it as a shared number and show the warning immediately. Do not ask the number-type question again. Otherwise, ask which WhatsApp number NanoClaw will use: ```nc:prompt number_mode validate:^(dedicated|shared)$ Which WhatsApp number will NanoClaw use? `dedicated` (recommended) — a separate number used only for NanoClaw (spare SIM, eSIM, or old phone). `shared` — your existing everyday / personal
- Number safety check (required)
- Apply
- 1. Copy the adapter and its registration test
- 2. Register the adapter
- 3. Install the adapter packages
- 4. Build and validate
- Authenticate
- Your personal chat number (dedicated number only)
- Dedicated vs personal number
- Assistant name
- Update path: existing install, flag unset
- Migration audit: spam-era group wirings
- Self-chat engagement (shared number only)
- Restart
What does the add-whatsapp skill do?
Add WhatsApp channel via native Baileys adapter. Direct connection — no Chat SDK bridge. Uses QR code or pairing code for authentication.
How do I install it?
Run `npx skills add nanocoai/nanoclaw --skill add-whatsapp --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From nanocoai/nanoclaw, a repository with 30,426 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.