Open tunglthtv opened 9 months ago
Hi @tunglthtv,
Thanks for reporting this issue.
I can confirm, you will not receive a response as expected. All new/recently added platforms send responses as required, though legacy code does not - a rework for this is planned in future.
For now, you can simply call await TwilioVoice.instance.unregister(String)
until such a time the rework is complete.
@cybex-dev I have used to call await TwilioVoice.instance.unregister(String) but on IOS, it's a occur.
Do you have meet it? I am thinking that this error still no unregister device token on IOS.
Hmm, that sounds like a different issue (usually occurs on registering a token sandbox/production APNs confusion). See this for some more information.
When you call unregister(String)
, take a look at the log output, you should see:
Successfully unregistered from VoIP push notifications.
An error occurred while unregistering: {error.localizedDescription}
Do you see any of these messages in the Flutter console output?
@cybex-dev I am not receive any of these message in console. If i use
final result = await TwilioVoice.instance.unregister(accessToken: voiceToken);
if (result == true) {
onSuccess?.call();
} else {
onFailure?.call("Failed to unregister");
}
It will block UI and not get result on IOS
@tunglthtv
Hi, I think the error is from the certificate you provided because as i also face that problem to have ERROR 52134 - this is certificate related that you provided for
You need to use voip services token for this. Also some of that dont usually matter on twilio side since that is connected to notification.
@cybex-dev I am not receive any of these message in console. If i use
final result = await TwilioVoice.instance.unregister(accessToken: voiceToken); if (result == true) { onSuccess?.call(); } else { onFailure?.call("Failed to unregister"); }
It will block UI and not get result on IOS
@tunglthtv the unregister()
call should not freeze the UI unless you've put a breakpoint there. I've done quite a bit of testing today and have not one run into this issue.
Can you provide an MCVe / video of the issue?
@cybex-dev Thanks you for your support. Finally i also get result from unregister token on IOS. But i met other issue that after i unregister and i wanna re-register device token on IOS. I register again but it's seems that old device token sent to Twilio. So it's invalid APNs token. How can i re-generate a new device token on IOS?
2023-11-22 12:37:13.250793+0900 Runner[19255:1019086] LOG|providerDidBegin
2023-11-22 12:37:13.251102+0900 Runner[19255:1019086] LOG|pushRegistry:didUpdatePushCredentials:forType:
Only when I call this function 'TwilioVoice.instance.call.place' will the device token be registered again
@tunglthtv these tokens persist for the device until they are expired. If you seem to be receiving calls meant not for the "current token", this may indicate several possible issues:
I got this error in my application
Hi @cybex-dev,
I am also getting the same issue, I had done some debugging at my end and found that I am able to register and unregister the deviceToken once in the current appLifeCycle. When I try to register device again it only register me to twilio but does not register to VoIP notification service. Don't know why I am getting the issue. Also, this issue only persist in IOS, may be some limitation from IOS end still don't know.
Please let me know if there is any solution to this.
cc: @Erchil66 @tunglthtv @sravanthikotaru
Hi @Punit30 @cybex-dev
Shiv here, i like to connect with you , I also need this SDK setup and working on a call application, if you are available for this help I like to pay for your valuable time.
let's connect on my email shivkumawat1985@gmail.com .
Thank you
@cybex-dev I can not get response from result. It's seem that stuck on IOS
![Uploading Screenshot 2023-11-18 at 15.02.15.png…]()