Twilio Voice Trigger
Trigger workflow when phone calls are received via Twilio Voice
Trigger workflow when phone calls are received via Twilio Voice
This is a webhook-based trigger. Configure the external service to send events to the workflow webhook URL.
Setup Instructions
-
Enter a TwiML Response above - this tells Twilio what to do when a call comes in (e.g., play a message, record, gather input). Note: Use square brackets [Tag] instead of angle brackets for TwiML tags
-
Example TwiML for recording with transcription: [Response][Say]Please leave a message.[/Say][Record transcribe="true" maxLength="120"/][/Response]
-
Go to your Twilio Console Phone Numbers page at https://console.twilio.com/us1/develop/phone-numbers/manage/incoming
-
Select the phone number you want to use for incoming calls.
-
Scroll down to the "Voice Configuration" section.
-
In the "A CALL COMES IN" field, select "Webhook" and paste the Webhook URL (from above).
-
Ensure the HTTP method is set to POST.
-
Click "Save configuration".
-
How it works: When a call comes in, Twilio receives your TwiML response immediately and executes those instructions. Your workflow runs in the background with access to caller information, call status, and any recorded/transcribed data.
Configuration
Output Schema
callSidstringUnique identifier for this callaccountSidstringTwilio Account SIDfromstringCaller's phone number (E.164 format)tostringRecipient phone number (your Twilio number)callStatusstringStatus of the call (queued, ringing, in-progress, completed, etc.)directionstringCall direction: inbound or outboundapiVersionstringTwilio API versioncallerNamestringCaller ID name if availableforwardedFromstringPhone number that forwarded this calldigitsstringDTMF digits entered by caller (from <Gather>)speechResultstringSpeech recognition result (if using <Gather> with speech)recordingUrlstringURL of call recording if availablerecordingSidstringRecording SID if availablecalledstringPhone number that was called (same as "to")callerstringPhone number of the caller (same as "from")toCitystringCity of the called numbertoStatestringState/province of the called numbertoZipstringZip/postal code of the called numbertoCountrystringCountry of the called numberfromCitystringCity of the callerfromStatestringState/province of the callerfromZipstringZip/postal code of the callerfromCountrystringCountry of the callercalledCitystringCity of the called number (same as toCity)calledStatestringState of the called number (same as toState)calledZipstringZip code of the called number (same as toZip)calledCountrystringCountry of the called number (same as toCountry)callerCitystringCity of the caller (same as fromCity)callerStatestringState of the caller (same as fromState)callerZipstringZip code of the caller (same as fromZip)callerCountrystringCountry of the caller (same as fromCountry)callTokenstringTwilio call token for authenticationrawstringComplete raw webhook payload from Twilio as JSON string