MoEngage Docs

Compliance

Opt-Out of Data Tracking

To opt-out of data tracking by the SDK use optOutOfDataTracking: method as shown below. Once you have opted out of data tracking you need to explicitly opt-in to start tracking any event OR attributes for the user.

MoEngage.sharedInstance().optOut(ofDataTracking: true)
[[MoEngage sharedInstance] optOutOfDataTracking:true];

Opt-Out of Push

To opt-out of push notification from MoEngage use optOutOfMoEngagePushNotification: method as shown below. Once you have opted out of push notification you need to explicitly opt-in to enable push notifications for the user.

MoEngage.sharedInstance().optOut(ofMoEngagePushNotification: true)
[[MoEngage sharedInstance] optOutOfMoEngagePushNotification:true];

❗️

NOTE:

  • In this method, we are tracking an attribute for the user MOENGAGE_PUSH_OPTED_OUT. Make sure you are using this Attribute to segment out the users while creating the campaign.

  • This method will not disable Push Notification for the app but only track an attribute as mentioned above which can be used while setting segmentation for the campaign.

  • To disable Push Notifications redirect the user to App settings screen.

Opt-Out of InApp

To opt-out of in-app notification use optOutOfInAppCampaign: method as shown below. Once you have opted out of in-app notification you need to explicitly opt-in to show any inApp campaign to the user.

MoEngage.sharedInstance().optOutOf(inAppCampaign: true)
[[MoEngage sharedInstance] optOutOfInAppCampaign:true];

IDFA and IDFV OptOuts

SDK tracks IDFA(Advertising Identifier) by default as a UserAttribute, it's tracked only if the AdSupport framework is included in the project and if the User has not limited Ad Tracking. Incase you would want to opt-out of IDFA Tracking call the opt-out method as shown below:

MOAnalytics.sharedInstance().optOut(ofIDFATracking: true)
[[MOAnalytics sharedInstance] optOutOfIDFATracking:true];

SDK also tracks IDFV(Identifier for Vendor) by default as a device Identifier. Incase you would want to opt-out of IDFV Tracking call the opt-out method as shown below:

MOAnalytics.sharedInstance().optOut(ofIDFVTracking: true)
[[MOAnalytics sharedInstance] optOutOfIDFVTracking:true];

IDFA and IDFV opt-outs are available from SDK version 6.1.1

Enable/Disable SDK

If you don't want the MoEngage SDK to track any user information or send any data to the MoEngage System use the below method:

MoEngage.sharedInstance().disableSDK()
[[MoEngage sharedInstance] disableSDK];

Once this API is called all the SDK APIs will be non-operational. SDK will be disabled until enableSDK() is called.
Once you have the user's consent use the below API to enable the SDK.

MoEngage.sharedInstance().enableSDK()
[[MoEngage sharedInstance] enableSDK];

Enable/Disable SDK methods are available from SDK version 6.3.0.

Updated 4 months ago

Compliance


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.