Skip to content

Wait for WhatsApp Message

Twilio

Twilio

Wait for WhatsApp Message

Triggered when a WhatsApp message is received on your Twilio number. Configure your Twilio Sandbox or production number webhook URL to point to this integration's webhook endpoint.

Trigger

Inputs

Name Type Required Description
fromtextOptionalFilter: only trigger for messages from this WhatsApp number. The whatsapp: prefix is optional — it will be added automatically if omitted. Leave empty to accept from any sender.
totextOptionalFilter: only trigger for messages sent to this WhatsApp number. The whatsapp: prefix is optional — it will be added automatically if omitted. Leave empty to accept for any recipient.
contains_texttextOptionalFilter: only trigger when the message body contains this text (case-insensitive). Leave empty to accept any message body.
hasMediayes/noOptionalWhen set, only trigger for messages that match the specified media presence (yes = must have media, no = must not have media).

Outputs

Name Type Description
messageSidtextUnique SID of the incoming Twilio message
accountSidtextTwilio Account SID that received the message
fromtextSender's WhatsApp number with whatsapp: prefix
totextRecipient WhatsApp number with whatsapp: prefix
bodytextText content of the received WhatsApp message
profileNametextWhatsApp profile name of the sender
numMediatextNumber of media items attached to the message
hasMediayes/noWhether the message contains one or more media attachments
mediaItemsarray of objectMedia URLs and content types as received from the Twilio webhook (MediaUrl/MediaContentType). Requires Twilio authentication to download.
urltextTwilio media URL (MediaUrlN from the webhook)
contentTypetextMIME type of the media item (MediaContentTypeN from the webhook)
mediaFilesfilesMedia files attached to the message, resolved as usable file values with base64 content