sessions
WhatsApp session management
Create a new WhatsApp session
Create a new WhatsApp session
List all sessions
List all sessions
Get session by ID
Get session by ID
Delete a session
Delete a session
Get the tunable configuration for a session
Get the tunable configuration for a session
Update the tunable configuration for a session
Merges the supplied keys into the session config; omitted keys are left unchanged and an explicit null clears a key back to its default. No restart is required or performed. `autoRejectCalls` is re-read on every incoming call, so it applies immediately; the two reconnect settings are read once per start and therefore apply on the next start.
Start a session and initialize WhatsApp connection
Start a session and initialize WhatsApp connection
Stop a session and disconnect WhatsApp
Stop a session and disconnect WhatsApp
Log out of WhatsApp (unlinks this device) and stop the session
Attempts an engine-native unlink of this companion device, then tears the session down locally. `200` means the engine-native unlink operation completed AND the required local credential cleanup completed — for Baileys a valid companion identity, an acknowledged `remove-companion-device` IQ response, and removal of the on-disk auth dir; for whatsapp-web.js the native `Client.logout()` promise settled. `200` is NOT an independent observation that the handset UI no longer shows the linked device. Because a completed unlink wipes the stored credentials, reconnecting after a `200` always requires a fresh QR scan or pairing code.
Force-kill a stuck session (SIGKILL its wedged engine, then tear it down)
Force-kill a stuck session (SIGKILL its wedged engine, then tear it down)
Get QR code for session authentication
Get QR code for session authentication
Request an 8-char pairing code to link via phone number (alternative to QR)
Request an 8-char pairing code to link via phone number (alternative to QR)
Get all groups for a session
Get all groups for a session
Get active chats for a session
Get active chats for a session
Mark a chat as read/seen
Mark a chat as read/seen
Subscribe to a chat's presence
Asks WhatsApp to start reporting who is online or typing in this chat. Updates arrive as the `presence.update` webhook and socket event — there is no synchronous answer, because presence cannot be queried from either engine, only received.
Set the account's own global presence (appear online or offline)
Publishes whether this account appears online. WhatsApp routes notifications away from the phone while a linked device announces itself online, so a headless bot that never goes offline suppresses the phone's own alerts — set `available: false` to hand them back.
Read a chat's last reported presence
Serves the most recent report received since the chat was subscribed. Returns `null` when nothing has been reported — either the chat was never subscribed, or nothing has changed since. That is a normal state, not a missing resource, so it is `200` with a null body rather than a `404`.
Mark a chat as unread
Mark a chat as unread
Delete every message in a chat, keeping the chat itself
Delete every message in a chat, keeping the chat itself
Archive or unarchive a chat
Archive or unarchive a chat
Mute or unmute a chat
Mute or unmute a chat
Pin or unpin a chat at the top of the chat list
Pin or unpin a chat at the top of the chat list
Delete a chat from the chat list (e.g. a group you have left)
Delete a chat from the chat list (e.g. a group you have left)
Send a typing/recording presence indicator to a chat (or clear it with 'paused')
Send a typing/recording presence indicator to a chat (or clear it with 'paused')
Get session statistics for multi-session monitoring
Get session statistics for multi-session monitoring