List of available/registered twilio voice clients - twilio

I'm looking through documention but didn't find anything that can help me find registered clients to twilio voice incoming calls.
For example. I have 10 registered clients to javascript sdk, that can handle incoming calls by their identities. But on my backend I need to find out who is registered and who is not busy making another call.
Is there any endpoint or someting that can return list of users(identites, clients, devices) with their status?
Because with TwiML I can redirect incoming call up to 10 clients. But when I don't know who is ready to answer and not busy I can't redirect responsible.
Thanks for any leads.

Twilio developer evangelist here.
I'm afraid that there isn't a way to list your currently registered clients. But you have a couple of options with how to deal with this.
You could keep a list of your registered clients manually. Adding a client to the list as they log in and removing them when they disconnect.
Alternatively, you could consider using TaskRouter to keep track of this and control the passing out of incoming call tasks to available agents. Then the agents would log on and enter an idle status in TaskRouter, when they accept a call they would be busy, once the call is over they go through a wrapping up stage before you return them to idle and ready for another call.

I resolved it with another way. When the user connects a device to twilio, I put him in the presence group with WS. When the device starts calling, I put him in another presence group. On the backend, when recieving calls, I just check who is in the ready group and not in the calling one and connect him with this incoming call.

Related

How to avoid voicemail interaction in a outbound call?

We have a code that connects two target numbers in a conference to talk to each other.
We make two outbound calls, directing both to a unique conference via twiml.
Our logic is perfect when both of them answers or when one of the outbound calls gives up on ringing returning a webhook in a 'no-answer' status.
The problem is when the person rejects the call. In that case, the voicemail triggers the conference start, like if it was answered. It connects the voicemail with a person.
We need a way to stop this from happening or to identify a true human answer from an voicemail one. It is generating empty recordings, confusing the callers and in a not answered call we are sending an SMS, explaining who was trying to communicate. We need to identify all unsuccessful calls for that.
Anybody has a hint?
Twilio developer evangelist here.
You are looking for answering machine detection. Or, alternatively, you can use call screening as described on this page.

Twilio - should not reject incoming call when unregister device

Use case:
Twilio calling used both in web app and in mobile app.
There is incoming call - it is ringing both on mobile and in web app.
Current result:
when close tab in web browser it automatically rejects incoming call - it stops ringing on mobile.
Expected result:
it should be still ringing on mobile after closing tab with calling web app
Twilio developer evangelist here.
When you reject a call to a client identifier, including by reloading the page, then the call is rejected for all versions of that client identifier across all applications.
To work around this, I would recommend using different identifiers for different devices and making simultaneous outbound calls to them, either with multiple <Client> elements if you are using TwiML or by starting multiple calls with the REST API. If you have to use the REST API, you should keep track of the calls so that once one connects you can end the others.

Forwarding call recordings in Twilio for Zoho

I use Twilio and Zoho Phonebridge for inbound and outbound calling to customers. I use Zoho's built in IVR which works well, but has gaps. The main gap is when I get a voicemail, I need to login to Twilio to get it and that's a time sink. I would like Twilio to email (or text, for all I care) those messages to me, transcribed or not. Problem is, I cannot modify the code provided by Zoho, so I need to have the function carry out in parallel. I'm not sure where to start. I can do code snippets easily enough, but I seems I need to replace the "Voice Configuration - Request URL", which kills the IVR.
Any help?

Making a call from a Twilio client to another Twilio client directly

what I am trying to achieve is to make a VoIP call from an iPhone to an iPhone using Twilio.
To do that I'm using the iOS SDK, the Twilio Voice to be more specific as the iOS SDK is superseded.
I have a server that generates an access token and when I create a call the Twilio API would make a request to my server and I would return a <Dial /> keyword with the client name and the connection would be established.
The problem is, this counts as two calls(iOS app to Twilio is the first one and when I return a TwML <Dial /> response is the second one) so the price is practically doubled.
Is there a way to make it as a single iOS app to an iOS app call? All my server does is to generate the TWiML using the parameters that are sent from the client anyway.
Oh and also in the documentation there are some talks about capability tokens but all the current documentation is using Access Tokens.
Are capability tokens relics of the past for the older API?
Thanks
Twilio developer evangelist here.
Twilio calls are always priced per leg, so in a call between two people you do always pay for the outgoing leg and the incoming leg. They may also have different lengths, if the outgoing call goes through some other TwiML before making the <Dial> for example.
However, if all you want to do is make calls between applications and you don't need to be able to make calls to the phone network then can I recommend you take a look at the Twilio Video project. While it is called "Video" you can use the SDK to make audio calls between apps too. And if you choose to create peer-to-peer rooms, then the audio stream is sent directly between the two devices and not charged as a call leg at all. The only extra thing you need to do is to generate the call notifications yourself.
As for capability tokens, they are indeed a left over bit of documentation. Capability tokens have mostly been renamed as access tokens so you can use them interchangeably. If you investigate the Video SDK, then everything will be Access Tokens too.

Use incoming caller ID on Twilio to make outgoing call

I'm wondering if the following is possible:
Caller rings Twilio number which gets answered and then automated message is played.
Caller is placed in a queue
In parallel to this, our system dials a number (using the rest API) showing the caller id of the incoming call, plays a gather to verify the user wants to pick up, and then connects the call.
I know that the easiest way to achieve something similar to this is to redirect the incoming call with a Dial verb, but for reasons that aren't really relevant to the question that isn't possible.
Twilio evangelist here.
Yes, this is possible, with the caveat that the initial callers phone number must be previously verified with Twilio. See this topic in the help center:
http://www.twilio.com/help/faq/voice/can-i-use-a-non-twilio-number-as-the-caller-id-for-outgoing-calls
Hope that helps.
Devin

Resources