WazoneIndia REST API

Manage multiple WhatsApp client sessions and dispatch rich interactive messaging types including lists, reply buttons, carousels, and polls.

⚡ Dynamic Playground Helper
API Key: -
API Token: -

🔒 Authentication & API Credentials

Each WhatsApp session has its own unique, deterministic credentials that are displayed in the Device Manager dashboard card.

Pass your credentials via one of the following methods:

  • Header: x-api-key: wz_key_xxxx or Authorization: Bearer wz_key_xxxx
  • Query parameter: ?apiKey=wz_key_xxxx or ?token=wz_tok_xxxx

Backward Compatibility Note: Authorization checks are graceful; if credentials are not supplied, the request is allowed (with a console warning) to avoid breaking local service scripts.

GET /api/sessions
List all configured WhatsApp sessions
Request Headers
HeaderRequiredDescription
x-api-keyNoYour API Key or Token (graceful bypass if missing)
Copy cURL Command
cURL
Response (200 Success)
JSON
{ "success": true, "sessions": [ { "sessionId": "default", "connected": true, "status": "connected", "qrAvailable": false, "pairingCode": null, "apiKey": "wz_key_9a8b...", "apiToken": "wz_tok_f8d7...", "phoneNumber": "919843350000", "jid": "919843350000@s.whatsapp.net", "pushName": "Admin Panel", "platform": "smba" } ], "total": 1 }
POST /api/connect-qr
Initialize a session and generate a QR code
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringUnique identifier for the WhatsApp session to create/start
Copy cURL Command
cURL
Response (200 Success)
JSON
{ "success": true, "connected": false, "qr": "2@...", "qrDataUrl": "data:image/png;base64,...", "message": "QR code ready" }
GET /api/qr/:sessionId
Retrieve the current QR authentication state
Copy cURL Command
cURL
POST /api/connect
Link WhatsApp via an 8-character pairing code
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringUnique identifier for the session
phoneNumberRequiredstringMobile number including country code (e.g. "919843350000")
Copy cURL Command
cURL
Response (200 Success)
JSON
{ "success": true, "message": "Open WhatsApp -> Linked Devices -> Link with phone number and enter pairing code", "pairingCode": "ABC123XY", "phoneNumber": "919843350000" }
GET /api/check-status/:sessionId
Fetch connection details and status
Copy cURL Command
cURL
POST /api/send (Text)
Send a plain text message
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringID of the sending device session
numberRequiredstringRecipient phone number (e.g. "919843350000" or group JID)
typeRequiredstringSet this to "text"
messageRequiredstringText content of the message
Copy cURL Command
cURL
Response (200 Success)
JSON
{ "success": true, "message": "Message sent successfully", "messageId": "3EB04D368C1C" }
POST /api/send (Media)
Send image messages with captions
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringSending session ID
numberRequiredstringRecipient phone number
typeRequiredstringSet this to "image"
mediaUrlRequiredstringPublic direct link to image asset
messagestringCaption text below the media
Copy cURL Command
cURL
POST /api/send (Document)
Send document files (PDF, DOCX, ZIP, etc.)
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringSending session ID
numberRequiredstringRecipient phone number
typeRequiredstringSet this to "document"
mediaUrlRequiredstringPublic direct link to the document
messagestringOptional caption text
fileNamestringThe name displayed for the file (e.g. "Invoice.pdf")
mimetypestringMime type of document (defaults to "application/octet-stream")
Copy cURL Command
cURL
POST /api/send (Buttons)
Send quick reply or call-to-action buttons
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringSending session ID
numberRequiredstringRecipient phone number
typeRequiredstringSet this to "button"
optionsRequiredobjectButton settings containing text, footer, and buttons array
Copy cURL Command
cURL
POST /api/send (List)
Send interactive select menus (List Messages)
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringSending session ID
numberRequiredstringRecipient phone
typeRequiredstringSet to "list"
optionsRequiredobjectList data: title, text, footer, buttonText, and sections
Copy cURL Command
cURL
POST /api/send (Poll)
Send WhatsApp interactive polls
JSON Body Parameters
FieldTypeDescription
sessionIdRequiredstringSending session ID
numberRequiredstringRecipient JID / number
typeRequiredstringSet to "poll"
optionsRequiredobjectPoll options: name (question) and values (options array)
Copy cURL Command
cURL
GET /api/devices/:sessionId
Query active linked client devices from WhatsApp servers
Copy cURL Command
cURL
GET /api/groups/:sessionId
Fetch JIDs and metadata for joined groups
Copy cURL Command
cURL
POST /api/disconnect
Disconnect socket link without logging out
Copy cURL Command
cURL
POST /api/reconnect
Trigger socket reconnection
Copy cURL Command
cURL
POST /api/remove-session
Disconnect session and delete credential files
Copy cURL Command
cURL
POST /api/logout
Perform full logout (de-authorizes instance on WhatsApp)
Copy cURL Command
cURL