Privacy & Consent
Gate the Grovs Android SDK on user consent, and see what it collects
Gating collection on consent
The SDK collects nothing while it is disabled. To start a launch disabled, pass your stored consent to configure — calling setSDK(false) afterwards is too late, because configuring starts the first round of collection:
val hasConsent = ConsentStore.hasConsent()
Grovs.configure(
this,
"your-api-key",
useTestEnvironment = false,
baseURL = null,
autoTrackScreenViews = true,
clipboardDomains = null,
enabled = hasConsent
)Then turn it on or off as consent changes:
fun userDidChangeConsent(granted: Boolean) {
ConsentStore.save(granted)
Grovs.setSDK(granted)
}The flag is not persisted by the SDK — pass your stored value to configure on every launch. The shorter configure overloads reset it to true, so use the full overload when you gate on consent, and call setSDK only after configure.
Configuring with enabled = false starts no requests, reads no clipboard or device identifiers, and records no events. The install and first open are recorded once the SDK is enabled and authenticates.
While the SDK is disabled
- Nothing leaves the device: no authentication, device lookup, events, screen views, or purchases.
- Automatic screen tracking stops, and time spent disabled is excluded from engagement.
- Features that need the backend are unavailable: link generation and link details complete with their usual
GrovsException, the unread count returnsnull, and the messages list is not shown. Message UI already on screen stays visible but makes no further requests. - Outstanding SDK operations, including their retries, are cancelled. Requests already transmitted may still reach the server.
- Changes to
identifier,attributes,pushToken, and screen aliases are held as the latest desired values. - Queued events keep their identity and stay on the device, subject to the usual retention limits.
When you enable it again, the SDK authenticates if needed and sends everything that was held or queued.
Enabling does not replay a launch deep link or a link request that was cancelled while disabled. If the app was opened from a link while disabled, forward a later Grovs.onStart(activity) or Grovs.onNewIntent(intent, activity) to resolve it.
What the SDK collects
| Data | When | Why |
|---|---|---|
| App version and build, package name, device model, user agent, screen size, time zone, preferred language, WebGL vendor and renderer | When the SDK authenticates and looks up the device | Matching installs and opens to link clicks; analytics |
The Android ID (Settings.Secure.ANDROID_ID) and the Google Play install referrer | Same | Recognizing the device across launches; install attribution. The backend-issued device identifier is held in memory only |
| User identifier, user attributes, push token | Only if you set them | Showing users in the dashboard; delivering messages |
| Installs, opens, time spent, reactivations | Automatically | Attribution and analytics |
| Custom events and screen views | When you call track / trackScreenView / trackNavigation, and through automatic screen tracking | Analytics |
| Purchases | When you call logInAppPurchase or logCustomPurchase | Revenue analytics |
| Clipboard contents | Read only on the first launch after install, when fingerprint matching found nothing, your project has recent copy-to-clipboard link clicks, and the clipboard holds a web URL. Sent only if it is a link on a Grovs host or one of your clipboardDomains | Deterministic install attribution — see clipboard-assisted deferred deep linking |
The SDK does not read the advertising ID.
Google Play data safety
Your app's Data safety form in Google Play Console must cover what the SDK collects on your behalf. Based on the table above, that is typically:
- Device or other IDs
- App activity → App interactions
- Personal info → User IDs, if you set
identifier - Financial info → Purchase history, if you log purchases
Anything you put in attributes or event properties — an email address or name, for example — is data you collect too, and needs its own declaration.
Logs
SDK logs go through android.util.Log with the tag Logger, and every message starts with 🔗GROVS. Filter Logcat by message text, not by tag. The default level is ERROR; pass LogLevel.INFO to setDebug while integrating.