I have made an Android app using Adobe Phonegap Build. It is complete and I'm on the verge of submitting it to the Google Play market, except that I only recently discovered that in order to support the intended business model that supports the app, that I need to enable "billing" permissions.
Unfortunately, it seems it is not in any way possible to enable the billing permissions using the config.xml
file where Phonegap sets the rest of the permissions. Billing is not yet, and might not ever be, supported by Phonegap.
So now I'm stuck and wondering what my options are, or if I even have any. Is it in any way possible to hack or modify the apk
file generated by Adobe Phonegap Build to enable billing permissions? Is there any other way I can get the billing permission attached to my app?
(Please note that if it had been possible to build my app in native Android code, then I would have taken that option from the start, so please do not suggest that I should solve this problem by rewriting the app. For better and for worse, this is the point I'm at now. Thanks for your understanding.)
This should be possible using apktool, found here:
http://ibotpeaches.github.io/Apktool/
You should be able to decode XML resources and repackage as an APK.
Decompiling the apk is done as follows:
java -jar apktool.jar decode app.apk app
If it is just the billing permission that you need to add you will need to add the following line to the AndroidManifest.xml file:
<uses-permission android:name="com.android.vending.BILLING" />
After you have made the necessary changes you can recompile into an apk using:
java -jar apktool.jar build app app_new.apk
Several other links that you may find useful:
Android, is it possible to manually change somethings in manifest file directly from APK?
How to view AndroidManifest.xml from APK file?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With