4

A question regarding in-app purchase auto-renewing subscriptions:

I'm unclear how to handle the case where a user purchases multiple subscriptions of differing durations. It seems that Apple will recognize if the user has already purchased a given SKU (based on product-id) and prevent re-purchasing (my app gets a failed-transaction event in this case), but if I offer the same content using different product-ids having different durations, then the user can potentially purchase twice or more.

Even if I hide the additional purchase options once the user has subscribed once, they could potentially buy another subscription on an alternate device, and that purchase would/could ultimately be restored to the other device already having a subscription.

Am I supposed to track purchased subscriptions by transaction-ID and product-ID, and calculate an ultimate expiration date? That seems complicated.

TomSwift
  • 39,369
  • 12
  • 121
  • 149
  • This link https://stackoverflow.com/questions/22680059/auto-renewable-subscription-in-ios7/45220204#45220204 might help you. – Arun Jain Jul 27 '17 at 12:44

4 Answers4

12

Before I proceed, please see the comments on this linked post on why it may be a bad idea to use auto-renewing subscriptions.

Stop me if you've heard this before.
When you choose Auto-Renewable Subscriptions in iTunes Connect, you are given the opportunity to add multiple durations, with different Product ID's to one subscription Family. Apple won't allow a user to purchase multiple, overlapping subscription durations within one family. (If you're using multiple families in your app, please explain the reasoning, so I can give you guidance based on that).

In fact, Apple won't let the user stack different durations of a subscription within one family.

Here's an example.
I (as a user) download the hypothetical Acme app and subscribe with a 1-month subscription. If I do nothing, my subscription will automatically renew at the end of the period with another 1-month subscription. And so on.

But instead I go back in and purchase a 6-month subscription. Apple will tell me (with an alert) that my 6-month subscription will begin at the completion of my current 1-month subscription, and would I like to proceed. If I say yes, Apple will make note of it, but they won't charge me until my current 1-month is up.

Now if I go back in again and purchase a 1-year subscription, then again Apple would respond with an alert telling me that it will begin at the end of my current 1-month subscription. It won't get added to the upcoming 6-month subscription. It will replace it.

In Summary
So a user can only have one Current subscription and one Upcoming subscription (within a family. This is why you use a Family of product durations within a subscription. If you create multiple subscription families then they can exist simultaneously, and you loose that protection.

If, as a developer, you'd like to manually extend, shorten, cancel or stack subscriptions, you should be doing it with Non-Renewing Subscriptions. And if you read the link I posted at the top, you'll realize that Apple may force you to do that.

Community
  • 1
  • 1
Andrew
  • 8,363
  • 8
  • 43
  • 71
  • Thanks, Andrew. I did figure all this out, months ago, and did get my auto-renewing app approved. I've since been asked to switch to non-renewing subscriptions, however, due to a "policy change" (grr...). – TomSwift Jan 23 '12 at 17:58
  • @TomSwift, another twist that you may have run into. My app was rejected again. Even though I implemented `Non-Renewable Subscriptions` (NRS's) like they asked, now they're saying they don't like my use of iCloud to sync the subscription across a user's multiple devices. For those who don't' know, Apple requires you make this type of IAP sync across all a user's devices, *but* `restore` doesn't work with NRS's so they want you to implement an *optional* registration mechanism so a user can login to retrieve functionality they've already purchased elsewhere. – Andrew Jan 24 '12 at 02:11
  • @Andrew Hey can u explain the scenario where I have two families say Gold and Platinum and the user wants to jump from family one to two? Is this allowed from the manage subscriptions section in the app store or iTunes or can it only be done from the app? – Nitin Nov 23 '12 at 06:49
  • @Nitin that's a good question. I've been out of the loop for a while on ARS's because I've been using NRS's but I'll try and answer best I can. From within your app a user can choose a new duration within a given subscription family. They can also start a new subscription in a new family. But they can't cancel any subscription from within your app. And I think if you need them to change families, they'll need to cancel the first or they'll start getting charged for both families. And I don't think there's a way to tell Apple that one family should supersede the other. – Andrew Nov 24 '12 at 16:56
  • @Andrew Yes you are correct. But my concern is this, its possible to change the duration of your subscriptions from outside the app as these are listed under the "manage subscriptions" section in iTunes and App store app. Similarly, are the products of families other than the one that you are subscribed to also listed under "manage subscriptions"? If yes then obviously the user can start a new subscription from outside the app? How to handle that? Also, do you know of any app that has ANRs with multiple families, may be one of your creations :) – Nitin Nov 26 '12 at 05:20
  • @Nitin I see what you're saying. I don't know. I'd have to build a test project to find out, so that's what I suggest you do. I'm sure a user can change durations within a family from outside the app (under "Manage Subscriptions"), but I don't know if other families will also appear in that section. This is a unique-enough case that I'd be surprised if anyone had the answer without testing it. Sadly I don't know of any example apps to show you. My app uses Manually Renewing Subscriptions which aren't managed from outside the app. – Andrew Nov 27 '12 at 07:41
  • @Andrew We are going down the same road i.e. trying and getting rejected :) Thanx a ton for such prompt replies, u rock \m/ – Nitin Nov 27 '12 at 09:31
  • If a user subscribes for say monthly and later goes over to subscribe for yearly inspite of the alert. The receipts will show both monthly and yearly as active. How do we handle this? – iPP Nov 08 '16 at 06:34
0

Please consult Appstore Subscription page for latest information https://developer.apple.com/app-store/subscriptions/. The gist is to use group to define multiple subscription channels

Creating Subscriptions

Users can only buy one subscription within a subscription group at a time. If users would want the ability to buy more than one type of subscription — for example, to subscribe to more than one channel in a streaming app — you can put these in-app purchases in different subscription groups.

Upgrades, Downgrades, and Crossgrades

When a user upgrades to a subscription of any duration, or crossgrades to a subscription with the same duration, the service level change goes into effect immediately. When a user downgrades to a subscription of any duration, or crossgrades to a subscription with a different duration, the change goes into effect at the next renewal date.

onmyway133
  • 45,645
  • 31
  • 257
  • 263
0

Having a similar issue. Had an app approved with two subscription groups (for annual and monthly). They are auto renewing subscriptions. We have hundreds of users and they want us to change by deleting subscriptions groups and create a new one. Is it possible to create a new group and move existing products to that? Not sure what to do here and what happens next.

kierandes
  • 161
  • 3
  • 16
0

try using MKStoreKit 4, it has support for auto renewable subscriptions http://blog.mugunthkumar.com/coding/mkstorekit-4-0-supporting-auto-renewable-subscriptions/

rkheik
  • 39
  • 8
  • For various reasons im not using mkstorekit. For one, i have different requirements serverside than their simple php script. Also im not convinced they handle this scenario that Im asking about. (someone prove me wrong, please) – TomSwift Aug 17 '11 at 04:15