On android, the In-App-purchase demo app and the tutorial on the website is legit, i succeed to create my app depending on that scheme.
But on OSX we don’t use iTunes anymore, we should use appstoreconnect and set way more parameters as it mentioned.
I tried the following stuffs:
- Created an identifier and uploaded and signed the application
- In appstoreconnect i created an internal testing group and this is how i can test my own app.
- On the page “App Store” in the feature section I added the sample product what the sample app uses and filled the informations until it writes “Ready to submit”.
- On the “iOS App” page I added the most fresh build and i selected my items in the IAP and SUBS section on the same page.
I tried to upload the sample (and) my app to TestFlight sooo freakin many times and I only see “Retrieving price…” at the price tags.
Please help me,
When you finish working on an App and after you’ve done all necessary local tests on a simulator or on a real device, you can use the Build → Archive function in Xcode and fill the form to upload the App to the app store connect. Once done, to start using the Testflight you can ignore everything and jump to the testflight section directly, choose a build, declare that it doesn’t use any cryptography and then add some testers.Then wait… wait… wait… wait a day, wait two days, wait patiently until someone at Apple wakes up and approves your build for testing, then the testers will be invited.
For testing IAPs, just go to the IAP section, add a new IAP, enter the name and the unique ID, price, description and everything is necessary.
Consider that if you want to test locally, you need to add a Sandbox user to your users section. The sandbox users can test purchases without being charged. Also, you can request the deletion of the purchase history for the sandbox users so all their purchases are revoked and you can test the IAP again. Unfortunately this isn’t (still?) possible in the testflight: if one of the testers tries an IAP, they don’t get charged but there’s no way to cancel their purchase to test the IAP once again.
When you setup your IAP class you should call
juce::InAppPurchases::getInstance()->getProductsInformation() to retrieve prices and other information about your IAPs (pass a Stringarray with IAPs IDs). This will call the callback
void productsInfoReturned(const juce::Array<juce::InAppPurchases::Product>& products) override with an array that you can iterate and compare each ID to your local list and set prices and other information accordingly.
Okay, but I talked about “Internal testers”. They dont need to approved by apple, and until now I tested all my work as an internal tester, it’s so fast. I don’t care if i get charged with 1$ few times, I just want to be sure the purchase process works. So the question is still actual, can I test my in app purchase as an internal tester? I read in appstoreconnect I need to submit IAPs with a new version and it need to be reviewed by apple. But my app is not finished, I don’t want it to be reviewed, and I can’t add new version since its not reviewed, I don’t have the “+” sign next to the “iOS App” label. Or I need to test it on sandbox and there is no other way?
Please somebody help me, this is a real pain in the *ss .