Twilio

tw

Twilio is a cloud communications platform that lets developers programmatically send and receive SMS, MMS, and voice calls. It provides a widely used API for building messaging into applications, including delivery status callbacks and inbound message handling.

With the Twilio triggers, you can:

  • React to message status changes: Start a workflow whenever a sent message's status updates (sent, delivered, failed, undelivered)
  • React to inbound messages: Start a workflow whenever an SMS or MMS is received on a Twilio number
  • Access full message context: Read sender/recipient details, message body, media attachments, and error codes from the triggering event

In Zoen, the Twilio triggers allow your agents to start workflows directly from Twilio messaging events. The Twilio Message Status trigger fires when a message's delivery status changes, exposing fields like messageSid, smsStatus, messageStatus, and errorCode so a workflow can react to delivery failures or confirmations. The Twilio SMS Received trigger fires on inbound SMS/MMS messages, exposing the sender and recipient numbers, message body, and any attached media, so a workflow can process incoming texts, route them, or trigger automated replies.

Triggers

A Trigger is a block that starts a workflow when an event happens in this service.

Twilio Message Status

Trigger workflow when a Twilio message status changes (sent, delivered, failed)

Configuration

ParameterTypeRequiredDescription
accountSidstringYesYour Twilio Account SID from the Twilio Console
authTokenstringYesYour Twilio Auth Token, used to verify the X-Twilio-Signature header

Output

ParameterTypeDescription
messageSidstringUnique 34-character identifier for the message
accountSidstringTwilio Account SID
messagingServiceSidstringMessaging Service SID, if the message was sent through one
fromstringPhone number or channel address that sent the message (E.164 format)
tostringPhone number or channel address of the recipient (E.164 format)
bodystringText body of the message (up to 1600 characters)
numMediastringNumber of media items attached to the message
numSegmentsstringNumber of segments that make up the message
mediajsonArray of attached media as { url, contentType } objects (MMS)
smsStatusstringSMS status (e.g., received, sent, delivered, undelivered, failed)
messageStatusstringMessage status for status callbacks (sent, delivered, undelivered, failed)
errorCodestringTwilio error code, present when the status is failed or undelivered
apiVersionstringTwilio API version used to process the message
fromCitystringCity of the sender, when available
fromStatestringState/province of the sender, when available
fromZipstringZip/postal code of the sender, when available
fromCountrystringCountry of the sender, when available
toCitystringCity of the recipient, when available
toStatestringState/province of the recipient, when available
toZipstringZip/postal code of the recipient, when available
toCountrystringCountry of the recipient, when available
rawstringComplete raw webhook payload from Twilio as a JSON string

Twilio SMS Received

Trigger workflow when an inbound SMS or MMS message is received via Twilio

Configuration

ParameterTypeRequiredDescription
accountSidstringYesYour Twilio Account SID from the Twilio Console
authTokenstringYesYour Twilio Auth Token, used to verify the X-Twilio-Signature header

Output

ParameterTypeDescription
messageSidstringUnique 34-character identifier for the message
accountSidstringTwilio Account SID
messagingServiceSidstringMessaging Service SID, if the message was sent through one
fromstringPhone number or channel address that sent the message (E.164 format)
tostringPhone number or channel address of the recipient (E.164 format)
bodystringText body of the message (up to 1600 characters)
numMediastringNumber of media items attached to the message
numSegmentsstringNumber of segments that make up the message
mediajsonArray of attached media as { url, contentType } objects (MMS)
smsStatusstringSMS status (e.g., received, sent, delivered, undelivered, failed)
messageStatusstringMessage status for status callbacks (sent, delivered, undelivered, failed)
errorCodestringTwilio error code, present when the status is failed or undelivered
apiVersionstringTwilio API version used to process the message
fromCitystringCity of the sender, when available
fromStatestringState/province of the sender, when available
fromZipstringZip/postal code of the sender, when available
fromCountrystringCountry of the sender, when available
toCitystringCity of the recipient, when available
toStatestringState/province of the recipient, when available
toZipstringZip/postal code of the recipient, when available
toCountrystringCountry of the recipient, when available
rawstringComplete raw webhook payload from Twilio as a JSON string

On this page