If you're using this tools to generate income, consider supporting its development by becoming a Patreon member!
Your support helps ensure the library stays maintained and receives regular updates!
ARM & AMD Architecture along with MCP SupportDownload:
@aldinokemal2104/n8n-nodes-gowa -> Installv6<binary> rest instead of <binary>./whatsapp rest instead of ~~./whatsapp~~<binary> mcp./whatsapp mcpv7v8/devices for managing multiple devicesX-Device-Id header, ordevice_id query parameter/ws?device_id=<id> to scope WebSocket to a specific devicedevice_id field identifying which
device received the event:```json
{
"event": "message",
"device_id": "628123456789@s.whatsapp.net",
"payload": { ... }
}
```
@phoneNumberHello @628974812XXXX, @628974812XXXX@phone in message textmentions field to mention users without visible @ in message@everyone to automatically mention ALL group participants--os=Chrome or --os=MyApplication--basic-auth=kemal:secret,toni:password,userName:secretPassword, or you can simplify-b=kemal:secret,toni:password,userName:secretPassword--base-path="/gowa" (allows deployment under a specific path like /gowa/sub/path)--port 8000--debug true--autoreply="Don't reply this message"--auto-mark-read=true (automatically marks incoming messages as read)--auto-download-media=false (disable automatic media downloads, default: true)--auto-reject-call=true or WHATSAPP_AUTO_REJECT_CALL=true (see Webhook Payload for call events)--presence-on-connect=unavailable or WHATSAPP_PRESENCE_ON_CONNECT=unavailableavailable — mark as online (suppresses phone notifications)unavailable — register pushname without going online (default, preserves phone notifications)none — skip presence entirely (pushname won't be registered, contacts may see "-" as name)--presence-pulse-enabled=true or WHATSAPP_PRESENCE_PULSE_ENABLED=true (default: true)--presence-pulse-interval=24h controls how often each connected device is pulsed--presence-pulse-duration=5m controls how long the account stays available before returning to unavailable--webhook="http://yourwebhook.site/handler", or you can simplify-w="http://yourwebhook.site/handler"PATCH /devices/:device_id/webhook with {"webhook_url": "https://device-webhook.site/handler"}GET /devices/:device_id/webhook--webhook)"" via PATCH to clear and use global webhooksecret.You may modify this by using the option below:
- --webhook-secret="secret"
- Webhook Payload Documentation
For detailed webhook payload schemas, security implementation, and integration examples,
see Webhook Payload Documentation
- Webhook Event Filtering
You can filter which events are forwarded to your webhook using:
- --webhook-events="message,message.ack" (comma-separated list)
- Or environment variable: WHATSAPP_WEBHOOK_EVENTS=message,message.ack
Available Webhook Events:
| Event | Description |
|---|---|
message |
Text, media, contact, location messages |
message.reaction |
Emoji reactions to messages |
message.revoked |
Deleted/revoked messages |
message.edited |
Edited messages |
message.ack |
Delivery and read receipts |
message.deleted |
Messages deleted for the user |
chat_presence |
Typing and recording indicators from contacts |
group.participants |
Group member join/leave/promote/demote events |
group.joined |
You were added to a group |
label.edit |
WhatsApp label metadata changed |
label.association |
Label applied to or removed from a chat |
newsletter.joined |
You subscribed to a newsletter/channel |
newsletter.left |
You unsubscribed from a newsletter |
newsletter.message |
New message(s) posted in a newsletter |
newsletter.mute |
Newsletter mute setting changed |
call.offer |
Incoming call received |
If not configured (empty), all events will be forwarded. - Webhook TLS Configuration
If you encounter TLS certificate verification errors when using webhooks (e.g., with Cloudflare tunnels or self-signed certificates):
tls: failed to verify certificate: x509: certificate signed by unknown authority
You can disable TLS certificate verification using:
- --webhook-insecure-skip-verify=true
- Or environment variable: WHATSAPP_WEBHOOK_INSECURE_SKIP_VERIFY=true
Security Warning: This option disables TLS certificate verification and should only be used in: - Development/testing environments - Cloudflare tunnels (which provide their own security layer) - Internal networks with self-signed certificates
For production environments, it's strongly recommended to use proper SSL certificates (e.g., Let's Encrypt) instead of disabling verification.
You can configure the application using either command-line flags (shown above) or environment variables. Configuration can be set in three ways (in order of priority):
.env file (lowest priority)You can configure the application using environment variables. Configuration can be set in three ways (in order of priority):
.env file (lowest priority)To use environment variables:
.env.example to .env in your project root (cp src/.env.example src/.env).env according to your needs| Variable | Description | Default | Example |
|---|---|---|---|
APP_PORT |
Application port | 3000 |
APP_PORT=8080 |
APP_HOST |
Host address to bind the server | 0.0.0.0 |
APP_HOST=127.0.0.1 |
APP_DEBUG |
Enable debug logging | false |
APP_DEBUG=true |
APP_OS |
OS name (device name in WhatsApp) | GOWA |
APP_OS=MyApp |
APP_BASIC_AUTH |
Basic authentication credentials | - | APP_BASIC_AUTH=user1:pass1,user2:pass2 |
APP_BASE_PATH |
Base path for subpath deployment | - | APP_BASE_PATH=/gowa |
APP_TRUSTED_PROXIES |
Trusted proxy IP ranges for reverse proxy | - | APP_TRUSTED_PROXIES=0.0.0.0/0 |
DB_URI |
Database connection URI | file:storages/whatsapp.db |
DB_URI=postgres://user:pass@host/db |
DB_KEYS_URI |
Optional database URI for encryption/session key cache. Leave blank to use DB_URI; avoid in-memory storage in production because restarts can lose WhatsApp session state. |
- | DB_KEYS_URI=file:storages/whatsapp-keys.db?_foreign_keys=on |
CHAT_STORAGE_MAX_OPEN_CONNS |
Max concurrent SQLite connections for chat storage | 5 |
CHAT_STORAGE_MAX_OPEN_CONNS=10 |
WHATSAPP_AUTO_REPLY |
Auto-reply message | - | WHATSAPP_AUTO_REPLY="Auto reply message" |
WHATSAPP_AUTO_MARK_READ |
Auto-mark incoming messages as read | false |
WHATSAPP_AUTO_MARK_READ=true |
WHATSAPP_AUTO_DOWNLOAD_MEDIA |
Auto-download media from incoming messages | true |
WHATSAPP_AUTO_DOWNLOAD_MEDIA=false |
WHATSAPP_AUTO_REJECT_CALL |
Auto-reject incoming WhatsApp calls | false |
WHATSAPP_AUTO_REJECT_CALL=true |
WHATSAPP_WEBHOOK |
Webhook URL(s) for events (comma-separated) | - | WHATSAPP_WEBHOOK=https://webhook.site/xxx |
WHATSAPP_WEBHOOK_SECRET |
Webhook secret for validation | secret |
$ claude mcp add go-whatsapp-web-multidevice \
-- python -m otcore.mcp_server <graph>