How can I do paymentQueue(_:shouldAddStorePayment:for:) method by IAP from AppStore as Sandbox tester?

As the apple document, paymentQueue(_:shouldAddStorePayment:for:) method should be called when an app user purchased a product including any subscriptions from App Store.

So, I implemented the delegate method, however the method wasn't called when Sandbox Tester purchased it.

How can I catch the payment request by the method in Sandbox or I cannot do that in Sandbox environment?

Replies

Check that you have implemented your transaction observer as recommended in Setting Up the Transaction Observer for the Payment Queue. StoreKit automatically notifies a persistent transaction observer whenever there are pending transactions in the payment queue.