To Monetize your app with admob you must set it up first. it could have been a normal setup but we do extra steps to ensure the app ad system stays Secure and if someone modify the app and try to remove the AD its not possiable as we will be verifying the ad views serverside.
First you must add your app to admob then follow these steps:
1. Click on ad Units then click on Add ad unit
2. Then select Rewarded
as we currently use rewarded ad to unlock some premium wallpaper if you give that option to the wallpaper.
3. Fill the details in this page and click on Advanced settings
4. after clicking Advanced settings
these section will open up. now click on the Set up and verify callback url
5. Now you will see this form fill all the details like these but replace the Callback url yourdomain.com
part with your own domain
Callback url: https://yourdomain.com/api/reward_ad_verify_callback_url
User ID: 0
Custom data: {"gaid":"1","wallpaper_id":1}
6. Then click on Verify
url and as after it successfully verifed click on Use verified url
7. now Create the AD Unit and copy the ad unit id
8. after getting the ad unit id
open android studeo project
9. in android studio go to this path res/values/
and open this file strings.xml
and find these 2 lines and add your own app ID
and ad unit id
<string name="admob_app_id">ca-app-pub-8903845512397037~8237380722</string>
<string name="rewarded_ad_id">ca-app-pub-3940256099942544/5224354917</string>