iPhone StoreKit - Getting Started with In-App Purchasing

While the fact that StoreKit is not supported in the iPhone Simulator is fairly common knowledge, I wish I knew these two things when starting up with StoreKit programming on the iPhone.

1. In iTunes Connect, you won't see the "Manage In-App Purchases" option until you create a product in iTunes Connect. You need to be able to select an application before you can create products in "Manage In-App Purchases". Create an application and "upload an application bundle later" to get around the requirement. Once you have an application defined, you'll get "Manage In-App Purchases" in the main iTunes Connect menu.

2. In-App Purchasing test users can never be used on the iPhone outside your app. In other words, in the Settings application, log your App Store user out (under "App Store" in Settings) and NEVER log in there as your test user. The reason is, a sandbox user will skip the "enter credit card info" step and just run test purchases directly through your app without involving the system's management of the App Store user. If the iPhone tries to send you to some other application (such as the App Store application) to confirm changes of some sort or another, that user is hosed. The iPhone won't let you run test purchases for that user. You must create a new test user in iTunes Connect with a different email address. Using Gmail's "+" notation to simulate new email addresses is helpful here. For example, mail sent to user+foo@gmail.com and user+bar@gmail.com will both be forwarded to user@gmail.com so you can make up a virtually unlimited number of email addresses.

Other than that, the Apple documentation for StoreKit should be all you need to get In-App Purchasing going in your iPhone application.

Tags

Trackbacks

To send a trackback, use the URL of this story appending ?page=tb at the end.

Comments (0)

Leave a Comment

Name:
Location: (city / state / country)
Email: (not published / no spam)

No HTML is allowed. Cookies must be enabled to post. Your comment will appear on this page after a moderator OKs it. Offensive content will not be published.

Click the umbrella to submit your comment.

To create links in comments:

[link:http://www.anders.com/] becomes http://www.anders.com/

[link:http://www.anders.com/|Anders.com] becomes Anders.com

Notice there is no rel="nofollow" in these hrefs. Links in comments will carry page rank from this site so only link to things worthy of people's attention.

About Me:


Name: Anders Brownworth
Location: Boston, USA
Work: Writing iPhone and Android applications.
Play: Technology, World Traveler and Licensed Helicopter Pilot
Follow:
more...

Books:

Lars Brownworth's book on Byzantine History spawned from our 12 Byzantine Rulers podcast:



or get the Audiobook in iTunes

Contact Me:

Name:
Email:

Click the umbrella to submit. (Why?)

Want to stop form spam on your website? Try JustHumans.com.
user:
pass: