Is it possible to automatically restore purchases of applications in iOS?

I'm going to add the ability to remove ads from the free app that I have on the App Store. I know that I will need a way to โ€œrestoreโ€ IAP on devices that have reinstalled the application, etc.

Is there a way to automatically determine if a user has purchased and installed an โ€œupdateโ€, perhaps in the didFinishLaunchingWithOptions method, etc.? I can enable the restore button, but I think that it would be neat to automatically recover if the user should not have thought about it. Is this something that can / is done?

+6
source share
1 answer

It's amazing what you think of the little details. Go on!

Unfortunately, there is a reason why this is not done in applications: the scary password dialog. When you try to restore the IAP, the system asks the user for the password for their iTunes Store.

Not really the best user interface when a large ugly password dialog appears as soon as the application opens. The user (if configured for security) is likely to reject the dialog.

On the other hand, users are used to click the "Restore purchases" button. It makes sense that a password is required to restore a purchase, and thus it will give it.

Just follow the standard, normal, boring restore button. Keep thinking about these little things though!

+11
source

Source: https://habr.com/ru/post/958671/


All Articles