Introduction

This API provides a robust interface for integrating WhatsApp messaging capabilities into your applications. Built on WhatsApp Web's infrastructure, it enables automated message sending, media sharing, and chat management.

Authentication

Authentication is handled through WhatsApp Web's QR code scanning mechanism. Follow these steps:

  1. Request the QR code from the /qr-code endpoint
  2. Scan the QR code using your WhatsApp mobile app
  3. Wait for the authentication confirmation

Get Authentication QR Code

GET /qr-code

Returns: PNG image of the QR code

Sending Messages

Send Text Message

POST /send-message
Parameter Type Required Description
number string Yes Recipient's phone number (with country code)
message string Yes Message content to send
{ "number": "1234567890", "message": "Hello from the API!" }

Media Handling

Send Media File

POST /send-media
Parameter Type Required Description
number string Yes Recipient's phone number
file file Yes Media file to send
caption string No Optional caption for the media

Connection Status

Check Connection Status

GET /status
{ "status": "connected", "info": { "pushname": "User Name", "wid": "1234567890@c.us" } }

Managing Chats

Get All Chats

GET /chats

Returns an array of chat objects containing chat information and messages.