Local currency for pricing In-App purchase?

I’m doing great with the In-App purchase system… It works great, all my tests are done, etc.

I just had the realization, though, that I need to show a localized price to users in the app… not the US price.

While I see where we get the price of In-App purchase … I can’t find any mention of what currency that amount is. Is that not provided by Apple (or Corona)?

If not, please tack my request for that to the list. :wink:

Thanks,
~~Kenn [import]uid: 13859 topic_id: 6145 reply_id: 306145[/import]

+1 here [import]uid: 14101 topic_id: 6145 reply_id: 21254[/import]

+1, isn’t this essential? [import]uid: 8782 topic_id: 6145 reply_id: 21587[/import]

Just as an update…

I looked around at some of the apps I have and, while logged in as a Canadian test user, I couldn’t find anyone who was actually showing me in-app purchases in Canadian dollars…

Realistically, it’s difficult to show localized pricing in app because someone would have to be logged into their account in order to generate the prices.

Anyway, my end solution was this:

I setup the default of $0.99 and added a line at the bottom “* Prices shown in US currency.” or something like that. Then I also setup the checks for localized pricing if they’re logged in. It just shows the numeric value of the price and at the bottom changes to “* Prices shown in local App Store currency.”

I’m honestly not entirely sure it works, but at the same time, I don’t think I care as I’m going a step farther than any other app I looked at to tell them it’s US currency and the in-app purchase pop-up from Apple WILL show them their localized price and currency.

All in all, I’m pretty happy with the ease of In-App purchases.
***—>> Robert if you haven’t gotten this into Bubble Ball yet, you need to get on the “ball”. If you have any questions, let me know. You just need to get it done. :wink:

Best,
~~Kenn
[import]uid: 13859 topic_id: 6145 reply_id: 21592[/import]

Some way I could contact you, @kennwags? Mine’s robert (at) naygames.com [import]uid: 8782 topic_id: 6145 reply_id: 21593[/import]

Please correct me if I’m wrong, but for some reason I was under the impression that the pricing information returned to you from the APIs (which are from Apple) are already priced in the user’s home currency.

So if you are a US user, you get back .99 (dollars) for tier 1, but if you are in a UK user, you might get back .79 (pounds) or whatever tier 1 is over there.

[import]uid: 7563 topic_id: 6145 reply_id: 21594[/import]

Yes, it’s a number back from the API.

If you’re saying we need to just create our own table of currencies based on the different price tiers and then determine the currency from the amount returned… then ok I guess (as long as they’re no two amounts that are the same but different currencies)…

… just realize that the number itself from the API isn’t a currency, it’s just an amount. :wink:
@Robert = emailed. [import]uid: 13859 topic_id: 6145 reply_id: 21598[/import]

That sounds reasonable, though you might be able to utilize system.getPreference(“locale”, ) to further help determine which currency you want.

[import]uid: 7563 topic_id: 6145 reply_id: 21600[/import]

system.getPreference(“locale”, ) is likely the answer I was looking for… I will likely just use that to handle the top bunch of store currencies and not worry about much else.

… If you guys wanna be super helpful, you could just use system.getPreference(“locale”, ) data to give us a store.localCurrency so people don’t have to deal with that legwork.

[import]uid: 13859 topic_id: 6145 reply_id: 21607[/import]

Yeah and now that I’m looking at the table again, I note that Canada and the US are both 99 cents. And that reminded me why I made my test account Australian with the 1.19 price.

You just have to use the system.getPreference(“locale”, ) and a table matching currencies to countries. [import]uid: 13859 topic_id: 6145 reply_id: 21614[/import]

Isn’t locale according to the language and region you set in your iPhone and has nothing to do with your current app store? [import]uid: 14101 topic_id: 6145 reply_id: 21621[/import]

Since this is a feature that just about everybody using InAppPurchases can benefit from, I just added a new API, localizedPrice. Example:

print(event.products[i].price)
print(event.products[i].localizedPrice)

price returns the number .99
localizedPrice returns the string $0.99

This can be found in the daily builds starting with #296.
[import]uid: 7563 topic_id: 6145 reply_id: 22267[/import]

Wonderful - This is awesome. Thanks so much for the quick turn around on this!!!

~~Kenn [import]uid: 13859 topic_id: 6145 reply_id: 22269[/import]

localizedPrice is returning a nil value for me, whereas price returns 0.99 fine… has there been any update to this? [import]uid: 91921 topic_id: 6145 reply_id: 95635[/import]