"Adapty SDK was not initialized" on Android
complete
U
Ugur Genc
I am using React Native to develop my iOS and Android Apps. On iOS, everything works well. But on Android, my adapty.purchases.restore() function throws an error like below;
{"adaptyCode": "sdkNotActive", "code": 403, "localizedDescription": "Adapty SDK was not initialized"}
Also, while getting the products, it turns the empty products (with prices of 0). So, it is not a problem about the connection between my App and Adapty.
I followed the Android instructions part, twice. But the results are the same. What should I do?
Thank you all, in advance.
Adapty Support
complete
A
Adapty Support
Hey Ugur,
Have you activated that product? After creating a new product, in the GP console, you should be able to see the "Activate" button. Be sure, that you hit it
Let's double-check, if the steps below were done previously:
- Be sure, that you're using a Google Account which was added as a tester when it comes to testing on a device (the application build, which includes a Billing Library must be published in Google Play Console test track)
- Bear in mind, that the applicationID of the build must match with the applicationID from Play Console. In case you're adding prefixes to applicationID in your debug builds, you'd need to pay this double attention
U
Ugur Genc
Activating Adapty SDK issue had been automatically fixed by its own.
Now, I am facing only this "empty values of Adapty requests" problem.
Such As;
[{"android": {}, "introductoryOfferEligibility": true, "localizedDescription": "", "localizedTitle": "Monthly", "paywallABTestName": "Basic", "paywallName": "Basic", "price": 0, "variationId": "ANONYMIZED", "vendorProductId": "xxxxxxx"}, {"android": {}, "introductoryOfferEligibility": true, "localizedDescription": "", "localizedTitle": "Yearly", "paywallABTestName": "Basic", "paywallName": "Basic", "price": 0, "variationId": "ANONYMIZED", "vendorProductId": "xxxxxxxx"}]
A
Adapty Support
Can you share with us your flow, which is responsible for activating Adapty SDK?
U
Ugur Genc
Hello again İvan,
As mentioned I followed The instructions twice. Everything works On iOS very well. But on android I am getting this problem. And I have the prices etc as 0.
A
Adapty Support
Hey, we do have some instructions for RN, as well: https://docs.adapty.io/docs/react-native-configuring
U
Ugur Genc
Hello Ivan,
I am using React Native SDK. For RN, should I add the stated changes in Flutter section to my AndroidManifest.xml?
A
Adapty Support
Hey Ugur,
Which version of the Flutter SDK do you use? Did you configure the SDK, as described here?:
U
Ugur Genc
Products array of my app looks like this. I think there is no data from Play Console but Adapty. :/
[{"android": {}, "introductoryOfferEligibility": true, "localizedDescription": "", "localizedTitle": "Monthly", "paywallABTestName": "Basic", "paywallName": "Basic", "price": 0, "variationId": "ANONYMIZED", "vendorProductId": "xxxxxxx"}, {"android": {}, "introductoryOfferEligibility": true, "localizedDescription": "", "localizedTitle": "Yearly", "paywallABTestName": "Basic", "paywallName": "Basic", "price": 0, "variationId": "ANONYMIZED", "vendorProductId": "xxxxxxxx"}]