App keeps getting rejected because the reviewer gets 'Cannot connect to iTunes store' error during IAP

Hello,


I'm trying to submit the first version of my app, but I keep getting a rejection because the reviewer is failing to purchase my non-consumable in-app purchase. Everything works fine in sandbox mode, but something is different for them which makes it fail with an SKError.Code == .unknown and localizedDescription of 'Cannot connect to iTunes Store'. I've resubmitted many many times and asked for clarification, but I'm not getting any more info. I'm not doing anything fancy, from the screenshot they sent me it seems the SKProduct request goes through fine, but the purchase fails. The in-app purchase is showing 'Waiting for Review' in app store connect, not sure that has anything to do with it.


Has anyone seen something like this? What do I do?

Accepted Reply

It turns out I was calling things in the wrong order, you need to follow https://developer.apple.com/documentation/storekit/in-app_purchase/setting_up_the_transaction_observer_for_the_payment_queue *exactly*

Replies

Just to clarify: I'm not using receipt validation. Just submitting an SKPayment with my product, which keeps on failing.

>Everything works fine in sandbox mode


You can try it using TestFlight and confirm it works there.


Other things to consider:


- Since the IAP is marked 'waiting for review' that means it was attached to the binary. But didn't it get marked 'needs developer action' when the app was rejected? If not - why not????


- Mark the IAP 'cleared for sale'


- Are your banking contracts up to date?

>I keep getting a rejection...


What do those rejections say, exactly?

It turns out I was calling things in the wrong order, you need to follow https://developer.apple.com/documentation/storekit/in-app_purchase/setting_up_the_transaction_observer_for_the_payment_queue *exactly*

You wrote:


>Everything works fine in sandbox mode


Can you explain what "wrong order" works in the sandbox mode but not in App Review such that the 'correct answer' is what you marked above? Or is the correct answer:


"It turns out it was not working in the sandbox mode. Here's why I thought it was....."