Reaver
1
Hi,
I am trying to build an enterprise project for publishing on Amazon, but am having some trouble.
We require In App Purchases.
I have tried including the amazon iap plugin in android/lib/ and setting the targetedStore meta data field but the store still failes to load.
I know this was possible before. Is it still possible? Is there a resource anywhere that explains how this is done?
Can anyone share how to do it?
Thanks!
Lerg
3
@Reaver, hi
-
Copy plugin.amazon.iap.jar and in-app-purchasing-2.0.61.jar into the libs/ directory of your project.
-
Add the following section into your AndroidManifest.xml file, inside the application tag:
<receiver android:name = “com.amazon.device.iap.ResponseReceiver”>
<intent-filter>
<action android:name = “com.amazon.inapp.purchasing.NOTIFY”
android:permission = “com.amazon.inapp.purchasing.Permission.NOTIFY”/>
</intent-filter>
</receiver>
You can download in-app-purchasing-2.0.61.jar as a part of Amazon SDK from their website.
Lerg
4
@Reaver, the updated version of the plugin will appear in .tgz for the next daily build (after 2016.2862).
Reaver
5
Thank you for answers. Sorry for taking so long to get back to this. I finally had the chance to try it and it’s working.
I just want to leave this here as an answer for anyone coming along later wondering the same thing.
Project setup
I downloaded the plugins .tgz for 2016.2866 and copied plugin.amazon.iap.jar and in-app-purchasing-2.0.61.jar into the libs folder of the project.
I’m using 2016.2866 to build as well. (Using an earlier version (2016.2830) to build with caused a NoClassDefFoundError)
Added the following in the AndroidManifest.xml
\<!-- Amazon Store --\> \<meta-data android:name="targetedAppStore" android:value="amazon"/\> \<receiver android:name="com.amazon.device.iap.ResponseReceiver"\> \<intent-filter\> \<action android:name="com.amazon.inapp.purchasing.NOTIFY" android:permission="com.amazon.inapp.purchasing.Permission.NOTIFY"/\> \</intent-filter\> \</receiver\>
Thank you, Lerg!
Lerg
7
@Reaver, hi
-
Copy plugin.amazon.iap.jar and in-app-purchasing-2.0.61.jar into the libs/ directory of your project.
-
Add the following section into your AndroidManifest.xml file, inside the application tag:
<receiver android:name = “com.amazon.device.iap.ResponseReceiver”>
<intent-filter>
<action android:name = “com.amazon.inapp.purchasing.NOTIFY”
android:permission = “com.amazon.inapp.purchasing.Permission.NOTIFY”/>
</intent-filter>
</receiver>
You can download in-app-purchasing-2.0.61.jar as a part of Amazon SDK from their website.
Lerg
8
@Reaver, the updated version of the plugin will appear in .tgz for the next daily build (after 2016.2862).
Reaver
9
Thank you for answers. Sorry for taking so long to get back to this. I finally had the chance to try it and it’s working.
I just want to leave this here as an answer for anyone coming along later wondering the same thing.
Project setup
I downloaded the plugins .tgz for 2016.2866 and copied plugin.amazon.iap.jar and in-app-purchasing-2.0.61.jar into the libs folder of the project.
I’m using 2016.2866 to build as well. (Using an earlier version (2016.2830) to build with caused a NoClassDefFoundError)
Added the following in the AndroidManifest.xml
\<!-- Amazon Store --\> \<meta-data android:name="targetedAppStore" android:value="amazon"/\> \<receiver android:name="com.amazon.device.iap.ResponseReceiver"\> \<intent-filter\> \<action android:name="com.amazon.inapp.purchasing.NOTIFY" android:permission="com.amazon.inapp.purchasing.Permission.NOTIFY"/\> \</intent-filter\> \</receiver\>
Thank you, Lerg!