On September 20th the London DVELP team joined a full house in a converted 18th century brewery for a 21st century conference. With fresh insights on the Twilio stack and success stories of Twilio customers it was an engaging day. Most exciting was connecting with some of the team behind Twilio's innovative communication APIs.
Using Twilio with our own api we were easily able to set up a DVELP support line. Our own app does the following:
When someone calls our hotline, Twilio makes an api call to our own server. The server checks which users are currently set up to receive calls and returns a TwiML response, for example:
<?xml version="1.0" encoding="UTF-8"?> <Response> <Say>Welcome to DVELP, Jason and Richard are online, would you like to speak to them? Or create a support request directly by dialling any number.</Say> <Gather action="/api/no-answer' numDigits='1' /> <Dial timeout="9" callerId='xxxxxxxxxx'> <Number>+44xxxxxxx</Number> </Dial> <Dial timeout="9" action="/api/no-answer" callerId='xxxxxxxxxx'> <Number>+44xxxxxxx</Number> </Dial> </Response>
<Say>element into speech which is spoken to the caller.
<Gather>tells Twilio to listen for keypad presses.
actionis the url that the user will be sent to if they enter digits.
numDigitsinstructs Twilio how many digits to listen for.
<Dial>informs Twilio to put a call out to the
timeoutseconds without answer, Twilio either goes to the
actionurl or proceeds to the next instruction.
With the example above, the no-answer endpoint returns the following TwiML:
<?xml version="1.0" encoding="UTF-8"?> <Response> <Say>Please leave a voice message</Say> <Record action='/api/recordings' transcribe='true' transcribeCallback='api/transcriptions' /> </Record>
<Record>tells Twilio to record a message.
actiontells Twilio where to make the api call to send us the recording
transcribewe can decided if we want a transcription
transcribeCallbacktells Twilio where to call to send us the transcription - this service is asynchronous from recording creation
On receipt of a callback from Twilio to the transcriptions endpoint we create a new Trello card with the following details:
Go ahead and give it a try: +44 (0) 20 31 37 63 39
The functionality rolled out in our Hackathon is just the tip of the Twilio iceberg... We are now looking into extending our support line to respond to a variety of inbound methods such as voice, sms or even social media.