add-whatsapp-cloud
Skill3 starsChanged 59 days agoMITView on GitHub
Add WhatsApp Business Cloud API channel via Chat SDK. Official Meta API.
- Reads credentials
We split this skill into the rules it gives an agent
4 rules. 1 is common, 1 is distinctive, and 2 are very specific to this project.
1
Common
Most of the 6 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 76
Update the callback URL in your Meta App dashboard (WhatsApp > Configuration) accordingly.
- Common: line 91
Add the WhatsApp product.
- Very specific: line 138
If you're in the middle of /setup, return to the setup flow now.
- Very specific: line 159
Adapter installed but nothing flows: Run pnpm exec vitest run src/channels/whatsapp-cloud-registration.test.ts — red means the barrel …
“Common” is measured: kept by at least 6 in 10 of the 6 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Add WhatsApp Cloud API Channel
Connect NanoClaw to WhatsApp via the official Meta WhatsApp Business Cloud API.
NanoClaw doesn't ship channels in trunk — this skill copies the WhatsApp Cloud
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.
Apply
1. Copy the adapter
Fetch the channels branch and copy the WhatsApp Cloud adapter into
src/channels/ (overwrite — the branch is canonical):
src/channels/whatsapp-cloud.ts
src/channels/whatsapp-cloud-registration.test.ts2. Register the adapter
Append the self-registration import to the channel barrel (skipped if the line is already present). This one line is the skill's only reach-in into core:
import './whatsapp-cloud.js';3. Install the adapter package
Pinned to an exact version — the supply-chain policy rejects ranges and latest:
@chat-adapter/whatsapp@4.29.04. Build and validate
Build guards the typed createChatSdkBridge(...) core call and proves the
dependency is installed — the import throws at evaluation if @chat-adapter/whatsapp
is missing or the barrel drifts:
pnpm run buildpnpm exec vitest run src/channels/whatsapp-cloud-registration.test.tswhatsapp-cloud-registration.test.ts imports the real channel barrel and asserts
the registry contains whatsapp-cloud — it goes red if the import line is deleted
or drifts, if the barrel fails to evaluate, or if @chat-adapter/whatsapp isn't
installed (the import throws), so it also covers the dependency from step 3.
End-to-end message delivery against a real WhatsApp Business number is verified manually once the service is running — see Next Steps and the webhook setup below.
Upgrading an existing install
Older copies of the adapter registered this bridge under the bare whatsapp key,
which collided with the native Baileys adapter. It now registers under a distinct
whatsapp-cloud instance (channelType stays whatsapp). Two consequences for an
install that ran the previous version:
- Webhook route moves from
/webhook/whatsappto/webhook/whatsapp-cloud. Update the callback URL in your Meta App dashboard (WhatsApp > Configuration) accordingly. - Chat SDK state namespace moves. Subscriptions in the
chat_sdk_*tables re-key under the new instance, so previously-subscribed threads may need to re-engage the bot.
Fresh installs need none of this.
Credentials
Meta app setup is human and interactive — these steps are prose, not directives (no parser can click through the Meta dashboard). A recipe rebuild produces a compiling, registered adapter that cannot receive a message until they're done.
- Go to Meta for Developers and create an app (type: Business).
- Add the WhatsApp product.
- Go to WhatsApp > API Setup:
- Note the Phone Number ID (not the phone number itself).
- Generate a permanent System User access token with
whatsapp_business_messagingpermission.
- Go to WhatsApp > Configuration:
- Set webhook URL:
https://your-domain/webhook/whatsapp-cloud. - Set a Verify Token (any random string you choose).
- Subscribe to webhook fields:
messages.
- Set webhook URL:
- Copy the App Secret from Settings > Basic.
Store the credentials
Capture the four values, then write them. prompt only asks and binds the
answer to a name; a separate directive consumes it — so the same prompts could
feed ncl or the OneCLI vault instead of .env by swapping only the consumer.
Here they go to .env (set-if-absent — a value you've already filled in is
never overwritten):
Paste the System User access token — WhatsApp > API Setup, with `whatsapp_business_messaging` permission.Paste the Phone Number ID — WhatsApp > API Setup (not the phone number itself).Paste the App Secret — Settings > Basic.Paste the Verify Token — the random string you set under WhatsApp > Configuration.WHATSAPP_ACCESS_TOKEN={{access_token}}
WHATSAPP_PHONE_NUMBER_ID={{phone_number_id}}
WHATSAPP_APP_SECRET={{app_secret}}
WHATSAPP_VERIFY_TOKEN={{verify_token}}Webhook server
The Chat SDK bridge automatically starts a shared webhook server on port 3000
(WEBHOOK_PORT to change it), handling /webhook/whatsapp-cloud. This port must be
publicly reachable for Meta to deliver events. Running locally, expose it with
ngrok (ngrok http 3000), a Cloudflare Tunnel, or a reverse proxy on a VPS —
the resulting public URL is the base for the webhook URL set under WhatsApp >
Configuration above.
Next Steps
If you're in the middle of /setup, return to the setup flow now.
Otherwise, run /manage-channels to wire this channel to an agent group.
Channel Info
- type:
whatsapp-cloud - terminology: WhatsApp Cloud API supports 1:1 conversations only (no group chats). Each conversation is with a phone number.
- how-to-find-id: The platform ID is the Phone Number ID from the Meta Business dashboard (not the phone number itself). Find it under WhatsApp > API Setup.
- supports-threads: no
- typical-use: Interactive 1:1 chat -- direct messages only
- default-isolation: Same agent group if you're the only person messaging the bot. Each additional person who messages gets their own conversation automatically, but they share the agent's workspace and memory -- use a separate agent group if you need information isolation between different contacts.
Troubleshooting
Meta's "Verify and save" fails on the webhook. Meta hits your URL with a challenge the moment you click, so the endpoint must already be publicly reachable at /webhook/whatsapp-cloud (shared webhook server, port 3000) and the service must be running with WHATSAPP_VERIFY_TOKEN set to exactly the string you typed under WhatsApp > Configuration. Start or restart the service first, then click verify.
Everything works for a day, then all calls 401. You stored the temporary token from WhatsApp > API Setup, which expires in ~24 hours. Create a System User under Business Settings → Users, grant it the app with whatsapp_business_messaging, generate a permanent token, and replace WHATSAPP_ACCESS_TOKEN.
Outbound messages are accepted but never delivered. Two Meta-side gates: while the app is in development mode you can only message numbers added to the recipient allowlist in API Setup; and free-form replies are only allowed within 24 hours of the user's last inbound message — outside that window you need an approved template. Also confirm WHATSAPP_PHONE_NUMBER_ID is the Phone Number ID, not the phone number itself.
Adapter installed but nothing flows. Run pnpm exec vitest run src/channels/whatsapp-cloud-registration.test.ts — red means the barrel import or the @chat-adapter/whatsapp install drifted, so re-run the Apply steps. If green, restart the service (see Next Steps) so the adapter and .env values are live.
Other versions7 projects use a version of this.
Word for word · 1
- prathish-ks/isthmus★ 2100% same
Edited · 6
- gavrielc/nanoclaw★ 31k92% same
- nanocoai/nanoclaw★ 31k92% same
- qwibitai/nanoclaw★ 31k92% same
- microsoft/amplifier-app-nanoclaw★ 462% same
- mcarmona1064-cell/clawbridge-codex★ 161% same
- ss2code/nanoclaw-ops★ 158% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
Used alongsideProjects with it also use add-iron-proxy, add-mattermost and 2 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
qwibitaiSkilladd-iron-proxy
Install or refresh Iron Proxy and its official Iron Control web console for NanoClaw. Use when selecting the Iron gateway, adding its management UI, configuring credentials and grants, or restoring the proxy, approval bridge, and agent guidance.
Also in 4 projects that use this
qwibitaiSkilladd-mattermost
Add a self-hosted or cloud Mattermost bot channel through the Chat SDK bridge, reusing a healthy server when available and linking to official server setup guidance when needed.
Also in 4 projects that use this
- +2 more from qwibitai
In this repository51 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- container/CLAUDE.mdCLAUDE.md
- add-anydocSkill
- add-atomic-chat-toolSkill
- add-clidashSkill
- add-codexSkill
- add-dashboardSkill
- add-deltachatSkill
- add-dial-numberSkill
- add-dialSkill
- add-dial-toolSkill
- add-discordSkill
- add-emacsSkill
- add-gchatSkill
- add-githubSkill
- add-imessageSkill
- add-karpathy-llm-wikiSkill
- add-linearSkill
- add-macos-statusbarSkill
- add-matrixSkill
- add-mnemonSkill
- add-ollama-providerSkill
- add-ollama-toolSkill
- add-opencodeSkill
- add-resendSkill
- add-rtkSkill
- add-signalSkill
- add-slackSkill
- add-tavily-toolSkill
- add-teamsSkill
- add-telegramSkill
- add-vercelSkill
- add-webexSkill
- add-wechatSkill
- add-whatsappSkill
- customizeSkill
- debugSkill
- init-first-agentSkill
- init-onecliSkill
- learnSkill
- manage-channelsSkill
- manage-mountsSkill
- migrate-from-openclawSkill
- migrate-from-v1Skill
- migrate-memorySkill
- migrate-nanoclawSkill
- migrate-slack-agentsSkill
- setupSkill
- update-nanoclawSkill
- update-skillsSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

