Jump to content
PortSIP PBX for Unified Communications
Sign in to follow this  
András Tóth

Handling of ringing

Recommended Posts

Dear PortSIP Support,

 

Recently we have purchased your VOiP SDK. We are implementing basic VOIP functionallity to our Xamarin Forms application.

How do we need to implement the ringing of the incoming call?

How will the application know, even if it is terminated, if there is an incoming call?

Does the SDK implement the functionnality of the iOS UICallKit?

 

Share this post


Link to post
Share on other sites

How do we need to implement the ringing of the incoming call?

For iOS, if you enable CallKit, the ringing is play by iOS System.

If not enable CallKit, you can play the ringing in onInviteIncoming or OnIncomingCallWithoutCallKit.

How will the application know, even if it is terminated, if there is an incoming call?

This must use PUSH, it's need server support.

Our PortPBX is support PUSH, You can refer the manual :

https://www.portsip.com/knowledge-base/implement-push-notifications-in-xamarin-android-app-with-portsip-pbx-12-0/

https://www.portsip.com/knowledge-base/implement-the-push-notifications-in-native-ios-app-with-portsip-pbx/

Does the SDK implement the functionnality of the iOS UICallKit?

Yes, our Sample have implement CallKit.

Share this post


Link to post
Share on other sites

We are using FreeSwitch for calls. What notification payload do we need to send, if we want to take back the app from terminated state?

 

Share this post


Link to post
Share on other sites
Posted (edited)

Our application uses Xamarin Forms, wich behaves differently like your sample app. We have created an AndroidBindings android project (and also iOS) wich wraps the SDK functionnality. We use dependency service, to register the current platform implementation for it. On a certain screen of the app, ViewModel gets the platform specific implementation from dependency service, and ensures the connection between the VOIP server, and the SDK. When the application is in foreground, we can make calls, receive calls, hang up etc. I also understand, that we need to send a push notification for the devices. We are currently working with push notifications, using a C# backend of FCM, and Plugin.FirebasePushNotification NuGet on the client side. This pair is working fine for normal push notifications. I'm trying to figure out, how to start the app, to start communication even if it is in terminated state. I have already noticed, that iOS is not allowing us to fire up the application and bring it to front, thats why I am informed, that CallKit is necessary, but it does not combine in my head, how to pass the information for your SDK from the push notification. The other unknown scenario is, how CallKit will build up the connection between the app and the VOIP server. Also do not understand how Android will handle this notification. From version Q, Android disabled the option to bring activities to front.

Edited by András Tóth

Share this post


Link to post
Share on other sites

We are using FreeSwitch for calls. What notification payload do we need to send, if we want to take back the app from terminated state?

5 hours ago, András Tóth said:

We are using FreeSwitch for calls. What notification payload do we need to send, if we want to take back the app from terminated state?

 

this is our PBX used payload, you can change as you like.   

Payload: {

   "message_id" = "96854b5d-9d0b-4644-af6d-8d97798d9c5b";

   "msg_content" = "Received a call.";

   "msg_title" = "Received a new call";

   "msg_type" = "audio";//audo or video

   "x-push-id" = "96854b5d-9d0b-4644-af6d-8d97798d9c5b";

   "send_from" = "102";

   "send_to" = "sip:105@portsip.com";

   }

Share this post


Link to post
Share on other sites
5 hours ago, András Tóth said:

What does enableCallKit method exactly do? Do we need to do something else than setting this to true?

Simply put, it is to let the example program use the system's CallKit interface.
The SIPSample program has complete code using CallKit, you can refer to our code

 

Share this post


Link to post
Share on other sites
4 hours ago, András Tóth said:

Our application uses Xamarin Forms, wich behaves differently like your sample app. We have created an AndroidBindings android project (and also iOS) wich wraps the SDK functionnality. We use dependency service, to register the current platform implementation for it. On a certain screen of the app, ViewModel gets the platform specific implementation from dependency service, and ensures the connection between the VOIP server, and the SDK. When the application is in foreground, we can make calls, receive calls, hang up etc. I also understand, that we need to send a push notification for the devices. We are currently working with push notifications, using a C# backend of FCM, and Plugin.FirebasePushNotification NuGet on the client side. This pair is working fine for normal push notifications. I'm trying to figure out, how to start the app, to start communication even if it is in terminated state. I have already noticed, that iOS is not allowing us to fire up the application and bring it to front, thats why I am informed, that CallKit is necessary, but it does not combine in my head, how to pass the information for your SDK from the push notification. The other unknown scenario is, how CallKit will build up the connection between the app and the VOIP server. Also do not understand how Android will handle this notification. From version Q, Android disabled the option to bring activities to front.

1. CallKit is a UI, can't received call.
   VoIP Push can start the APP when the APP is terminated. 

About iOS 13 PUSH, please refer https://forums.developer.apple.com/thread/117939

2.Android Q is system limit, you can refer this

https://developer.android.com/guide/topics/ui/notifiers/notifications#foreground-service

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...