Edit in GitHubLog an issue

Consent for Edge Network

The Adobe Experience Platform Consent mobile extension enables consent preferences collection from your mobile app when using the Adobe Experience Platform Mobile SDK and the Edge Network extension.

  1. In Data Collection UI, in your mobile property, select the Extensions tab.
  2. On the Catalog tab, locate or search for the Consent extension, and select Install.
  3. Set your desired default consent level.
  4. Select Save.
  5. Follow the publishing process to update SDK configuration.

AEP Consent extension configuration

  1. Add the Mobile Core and Edge extensions to your project using the app's Gradle file.

Kotlin

Copied to your clipboard
implementation(platform("com.adobe.marketing.mobile:sdk-bom:3.+"))
implementation("com.adobe.marketing.mobile:core")
implementation("com.adobe.marketing.mobile:edge")
implementation("com.adobe.marketing.mobile:edgeidentity")
implementation("com.adobe.marketing.mobile:edgeconsent")

Groovy

Copied to your clipboard
implementation platform('com.adobe.marketing.mobile:sdk-bom:3.+')
implementation 'com.adobe.marketing.mobile:core'
implementation 'com.adobe.marketing.mobile:edge'
implementation 'com.adobe.marketing.mobile:edgeidentity'
implementation 'com.adobe.marketing.mobile:edgeconsent'
  1. Import the Mobile Core and Edge extensions in your Application class.
Copied to your clipboard
import com.adobe.marketing.mobile.MobileCore;
import com.adobe.marketing.mobile.Edge;
import com.adobe.marketing.mobile.edge.identity.Identity;
import com.adobe.marketing.mobile.edge.consent.Consent;

Register Edge extensions with Mobile Core

Java

Copied to your clipboard
public class MainApp extends Application {
private final String ENVIRONMENT_FILE_ID = "YOUR_APP_ENVIRONMENT_ID";
@Override
public void onCreate() {
super.onCreate();
MobileCore.setApplication(this);
MobileCore.configureWithAppID(ENVIRONMENT_FILE_ID);
MobileCore.registerExtensions(
Arrays.asList(Consent.EXTENSION, Identity.EXTENSION, Edge.EXTENSION),
o -> Log.d("MainApp", "Adobe Experience Platform Mobile SDK was initialized")
);
}
}

Kotlin

Copied to your clipboard
class MainApp : Application() {
override fun onCreate() {
super.onCreate()
MobileCore.setApplication(this)
MobileCore.configureWithAppID("YOUR_APP_ENVIRONMENT_ID")
val extensions = listOf(Consent.EXTENSION, Identity.EXTENSION, Edge.EXTENSION)
MobileCore.registerExtensions(extensions) {
Log.d("MainApp", "Adobe Experience Platform Mobile SDK was initialized")
}
}
}

Configuration keys

To update the SDK configuration programmatically, use the following information to change the Edge Consent configuration values.

KeyRequiredDescriptionData Type
consent.default
No
Consents in XDM format. For more details, see Privacy/Personalization/Marketing Preferences (Consents) Schema.
Map
Was this helpful?
  • Privacy
  • Terms of Use
  • Do not sell or share my personal information
  • AdChoices
Copyright © 2024 Adobe. All rights reserved.