W WA Gateway Docs
API v1

Build with WA Gateway

Integrate WA Gateway into your application. Authenticate requests with your API key, call endpoints in your preferred language, and receive real-time webhook events.

⌁

Authentication & Base URL

Every request requires your API key.

Base URL
https://waapi.fireclashpro.com/api/v1/
Authentication Header
X-API-Key: wag_live_YOUR_API_KEY_HERE
POST

Send Message

Sends a text or media message to a recipient using your connected WhatsApp session. For a file, set message_type to "media" and pass media_url (and optionally caption) - see "Sending Files" below for the full steps, plan rules and limits.

POST /messages/send
Request examples
JSON body
application/json
{
    "session_id": "9482521",
    "recipient": "919876543210",
    "message_type": "text",
    "message": "Hello from WA Gateway!"
}
Example response
200 OK
{
    "success": true,
    "message_id": "wamid_xxxxxxxxx",
    "status": "queued"
}
GET

List Sessions

Returns the WhatsApp sessions available for your API key.

GET /sessions
Request examples
Example response
200 OK
{
    "success": true,
    "sessions": [
        {
            "id": "9482521",
            "status": "connected",
            "name": "My WhatsApp"
        }
    ]
}
POST

Register Webhook

Registers an HTTPS endpoint that receives real-time WhatsApp events.

POST /webhooks
Request examples
JSON body
application/json
{
    "session_id": "9482521",
    "url": "https://example.com/webhook"
}
Example response
200 OK
{
    "success": true,
    "webhook_id": "wh_123456"
}
POST

Upload Media

Uploads an image, video, audio, or document file and returns a media_url ready to use with Send Message.

POST /media/upload
Request examples
JSON body
application/json
{
    "file": "(binary file data)",
    "category": "image"
}
Example response
200 OK
{
    "success": true,
    "media_url": "https://app.fireclashpro.com/media/f/6b1f...a92.jpg",
    "category": "image",
    "content_type": "image/jpeg",
    "size_bytes": 84213
}
GET

Media Storage Usage

Returns how much of your plan's media storage quota is currently in use.

GET /media/storage
Request examples
Example response
200 OK
{
    "used_mb": 45.5,
    "quota_mb": 200,
    "image_video_enabled": false,
    "retention_days": 30
}
⇪

Sending Files (images, video, audio, documents)

Two steps: upload the file, then send the link you get back.

Step by step

  1. Upload the file with POST /media/upload as multipart/form-data, field name file. Example:
    curl -X POST https://waapi.fireclashpro.com/api/v1/media/upload \
      -H "X-API-Key: wag_live_YOUR_API_KEY_HERE" \
      -F "file=@invoice.pdf"
    The response contains a ready-to-use media_url:
    { "media_url": "https://app.fireclashpro.com/media/f/6b1f...a92.pdf",
      "category": "document", "content_type": "application/pdf", "size_bytes": 84213 }
  2. Send it with POST /messages/send, using message_type: "media" and that media_url. caption is optional (not used for audio):
    curl -X POST https://waapi.fireclashpro.com/api/v1/messages/send \
      -H "X-API-Key: wag_live_YOUR_API_KEY_HERE" -H "Content-Type: application/json" \
      -d '{ "session_id": "9482521", "recipient": "919876543210",
            "message_type": "media",
            "media_url": "https://app.fireclashpro.com/media/f/6b1f...a92.pdf",
            "caption": "Your invoice" }'
  3. Check the result - the send call returns a message_id and status queued; the final status (sent / failed) arrives on your webhook or via GET /messages/{message_id}.

Already host the file yourself? Skip step 1 and put your public link in media_url. The same plan rules apply, and the file is downloaded and checked by its real content before it is sent. The link must be https (or http) on port 80/443, reachable from the internet, and must not point to a private/internal address or redirect more than 3 times.

What each plan can send

PlanImageVideo AudioDocumentStorage
StarterYes--PDF only, max 2 MB200 MB
ProYesYesYesYes500 MB
BusinessYesYesYesYes2000 MB

Annual plans have the same access as their monthly version. Storage is a rolling 30-day total of what you uploaded; files are deleted after 30 days. There is no free plan: you need an active paid plan to connect WhatsApp and send anything. If your plan expires, sending and uploads stop until you renew.

File types and limits

TypeFormatsMax sizeMax length
ImageJPG, PNG, WebP, GIF10 MB-
VideoMP4, MOV60 MB2 minutes
AudioMP3, OGG, AAC, WAV15 MB (WAV 20 MB)5 minutes
DocumentPDF, DOCX, XLSX20 MB (Starter: PDF only, 2 MB)-
TextTXT, CSV (UTF-8)5 MB-

Uploads are limited to 60 per hour per account. Old .doc / .xls files are not accepted - save as .docx / .xlsx or send a PDF.

How files are checked (and what gets refused)

  • The type is read from the file's content, never from its name. A renamed file is identified as what it really is.
  • Every file is scanned by an antivirus engine before it is stored. Infected files are rejected.
  • Word / Excel files containing macros, ActiveX or embedded objects are rejected. PDFs containing scripts, launch actions or embedded files are rejected.
  • Executables, scripts, HTML, SVG, archives and anything else not in the table above are rejected.

Errors you may see

CodeHTTPMeaning / what to do
PLAN_RESTRICTED403Your plan does not include this file type. Upgrade (see the table above).
STORAGE_QUOTA_EXCEEDED413Your 30-day media storage is full. Wait for old files to expire or upgrade.
FILE_TOO_LARGE413Over the size limit for that file type.
MEDIA_TOO_LONG413Video over 2 minutes or audio over 5 minutes.
INVALID_FILE_CONTENT400The file is not one of the supported types (checked by content).
FILE_TYPE_MISMATCH400The category you sent does not match the real file.
UNSAFE_FILE400Macros, scripts or embedded objects found. Re-save a plain file.
MALWARE_DETECTED400The antivirus scan flagged the file.
SCANNER_UNAVAILABLE503The scanner is temporarily unreachable - retry in a few minutes.
QUOTA_EXCEEDED403Monthly message limit reached. Upgrade or buy a top-up (top-ups need an active paid plan).
RATE_LIMITED429Too many requests - slow down and retry.

When you send a link you host yourself: if the link clearly names a file type your plan does not allow, the send call returns PLAN_RESTRICTED straight away; otherwise the file is checked when it is delivered and the message shows as failed with the reason.

↗

Webhook events

Your webhook URL should be reachable over HTTPS. WA Gateway sends event payloads to the registered endpoint as JSON.