Twilio Studio allows you to drag and drop widgets to build a number of different Programmable Messaging flows. Here are steps for creating a simple SMS message keyword response tree flow, and configuring it for use on your Twilio number.
Create an SMS Message Response Menu Tree Flow
- Login to your account at www.twilio.com/console.
- Click Studio from the left-side navigation bar.
NOTE: If Studio is not visible, you may first need to click All Products & Services. - Click the + sign icon to create a new flow.
- Enter the desired name, and then click Add Flow.
- From the Widget Library on the right, drag and drop the following widgets into the flow:
- Send & Wait for Reply
- Split Based On...
- Send Message (one for each response option)
- Click and drag the Trigger widget’s Incoming Message lead to connect it to the Send & Wait for Reply widget.
- Click the Send & Wait for Reply widget, and then enter the necessary information:
- Config tab: Enter the desired message in the MESSAGE BODY field.
- Transitions tab: Click the IF REPLY drop-down menu, and then select the Split Based On widget.
- Click the Split Based On widget, and then edit as desired:
- Config tab: Click the VARIABLE TO TEST drop-down menu, and then select the .inbound.body option for the previous Send & Wait for Reply widget.
- Transitions tab: Click New Transition to create a new mapping, and then select Equal To from the first drop-down menu, enter the expected input for the VALUE field, and select the desired Send Message widget for this result from the THEN TRANSITION TO drop-down menu. Click Save when finished.
- Click the Send Message widget, and then enter the desired message body.
- Click Save. Studio Plus users, click Publish.
Activate a Flow on a Twilio Number
When your flow is published, it can then be configured to handle incoming phone calls or text messages for Twilio phone numbers that support these products. Here’s how to add your flow to a phone number:
- Login to your account at www.twilio.com/console.
- Click Phone Numbers from the left-side navigation bar.
NOTE: If Phone Numbers is not visible, you may first need to click All Products & Services. - Click the desired phone number.
- Add your Studio flow for incoming messages:
- CONFIGURE WITH: Webhooks, TwiML Bins, Functions, Studio, or Proxy
- A MESSAGE COMES IN: Studio Flow
- Select the desired flow.
- Click Save.