Adobe Journey Optimizer
The Adobe Journey Optimizer extension for Adobe Experience Platform Mobile SDKs powers push notifications and in-app messages for your mobile apps. This extension also helps you to collect user push tokens and manages interaction measurement with Adobe Experience Platform services.
The following documentation details how to use the extension and required configurations to get started with Adobe Journey Optimizer for Adobe Experience Platform services, app stores, and your apps.
Before starting
- Read the tutorial on getting started with push configuration to learn how to configure push channels in Adobe Journey Optimizer.
- Update your app's Datastream in Adobe Experience Platform Data Collection
- Integrate with following extensions:
Update Datastream with a Profile dataset
Navigate to a previously configured Datastream by following the instructions in the configure datastreams tutorial in Adobe Experience Platform Data Collection and select Add Service. In the service dropdown select Adobe Experience Platform.
- In the Event Dataset dropdown, select a dataset previously created in the Adobe Experience Platform UI.
- In the Profile Dataset dropdown, select the AJO Push Profile Dataset.
- Ensure the Personalized Destinations box is checked.
- Ensure the Adobe Journey Optimizer box is checked.
- Select Save after making these selections.
Set up a mobile property in Adobe Data Collection
To learn how to create the mobile property, please read the tutorial on creating a mobile property
Now that a mobile property is created, we can setup the Adobe Journey Optimizer extension.
Setup Adobe Journey Optimizer extension
Configure extension in the Data Collection UI
Go to the Experience Platform Data Collection UI, select mobile property and navigate to Extensions from the left navigation panel:
- Navigate to the Catalog tab, locate the Adobe Journey Optimizer extension, and select Install
- Select the pre-created AJO Push Tracking Experience Event Dataset from the Event Dataset dropdown.
- Select Save.
- Follow the publishing process to update SDK configuration.
The datasets selected should use a schema that uses the "Push Notification Tracking" XDM field group. The pre-created CJM Push Tracking Dataset contains this XDM field group in its schema definition. For more information, please read the tutorial on setting up schemas and datasets.
Add the Adobe Journey Optimizer extension to your app
Include Messaging extension as an app dependency
Add MobileCore, Edge and Messaging extensions as dependencies to your project.
(Android)
Add the required dependencies to your project by including them in the app's Gradle file.
Copied to your clipboardimplementation(platform("com.adobe.marketing.mobile:sdk-bom:3.+"))implementation("com.adobe.marketing.mobile:core")implementation("com.adobe.marketing.mobile:edgeidentity")implementation("com.adobe.marketing.mobile:edge")implementation("com.adobe.marketing.mobile:messaging")
Using dynamic dependency versions is not recommended for production apps. Please read the managing Gradle dependencies guide for more information.
(Android)
Add the required dependencies to your project by including them in the app's Gradle file.
Copied to your clipboardimplementation platform('com.adobe.marketing.mobile:sdk-bom:3.+')implementation 'com.adobe.marketing.mobile:core'implementation 'com.adobe.marketing.mobile:edgeidentity'implementation 'com.adobe.marketing.mobile:edge'implementation 'com.adobe.marketing.mobile:messaging'
Using dynamic dependency versions is not recommended for production apps. Please read the managing Gradle dependencies guide for more information.
(iOS)
Add the required dependencies to your project using CocoaPods. Add following pods in your Podfile
:
Copied to your clipboarduse_frameworks!target 'YourTargetApp' dopod 'AEPCore', '~> 5.0'pod 'AEPEdge', '~> 5.0'pod 'AEPEdgeIdentity', '~> 5.0'pod 'AEPMessaging', '~> 5.0'end
Add the required dependencies to your project by including them in the app's Gradle file.
Copied to your clipboardimplementation(platform("com.adobe.marketing.mobile:sdk-bom:3.+"))implementation("com.adobe.marketing.mobile:core")implementation("com.adobe.marketing.mobile:edgeidentity")implementation("com.adobe.marketing.mobile:edge")implementation("com.adobe.marketing.mobile:messaging")
Using dynamic dependency versions is not recommended for production apps. Please read the managing Gradle dependencies guide for more information.
Add the required dependencies to your project by including them in the app's Gradle file.
Copied to your clipboardimplementation platform('com.adobe.marketing.mobile:sdk-bom:3.+')implementation 'com.adobe.marketing.mobile:core'implementation 'com.adobe.marketing.mobile:edgeidentity'implementation 'com.adobe.marketing.mobile:edge'implementation 'com.adobe.marketing.mobile:messaging'
Using dynamic dependency versions is not recommended for production apps. Please read the managing Gradle dependencies guide for more information.
Add the required dependencies to your project using CocoaPods. Add following pods in your Podfile
:
Copied to your clipboarduse_frameworks!target 'YourTargetApp' dopod 'AEPCore', '~> 5.0'pod 'AEPEdge', '~> 5.0'pod 'AEPEdgeIdentity', '~> 5.0'pod 'AEPMessaging', '~> 5.0'end
Initialize Adobe Experience Platform SDK with Messaging Extension
Next, initialize the SDK by registering all the solution extensions that have been added as dependencies to your project with Mobile Core. For detailed instructions, refer to the initialization section of the getting started page.
Using the MobileCore.initialize
API to initialize the Adobe Experience Platform Mobile SDK simplifies the process by automatically registering solution extensions and enabling lifecycle tracking.
(Android)
This API is available starting from Android BOM version 3.8.0.
Copied to your clipboardimport com.adobe.marketing.mobile.LoggingModeimport com.adobe.marketing.mobile.MobileCore...import android.app.Application...class MainApp : Application() {override fun onCreate() {super.onCreate()MobileCore.setLogLevel(LoggingMode.DEBUG)MobileCore.initialize(this, "ENVIRONMENT_ID")}}
(Android)
This API is available starting from Android BOM version 3.8.0.
Copied to your clipboardimport com.adobe.marketing.mobile.LoggingMode;import com.adobe.marketing.mobile.MobileCore;...import android.app.Application;...public class MainApp extends Application {@Overridepublic void onCreate(){super.onCreate();MobileCore.setLogLevel(LoggingMode.DEBUG);MobileCore.initialize(this, "ENVIRONMENT_ID");}}
(iOS)
This API is available starting from iOS version 5.4.0.
Copied to your clipboard// AppDelegate.swiftimport AEPCoreimport AEPServices...final class AppDelegate: NSObject, UIApplicationDelegate {func application(_: UIApplication, didFinishLaunchingWithOptions _: [UIApplication.LaunchOptionsKey: Any]? = nil) -> Bool {MobileCore.setLogLevel(.debug)MobileCore.initialize(appId: "ENVIRONMENT_ID")...}}
(iOS)
This API is available starting from iOS version 5.4.0.
Copied to your clipboard// AppDelegate.m#import "AppDelegate.h"@import AEPCore;@import AEPServices;...@implementation AppDelegate- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {[AEPMobileCore setLogLevel: AEPLogLevelDebug];[AEPMobileCore initializeWithAppId:@"ENVIRONMENT_ID" completion:^{NSLog(@"AEP Mobile SDK is initialized");}];...return YES;}@end
This API is available starting from Android BOM version 3.8.0.
Copied to your clipboardimport com.adobe.marketing.mobile.LoggingModeimport com.adobe.marketing.mobile.MobileCore...import android.app.Application...class MainApp : Application() {override fun onCreate() {super.onCreate()MobileCore.setLogLevel(LoggingMode.DEBUG)MobileCore.initialize(this, "ENVIRONMENT_ID")}}
This API is available starting from Android BOM version 3.8.0.
Copied to your clipboardimport com.adobe.marketing.mobile.LoggingMode;import com.adobe.marketing.mobile.MobileCore;...import android.app.Application;...public class MainApp extends Application {@Overridepublic void onCreate(){super.onCreate();MobileCore.setLogLevel(LoggingMode.DEBUG);MobileCore.initialize(this, "ENVIRONMENT_ID");}}
This API is available starting from iOS version 5.4.0.
Copied to your clipboard// AppDelegate.swiftimport AEPCoreimport AEPServices...final class AppDelegate: NSObject, UIApplicationDelegate {func application(_: UIApplication, didFinishLaunchingWithOptions _: [UIApplication.LaunchOptionsKey: Any]? = nil) -> Bool {MobileCore.setLogLevel(.debug)MobileCore.initialize(appId: "ENVIRONMENT_ID")...}}
This API is available starting from iOS version 5.4.0.
Copied to your clipboard// AppDelegate.m#import "AppDelegate.h"@import AEPCore;@import AEPServices;...@implementation AppDelegate- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {[AEPMobileCore setLogLevel: AEPLogLevelDebug];[AEPMobileCore initializeWithAppId:@"ENVIRONMENT_ID" completion:^{NSLog(@"AEP Mobile SDK is initialized");}];...return YES;}@end
Configuration keys
You can update the SDK configuration, including the Messaging configuration values, programmatically by using the following information.
Key | Required | Description | Data Type | Operating System |
---|---|---|---|---|
messaging.eventDataset | Yes | Experience Event Dataset ID which can be found from Experience Platform | String | Android/iOS |
messaging.useSandbox | No | A variable that lets the apnsSandbox environment be used for receiving push notifications. More details can be found in the messaging documentation | Boolean | iOS |
Next Steps
- Push notification implementation guide
- In-App message implementation guide
- Code-based experiences implementation guide