Forum Discussion
Braze SDK: Logged Out/In States & Push States
- 2 months ago
Hello inespais based on your requirement, it is best to use disableSDK on device when a user logs out.
This will stop data collection and any tracking on that specific device. Other devices registered for that user will still work.
When the user login again, then you can use enableSDK to resume the data collection.
ECulle thank you for your response. I would agree that generally the custom attribute identifying whether the user is logged in/out is a good way to approach it, however, in this case that would mean that if you logout from one device, you also stop receiving comms on additional devices where you're still logged in... So ideally I want to find a solution that works on the device-level and doesn't affect the entire user profile (and all other devices associated with it).
Any advice?
Hello inespais based on your requirement, it is best to use disableSDK on device when a user logs out.
This will stop data collection and any tracking on that specific device. Other devices registered for that user will still work.
When the user login again, then you can use enableSDK to resume the data collection.
- inespais2 months agoMentor
Manoj__ hello & thank you! Just to double check, do you also disable the push token? I.e. on iOS stop APNs delivery via UIApplication.shared.unregisterForRemoteNotifications(); and on Android stop FCM delivery via FirebaseMessaging.getInstance().deleteToken() ?
I believe that would be the only way to really ensure no push notifications can be delivered...- Manoj__2 months agoVisionary
Yes, that will stop the device from receiving the push notification. However when the user login again then you will to request a new token from APNS and FCM.
Related Content
- 3 years ago
- 3 years ago
- 3 years ago
- 3 years ago