In-App Purchases what am I missing? [swift] - ios

I'm trying to learn how to implement in-app purchases.
I found this really useful guide LINK which is related to this GitHub project LINK.
The project works by itself I only needed to create a couple of things in order to let it work:
I created a sandbox account for testing (without paying :])
I created a new App in iTunes Connect using my bundle identifier
I created the in-app purchase as requested by the app
I created all the App IDs and Provisioning profile for the App and connected to it
Running the app everything goes smoothly but the only thing (and most important one) it is that the transaction fails.
I have no idea where to look since I think I've everything correctly.
Someone can help me through the process reaching the end?
Thanks

The answer is quite easy and I found it HERE
The In-App Purchases do not work on the simulation a real device must be used!
In fact I used a real device and everything worked smoothly.

Related

iOS, in app purchases - "Waiting for Review"

Quick question, if my in-app purchases are listed on iTunes Connect as "Waiting for Review", should I be able to test them in a sandbox environment? Atm I'm getting an error that no products are available, but I'd like to make sure it's because of that and not an error on my end, just to speed things up. I'm using Unity to build my app and the store is built using their tutorial that can be found here: https://unity3d.com/learn/tutorials/topics/ads-analytics/integrating-unity-iap-your-game . The store does work on Android just fine btw. Thanks!
You should be aware of that if your app uses a brand new IAP but is not reviewed yet, your new release will crash immediately after it launches.
The experience was expensive for me :)
So, first make the IAP got approved. Then publish the build.
Well usually before you submit your app and your IAP too Apple to review everything and accept it you're supposed to have tested all your IAP and taken screenshots of them working.
So yes they should work before they're even sent to be reviewed.
You might want to follow those steps to make sure you've set everything up correctly : Adding In-App Purchase to your Applications

Unibill, testing iOS In App Purchases & Unity

Big headache! I cannot get IAP to work on my iPad device.
I have created a developer account on iTunes.
I created some app information, SKU etc., without uploading a binary.
I have set up Unibill to use the bundle identifiers and Ids as shown in the iTunes dashboard.
I logged out of existing users on the iPad.
I created a test user with a new email.
I fooled around with Xcode settings, trying a million different settings, but mainly following the documentation best I could: specifically, linking the Storekit library.
Unibill initialization keeps returning a 'CRITICAL_ERROR'. Maybe it's a Unibill problem, but what could I have forgotten?
Does testing In-App Purchases require a special contract type?
It is probably not the fault of Unibill. There are too many reason for the failure of IAP test. Basically, you can have a look at this check list first. Follow the questions could solve for most situation.
But there is something not correct in that checklist, the most important one is you do not need to upload the binary.
For your situation, I suggest you check the following things:
If you can create the IAP product, so it seems your contract is OK. IAP need a valid paid contract and correct bank information. So you can check if your bank information is correct or not.
Did you try to uninstall the app in your device and install it again? The old one would not be luck.
Did you generate and use new provision file for the build? Maybe old one does not contain the IAP feature.
Check your app id, version and build version. They should be all set properly or the IAP won't work.
Hope it can help.

struggling testing IOS in app purchase with xamarin

For the last couple of days I have been struggling trying to set up the enviroment to test in app purchase in xamarin. Their docs page is not very clear on what it needs to be done, at least for me.
For what I have researched, I need to sign a contract with apple, which requires me to give apple some information about my bank account, taxes, etc. That information is going to take a little while, maybe a week. So without contract, can I test in the sandbox mode in app purchase?
So far, I have created a development provisioning profile, my app id and bundle id as well, the products which I am going to sell within my app, and my test users. I tried getting product info from my device, but it did not work, no error, or app crash. Probably I am missing something here which causes this behavior.
I read in this page that I need to install my provisioning profile and configure xcode to sign the app with this profile. How do I do this in xamarin studio?
Also, I need to tell xcode whats the application bundle id, again, how do I do this?
I read the In-App Purchase Programming Guide and gave me an overall understanding about the architecture needed to implement in app purchases, but I am failing on the little details.
Any help would be appreciated. Thank you very much.
CraigD's answer to this may help: IAP ( In App Purchase ) sample for MonoTouch?
It doens't touch on live testing per se, but Craig's github example may help you with those details of implementation.

In app purchase not work after submitting app

I created my app and add the in-app-purchase items.Before I submit App, I tested the purchase function lots of times using test user on iphone device, it worked fine. But after I submit the app, all purchase item was not working, and this cause my app be rejected.( I am sure the I selected all iap production before submit)
Now neither the requesting product information nor the buy transaction is not working. But both worked fine before sumbitting the app. I'v investigated it for several days and cannot solve the problem.
Really appreciate if you can help.
Thanks a lot !
Just do make sure: You did look that you unique app id you used for testing in app purchases was also used for the provisioning profile?
Cheers, Jörg

iOS/Apple App Store Release Process

I've been trying to find some guidelines on the overall process for releasing an iOS app. The documentation on Apple's iOS Dev Center doesn't seem clear. I've found some sites that try to explain aspects of the process, but I haven't been able to find a clear, conscise guide that explains some of my questions, such as:
What do I have to do within my project (ie info.plist file changes, target/build settings, etc.)
I am using In-App Purchases. It is working in my sandbox, but what do I need to do (if anything else) to make sure this works when my app is released? As far as I can tell from what I've read, there is no way to test this in live environment until after the app appears on the app store.
Is there any other provisioning/certificates needed beyond what I have used when developing my app?
Anything else that I am overlooking?
If you know of a site (or sites) that explains this in more detail, it would be much appreciated. After searching for hours I can't seem to find answers to these questions.
Thank you.
Have you seen this document from Apple on "preparing for app store submission"? It's pretty clear on the steps you have to take to get onto the app store.
In short:
No specific changes, but you have to archive for a device rather than building for testing.
In App Purchasing will work on the app store without any more configuration
You need a distribution certificate for when you build an archive for the app store, make it in your iOS Provisioning Portal, under Provisioning page and Distribution tab.

Resources