Skip to content
Sales sourcesUpdated on November 23, 2026 · 12 min read

Connect Google Play

Step by step to bring your Android app sales, subscriptions and refunds into CrazyLeads, from the screen or from your AI assistant (MCP).


With the Google Play source, every charge of your Android app shows up in Sales, already with the net amount Google pays out, and every subscription becomes events on the buyer timeline: free trial, start, renewal, failed billing, cancellation, expiration and refund. You use those events in Deliveries, automations and audiences.

Who does what: steps 1, 2, 3 and 5 are done by whoever manages the Play Console and the app Google Cloud, no code. Step 4 belongs to the app developer: send them this link. Without step 4, sales still show up in Sales, but with no buyer: nothing reaches the timeline, and Deliveries (such as the purchase to Meta) and automations do not fire.

Before you start

  • The Google Play source is in beta. If the card does not show up in Sources → Add source, ask for it through the support page (crazyleads.com.br/landing/suporte, in Portuguese), with the project name and the store.
  • The app published on Google Play, with subscriptions or in-app purchases.
  • Admin access to the Play Console and to the app Google Cloud project.
  • Someone who works on the app server (the one that handles login), for step 4.
  • No approved app or Google review needed: the connection uses a service account you create yourself.

1. Create the service account

  1. 01In Google Cloud, in the app project, enable the Google Play Android Developer API.
  2. 02In IAM & Admin → Service accounts, create an account (for example, crazyleads-reader). Then, in Keys → Add key → JSON, download the file.
  3. 03In Play Console → Users and permissions, invite that account e-mail for this app only, with the permissions that start with: View app information, View financial data and Manage orders and subscriptions.

2. Connect in CrazyLeads

Pick one of the two paths. The result is the same.

From the screen

  1. 01In the project, open Sources → Add source → Google Play → Continue.
  2. 02First step: enter the app package name (for example, com.company.app). The source name and identifier come pre-filled; the app name is optional.
  3. 03Second step: pick the service account JSON file and click Connect and create source. The push service account e-mail can wait (step 3).
  4. 04Copy the identification key shown and hand it to the developer (it goes into step 4). It is shown only once. Tick I saved the key and click Open source.

Google can take a few hours to accept a newly invited service account. Meanwhile the source shows Waiting for permission and retries on its own every 30 minutes, for up to 48 hours. You do not need to redo anything.

From your AI assistant (MCP)

  1. 01With CrazyLeads connected to Claude or another AI assistant (see the Connect Claude to your data guide, at the end of this page), ask for example: "Connect Google Play for the app com.company.app in the project My Company".
  2. 02The assistant returns a connection link. Open it and upload the JSON file. The file goes straight to the vault, never through the chat.
  3. 03Copy the identification key shown on the page and hand it to the developer.
  4. 04Go back to the chat and say you are done. The assistant shows the source URL and whether Google already accepted the account. Then follow steps 3 to 5.

Do not paste the service account JSON or the identification key in the chat. Always use the link.

3. Send Google notifications to CrazyLeads

Google announces subscription changes through a Pub/Sub topic, in Google Cloud. On the source page, Connection tab, copy the source URL and follow:

  1. 01Open Play Console → Monetize with Play → Monetization setup → Real-time developer notifications.
  2. 02Is there a topic name already? Write it down. None? In Google Cloud → Pub/Sub → Topics, create a topic, paste its full name (projects/your-project/topics/name) into that Play Console field, enable notifications and save.
  3. 03In Google Cloud, on the topic, grant the Pub/Sub Publisher role to google-play-developer-notifications@system.gserviceaccount.com.
  4. 04Still on the topic, create a Push subscription to the source URL. Enable authentication, pick a service account of yours for the push and leave the Audience field empty.
  5. 05On the source page, Edit connection, enter that push service account e-mail and save.

If the app server already listens to that topic, it stays the same: a topic accepts more than one subscription.

4. Link the purchase to the buyer (developer)

This step is for the app developer. Google does not send the buyer e-mail or phone. The app writes an account ID into each purchase, and the app server tells CrazyLeads who that ID belongs to: on sign-up, on login and when the person changes their e-mail. The Connection tab shows the snippets with the right URL, in Node and Python.

  1. 01In the app: on each purchase, pass the account ID as obfuscatedAccountId (Play Billing: setObfuscatedAccountId; expo-iap: obfuscatedAccountId in the request).
  2. 02On the server: send the account ID with the e-mail and/or phone to the source URL, signed with the identification key.
Server: identify the buyer (Node)
import crypto from 'node:crypto'

// The identification key: the 64 characters shown ONCE when connecting.
const KEY = process.env.CRAZYLEADS_IDENTIFICATION_KEY
// The source URL (Connection tab of the source in CrazyLeads).
const SOURCE_URL = 'https://webhook.crazyleads.com.br/webhooks/webhook/v1/YOUR_KEY'

// Call it on sign-up, on login and when the person changes their e-mail.
export async function identifyBuyer({ accountId, email, phone }) {
  const body = JSON.stringify({
    account_id: accountId, // the SAME id the app writes into the purchase
    email,
    phone,
    ts: Math.floor(Date.now() / 1000), // in seconds; valid for 5 minutes
  })
  const signature = crypto
    .createHmac('sha256', KEY)
    .update(body)
    .digest('hex')
  await fetch(SOURCE_URL, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
      'X-CL-Identificacao': '1',
      'X-CL-Assinatura': signature,
    },
    body, // send exactly the text you signed
  })
}
  • App in both stores? Use the same account ID in both: one UUID per user or, if your system ID is not a UUID, a UUID v5 of it (the snippet is in the Connect the App Store guide). One identification covers both sources.
  • Never use the e-mail as the account ID: Google does not accept personal data in that field.
  • Subscribers from before this setup: send the subscription purchase_token (the server usually stores it) instead of account_id.
  • App without its own server (only Firebase or similar): there is no server-less path yet. Sales show up in Sales, but with no buyer, timeline or Deliveries.

5. Test

  1. 01In the Play Console, under Real-time developer notifications, click Send test notification.
  2. 02On the source page, Health tab, Last notification stops showing None yet, and the top of the page shows Receiving. From the assistant, ask: "is the Google Play source receiving yet?".
  3. 03Optional, with the developer: make a purchase with a license tester account: it shows up in the Subscriptions and charges tab marked Test. A test purchase never becomes a sale nor goes to Meta.

When something goes wrong

If you seeWhat to do
"This file is not a service account JSON key"Download it again in IAM & Admin → Service accounts → Keys → Add key → JSON.
Waiting for Google permission for many hoursCheck the Play Console invite: the account e-mail, this app only and the three permissions. The Google Play Android Developer API must be enabled.
Needs attention, after 48 hoursGoogle did not accept the account. Fix the invite and send the key again in Edit connection.
"This app is already in another active Crazyleads source"An app can be in only one source in CrazyLeads. Pause or delete the other one.
At the top of the page: Waiting for first notificationCheck the topic in the Play Console, the Pub/Sub Publisher role, the authenticated Push subscription and the push e-mail in Edit connection.
Health: Purchases waiting for the buyerThe app writes the account ID, but the server has not identified it yet. Check step 4.

CrazyLeads only reads and records: it never acknowledges or consumes a purchase, that stays with your app. Refund, cancel and revoke from CrazyLeads come in the next phase.

Start measuring what actually becomes revenue

Create a free account, connect your first source and see your first lead timeline today. No card required.