A few months ago, I decided to add an Upgrade option to one of my apps: TouchUp Lite for iOS. I wanted to use the In App Purchase API to allow people to instantly upgrade their Lite version to Pro.
It turned out to be one of the best decisions I’ve ever made. Since then my revenues have basically doubled for that App. And now, after months of slow and steady growth, income from TouchUp Lite Upgrade has exceeded sales of the TouchUp Pro as a standalone app!
Here you can see the steady growth of the In App Purchase revenue:
Note: Christmas leading into January creates a major sales bump that lasts a while, but seems to be fading…
So, given that experience, it was a no-brainer that I need to do the same thing with my upcoming editor PicShop. The rest of this post will walk about how you do this in Adobe AIR.
If you just wanted the growth numbers, you can leave now
Adobe AIR does not support In App Purchases for any platforms out of the box, in order to enable it you must use things called Actionscript Native Extensions, or ANE’s. You can think of an ANE as a SWC by a different name, you include it in your FlashBuilder 4.6 project, and then you can make API calls on it just like you would a SWC.
When I added the initial IAP support for TouchUp Lite on iOS, I used a free ANE which you can find here:
That ANE works just fine, but it does have an annoying bug where it dispatches lots of extra events in certain edge cases (complete, cancelled, etc). Still it’s free, so if you need something on the cheap, give this a run.
For PicShop though, I need to support Android, and I also wanted a better iOS implementation because the extra events coming from the extension were a pain in the ass to deal with. Luckily, I found Milkman Games!
Milkman offers InApp Purchase ANE’s for both Android and IOS, complete with full documentation. They are not free though, and will cost you about $50 USD each. In my books, that’s about 1-2hrs worth of work, so I think it’s an absolute steal.
Each extension comes with a lengthy tutorial on setting up each store, as well as complete ASDOC documentation. You can preview the API’s here:
Going over the actual implementations is outside of the scope of this Article, but really there’s not much to say. If you look at the ASDocs, you’ll see that the API is extremely straightforward, and the documentation takes care of explaining any grey areas. Honestly, setting up the data in the App Store(s) is the hardest part, once you get to the AS3 implementation you’re past the tough stuff…
I was especially impressed with how the documentation took the time to cover all the various edge cases that I didn’t even know existed, talk about sharing the knowledge! Not only was the code well documented, but the email support from Milkman Games was some of the best I’ve ever experienced.
All in all, it took just 6 hours for UI work, and another 4 hours to wire up both Android and iOS support. 10 hours in total, and a $100, for 2 platforms and potentially tens of thousands of dollars of potential revenue. Now that’s a good days work!
The iOS version is still awaiting approval, but you can check out the finished Android version here:
NOTE: This gives an interesting opportunity to compare Android and iOS IAP Numbers, since I have two free apps launching at the same time across both platforms. If you’re interested in seeing how the numbers compare and grow, subscribe to the blog. I’ll post updates every month or two. Thanks for reading :)