voximplant / react-native-voximplant

Voximplant mobile SDK for React Native (iOS/Android)
http://voximplant.com
205 stars 39 forks source link

How to handle calls when the app is killed? #143

Open anniewey opened 2 years ago

anniewey commented 2 years ago

Hi, I'm having trouble connecting calls when app is killed. As I'm using OneSignal for notification, I had no idea how to sync the call with notification which is needed to trigger the app to open.

When app is in bg, I used react-native-invoke-app to bring the app back to fg. But when the app is killed, I'm not sure how to trigger the app to launch and connect to the client.

The client returned 480 error almost immediately after the call is initiated. How do I handle calls in this scenario?

call: Call {_VICallConnectedCallback: ƒ, _VICallDisconnectedCallback: ƒ, _VICallEndpointAddedCallback: ƒ, _VICallFailedCallback: ƒ, _VICallICETimeoutCallback: ƒ, …}
code: 480
headers: {X-VI-Hangup-Cause: 'Normal termination'}
name: "Failed"
reason: "Temporarily Unavailable"
michaeldadi commented 1 year ago

+1