I am implementing a subscription in a Flutter app for the first time, and this app is a little bit special with the user account. Being logged in is a premium feature. Premium gives you the possibility to download other users published content, backup to the cloud, sync of your data between devices. But…
1. You don’t HAVE to login.
2. You have to get premium first to be able to login .
So I did what I thought was right, I just use the anonymous id until the user logs in, then they are also logged into revenuecat with their firebase uid.
The problem is that they could log out, and then log in with another account. The they’re logged in to revenuecat with the new uid.
But I noticed some problems. I did this:
1. Get premium
2. Login
3. Log out
4. Log in with another account
After step 4 the premium went away and I couldn’t restore it. I’m not loggin the user out from Revenuecat at any point, since that also made me lose premium.
Now I’m leaning more towards just skipping logging the user into revenuecat alltogether, and just use the anonymous id. WOuld that actually be a problem?
When the user syncs to the server I send the current RC id to the backend and updates it in the database, so I have that as a reference for support. The user can also tap a button to copy the RC id if they want to send it.
I’m wondering:
a) Is it ok to only use anonymous id? Will the user keep premium status no matter if the login in my app or not, and will they keep it between Android devices (if they have the samme Google play account)
b) If I go with loggin the user in and out of RC with my app login/out, what should I set the Handling multiple app user IDs to? I currently have Transfer to new App Iser ID, is that wrong? Is that why I have problems?
