Messages API

Send text and media messages and track delivery status.

JWT-authenticated sends use `https://api.actiwapi.com/api/messages`. API key sends use `https://api.actiwapi.com/api/external/messages/*`.

POST/api/messages/send-text

Send text message

Send a text message through a connected WhatsApp session.

URL: https://api.actiwapi.com/api/messages/send-text

Auth: JWT Bearer

Headers

HeaderValueRequired
AuthorizationBearer {accessToken}Yes
Content-Typeapplication/jsonYes*

Request example

{
  "sessionId": "uuid",
  "to": "919876543210",
  "text": "Hello from ActiWAPI!"
}

Code examples

curl -X POST "https://api.actiwapi.com/api/messages/send-text" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer {accessToken}"
  -d '{  "sessionId": "uuid",  "to": "919876543210",  "text": "Hello from ActiWAPI!"}'

Response example200

{
  "success": true,
  "data": {
    "id": "uuid",
    "status": "queued",
    "to": "919876543210"
  }
}

Try in Swagger UI

POST/api/messages/send-image

Send image

Send an image with optional caption. Use multipart/form-data.

URL: https://api.actiwapi.com/api/messages/send-image

Auth: JWT Bearer

Headers

HeaderValueRequired
AuthorizationBearer {accessToken}Yes
Content-Typeapplication/jsonIf JSON

Request example

Form fields:
  sessionId: uuid
  to: 919876543210
  caption: Optional caption
  file: (binary image)

Code examples

curl -X POST "https://api.actiwapi.com/api/messages/send-image" \
  -H "Content-Type: multipart/form-data" \
  -H "Authorization: Bearer {accessToken}"
  -d 'Form fields:  sessionId: uuid  to: 919876543210  caption: Optional caption  file: (binary image)'

Response example200

{ "success": true, "data": { "id": "uuid", "status": "queued" } }

Try in Swagger UI

GET/api/messages/{id}

Get message status

Retrieve delivery status for a sent message.

URL: https://api.actiwapi.com/api/messages/{id}

Auth: JWT Bearer

Headers

HeaderValueRequired
AuthorizationBearer {accessToken}Yes
Content-Typeapplication/jsonYes*

Path parameters

  • idMessage UUID

Code examples

curl -X GET "https://api.actiwapi.com/api/messages/{id}" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer {accessToken}"

Response example200

{
  "success": true,
  "data": {
    "id": "uuid",
    "status": "delivered",
    "direction": "outbound",
    "remoteJid": "919876543210@s.whatsapp.net"
  }
}

Try in Swagger UI

POST/api/external/messages/send-text

Send text (API key)

Send a text message using your API key.

URL: https://api.actiwapi.com/api/external/messages/send-text

Auth: API Key

Headers

HeaderValueRequired
X-API-Key{apiKey}Yes
Content-Typeapplication/jsonYes*

Request example

{
  "sessionId": "uuid",
  "to": "919876543210",
  "text": "Hello from ActiWAPI!"
}

Code examples

curl -X POST "https://api.actiwapi.com/api/external/messages/send-text" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: {apiKey}"
  -d '{  "sessionId": "uuid",  "to": "919876543210",  "text": "Hello from ActiWAPI!"}'

Response example200

{ "success": true, "data": { "id": "uuid", "status": "queued" } }

Try in Swagger UI

Error codes

Failed requests return a JSON envelope with success: false and a human-readable message.

{
  "success": false,
  "message": "Validation failed",
  "errors": {
    "phone": "Valid phone number is required"
  }
}
HTTPCodeDescription
400VALIDATION_ERRORRequest body or query failed validation.
401UNAUTHORIZEDMissing or invalid JWT / API key.
403FORBIDDENAuthenticated but lacking permission or entitlement.
403SUBSCRIPTION_INACTIVETrial expired or subscription not active.
403LIMIT_EXCEEDEDPlan limit reached (sessions, messages, API requests, etc.).
404NOT_FOUNDResource does not exist or is not in your tenant.
409CONFLICTDuplicate resource or invalid state transition.
429RATE_LIMITEDToo many requests; retry after backoff.
500INTERNAL_ERRORUnexpected server error.
502WHATSAPP_UNAVAILABLEWhatsApp session disconnected or provider error.

← Back to Getting Started