Add whatsapp

From Geralt2026/RAG-learning · View interactive version

Add whatsapp is an AI agent skill from the GitHub repository Geralt2026/RAG-learning. Add WhatsApp as a communication channel for NanoBob.

How to use this skill

Skill file

/add-whatsapp - WhatsApp Channel Skill

Purpose

Add WhatsApp as a communication channel for NanoBob.

Prerequisites

What This Skill Does

  1. Creates src/channels/whatsapp.ts with WhatsApp channel implementation
  2. Adds import to src/channels/index.ts
  3. Sets up authentication flow using Baileys library
  4. Creates authentication storage in store/auth/

Usage

Inside the claude CLI, run:

/add-whatsapp

Then follow prompts to:

  1. Enter the WhatsApp number for the bot
  2. Scan the QR code displayed
  3. Wait for authentication to complete
  4. Register WhatsApp groups

Implementation Details

Channel File: `src/channels/whatsapp.ts`

import { registerChannel, ChannelOpts } from './registry.js';
import makeWASocket from '@whiskeysockets/baileys';

export class WhatsAppChannel implements Channel {
  // Implementation using Baileys library
  // Handles WhatsApp message reception and sending
  // Manages authentication state
}

registerChannel('whatsapp', (opts: ChannelOpts) => {
  // Check for auth credentials
  return new WhatsAppChannel(opts);
});

Dependencies

Add to package.json:

"@whiskeysockets/baileys": "^6.7.0"

Authentication

Credentials stored in store/auth/whatsapp.json

Post-Installation

  1. Run npm install to install new dependencies
  2. Run npm run build to compile TypeScript
  3. Run authentication flow
  4. Restart NanoBob
  5. Use @Bob in your WhatsApp chats
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.