1

MarketingCloud analytics for tracking push notifcations can be enabled by calling setAnalyticsEnabled(true) on the MarketingCloudConfig.builder() instance when initializing SFMCSdk, as explained here.

We would like to enable/disable analytics according to user consent for tracking, to make our app 100% GDPR compliant.

In our app user can update user consent multiple times, so is there a way to enable/disable MC analytics without reinitialising SDK?

1 Answer 1

0

Yes! We introduced a series of runtime toggles expressly for this use-case:

  SFMCSdk.requestSdk { sdk ->
    sdk.mp { push ->
      // Enable
      push.analyticsManager.enableAnalytics()
      
      // Disable
      push.analyticsManager.disableAnalytics()
    }
  }

The docs are being updated to include these code snippets and instructions.

1
  • 1
    This is working. Thank you!
    – VladSabau
    Commented Apr 19 at 6:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .