I\'m developing in-app purchase using this excellent tutorial: http://www.raywenderlich.com/21081/introduction-to-in-app-purchases-in-ios-6-tutorial and I\'m getting an error \"
For testing an app in Sand Box . Follow these steps
To test IAP ,we have to create a test user at itunesconnect.apple.com
Go to Settings and sign out from all active accounts (mail, iTunes & App Store , Game Center)
Restart your device.
Run your app on the device. Click on the IAP button -> choose existing account -> enter apple id and password created from step 1. Now everything will be fine.
I'll answer this in case someone else also comes up against this. I have an app in the app store that was built using the tutorial mentioned in the question, and it performs flawlessly. Unfortunately, in my experience the reliability of the Apple Sandbox servers can be iffy, with no obvious place to check online aside from posting to the Apple forums and hoping for a corroborative reply.
As others have said on StackOverflow, the key is to make sure that:
Almost a year late, but I'm facing the same problem right now. As far as I know, the best way to test the status of the iTunes Sandbox environment is checking this url:
http://sandbox.itunes.apple.com
An Http/1.1 Service Unavailable
means SSErrorHTTPStatusCodeKey=503
in your debugger output.
I got the "Cannot connect to itunes store" error when using a tester sandbox account. The problem was I had signed in on my iPhone with that account and confirmed the email address associated with the test account.
I solved the problem by creating a new tester account under Users and Roles in Itunes Connect and never sign in on my device with the account.
The reason for the error in my case was that when I confirmed the email address, the account was registered as a production account in AppStore and it did not work as a sandbox account anymore.
So if you sign in on your device once, the account will be registered as a production account and even if you sign out again, that account won´t work in the sandbox.