Allows developers to monetize their Kivy mobile applications using Google AdMob.
- No need to change internal Android project manifest templates or Java code.
- Supports banner, interstitial, and rewarded video ads.
You can install KivMob with the following command.
$ pip install kivmob
Create an new folder containing main.py and buildozer.spec.
$ mkdir kivmob-quickstart
$ cd kivmob-quickstart
$ touch main.py
$ buildozer init
Copy the following into main.py.
from kivmob import KivMob, TestIds
from kivy.app import App
from kivy.uix.button import Button
class KivMobTest(App):
def build(self):
ads = KivMob(TestIds.APP)
ads.new_interstitial(TestIds.INTERSTITIAL)
ads.request_interstitial()
return Button(text='Show Interstitial',
on_release=lambda a:ads.show_interstitial())
KivMobTest().run()
Make the following modifications to your buildozer.spec file.
requirements = hostpython2, kivy, android, jnius, kivmob
...
android.permissions = INTERNET, ACCESS_NETWORK_STATE
android.api = 27
android.minapi = 21
android.sdk = 24
android.ndk = 17b
android.gradle_dependencies = 'com.google.firebase:firebase-ads:10.2.0'
p4a.branch = master
android.meta_data = com.google.android.gms.ads.APPLICATION_ID=ca-app-pub-3940256099942544~3347511713
Finally, build and launch the application.
$ buildozer android debug deploy run
Please open a pull request or project issue if you would like your KivMob app featured in this README and the documentation.
App | Play Store Link | Author |
---|---|---|
MIUI Hidden Settings | https://play.google.com/store/apps/details?id=com.ceyhan.sets | Yunus Ceyhan |
Themes for MIUI | https://play.google.com/store/apps/details?id=com.ceyhan.tema | Yunus Ceyhan |
KivMob is an open source project not associated with AdMob. Please abide by their policies when designing and testing your application.