in-app purchase on MAS

Hi,

I am wondering if anyone used in-app purchase option in their MAS distributed applications.
And of course how they did it…

Thanks,
have a nice day,
Franck

Hi Franck… Looking into this myself at the moment. So far I see that MBS has already written the functions, I just need to spend some time to understand what they do exactly and how to create my own app using IAP.

Thanks Sam. That would be great. And as a hyper-satisfied user of some of your apps (App Wrapper) I am confident that you will find the solution !
I have nothing against MBS (I actually own a license) but I try to challenge myself developing my first cocoa App 100% in Xojo with a few declare and Applescript. So a declare-based solution to detect in-App purchase and unlock certain function would be super !

I’m surprised not to see more discussion about this. Any progress, Sam? The last time I looked into this was over a year ago and I couldn’t get anywhere, even with the MBS functions.

I haven’t looked at it since, we decided not to pursue it with the intended apps last year, due to time constraints. I am hoping to tackle it this year, once and for all.

If in-app purchase works, there is real potential here : a free limited edition triggering lots of downloads, with in-app purchase to unlock it comes to mind…

Indeed that’s the principle, although it’s a difficult challenge, not just to code, but also to be able to utilize this function.

For instance as a shareware developer, I’m used to providing a time limited version of my application, so that users can use it to the full extent, but after a while important functions get disabled.

The main way how this seems to be applied is to create a fully usable FREE application (not a time trial version or appear to be a crippled version), then to charge for premium features. You must ‘hide’ the premium features (so if printing is premium, hide the print options until they’ve purchased).

Hopefully there are others who’ve already done this and can chime in. It’d be good to have a greater understanding of the dos and don’ts before I start down this path.

Well, the easiest seems to be to take our plugin and the sample project and get up and running a few minutes :slight_smile:

So, is it part of the regular MBS plugins, or is it a separate package ? Can you provide a link ?

it’s part of Lion plugin, but requires also the Cocoa plugins:

http://www.monkeybreadsoftware.net/pluginpart-storekit.shtml

Maybe you just download the big package and look into the examples?

Sounds like Christian must have improved the MBS plugins (which I love) since I tried them. Back then I think he was just beginning to start working on them.

I’ll give them a try again.

[quote=63036:@Christian Schmitz]it’s part of Lion plugin, but requires also the Cocoa plugins:

http://www.monkeybreadsoftware.net/pluginpart-storekit.shtml

Maybe you just download the big package and look into the examples?[/quote]

I went to the page, but could not quite understand which class would help with in app purchase…

By “big package”, you mean MBS-Xojo-Plugins133.dmg ?

Yes.
Maybe you start by looking into the “Store Kit Test” example project in the Examples/Lion folder?

Of course you will need to read some docs from Apple and our plugin documentation.

PS: You need to install Lion, Cocoa and CocoaBase plugins, I think.

[quote=63082:@Christian Schmitz]Yes.
Maybe you start by looking into the “Store Kit Test” example project in the Examples/Lion folder?

Of course you will need to read some docs from Apple and our plugin documentation.

PS: You need to install Lion, Cocoa and CocoaBase plugins, I think.[/quote]

Thank you.

Christian,

Could you help me with the format of the product identifier? I have created some in-app purchases for my app Quick File Renamer Lite. I see one of the in app purchases has a Product ID of QFRL1 and Apple ID 815419971.

So I have tried the following, hoping to figure out the format:

AppStoreModule.GetProductInfo("QFRL1", "com.rebrandsoftware.quickfilerenamerlite.QFRL1", "com.rebrandsoftware.quickfilerenamerlite", "815419971", "com.rebrandsoftware.quickfilerenamerlite.815419971")

All of them return Invalid Product ID errors.

I checked to make sure I was signed out of the App Store as the Apple docs suggest. I changed the Xojo Bundle Identifier to com.rebrandsoftware.quickfilerenamerlite.

Any idea what I’m doing wrong? These in-app purchases are currently “Ready to submit” on iTunes Connect. I have to submit them with a new version of the app so I want to make sure I’m able to properly test them first. The Apple docs suggest that I should be able to test with them before they are reviewed, is that right?

Thanks!

I don’t think the in-app codes are unique system-wide, they are only unique to the bundle. So I assume I need to provide the Bundle ID, which I have done in the OSX Build Bundle Identifier section. Is there anywhere else I need to specify it?

Sorry, I’m not sure. The product ID does not contain the bundle ID as far as I know. You can only query the products for your app and you may need to check Apple’s documentation on how to test this.

Thanks. I’ll keep looking.

Can you confirm that I don’t need to enter my bundle id anywhere in the plugin? Does it only send the product id, or possibly it grabs the bundle ID from xojo?

It just occurred to me that maybe my app needs to be signed, and that’s how it’s getting additional data about the developer or bundle id. I’ll try that and post again.

Signing it didn’t make any difference. Neither did sandboxing it, or creating a new provisioning profile.

Looks like it does need to be signed, though:

https://developer.apple.com/library/mac/technotes/tn2259/_index.html