Search code examples
phptwiliotwilio-apiivr

Starting and keeping a session in IVR


How do I keep a session in IVR? I am halfway done with an IVR application I am currently working on. I can collect customer ID & PIN to read out customer balance. After a customer confirms account balance, I want them to be able to continue with other options of PIN change, transfer credits to another customer without having to collect the Customer ID & PIN again till the call finally end. I am using Twilio webhook and my code is in php. Any help and idea will be appreciated.


Solution

  • Twilio respects cookies , so you should have no problem with persistence . You can view how twilio cookies with here https://support.twilio.com/hc/en-us/articles/223136287-How-do-Twilio-cookies-work- a more complex way would be to store the callsid and any data you want to persist in a database