Google In-App Purchases with Conscent
To enable the Google Play Android Developer API and the Google Play Developer Reporting API for your Google Cloud project, follow the steps outlined below:
Step 1. Enable the Google Developer and Reporting API
Access the Google API Console: Open your browser and go to the Google API Console.
Select Your Project: Choose an existing project or create a new one.
Enable the Required APIs:
Navigate to Library within the API Console.
Search for and select the following APIs:
Google Play Android Developer API
Google Play Developer Reporting API
Click Enable for each API.
Note: If the API is already enabled, you will see a Manage button instead.
Set Up Credentials:
Once the APIs are enabled, you’ll be redirected to the API’s main page.
If no credentials are set up, follow these steps to create them:
Click on Create Credentials.
Follow the on-screen prompts to generate the necessary credentials (OAuth 2.0, API keys, or service accounts) based on your project needs.
Ensure that these credentials are created by the project owner or a user with the appropriate permissions.
Important: User permissions are defined in Step 3 of the Google Play Console and are required to access the Developer and Reporting APIs.
Verify Permissions in Google Play Console:
Go to your Google Play Console and ensure the project owner or authorized user has the necessary permissions under Settings > Permissions.
Step 2. Create a Service Account
Navigate to Service Accounts
Open the Google Cloud Console.
Go to IAM & Admin > Service Accounts.
Alternatively, if you're in the Google Play Console, you can reach this page from the last setup screen.
Create the Service Account
Click Create Service Account.
Enter a name for the service account (e.g., "Platform Server Notifications Service").
Click Create and continue.
Assign Roles to the Service Account
In the Grant this service account access to the project section, add the following roles:
Pub/Sub Admin: Enables the account to manage Platform Server Notifications.
Monitoring Viewer: Allows monitoring of the notification queue.
Tip: If you can’t find these roles via search, manually browse for them under the Pub/Sub and Monitoring folders.
Download the JSON Key
Once the roles are assigned, navigate to the Service Accounts page in the Google Cloud Console.
In the Actions menu (three dots) for the new service account, select Manage Keys.
Click Add Key > Create new key.
Choose the JSON format and download the JSON key.
Important: Keep this JSON key secure, as it will be required in Step 4 of the setup process.
Step 3. Grant Financial Access
Access Users and Permissions
In the Google Play Console, navigate to the Developer homepage.
Go to Users and Permissions.
Invite the Service Account
Click on Invite user.
Enter the email address of the service account created in Step 2.
Set Permissions
Under App permissions, select your app to grant permissions specific to it.
Under Account permissions, enable the following permissions:
View app information and download bulk reports (read-only): Allows access to view app details and download bulk data reports.
View financial data, orders, and cancellation survey responses: Grants access to financial data and customer feedback.
Manage orders and subscriptions: Allows management of customer orders and subscriptions.
Note: Other permissions can be set based on your needs, but the three permissions listed above are essential for financial access.
Send the Invitation
Scroll to the bottom and click Invite user to activate the service account under Users and Permissions.
Step 4. Share Credentials JSON and Package Name
Locate the Credentials JSON: Use the Private Key JSON file that was downloaded in Step 2 when creating the service account.
Get the Package Name
Find the app’s package name in the Google Play Console.
Share Securely
Send both the Credentials JSON and Package Name to the Customer Success or Product Team via a secure method.
Last updated