- Home /
Unity IAP Unavaliable Product Google Play Store
I am having trouble with Unity IAP. I have an alpha release of my project in play store. I have setup iap on the store and have activated unity iap through the services on the editor by providing the correct service API key. The problem is that I cannot initialize the iap on my android build.
My IAP setup on the developer console:
Error I get on logcat:
Code for initialization:
void Start() { if (!IsInitialized()) { var builder = ConfigurationBuilder.Instance(StandardPurchasingModule.Instance()); builder.AddProduct("test_product", ProductType.Consumable); UnityPurchasing.Initialize(this, builder); } } public void OnInitialized(IStoreController controller, IExtensionProvider extensions) { Debug.Log("OnInitialized: PASS"); storeController = controller; storeExtension = extensions; } public void OnInitializeFailed(InitializationFailureReason error) { Debug.LogError("OnInitializeFailed InitializationFailureReason: " + error); }
Answer by SohailBukhari · Jun 06, 2018 at 08:29 AM
You do need to have your APK in the Alpha OR Beta release channels, but you don't have to download it (personally, we use Alpha). You can sideload it no problem. The only issues are that the APK needs to be "validated" (an hour or two, or slightly longer if it's a new app) and the version that you're loading has to be the same. - i.e. if you have version 1.0.0 on the App Store, then if you have 1.0.1 on your phone, you won't be able to buy anything, with a "Product unavailable" message.
So, if you upload a basic shell to get validated, you can continue to develop and load locally to get your implementation right.
in order to test the product you should manage the users Test Users .
also ad testers for alpha/beta release.
Goto your account => settings => manage testers and create list for the testers.
As far as I know, you do need to build a signed APK when testing (i.e. not a debug one). as we always build signed APK.
i hope this will sove your problem.
Your answer
Follow this Question
Related Questions
Unity IAP Subscription Doubts 0 Answers
Unity IAP not reliable in sandbox when restoring subscription after app deleted and re-installed 0 Answers
IAP button work in editor but not work in Android device ? 1 Answer
Process Purchase Event get called on each App launch - iOS 0 Answers
in app purchase sooma restore option 1 Answer