I have an app that offers annual, monthly and lifetime subscriptions. They all access the same ‘premium’ entitlement.
If a new in-app user account is created and I restore purchases, I am able to successfully transfer entitlements between users, provided that the parent App Store Sandbox account is the same.
I’m using web-hooks, so whenever a ‘transfer’ event is fired, I can update my database to make sure it is in-sync with RevenueCat. I remove any subscription information from the ‘transferred_from’ user, and apply it to the ‘transferred_to’ user.
This is working perfectly for restoring monthly and annual subscriptions. But there are issues for lifetime purchases.
- Purchase a lifetime subscription using App Store account ‘x’.
- Sign out of Sandbox account ‘x’, and sign into a completely new, unrelated Sandbox account ‘y’ with no purchase history.
- Create a new in-app account using the new Sandbox account.
- Call restorePurchases.
- I would expect that nothing should happen, since Sandbox account ‘y’ is brand new, with no previous purchases. However, a ‘transfer’ event is being fired by RevenueCat and now the lifetime entitlement is transferred across Sandbox accounts from ‘x’ to ‘y’.
I’m rather confused about why RevenueCat is firing a transfer event for completely different App Store Sandbox accounts. Thankfully, this is only happening for lifetime purchases.
Is this just a Sandbox issue? Do I need to ‘Clear Purchase History’ inside the Sandbox settings after I have purchased a non-consumable lifetime subscription in order to stop this from happening?
I’m currently unable to test restoring purchases at all, since now the lifetime entitlement is being passed between every account.
Thank you in advance for your time.