Use Twilio for app to app VoIP calls - android

We are developing an Android app with VoIP call feature like WhatsApp's calls.
Following quick-start guides and examples provided by Twilio in their web we managed to make a simple VoIP app for testing (Android Client Tutorial), but when we configured server side app (provided in their examples) we were asked to enter a callerID that must be a valid phone number.
Why is this callerId needed and why it has to be a valid number phone if we just want to make app to app VoIP calls, without using any real mobile number?

Twilio developer evangelist here.
Using Twilio Client you can make both app to app calls and app to phone calls. You only need a calledId if you are calling out to the phone network. You can get a free phone number with your Twilio trial account and use that if you want to follow the Android Client Tutorial exactly.
Otherwise, you can skip the bits of the app where you call phones and just send calls out to other Clients. When you do that, you need only to set the callerId as your Client name.
Let me know if that helps at all.

Related

How can I forward calls from a Twilio or Nexmo number I bought to my Android phone over data / VOIP?

I don't want to forward to my mobile number, I want to install some kind of "softphone" and have Twilio / Nexmo forward the call to that softphone. Can my Android phone receive VOIP calls directly somehow?
This seems like such a simple thing to do, but I can't figure out how to do it. Do I need my own "SIP trunk"? Surely not, for such a simple use-case.
Twilio developer evangelist here.
You can do this using an Android SIP soft phone (see this post for some recommendations) and Twilio's SIP Registration. Check out the gif below for how to set up SIP registration for incoming calls to a soft phone:
The steps are:
Create a SIP domain in the Twilio console
Create a Credential List with at least one username and password
Enable SIP registration for the SIP domain using the credential list you created
Configure your SIP Phone application
User the username and password you chose for your credential list
Make sure the soft phone registers successfully
Buy a number
Configure a TwiML Bin to <Dial> to your <Sip> address on incoming calls
Dial that number and your soft phone should ring
Let me know if that helps at all.
If you don't want to forward to your personal number, you can buy some Virtual number from Application like Vyke, RWG. and give that number it will reach your app in your mobile.

Is there any Callback that gives me feedback about lost packages in Twilio beta8 SDK?

I'm developing an app in Android that uses Twilio to communicate through VoIP the users. I´m using beta-8 of the Voice SDK. My problem is that the call sometimes goes to "black" and you can´t hear anything from one side or another. This is because of the network, because I have been monitoring this.
My question is if there is some way to know when this is happening to notify the App and inform the user that we are trying to reconnect the call with some layout.
Any help is appreciated.
Twilio developer evangelist here.
There is almost a way to do this.
We have a Voice Insights Dashboard right now, which you can enable in your account and see account reports for your calls.
In the latest JavaScript Twilio Client you can also get call quality events. However this is still under development for Android and iOS Clients.
So, the overall answer is: not yet, but it's being developed so keep an eye on the Twilio blog for announcements.

How to make a phone call without phone app like google hangout?

I'm not going to use Intent to invoke default system Phone App, such as Google Hangout. Can we make a call or receive a income call inside our own app rather than system phone app?
Yes,You can do that with the help of a VOIP account. Try over internet you can find lot of VOIP providers and you just have to create an account and use the given instructions.
Android provides an API that supports the Session Initiation Protocol (SIP). This lets you add SIP-based internet telephony features to your applications. Android includes a full SIP protocol stack and integrated call management services that let applications easily set up outgoing and incoming voice calls, without having to manage sessions, transport-level communication, or audio record or playback directly.
Here are examples of the types of applications that might use the SIP API:
Video conferencing.
Instant messaging
Check this Example or Example 2

Does Google Licence Verification Library run on an Android Wear device?

I have been looking into Google LVL to address stolen apps issues.
The API states the device need to "Run a system image on which the Google Play client application is preinstalled"
This cannot happend on a Wear device, but I am wondering if it can leverage the host phone instance of Google Client.
Has anyone faced this scenario?
You can't leverage the phone instance directly but a common approach at getting anything the phone can provide (network status etc) is to use the messaging api to send a custom message to request the information and get a message from the phone as a response. You could easily add to your wearable listener service on the mobile side to call the licencing and then wrap up a response and send a message to the wearable.
Depending on what your app does I'd try to put this as part of an existing message from mobile to wear to save unnecessary chatter.

Implementing Voice/Video Chat Application in android

my new task is to implement Voice/Video chat native application in Android. I browsed net for the same and it was written that using Android "SIP" API we can do it. I gone through the documents about SIP.In Implementing using SIP we required SIP address for each user which will be provided by different SIP providers. I also checked the SipDemo sample app provided in samples.
Problem is my app will be used by many Users and they can chat with any others.
So, how can we generate SIP address for each user dynamically and establish communication session ?
or each there any other way of doing this ?
Please Help
If you want to test your android app you can generate a free sip account from AntiSip.
and for generating sip account dynamically you have to configure sip on your server with the help of Asterisk:
Two VoIP software can contact each other directly by using direct SIP URI like username#IP:port.
This can work fine on local networks where the UA (sip user agent) has fix address. Otherwise you will need to use a SIP server (This is the main role of a SIP registrar server: to keep a track of the user locations). There are plenty open source software for this like the above mentioned Asterisk but you can also find a lot of services offering free calls (free from softphone to softphone; they charge only if you wish to make outbound calls to landline or mobile numbers).

Categories

Resources