Send Message

Send a message to an existing chat in the CRM. Supports multiple message types:

TypeDescriptionRequired Fields
textPlain text messagemessage
imageImage with optional captionmediaUri, optionally message (caption)
videoVideo with optional captionmediaUri, optionally message (caption)
documentDocument filemediaUri, filename, optionally message (caption)
templatePre-approved WhatsApp templatetemplate object (name, language, components)

Media: Pass a public URL in mediaUri. Base64-encoded media is also supported — the system will upload it to S3 automatically.

Templates: Only available on WHATSAPP_OFFICIAL channels. Use GET /api/wp-crm/channels/:orgId/templates to discover available templates and their parameter structure before sending.

Security: The channel and chat must belong to your organisation. Cross-organisation access is denied with a 403.

See the request body examples below for each message type.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
string
required

Your organisation UUID (returned as org from the /token endpoint)

string
required

Channel UUID from GET /api/wp-crm/channels/:orgId — must belong to your organisation

string
enum
required

Message type. Determines which other fields are required. See examples for each type.

Allowed:
string

Media content for image, video, or document messages. Accepts:

  • Public URL (recommended): https://example.com/image.jpg
  • Base64 string: data:image/jpeg;base64,/9j/4AAQ... (auto-uploaded to S3)

Not used for text or template message types.

string
required

Chat UUID returned from POST /api/wp-crm/messaging/create-chat — must belong to your organisation

string

The text content of the message:

  • text type: the message body (required)
  • image/video/document type: used as the media caption (optional)
  • template type: not used (template body comes from the template object)
string

Display filename for document messages (e.g., invoice.pdf). Only relevant when type is document.

template
object

Template object — required when type is template.

Use GET /api/wp-crm/channels/:orgId/templates to discover available templates and their expected parameters.

Templates are only supported on WHATSAPP_OFFICIAL channels.

boolean
Defaults to false

When true, the message is still delivered and recorded (and shows in the chat thread) but does NOT move the chat to the top of the agents' chat list or mark it unread. Use for automated/transactional sends that should not flood the inbox.

Responses
200

Message sent successfully. Returns the created conversation record.

400

Bad request — missing required fields, invalid message type, or template messages sent to a non-WHATSAPP_OFFICIAL channel

401

Unauthorized — invalid/expired JWT or organisation ID does not match the token

403

Forbidden — the specified channel does not belong to this organisation

404

Chat not found in this organisation

409

Conflict — you cannot send messages to another channel number within the same organisation

500

Internal server error

Language
Credentials
Bearer
JWT
LoadingLoading…
Response
Click Try It! to start a request and see the response here!