Skip to main content
Question

Managing subscriptions on multiple devices with the same App User ID


Forum|alt.badge.img+1

Hello,

We’ve got a Flutter app that requires user register / login and we’re providing the SDK with an App User ID tied to those credentials to allow our users to share the same subscription among multiple devices. 

This is working fine and we recover the same Entitlements no mater the device the user Logs In.

What we’re having problems is with subscription management since many actions (Upgrade, Downgrade, etc...) will only work from the device that did the original purchase as stated in the docs:

 

Managing Subscriptions

A user can only manage their subscription on the platform it was purchased from.


Having the same App Account logged in in two devices with different Google Play accounts and calling Purchases.purchasePackage() generates the following error:

PlatformException(4, One or more of the arguments provided are invalid., {code: 4, message: One or more of the arguments provided are invalid., readableErrorCode: PurchaseInvalidError, readable_error_code: PurchaseInvalidError, underlyingErrorMessage: Couldn't find existing purchase for SKU: <sku>, userCancelled: false}, null)

 

And on a second try:

PlatformException(15, The operation is already in progress., {code: 15, message: The operation is already in progress., readableErrorCode: OperationAlreadyInProgressError, readable_error_code: OperationAlreadyInProgressError, underlyingErrorMessage: , userCancelled: false}, null)

 

After enough time has passed we’ll get a PlatformException 4  once again.

This is indeed the expected behaviour but we need a way to tell which devices are using the same Store Account that did the original purchase from those that don’t so we can disable unavailable options there.

 

We’ve checked the PurchaserInfo and EntilementInfo objects but found no way to tell.

We were actually expecting this to be available under ownerShipType but it shows as OwnershipType.unknown for everyone.

Is there any way from within the SDK to handle this?

 

Thanks in advance,

Roger

 

6 replies

joshdholtz
RevenueCat Staff
Forum|alt.badge.img+5
  • RevenueCat Staff
  • 92 replies
  • April 11, 2022

👋 Hey @rlacamara-www!

I did some digging into this today with another engineer and it doesn’t appear that we have a great way within the SDK to handle this 😔 

One of the solutions would be to manually do a purchase history query. If there are no purchases on that device but there it an entitlement then you would know to not show that upgrade/downgrade options. But it might also get weird if there is a purchase for that user but its different than the logged in RevenueCat user.

I’m going to keep noodling on this but just wanted to let you know that we couldn’t think of an already built-in solution!


Forum|alt.badge.img+6
  • Dedicated Member
  • 29 replies
  • April 21, 2022

Managing Subscriptions

A user can only manage their subscription on the platform it was purchased from.

 

Does this statement really mean the user can only manage their subscription on the device in which he purchased the subscription? For what I read it’s actually saying “on the platform”, not “ont he device” it was purchased from.

For example, if a user has purchased a subscription in an Android device, he could then only manage his subscription on Google Play Store on any Android device, whereas if the user has purchased the subscription on an iPhone then he would only be able to manage his subscription on Apple’s App Store on any iOS device.

Is my understing about it correct? Or does the user really can only manage his subscription on the actual device he used to purchase the subscription? 


joshdholtz
RevenueCat Staff
Forum|alt.badge.img+5
  • RevenueCat Staff
  • 92 replies
  • April 21, 2022

Hey @UlyssesAlves

Is my understing about it correct? Or does the user really can only manage his subscription on the actual device he used to purchase the subscription? 

 

The user can manage their subscription from any device on the platform it was purchased (as long as the same account that purchased the subscription is the one that is logged in)

Example: I have an iPhone and an iPad. I can cancel my subscriptions on either of those because I’m logged into the same Apple ID on both.

Hope this helps!


Forum|alt.badge.img+6
  • Dedicated Member
  • 29 replies
  • April 21, 2022

The user can manage their subscription from any device on the platform it was purchased (as long as the same account that purchased the subscription is the one that is logged in)

That’s what I thought. 

But if this is the case, I can’t see why it could be an issue as described by @rlacamara-www when he said

What we’re having problems is with subscription management since many actions (Upgrade, Downgrade, etc...) will only work from the device that did the original purchase as stated in the docs:

Wouldn’t it be a solution @rlacamara-www if you write your code in a way that’s not dependend upon the device on which the subscription was purchased? Then you could just verify the platform (Android or iOS) rather than the physical device.


vic-a563d7
Forum|alt.badge.img+6
  • Dedicated Member
  • 44 replies
  • November 22, 2023

Running into a similar issues myself too.

First, to clarify, so is it the platform or the device that matters? @joshdholtz  your example was iPad and iPhone but the question was about iOS vs Android. If I purchase on Android phone and then login on my iPad, I can definitely compare the platform vs the “store” value in customerInfo object to tell the iPad app to repoint the user back to Android.

How would this work for repeated or multiple purchases, not just the first one?

 


Forum|alt.badge.img+6
  • Dedicated Member
  • 29 replies
  • February 28, 2025

First, to clarify, so is it the platform or the device that matters?

 

@vic-a563d7 The platform and the device and the user’s account. 

  • The platform because the user’s payments and thus money goes only to the platform owner (e.g: Apple or Google) in which the user made the purchase. If your app runs both on Android and iOS, then the user may choose in which of those two platforms he wants to buy a subscription. If he buys it on Google, Apple will not make any money with this purchase, and vice versa.
  • The device because the user’s device determines which platform the app is running on, which could be Google Play/Android or App Store / iOS on this context.
  • The user’s account because the user may use the same RevenueCat account to access your app on the different platforms. The user’s account is the means by which RevenueCat can know that your app’s user is accessing your app on Google or on Apple, and if the user bought the subscription on Google or Apple, etc.

How would this work for repeated or multiple purchases, not just the first one?

 

If by “repeated or multiple purchases” you mean recurring subscriptions, it works just ike I described above. For consumable products it should be very similar too, but someone else could give you a better answer on this subject.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings