Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to synchronize/verify in-app recurring subscriptions with a web server (cross platform subscription)

We run a SAAS Web app and are going to be launching our app in Apple’s app store (up to now we’ve had a mobile Web app).

We want to offer the ability to purchase a subscription in app due to the ease of use for our customers. No problem, we know how to do that.

The question we have is whether there is an easy way to keep our web app's db updated with the user’s current subscription status so if they access our Web app we know whether their subscription is valid.

Ideally it would be great if Apple offered a web hook option where they would post an update to a url on our server. From what I've read this isn't an option.

We can always post the data to our server from the iPhone app when the user logs in, but if the user doesn’t log in on the iPhone for a while the subscription status recorded on our server will be out of date.

How are other people handling this? Are we missing something?

Update:

The closest I've found is this thread: https://forums.developer.apple.com/message/70707#70707

The app gets a receipt the first time it buys a subscription or restores a subscription. The app can send that original receipt to anyone's server. Anyone's server can then use that orignal receipt to verify the current subscrition anytime it wants. You can't do that with a non-renewing subscription but with a non-renewing subscription the user must purchase the extension from the iOS device each time period.

Followed up with this: https://hetzel.net/2011-04-01/server-side-auto-renewable-subscription-receipt-verification/

And from Apple it sounds like they definitely do not make any provisions on their end for synchronization:

Cross-Platform Considerations

Product identifiers are associated with a single app. Apps that have both an iOS and OS X version have separate products with separate product identifiers on each platform. You could let users who have a subscription in an iOS app access the content from an OS X app (or vice versa), but implementing that functionality is your responsibility. You would need some system for identifying users and keeping track of what content they’ve subscribed to, similar to what you would implement for an app that uses non-renewable subscriptions.

like image 699
salonMonsters Avatar asked Nov 06 '15 00:11

salonMonsters


1 Answers

Late to the party, but I think this is a relevant reply to this question:

https://stackoverflow.com/a/47537279/543423

Hopefully this is helpful to someone :)

like image 127
finferflu Avatar answered Nov 04 '22 16:11

finferflu