I am implementing the Twilio Programmable Voice
to allow Outgoing calls to phone numbers from my Website.
I want to display a timer after the call has been picked by the client but I can't figure out how to monitor the status of a call in React
.
Twilio Docs - .status()
can be used to get the current status of the call.
They have the following endpoint status()
which can be used but in this case, should I create a function which keeps on checking the status of the call somehow until it reaches the accepted
state?
Is there a way I can track this?