How can I know if the user reinstalls the app or is using 2 devices with the same account? Is it possible to detect it?
A user has an FCM token per device, without a unique device id I don't know how to differentiate them.
How can I know if the user reinstalls the app or is using 2 devices with the same account? Is it possible to detect it?
A user has an FCM token per device, without a unique device id I don't know how to differentiate them.
Firebase Cloud Messaging only knows about app instances, a single app installed on a single device.
If your app associated that with users, the logic of how to do so is application specific. If you want to alert the user on all their devices, you'll want to store multiple tokens per user. If you want to only alert the user on their active or most recently active device, you'll only want to store a single token per user. All these scenarios are possible, but you'll have to implement as part of your application logic.
Also see: