appStoreReceiptURL returning no receipt

Seen another report of this in the "Other" section of the forum. This seems to only effect iOS 10 with iOS 9 correctly returning a valid receipt location for both sandbox and release.


iOS 10 the URL seems to return a sandbox receipt which doesn't exist so it's causing issues enabling the subscription functionality for our users as we have no receipt to confirm purchase.


Would love any thoughts on this one.


Other thread on this issue: https://forums.developer.apple.com/message/183382#183382

Replies

Have you used SKReceiptRefreshRequest? Depending on how the app is installed on the device there may or may not be an initial receipt.

I have a build going out shortly with that implemented. One downside to that is the user gets shown another password prompt, if they cancel then the rest of the subscription code isn't triggered.

Your code can first look for the receipt and if it is there and if it is current grant the user the appropriate IAP/subscription rights. If the receipt is not present, or does not indicate the user has certain rights then don't refresh the receipt unless the user tries to do something that requires IAP/subscription rights. And when they do, tell them that 'it appears your subscription is not active - do you want to buy or restore a subscription?' Only then - if they chose 'restore' - do a refresh; although I prefer to do a restoreCompletedTransactions since the user may be using a new device.