feat(v2): add native WhatsApp adapter using Baileys v6

Direct ChannelAdapter implementation — no Chat SDK bridge.
Ports v1 infrastructure: getMessage fallback, outgoing queue,
group metadata cache, LID-to-phone mapping, auto-reconnect.
Auth via pairing code (WHATSAPP_PHONE_NUMBER) or QR code.

Text messaging only (MVP). Not yet implemented:
- File/image attachments (send and receive)
- Edit message, delete message
- Reactions
- Bot echo filtering (own messages loop back as inbound)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Gabi Simons
2026-04-13 14:53:59 +00:00
parent d16755eabc
commit c303b6eb14
4 changed files with 1436 additions and 8 deletions

View File

@@ -34,10 +34,14 @@
"@chat-adapter/whatsapp": "^4.24.0",
"@onecli-sh/sdk": "^0.3.1",
"@resend/chat-sdk-adapter": "^0.1.1",
"@types/qrcode": "^1.5.6",
"@whiskeysockets/baileys": "^6.7.21",
"better-sqlite3": "11.10.0",
"chat": "^4.24.0",
"chat-adapter-imessage": "^0.1.1",
"cron-parser": "5.5.0"
"cron-parser": "5.5.0",
"pino": "^9.6.0",
"qrcode": "^1.5.4"
},
"devDependencies": {
"@eslint/js": "^9.35.0",