Incoming message
This section describes the webhook format for an incoming text message.
You can find more details about all parameters and their types in the WebHook documentation.
Incoming HSM-Template message (From WhatsApp Business Account (WABA)
Incoming WhatsApp Flow message (From WhatsApp Business Account (WABA)
The messages array contains all messages that were sent to the webhook URL. Sent on event "messages.post" or "messages.put". We mentioned more about the events here: Mode setting
Incoming text message
Use the messages.post setting to get this webhook.
Read incoming message
Incoming voice message played (listened to)
After an incoming voice message is listened to in a direct chat, its playback can be reported by a statuses.post webhook with status: "played" and code: 5.
Incoming group text message
Incoming reply by button
Incoming text message with URL
Incoming message with document
The link parameter will only appear when the Auto Download setting is enabled, which downloads files to the cloud and stores them for 30 days.
Incoming mention added to media (image, video, document)
Incoming message with voice audio
The link parameter will only appear when the Auto Download setting is enabled, which downloads files to the cloud and stores them for 30 days.
Incoming message from Facebook Ads (Click-to-WhatsApp)
This is a sample webhook payload for an incoming message triggered by a Click-to-WhatsApp (CTWA) ad on Facebook or Instagram. When a user clicks on a WhatsApp button in a Facebook ad and sends a message, the system delivers this webhook to your server.
You can use this data to:
Personalize your response based on the ad they came from
Track ad performance and conversions
Automatically assign leads to your CRM or sales team
This type of webhook is only triggered when the user contacts you via a Facebook Click-to-WhatsApp ad, and message attribution is enabled in your WhatsApp Business settings.
Incoming message with geolocation
Incoming message with Live geolocation
Incoming message with contact
Incoming message with contacts array
Incoming message with quote
Incoming message with mention of all participants (@all)
When a group message mentions everyone (@all), the webhook contains "context": {"mention_all": true}. The same field is present in outgoing messages sent with "mentions": ["all"].
Incoming message with sticker
The link parameter will only appear when the Auto Download setting is enabled, which downloads files to the cloud and stores them for 30 days.
Incoming message-emoji reaction
Incoming message with group invitation
Incoming message with product
Incoming message with catalog
Incoming message with poll
Use the messages.post setting to get this webhook.
Incoming message with poll update
Use the messages.post setting to get this webhook.
How to Quickly Check the Vote Count in a Poll
To see the final results of a poll, you can use the Get Message endpoint and provide the message ID of the poll. This will return the full voting data.
If you'd like to track the number of votes in real time, enable the messages.patch webhook.
Each time a vote is submitted or updated, you'll receive a webhook event containing:
"total"– total number of votes"count"– vote count for each poll option"voters"– a list of users who voted for each option
This allows you to monitor poll activity as it happens.
Use the messages.patch setting to get this webhook:
Incoming message with order
Incoming comment on a community announcement
A comment on a community announcement arrives as a messages.post webhook with message type action and action.type: comment. action.target contains the announcement message ID, and action.comment contains the comment text.
Incoming channel admin invite
Incoming HSM-Template message (WhatsApp Business Account (WABA)
Incoming WhatsApp Flow message (From WhatsApp Business Account (WABA)
A WhatsApp Flow is a form that a business sends from the official WhatsApp Business API. Such a message arrives with "type": "template" and "source": "business_api", and template.type is "flow".
Incoming Flow message updated after the reply
After the Flow form is submitted from your number, WhatsApp disables the Flow button: the form can be viewed but not submitted again. Whapi.Cloud reports this as an update of the original Flow message: changes: ["template"], and template.cta_disabled changes from false to true. It is not an edit by the sender.
Use the messages.patch setting to get this webhook. In the example, native_flow is shortened — it is the same as in the incoming Flow message.
Incoming carousel message
Incoming Group member tag changed
When a participant adds, edits, or deletes their member tag in a group, you will receive a system message via the messages.post webhook.
Group member tags are short text labels (up to 30 characters) that appear under a participant's name in a group chat — for example, "Coach" or "Manager". Tags are group-specific, so users can have different tags in different groups.
json
Incoming album
An incoming WhatsApp album includes a parent message with type: album. Its photos and videos arrive as separate image or video messages through messages.post.
Media item linked to an album
The following is one item from the messages array of a separate messages.post webhook. Media fields are shortened.
association.type: media_album identifies an album item. association.target is the ID of its parent album message — the same ID shown in the album notification above.
Message order and timestamps
WhatsApp displays an album as one block, while individual media items have their own timestamp values. Sorting all media items and text messages by timestamp can make album files appear interleaved with text messages.
To display these items together, group album media items by association.target and position the album block using the parent's timestamp. Add media items that arrive later to the same block.
Incoming motion photo (Live Photo)
A motion photo (a still picture with a short clip) arrives as two messages.post webhooks: first an image with "subtype": "motion_photo" (the photo itself), then a video (the clip). The clip has an association object whose target is the ID of the photo message.
Photo:
Clip:
Format
id*
string
Message ID
type*
MessageType string
default: text
Message type
Enum: [ text, image, video, gif, audio, voice, short, document, link_preview, location, live_location, contact, contact_list, sticker, system, call, unknown, action, group_invite, product, interactive, reply, poll, hsm, order, story, carousel ]
subtype
string
Message subtype
chat_id*
string
Chat ID
from
string
WhatsApp ID of the sender
from_me*
boolean
Is message from me
from_name
string
Pushname of the sender
source
MessageSource string
default: text
Message source
Enum: [ web, mobile, api, system, business_api ]
timestamp*
number
Message timestamp
device_id
number
Device ID, if the message was not sent through the app
status
StatusEnum string
List [ "Message failed to send (Red error triangle in WhatsApp Mobile)", "Message pending to send (One clock in WhatsApp Mobile)", "Message received by WhatsApp server (One checkmark in WhatsApp Mobile)", "Message delivered to recipient (Two checkmarks in WhatsApp Mobile)", "Message read by recipient (Two blue checkmarks in WhatsApp Mobile)", "Voice-message played by recipient (Two blue checkmarks in WhatsApp Mobile)", "Message deleted by the user" ]
Message ack status
Enum: [ failed, pending, sent, delivered, read, played, deleted ]
action
Message action {
}
context
Message context {
}
reactions
Reactions for message
Last updated