Solved

Can the same user (same app user id) receive entitlements on multiple devices?

  • 18 August 2021
  • 4 replies
  • 693 views

Badge +2

Hi there! I have a question about RevenueCat logIn (and Blocking Transfers) as introduced in: 

Suppose this is how my iOS/Node app is designed to work:

  1. I have a user database and each user has a unique record and id.
  2. We require users to sign up with email and password before they’re shown the purchase flow.
  3. We use their unique database record id as the RevenueCat appUserID when purchasing a package.
  4. Our RevenueCat app is set up to Block Transfers.

If I understand this correctly, this means that as long as a user logs in with the right appUserID, they should have the appropriate entitlement everywhere. That includes different devices on iOS, Android, and web that log in with the right appUserID and use the RevenueCat offerings API. Additionally, if the an entitled user signs out, and someone else logs in from the same device (different appUserID), RevenueCat will pull in THEIR entitlement, which may or may not exist, and would trigger their own Purchase flow if needed. In the other words, purchases won’t be transferred on the same device.

 

Can you help me validate if this is correct?

 

Thank you!

Xavier

Heroic Engineering

icon

Best answer by sundeep 19 August 2021, 22:45

View original

4 replies

Userlevel 3
Badge +8

Hi @Xavier Lopez!

 If I understand this correctly, this means that as long as a user logs in with the right appUserID, they should have the appropriate entitlement everywhere.

Yes, the user will have all entitlements associated with that App User Id. The user will be able to gain access to the content associated with that entitlement wherever you set up the logic to do so.

That includes different devices on iOS, Android, and web that log in with the right appUserID and use the RevenueCat offerings API.

Yes.

Additionally, if the an entitled user signs out, and someone else logs in from the same device (different appUserID), RevenueCat will pull in THEIR entitlement, which may or may not exist, and would trigger their own Purchase flow if needed. In the other words, purchases won’t be transferred on the same device.

Yes, when a different App User Id logs in, they’ll only have the entitlements associated with their id. Assuming the user hasn’t changed the underlying store account for that device:

  • If they try to restore purchases, it’ll trigger an error that the receipt is already in use (assuming Block Restore setting for your app).
  • If the user tries to make a purchase already associated with the underlying store account, it’ll trigger an error that the subscription is already active.
Badge +6

Hei there, sorry for hijacking this thread, but I am waiting for an answer about a similar question in another thread 

which might be of interest.

Depending on wether the user is currently logged into the store account from which the purchase was made or not, changes the outcome when calling the logOut() function.

  • if the user is logged into the same store account, the appUserId will loose the subscription on all devices
  • if the user is NOT logged into the same store account, the appUserId will KEEP the subscription everywhere

At least this is what we saw in our tests and what also makes sense…

But I am waiting for confirmation on this in the other thread.

 

Best,

Felix

Userlevel 3
Badge +8

@Felix B The App User ID prior to logout() will not have lost the entitlement - it’s just that when you call logout(), a new App User ID is generated that doesn’t have the entitlement, which is why the user doesn’t have access to the entitled content at that point.

Badge +6

@sundeep thanks for the reply. 

I will check this with the devs of the app. But as far as I remember the App User ID actually lost the entitlement on the device on which the purchase was made.

This was tested the following way (the user is logged into different google accounts on device 1 and device 2):

  1. Purchase the subscription on device 1 and log into (or create) an user account (not google account)
  2. log in to this user account on device 2 → User has a valid subscription on both devices
  3. User logs off the user account on the first device → User has not valid subscription on BOTH devices
  4. User can restore the purchase on device 1 (without being logged into the user account) → User has a valid subscription on device 1

Note: If the user would only log out from the second device, he would not loose the subscription on device 2.

 

This does seem logic to us, but is contrary to what you said in your last comment, at least in the first case…

Best,

Felix

Reply