I added IAP products to Amazon store exactly the same way as I did with Google Play, but it looks like amazon.sdktester.json lists these products in what-seems-to-be in a random order. I read somewhere in Amazon doc site that it doesn’t matter – but then, when the products are loaded on Kindle Fire, they are listed in what-appears-to-be in a random order again (but not the same order as they are listed in amazon.sdktester.json file.)
If I see the products loaded in the same order as Google Play version, I wouldn’t be so concerned, because I know my In-App Billing works fine with Google Play. But with Amazon store, I can’t verify if it works until it goes live, and I don’t know if I can trust test mode to yield exact same results as the live mode.
So… for a sanity check, I’m wondering if there’s a rule under which the products are listed when they are loaded.
For example, I added products to Amazon in this order:
Product A (consumable)
Product B (consumable)
Product C (entitlement)
Product D (entitlement)
The amazon.sdktester.json show them in the order of something like:
Product C
Product B
Product D
Product A
And these products are loaded onto Kindle device in the order of something like:
Product B
Product C
Product A
Product D
I then index the products to something like:
myProductTable[1] = Product B
myProductTable[2] = Product C
myProductTable[3] = Product A
myProductTable[4] = Product D
And then, when the user purchases Product A, my code would assume that the user purchased myProductTable[3].
But if Product A isn’t always loaded as the 3rd product in the table, it wouldn’t work… Am I worrying about things I don’t need to? Do I need to dynamically work out the index every time the app is launched to make sure index match up with intended products properly? (I hope my question is clear enough and make some sense…)
Naomi