react-native-webrtc / react-native-voip-push-notification

React Native VoIP Push Notification - Currently iOS only
ISC License
213 stars 83 forks source link

Listener 'register' never trigger to get device token #35

Closed hinodi closed 4 years ago

hinodi commented 5 years ago

I was config successfully, but this listener never trigger. Here is my code: VoipPushNotification.addEventListener('register', token => {

});

JB-CHAUVIN commented 5 years ago

Same issue goes for me.

dnolbon commented 5 years ago

it started working when i turned on Push Notifications in Capbilities Here is my settings which works: Screenshot 2019-06-13 at 08 39 17 Screenshot 2019-06-13 at 08 40 33

I hope this helps

priyasamyal commented 4 years ago

it started working when i turned on Push Notifications in Capbilities Here is my settings which works: Screenshot 2019-06-13 at 08 39 17 Screenshot 2019-06-13 at 08 40 33

I hope this helps

Works well Thanks

jayrenteria commented 4 years ago

Even with this capability on, I don't reliably register a voip token. Is there a way to retrieve the token if it's already been registered? Or does it fire the register call every time?

zxcpoiu commented 4 years ago

Under development ( build via xcode and test ), no matter Debug or Release, for some unknowing reasons, especially when you install/uninstall switching between Release/Debug, will happen.

Even we can see we've call register successfully, the ios just stop call didUpdatePushCredentials so you never get refreshed token...

There are bunch of questions on the internet, the solution in short:

Then rebuild.

The most upvoted option is: reboot your device and mac. Sometimes everything did not work, but only after few hours, it worked suddenly.

Maybe apple's push token server somehow banned the developing app (?)

Anyway, if all steps didn't work. You just uninstall app, clean all data and restart all devices and mac ( close xcode ), then just do another thing. Then try it maybe 2~3 hours later. :(

zxcpoiu commented 4 years ago

AFAIK, from my limited experience, there is no way to retrieve / refresh / revoke tokens. The only thing you know is the token previous stored on your server.

Please share if somebody knows some tricks, even evil's one. :)

djalmajr commented 4 years ago

I did all this things and yet, no device token... Can anyone help me with this? Simple demo:

https://github.com/djalmajr/CallKeepDemo

PS.: Did not work on iOS 13.x

jpudysz commented 4 years ago

@djalmajr hard reset your device. It should work

oojikoo commented 4 years ago

Under development ( build via xcode and test ), no matter Debug or Release, for some unknowing reasons, especially when you install/uninstall switching between Release/Debug, will happen.

Even we can see we've call register successfully, the ios just stop call didUpdatePushCredentials so you never get refreshed token...

There are bunch of questions on the internet, the solution in short:

  • clean all data / cache you can, including xcode's Derived Data
  • disable / re-enable push related capabilities and background mode
  • disable / re-enable signin related auto manage

Then rebuild.

The most upvoted option is: reboot your device and mac. Sometimes everything did not work, but only after few hours, it worked suddenly.

Maybe apple's push token server somehow banned the developing app (?)

Anyway, if all steps didn't work. You just uninstall app, clean all data and restart all devices and mac ( close xcode ), then just do another thing. Then try it maybe 2~3 hours later. :(

"Sometimes everything did not work, but only after few hours, it worked suddenly." happend to me as well.

rajngarg commented 4 years ago

I am having the same issue nothing worked. Please help if anyone made it work. Thanks in advance

stephanoparaskeva commented 3 years ago

What do I do, my 'register' never gets invoked, how do I solve this?

stephanoparaskeva commented 3 years ago

Even with this capability on, I don't reliably register a voip token. Is there a way to retrieve the token if it's already been registered? Or does it fire the register call every time?

Did you manage to find a way to reliably register a voip token? mine stopped calling 'register' randomly

CMLCNL commented 3 years ago

Same issue, Never triggered i try to everythings..

uday8373 commented 10 months ago

In my case event is getting called but, the token is coming as empty string always. Please help./