Building a SMS Survey with Twilio and Airtable
This tutorial demonstrates creating a SMS survey application by integrating Twilio Studio with Airtable. The workflow checks a database for existing contacts, welcomes returning users, retrieves active survey questions, and stores responses—all through text messaging.
Three Airtable Tables
- Contacts: Stores user names and phone numbers
- Questions: Contains survey questions with an "Active" status field to control which question is deployed
- Response: Records user answers, associated contacts, and questions
Workflow Process
The system performs a contact lookup via Airtable API when an SMS arrives. New users are prompted for their name; existing users receive personalized greetings. Both paths lead to retrieving the active survey question and capturing the response.
Technical Requirements
- Twilio account (trial includes $15 credit)
- Airtable account (free tier available)
- HTTP requests to Airtable's REST API using authentication keys
- Liquid templating in Twilio Studio to reference dynamic variables like incoming phone numbers
The complete implementation enables dynamic, database-driven SMS interactions without custom backend infrastructure.