Gifting subscriptions to other users from my app?

I am looking for an API that allows me to gift a subscription to another app from my app. Example: There is an app Swortkit Fitness and I have a subscription for it. I want to create an App that allows me to gift similar workout apps that require subscriptions to other Apple users. I looked in StoreKit, but I am not seeing if this is possible or if there is an API and Documentation out there.


Again, I want to use my app with the StoreKit framework and In-App Purchase to purchase a subscription to another user. How would this be done and is there an API and documentation on this?


Thanks

Replies

There is no way to allow a user to purchase an IAP in an app and gift it to another person for use in that app unless you are the developer of the app. You can purchase gift cards for the App Store and give that gift card to anyone.


If we are talking about your sapp, you can gift from one user to another anything that is able to be purchased multiple times - non-renewing subscriptions and consumables. There are a bunch of ways of doing that. The simplest is to make the IAP on an app and, based on that IAP, write some CKRecord to the public database in CloudKit. Create a corresponding code associated with that CKRecord (e.g. the CKRecordID.recordName) and provide that code to someone else who enters the code into their app. Their app then searches for the CKRecord, destroys the CKRecord and grants them the corresponding IAP rights. You need the CloudKit database to prevent an unock code from being used multiple times.

Post not yet marked as solved Up vote reply of PBK Down vote reply of PBK

What if I want to purchase an Apple Music Subscription for someone else? Is that done the same way? What would be the way to do that?

> What if I want to purchase an Apple Music Subscription for someone else?


You can't.

is there any example out there of the UX around gifting a non-renewing subscription? i cant find any info about this. and can you set up a non-renewing sub to ONLY be available as a gift? we have different gift sub lenghts compared to our standard offering.

> is there any example out there of the UX around gifting a non-renewing subscription? i cant find any info about this.


You just send someone a code and the app verifies that code and gives them a subscription for a fixed amount of time.


> and can you set up a non-renewing sub to ONLY be available as a gift?


Perhaps, it's unclear. But they can only be given from within an app. You can't charge for them or enable them through any means outside the app. The relevant guidelines are:

"If you want to unlock features or functionality within your app, (by way of example: subscriptions......), you must use in-app purchase"

"Apps may enable gifting of items that are eligible for in-app purchase to others."


Relevant to your question is the choice of words "eligible for" rather than "otherwise available as". But any attempt to use this new gifting opportunity to avoid the 30% will be met with rejection, I suspect.