Google Play setup
Create a service account, grant it Play Console access, and Refund Sensor wires up real-time notifications so chargeback reviews are answered within 24 hours.
Before you begin
Refund Sensor connects to Google Play with a service account you create in your own Google Cloud project. It never expires and needs no re-authorizing. You will need:
- A Google Cloud project on the account that owns your Play Console (a free one is fine).
- A service account with a JSON key you can download.
- Play Console access plus Pub/Sub Admin granted to that account.
- The package names or Play Store URLs you want to defend.
Create a service account and key
- Open Google Cloud Console with the account that owns your Play Console, and select or create a project. In the left menu open IAM & Admin and click Service accounts.
- Click + Create service account, give it a name like RefundSensor Google Play API, then click Create and continue and Done. You can skip the optional roles here.
- Copy the service account email (it ends in
.iam.gserviceaccount.com). You will need it in the next steps. - Open the service account, switch to the Keys tab, click Add key → Create new key, choose JSON, and click Create. Google downloads a
.jsonfile. Keep it safe; Google will not let you download it again.
Enable the required APIs
Your project needs two Google APIs enabled (a one-time step per project). In Google Cloud Console, with your project selected, search for and enable each:
- Google Play Android Developer API, which lets the service account read your refund and order data.
- Cloud Pub/Sub API, which powers real-time refund notifications. Make sure it is Cloud Pub/Sub, not Pub/Sub Lite, which is a different product.
Add your credentials
In Refund Sensor, open Add app, choose Google Play, and upload the .json key file. We verify it with Google and store it encrypted at rest with AES-256-GCM.
Grant Play Console permissions
Invite the service account into Play Console and give it financial access in two places, since refund (voided-purchase) data is read at the account level:
- In Google Play Console, open Users and permissions → Invite new users and paste the service account email. A service account becomes active as soon as you save; it does not accept the invite itself.
- Under App permissions, add each app you want to defend and turn on View financial data and Manage orders and subscriptions.
- Switch to the Account permissions tab (easy to miss) and, under Financial data, turn on View financial data, orders and cancellation survey responses and Manage orders and subscriptions, then save.
Grant Pub/Sub Admin
Real-time notifications reach Refund Sensor over a Pub/Sub topic that we create and wire up for you, so there is nothing to paste into Play Console. It just needs permission to manage Pub/Sub. In IAM & Admin → IAM, click Grant access, paste your service account email as the principal, select the role Pub/Sub Admin (roles/pubsub.admin), and save. Pick Pub/Sub Admin, not Pub/Sub Lite Admin; the Lite role will not work and is the most common reason auto-setup fails.
Add your apps
On the Add apps step, paste one Play Store URL or package name per line (the package name is the value after ?id= in a Play Store link, e.g. com.yourcompany.app). Refund Sensor validates each one against the connected account's Play Console access before importing, and flags any it cannot see.
Real-time notifications
With the APIs enabled and Pub/Sub Admin granted, importing an app auto-creates the topic and push subscription and registers it as the app's RTDN endpoint. The app then shows Awaiting first refund event until Google delivers the first real event (there is no test button on Google's side). If auto-setup ever fails, the app card shows Real-time notifications not set up with a link back to this guide.
What Refund Sensor answers on Google Play
Not every Google Play refund can be contested. A regular user refund is decided by Google on its own, so those are recorded for visibility but not challenged.
The one refund you can actually respond to is a chargeback under review (Google's pendingRefundReviewNotification). It gives you about 24 hours and honors the first response. Refund Sensor answers it automatically with a decline recommendation, well inside the window.
As a backstop, Refund Sensor also reconciles against Google's Voided Purchases API, so every refund and voided purchase is captured in your dashboard even when there was nothing to contest.

