This repo shows how to create a multilingual voice and SMS survey with questions and answers stored in an airtable base.
- A Twilio account
- An airtable account with one base containing:
- One table for questions. This table needs to have two columns:
Question Text
(single line of text): the actual questionLanguage
(single line of text): language code using one of the following language tags. This is used to generate the Text-To-Speech in the correct language and to apply the correct language for Speech-To-Text. This is not used for SMS Survey
- One table for questions. This table needs to have two columns:
- One (empty) table for answers. This table should have thre columns (self explanatory):
Number
(single line of text)Question
(single line of text)Answer
(single line of text)
- Clone the repo
- Install dependencies
npm install
- Run the provision script
node provision
- At the end of the process you should have two new Studio Flows created:
Airtable SMS Survey
Airtable Voice Survey
- In your Twilio console, set the two flows for
When a call coms in
andWhen a message comes in
for the number you want to run the surveys from - Fill-up some questions in the table for questions. The last row on this table is the final greetings, e.g.
To test them, trigger the Studio Flow providing from
abd to
number. More instructions on how to trigger a flow can be found here