Only receiving Notification, not call of upcoming calls

I have implemented the latest (version 1.2.0) sample app example in my application and everything works great except the upcoming call alert. In the latest version the receiver only receives a notification of upcoming call even if the phone is not in use.
How can we receive the notification like whatsapp does when phone is in use and full screen calling interface when the phone is not in use??

1 Like

@kckern @Alex_Preston can you guys please help with this

Hey @Nemi what SDK are you using? iOS or Android? Could you also provide a snippet of how you are handling incoming calls?

@Alex_Preston we are using Android SDK. we have added the exact code as shown in quickstart call sample app( version 1.2.0) i.e.
https://github.com/sendbird/quickstart-calls-android
I also tried your sample app and it also receives only notification doesn’t matter if the app is in foreground or background.
I couldn’t find the full screen layout code in the sample app.
Have you guys added the full screen incoming call layout or is it just the call notification with option to accept or reject in the latest sample app code?

Ahh, I get it. I was using 1.1.3 sample app, which does show how to display full screen notifications as you can see in image attached. Hadn’t pulled 1.2.0 to see that they changed the implementation. If you want a rough idea as to how it used to be done, I think you can reference this commit. Essentially in the SendBirdCall.addListener of the BaseActivity, they have a call ActivityUtils.startCallActivityAsCallee(context, call); this launches the Activity for either Video call or Voice call(Based on which it is, the appropriate UI will be displayed). Does this give you a better idea?

@Alex_Preston in our apps last version we were using the 1.1.3 sample app and as per your comment it does have upcoming call screen activity but it requires overlay permission to show the upcoming calls. Is there any way we can show upcoming call screen without requesting the overlay permission as our customers are not happy with providing this permission? That is the reason i was updating the version from 1.1.3 to 1.2.0 but i guess the latest sample app code has it’s own limitation.

1 Like

Thanks for the additional context. I think it depends on the situation, you can see the list of ‘exceptions’ to the rule here. In general I don’t think there is an easy way around this without explicitly granting:

<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" />

Which is why our new sample removed it. So I would say no there isn’t really a way to get around it.

@Nemi any luck with this?

how u handled it? i can’t see the screen for an incoming call or even this line
ActivityUtils.startCallActivityAsCallee(context, call);

can you tell me how you deal with it?

@Mes_Android i couldn’t find any better solution for this so i had to go ahead with the previous 1.1.3 version, where i am specifically asking for “Overlay Permission” from the user to show the incoming call screen.

@Nemican you please share with me the sample with 1.1.3?

@Mes_Android here is the link to the commit.

@Alex_Preston I already cloned that commit and I still get the incoming call as a notification not as the pop-up screen, I’d like if someone can assist me with sample code for that, also, I don’t know guys how you not handling it like pop-up, not notification :smiley:

also, I wanna report an issue, for some time my friends tried to call me on this app ( i didn’t open for a long time but he said the phone is ringing on his side ) I didn’t get a notification or calling sound, I asked him to re-try after I open the app, and set to background, I got sound only and no notification to answer it, I hope if you can justify that too for me, please.

Hey @Mes_Android,

Any chance you could provide a snippet of your code on how you are trying to do it? That code shows how it launches an activity once a notification comes in.

Can you verify that the push token is valid and active?

@Mes_Android you can also refer to the version 1.0.2 , this has the overlay permission and calling screen which maybe you are looking for.

2 Likes

I can’t share my code, can you please create me a simple sample for full screen, please?

yes, valid and active

tested and not working :frowning:

Hey @Mes_Android,

The simple sample I would create would do pretty much the same thing as the code I have linked which works for me. Unfortunately unless I see how you are trying to bring up full screen it makes debugging/pointing you in the right direction more difficult. Are you sure you have the appropriate permissions specified?

so, if u have code works for you, please share it’s repo link for me so I can change app_id with mine and test it.

Hey @Mes_Android,

The repo I linked above does work I believe the one @Nemi posted works as well. Here is the link again.

for once try this one. it’s version 1.1.3 and it’s working fine as i am currently using this one. Else if possible please share your code sample of how you are handling the calling activity.

1 Like