REST API v1 • Production Ready

Wapix Developer Documentation

Wapix provides high-reliability, low-latency REST endpoints to programmatically send WhatsApp OTP codes, 1-on-1 transactional alerts, and bulk broadcast campaigns. Pair your WhatsApp number once via QR code, generate an API key, and integrate directly with your backend in minutes.

Base URL
https://api.wapix.sbs/api/v1
Auth Method
api_key (JSON Body)
P95 Latency
< 120ms Instant
Pricing Model
Prepaid (From ₹0.25)
01

5-Minute Quickstart Guide

Get up and running with Wapix in three straightforward steps:

1

Top Up Your Prepaid Balance

Register your account at /signup. Navigate to Add Credit and add wallet money (minimum ₹50) with instant Cashfree checkout (UPI, GPay, PhonePe, Cards).

2

Pair Your WhatsApp Number & Create API Key

Open Dashboard, click Start Session, and scan the QR code using WhatsApp > Linked Devices on your mobile phone. Once paired, switch to the API Keys tab to generate your secret key.

3

Make an API Call

Send a JSON POST request to /api/v1/send/otp or /api/v1/send/message with your API key and recipient number. The message arrives instantly on WhatsApp!

02

Authentication & API Keys

All public dispatch endpoints require your secret API key passed in the request body under the field api_key. Management actions performed through the browser use JWT authentication via the standard Authorization: Bearer <token> header.

Sample / Test API KeyDemo Token (Do Not Use)
WAPIX.d94a6e8b23f1c4e708a5521b

Keys always begin with the WAPIX. prefix followed by a unique 24-character hexadecimal security hash.

vpn_keyHow to Generate Your Production API Key

1
Open Console

Head to the dashboard and ensure your WhatsApp session is started & paired.

2
Create New Key

Go to the API Keys tab, enter a label (e.g. "Backend Server"), and click Generate.

3
Store in .env

Save it in server environment variables (WAPIX_API_KEY). Never expose client-side.

03

Send OTP API

₹0.25 / OTP

Dispatches high-priority authentication codes directly to any valid WhatsApp number. The system concatenates your custom text prefix with the numeric OTP code. If delivery cannot be completed due to gateway downtime or invalid recipient, the ₹0.25 fee is automatically refunded to your wallet.

POST/api/v1/send/otpContent-Type: application/json
FieldTypeRequiredDescription
servicestringYesMust be exactly "otp"
whatsaap_numberstringYesPhone number with country code without plus sign (e.g. 919876543210)
otpstring | numberYesVerification code (e.g. "492018")
textstringYesMessage prefix (e.g. "Your verification code is:")
api_keystringYesYour secret Wapix API key
curl -X POST https://api.wapix.sbs/api/v1/send/otp \
  -H "Content-Type: application/json" \
  -d '{
    "service": "otp",
    "whatsaap_number": "919876543210",
    "otp": "492018",
    "text": "Your verification code is:",
    "api_key": "YOUR_WAPIX_API_KEY"
  }'
200 OK ResponseWallet charged ₹0.25
{
  "success": true,
  "message": "OTP message dispatched successfully",
  "data": {
    "chatId": "919876543210@c.us",
    "id": "false_919876543210@c.us_3EB0...",
    "timestamp": 1727914800
  }
}
04

Send Message API

₹0.45 / Message

Send 1-on-1 notifications, invoices, order updates, customer service replies, or rich messages to any WhatsApp user globally.

POST/api/v1/send/messageContent-Type: application/json
curl -X POST https://api.wapix.sbs/api/v1/send/message \
  -H "Content-Type: application/json" \
  -d '{
    "service": "message",
    "whatsaap_number": "919876543210",
    "text": "Hello Arpit, your order #89201 has been dispatched!",
    "api_key": "YOUR_WAPIX_API_KEY"
  }'
05

Send Bulk Campaign API

₹0.50 / Recipient

Dispatch promotional broadcasts or transactional blasts to up to 50 recipients per request. Includes built-in anti-spam protections.

speed2-Second Throttle Protection

Built-in delay between dispatches prevents WhatsApp spam flags and protects your connected number.

currency_rupeeAutomated Partial Refunds

If any recipient numbers fail or are invalid, ₹0.50 per failed number is automatically credited back to your wallet.

POST/api/v1/send/bulk/messageArray of up to 50 numbers
curl -X POST https://api.wapix.sbs/api/v1/send/bulk/message \
  -H "Content-Type: application/json" \
  -d '{
    "service": "bulk",
    "whatsaap_number": [
      "919876543210",
      "919876543211",
      "919876543212"
    ],
    "text": "Exclusive flash sale! 30% off with coupon code WAPIX30: https://wapix.io",
    "api_key": "YOUR_WAPIX_API_KEY"
  }'
200 OK Campaign SummaryAuto-reconciled
{
  "success": true,
  "message": "Bulk campaign processed: 3 sent, 0 failed",
  "data": {
    "total_requested": 3,
    "sent_count": 3,
    "failed_count": 0,
    "charged_amount": 1.50,
    "refund_amount": 0.00,
    "remaining_balance": 198.50
  }
}
06

Session Lifecycle & QR Pairing

Wapix maintains persistent WhatsApp Web client sessions on the gateway. Control session states seamlessly via the dashboard or through management endpoints:

play_circle

1. Start Session

Spawns a headless browser session and generates a real-time QR code.

qr_code_scanner

2. Link Device

Scan via WhatsApp > Linked Devices. The session transitions to READY.

stop_circle

3. Stop / Restart

Safely disconnect the session or restart when changing physical device numbers.

07

Webhooks & Real-time Inbound Events

Subscribe external HTTP URLs to capture instant event payloads whenever WhatsApp messages are delivered, read, received, or reacted to.

message
Inbound customer replies sent to your WhatsApp number
message.ack
Delivery acknowledgements (sent, delivered, blue ticks)
message.reaction
Emoji reaction updates on any message
message.revoked
Message deleted or unsent notification
message.edited
Message modified by the sender
Inbound Webhook Payload Example
{
  "event": "message",
  "session": "sess_89f02a",
  "data": {
    "from": "919876543210@c.us",
    "body": "CONFIRM 492018",
    "type": "chat",
    "timestamp": 1727914800,
    "message_id": "true_919876543210@c.us_3EB0..."
  }
}
08

Prepaid Wallet & Cashfree Billing

Wapix operates with 100% pay-as-you-go transparency. No monthly commitments, contracts, or hidden platform fees. Top up using Cashfree checkout:

OTP Verification
₹0.25
per successful OTP
Auto-refund on failure
Single Message
₹0.45
per transactional message
Immediate delivery
Bulk Broadcast
₹0.50
per recipient
Rate-limited safeguard
09

Error Codes & Handling

StatusReasonResolution
200 OKRequest dispatched successfullyInspect data.id for reference
400 Bad RequestMissing required payload fields or invalid phone formatCheck country code prefix and required keys
401 UnauthorizedInvalid or missing API keyGenerate a new key from the dashboard
402 Payment RequiredInsufficient wallet balanceTop up via /add-credit
503 UnavailableWhatsApp session is offline or stoppedStart the session on dashboard and scan QR