Configuring Google Play console¶
References¶
https://developers.google.com/android-publisher/getting_started
https://developer.android.com/google/play/billing/getting-ready
Steps¶
Before you can start making API calls, you need to set up API access to your Google Play Developer Account. This involves changes in both the Google Play Console and Google Cloud Console. The following instructions explain the four steps needed to start using the Google Play Developer API.
- Link your developer account to a new or existing Google Cloud Project.
- Enable the Google Play Developer API for your linked Google Cloud Project.
- Authorize and grant permissions
- Retrieve GoogleCloud service account key and email address
Authorize and grant permissions¶
On the GooglePlay console grant the following rights to the GoogleCloud service account:
- View financial data, orders and cancellation survey responses
- Manage orders and subscriptions
Get the GoogleCloud service account skey - needed by RedBee Media¶
- In the Google Cloud Console, for the new service account, select Keys → Add Key → Create new Key. Make it a JSON.
- Open the downloaded file, copy it to the clipboard and paste it as the
serviceaccountstring
in the user's googleplaygateway configuration. This file is sensitive, so be careful with it.
Google Cloud's Pub/Sub service¶
Next, we have to connect Google Play Console with Google Cloud's Pub/Sub service in order to get Subscription related Real Time Developer Notifications to RedBee's backend.
See https://developer.android.com/google/play/billing/getting-ready#configure-rtdn
Use this URL as push endpoint
https://origin-googleplaygateway-prod.enigmatv.io/api/googleplaygateway/v1/customer/{Customer}/businessunit/{BusinessUnit}/rtdn/subscription_notification
NOTE: replace {Customer}
and {BusinessUnit}
with your specific Customer unit and Business unit.
Also enable authentication and select the service account created in step Authorize and grant permissions
Recommended step¶
Add your account under License Testing in order to be able to test the app without paying, and in order to test in app payments when running the app locally in debug mode.