Menu

Expand
Rate this page:

Receive Inbound Messages from SMS, WhatsApp and Facebook Messenger

With Flex, your customers can reach you via channels like SMS, WhatsApp, and Facebook Messenger. This page details how to configure these Twilio-supported channels.

Configure SMS

The Flex Messaging page in the Twilio Console allows you to register a phone number with Flex to be handled for inbound SMS. When you register a number, we:

  1. Link the phone number's messaging handler to Proxy.
  2. Create a Flex Flow that redirects to your custom message handling. This defaults to a Studio Flow.

To manually configure SMS, you will need to update the messaging handler on the Phone Numbers page. Connect this to your 'Flex Proxy Service', and then use the Flex Flow API to create a new entry for your number.

Configure WhatsApp and Facebook

Like SMS, all other messaging channels have a configurable webhook for processing inbound messages. You'll need to update the messaging handler for each channel you want to connect to Flex.

For WhatsApp you can configure the message handler using the WhatsApp Sandbox.

For Facebook and other channels you can configure the callback URL from the Channels Page.

Set the Message Handler

Once you've found the right place in the console to configure the message handler, you can set the Incoming Message webhook to point to the Flex Proxy Service. This webhook looks like:

https://webhooks.twilio.com/v1/Accounts/ACxx/Proxy/KSxx/Webhooks/Message

Your unique URL will replace the ACxx and KSxx identifiers. You can find your default Flex Proxy instance SID in the Proxy section of the console. Your messaging channel needs to be connected to Proxy in order to be handled by Flex. Proxy translates all messages between Flex's chat channel (which your agent interacts with) and your messaging channel (which your customers interact with).

Configure the Flex Flow

As with SMS, you must create a Flex Flow entity for each identity that you are connecting to Flex. When Flex receives a new message, it will first send to Proxy and post to a new Chat Channel. Afterwards, the message handler will redirect to whatever destination you have specified in your Flex Flow. By default this is a Studio Flow. The Studio Flow can send automated responses to your inbound message or collect any additional information before passing the conversation to an agent within Flex.

Existing Flex Flows can be modified or removed from the Flex Messaging page in the Twilio Console.

Rate this page:

Need some help?

We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd by visiting Twilio's Community Forums or browsing the Twilio tag on Stack Overflow.

        
        
        

        Thank you for your feedback!

        We are always striving to improve our documentation quality, and your feedback is valuable to us. How could this documentation serve you better?

        Sending your feedback...
        🎉 Thank you for your feedback!
        Something went wrong. Please try again.

        Thanks for your feedback!

        Refer us and get $10 in 3 simple steps!

        Step 1

        Get link

        Get a free personal referral link here

        Step 2

        Give $10

        Your user signs up and upgrade using link

        Step 3

        Get $10

        1,250 free SMSes
        OR 1,000 free voice mins
        OR 12,000 chats
        OR more