APNS token valid even after Uninstall

Hi,


I was trying to detect whether my app is uninstalled or not. So I was trying to send push notification on the device from which I have uninstalled the app. As per the Docs and Videos, My token should have been invalidated and I would be getting 410 error. But I am receiving 200 (Success). I waited for 3 days after uninstall How this token invalidation works. If this works for anyone, Please share your views.

I have read other articles but none of them was satisfactory.

Post not yet marked as solved Up vote post of abhishek21PTM Down vote post of abhishek21PTM
4.1k views

Replies

From Apple's dev team:


APNs will eventually report that the push token is invalid after an app has been uninstalled. The time between an uninstall and the invalidation is dependent on various factors, and the details of when this will happen is not documented.

The guidance here is to send the puhes to devices until you receive an error response from APNs. Sending pushes to non-existent apps does not cause any harm.


We have no recommendations for determining when users uninstall apps. Our current implementation is indeed designed to avoid such detection by developers, and as such, we have no services, API, or code samples to have alerts sent when an app is uninstalled.

"Sending pushes to non-existent apps does not cause any harm." What if we want to know if a person did not receive a notification, so maybe we can send him an email instead...?
  1. User A is logged in, endpoint registered
  2. User uninstalls the app, endpoint is still registered
  3. User reinstalls the app, does not login

Unauthenticated client keeps getting pushes for the previously registered user A.

One might argue that it is not an issue and the client could simply ignore the pushes, this is not entirely true if we talk about VoIP notifications since Apple has a ******** requirement to notify CallKit within 5 seconds.