3
\$\begingroup\$

How do I check if an iOS subscription is active? Subscriptions are the only type of purchase available; however, there are several subscription lengths. I have scoured the internet, but all I can find is receipt verification.

The following code seems to work for Android:

var products = storeController.products.all;
bool subscribed = products.Where(p => p.hasReceipt).Count() > 0;

(although I am not sure if it takes the subscription's expiration date into account.)

But this does not work for iOS. How can I check to see if they have a valid iOS subscription?

\$\endgroup\$
1
\$\begingroup\$

Unity now has a built in SubscriptionManager. You can use it to determine Subscription validity.

https://docs.unity3d.com/Manual/UnityIAPSubscriptionProducts.html

| improve this answer | |
\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.