Experience League | Image

Building a Web Experience Foundation with AEM, Target, and Analytics

Lab Overview

In this lab, we will be integrating AEM with Adobe Analytics and Adobe Target. In doing so, we will leverage Adobe I/O and Launch, by Adobe. We will use Adobe I/O as it is the new centralized hub for integrations into Adobe's products and technologies. We will use Launch because tag management enables marketers to easily connect and manage their Experience Cloud and third-party solutions without developer intervention.

Integrating these solutions will provide us with the following value:

  • We will be able to leverage all of the value of the Adobe Target, Adobe Analytics, and Adobe Launch solutions on our website.
  • We will be able to publish Experience Fragments, reusable blocks of content, from Adobe Experience Manager to Adobe Target to use in our personalization and optimization activities.
  • We will be able to view performance metrics for our web content directly in the AEM UI. This allows our content authors to have access to analytics data even if they have not been trained in or do not have access to Adobe Analytics.

Key Takeaways

  1. How to leverage extensions, rules, and data elements in Launch to manage your Experience Cloud deployment
  2. How to use Adobe I/O to integrate Adobe Launch with AEM
  3. How to integrate AEM with Analytics and Target directly
  4. When and why to use Adobe Launch for integration vs AEM's legacy integrations
  5. How to use AEM Experience Fragments in a Target personalization activity
  6. How to view Analytics data directly in AEM

Prerequisites

We have configured this lab environment for you so that you have everything you require to complete these exercises. If you would like to walk through this lab again at home, we have provided a section at the end that covers how to configure these prerequisites in your own environment. To go through these pre-requisites, you will need access to:

  • AEM
  • Analytics
  • Target
  • Launch, by Adobe
  • The Adobe I/O Console for your Experience Cloud organization

Tips for the lab

If you do not already have a lot of experience with the solutions, do not worry, our teaching assistants are here to help. Additionally, we have provided you with some basic guidance for getting around that you may find helpful.

Accessing the Experience Cloud

We have added browser shortcuts to Chrome for the Experience Cloud solutions that we will be using today. You can also access our Experience Cloud account directly by pointing your browser to https://summit2019l725.experiencecloud.adobe.com.

The solution switcher

Throughout the lab, we will often switch between Experience Cloud solutions. To access the solution switcher from any of the SaaS-based Experience Cloud solutions, click on the solution switcher icon.

Note that Experience Manager is not connected to our other solutions through the solution switcher. Thus, Experience Manager is not illuminated in our SaaS-based solutions and our SaaS-based solutions are not illuminated in Experience Manager.

During the lab, we will be accessing Target and Activation. All other options can be ignored.

Accessing Experience Manager

We have installed two different Experience Manager environments on your lab machine: an author environment and a publish environment. The author environment is where we will author our content and configure our integrations. Our authored content and configurations will be _published,_activated,or replicated to our publish environment. These three terms are all synonymous. The publish environment in turn will serve our authored website.

At any time, you can access these environments in your web browser by using the provided bookmarks or directly at http://localhost:4502 for the author environment and http://localhost:4503 for the publish environment. When prompted to login to the author environment, you may use Experience Manager's default username and password: admin and admin.

Getting "Home" in Experience Manager

Whenever you are in one of Experience Manager's consoles and would like to access the central menu, just click on the Adobe Experience Manager icon in the top left of your screen or accessing http://localhost:4502/aem/start.html.

NOTE - This will be referenced a lot throughout this lab.

If you currently have an item selected in one of the Experience Manager consoles, it is possible that you will not be able to see this icon. In these cases, you can click on the "X" icon in the top right of your screen to deselect all items and dismiss the contextual menu that runs across the top of the screen.

Changing your view in Experience Manager consoles

Experience Manager's consoles provide several views of your content. In most of our exercises, we have shown how to complete the activity using list or column view. If your view does not match our instructions, you can change your view.

  1. In the current Experience Manager console, you will see an icon in the top-right that matches your current view.

  2. At any time, you can click this icon to choose one of the other views that is available.

Using omnisearch in Experience Manager

Experience Manager provides a feature called omnisearch that is useful for navigating the system. In many steps throughout the lab, rather than clicking to navigate to a location, you can click on the magnifying glass in the top bar and type the location that you would like to navigate to. This may come in handy if you have gotten lost and are trying to find a particular screen or console. For example, rather than clicking on Tools > Cloud Services > Adobe Launch Configurations to navigate to the Launch configurations, you can click the magnifying glass, type Adobe Launch Configurations, and click on the link that is returned.

Lesson 1 – Launch Configurations

Objective

  1. Understand Launch Extensions, and how they are different from Tools in DTM.
  2. Understand Data Elements, and why we use them.
  3. Understand Rules, the Rule Editor, and how to use Rules to configure and execute actions against our Experience Cloud solutions.

Lesson Context

In this lesson, we will review the configurations that have been implemented in preparation for this lab. This will allow you to understand the important role that Launch plays in our Experience Cloud deployment. We will be looking at various settings that have been put in place in preparation for this lab, but since we are all sharing an environment, we will not be updating any of them.

As you close each screen, you may be prompted that you have unsaved changes. In these cases, please choose to Discard Changes.

Exercise 1.1 - Review Launch Extensions

One of the biggest differences that Launch has introduced from its predecessor, DTM, is the concept of extensions. Adobe has provided extensions for each of the Experience Cloud products that we implement in Launch, but third-party partners can also implement extensions for their products, much like an App Store for your website. This decentralization is powerful in that it allows Adobe's teams and partner ecosystem to scale independently of the Launch team. In this exercise, we will review the extensions that have been installed for you.

  1. Login to the Experience Cloud by clicking the Experience Cloud bookmark in Chrome or by going to https://summit2019l725.experiencecloud.adobe.com.
  2. Click the button that is labeled Sign in with an Adobe ID.
  3. Click the button that is labeled Adobe ID Personal Account.
  4. Enter an Email address of ireasor+summitl725@adobetest.com and a Password of Batman_Triplet_Insignia.
  5. Click Sign In.
  6. Once logged in, click on the solution switcher and select Activation.

  1. On the screen that loads, click Go to Launch.

  1. In the launch landing page https://launch.adobe.com/, click on the link for the property named Summit Lab L725.

  1. Click on the Extensions tab.

  1. Note that there are four extensions installed: Core, Adobe Analytics, Adobe Target, and Adobe ContextHub.
  2. Click on the Configure button for the ContextHub extension.

  1. Note that we are using the Default ContextHub Data layer. This is the default data layer that is provided by Experience Manager. However, if our customer has a custom data layer, we can use this extension to map it as well – even if they aren't using Experience Manager.

  2. Click Cancel.

  3. Click the Catalog icon to switch to the extension catalog.

  1. Note that in addition to the extensions that Adobe offers, there are also many third-party extensions in the catalog.

Exercise 1.2 - Review Data Elements

Launch allows us to map values from our data layer to data elements. These data elements are available throughout the Launch UI in various extensions and rule editors. This helps ensure consistency in our implementation and ease of use for users. In this exercise, we will review the pagename data element that we have created.

  1. Click on the Data Elements tab.

  1. Click on the link for the _pagename_ data element.

  2. Note that we have used the Adobe ContextHub extension to map the value from pagedata.path to our pagename data element. This extension makes it easy for us to access our data layer for mapping to our data elements. Take a look through the values that are available in the Data Item field. Note that it contains all of the values that are exposed in the default AEM Context Hub.

  1. Click Cancel.

Exercise 1.3 - Review Rules

Installing the Target and Analytics extensions does not help if we do not actually send our Analytics beacon and fire our Target mboxes. This is where Rules come into play. We have set up two rules for this lab environment:

  • Page Top rule to fire the Target mbox
  • Page Bottom rule to fire our Analytics beacon

In this exercise, we will look at the rule editor and inspect the two rules that have been created for this lab.

  1. Click on the Rules tab.

  2. Click on the link for the Page Top rule.

  1. Note that the If section of the rule editor contains an event called Library Loaded (Page Top). This means that our rule will fire immediately after the Launch library is loaded at the top of the page.

  2. In the Then section, note that we are executing two actions: Load Target and Fire Global Mbox. These actions load the Target at.js library, fire the global mbox, and reveal our hidden page content. We recommend hiding page content until the Target global mbox has fired to prevent "flicker".

  1. Click Cancel.

  2. Click the link for the Page Bottom rule.

  3. In the Events, note that we are executing this rule at the bottom of the page.

  4. In the Actions, note that we are executing two: Set Variables and Send Beacon.

  5. Click on the Set Variables action. Be careful not to click on the X icon as this will remove the action.

  1. In the Action Configuration screen, scroll down in the right pane and locate the Page Name variable. Note that it has been set to %pagename%. This refers to the data element that we previously configured.

  2. Click on the data icon to the right of this field.

  1. Note that our pagename data element is listed here. Had we mapped other data elements, those would be listed here as well.
  2. You may now close any Launch browser tabs that you have opened as we will not be using them in future exercises.

Lesson 2 – Experience Manager/Launch Integration

Objective

  1. Review Adobe Launch integrations in Adobe I/O
  2. Attach an Adobe Launch configuration to a site in Experience Manager
  3. Test that Launch is correctly serving Experience Cloud solutions on our site

Lesson Context

In this lesson, we will configure Experience Manager to integrate with Launch, which will allow us to deploy the Analytics and Target configurations from the previous chapter to our site. In preparation for this lab, we have pre-configured an Adobe I/O integration with a public key certificate from your local Experience Manager environment. We will use this configuration to connect our Experience Manager environment with Adobe Launch.

Exercise 2.1 - Create the AEM/Launch integration

In this section, we will leverage the Adobe I/O integration that was previously created to create an Adobe Launch Configuration for our site.

  1. Navigate to the AEM Author environment by pointing your browser to http://localhost:4502 or by using the shortcut provided in Google Chrome.

  2. Log in with admin as both the username and the password.

  3. Click the Tools icon, followed by the Cloud Services menu item, followed by the Adobe Launch Configurations card.

  1. Click on We.Retail. Note that you will need to click on the label and not the folder icon. If you see a blue checkmark, you have done it wrong. If you see a blue Create button appear, you have done it correctly. Click the Create button.

  1. Fill in the following values. Note that the Company and Property fields are dynamically loaded from Launch, so you may need to wait a second for values to appear.

    a. Title: We.Retail Launch

    b. Associated Adobe IMS Configuration: Adobe I/O – Launch Integration

    c. Company: Summit 2019 Lab L725

    d. Property: Summit Lab L725

  1. As we click through the next screens, you will notice that we will be shown the URLs for our Launch libraries and could select Archive to host the Launch library directly on our AEM instance. While this is considered a best practice, we will not be doing so here for purposes of simplicity in the lab. Click Next through each of the following screens and then Create.

Exercise 2.2 - Publish and Validate

In this exercise, we will publish the integrations that we have configured and validate that we are able to see the Analytics and Target libraries on our site.

  1. In Experience Manager, click the Adobe Experience Manager icon to return to the home screen.

  2. Click the Sites icon.

  1. Click on the icon for the We.Retail site to select it. Do not click the link for the name of the site as this will open it instead. When you have selected the site, the icon will be overlaid with a blue checkmark.

  1. With the We.Retail site selected, click on Quick Publish in the top navigation. When prompted to confirm, click Publish.

  1. Open a new browser tab and open your Experience Manager publish environment by pointing your browser to http://localhost:4503. You should be redirected to http://localhost:4503/content/we-retail/us/en.html.

  2. From the OS Chrome menu, select View, Developer, Developer Tools.

  1. This will open a console at the bottom of your browser window. Click on the Network tab, then refresh the current page.

  1. Once the page finishes loading, use the search field in the Network tool to search for launch. This shows that our Launch code is being successfully loaded.

  1. Using the search field, search for AppMeasurement. This shows that our Analytics library has been successfully loaded.

  1. Using the search field, search for b/ss. This shows the call that we are making to Analytics to register our page load.

  1. Select the server call and scroll to the Query String Parameters section at the bottom of the pane to the right of it. Note that the pageName parameter has been set to our page's path. This is due to the mapping that we did when configuring the Analytics rule in Launch.

  1. Using the search field, search for mbox. This call for the global mbox shows that the Target library is being successfully loaded.

Lesson 3 – Content Insights

Objective

  1. Configure AEM to import Analytics data.

  2. View Analytics data in the Experience Manager UI.

Lesson Context

In this lesson, we will implement Content Insights. This feature allows us to import Analytics data directly into Experience Manager. This allows authors, even those who do not have Analytics logins or training, to see important performance data about their content directly in the CMS.

Exercise 3.1 - Configure the Analytics Legacy Cloud Service

In this exercise, we will configure the Analytics legacy cloud service to enable importing the impression data and apply it to the We.Retail reference site. It is sometimes confusing as to why we would be implementing both the Launch integration and the Analytics integration. This is because the Launch integration controls the client-side loading of the Analytics library and tracking of impression data while the Analytics integration controls the server-side import of reporting data from Analytics. For this reason, we will select Do not add tracking tag to page when configuring the integration to tell AEM that we are managing the tracking tag through a tag manager.

When configuring the integration framework, note that we will be mapping the pageName property from Analytics to the pageData.path CQ property. This matches the configuration that we made previously in Launch. This tells AEM how to determine which page it should apply the imported impression data to. If you have a different way of tracking the pageName in Analytics, you may need to implement a custom Analytics Page Name Provider Service, but that is beyond the scope of this lab.

  1. In your AEM author environment, click the Adobe Experience Manager icon to return to the home screen. If you cannot see the icon, it is likely that you have something selected. Click the X icon in the top right of your screen to escape from any selections.

  1. Under Tools, Cloud Services, select Legacy Cloud Services.

  1. In the list of cloud services, locate Adobe Analytics and click on Configure Now.

  1. Give your configuration a title of Analytics Configuration and click Create.

  1. Populate the dialog that opens with the following values and then click Connect to Analytics. Click OK. After clicking OK, you may see an error message stating that we have failed to obtain the available segment list from the Analytics API Server. It is safe to ignore this message and click OK to dismiss it.

a. Company: Summit 2019 Lab L725

b. Username: ireasor+summitl725@adobetest.com

c. Shared Secret: 9fa70a3724f6c9fb2393353a8738c8a7

d. Data Center: Oregon

e. Do not add tracking tag to page: Checked

f. All other fields can be left with default values

  1. Next to Available Frameworks, click the + icon.

  1. Give your framework a title of Analytics Framework and click Create.

  1. In the window that opens, click Add Item in the Report Suites section. You may need to move the Experience Manager sidekick out of the way to see it.

  1. In the dropdown that appears, select the summit2019l725prod report suite. When prompted to load the default server settings, click Yes. From the runmodes dropdown, select author.

  1. From the sidekick, scroll down in the General section until you see the Page components. Drag the first of the two into the Mappings defined in this Framework section.

  1. From the menu on the left of the screen, drag the Page Name item to the pagedata.path CQ variable on the right.

When you have successfully mapped the variable, it will look like:

  1. Close this browser tab.

Exercise 3.2 - Attach the cloud service to the We.Retail site

In this exercise, we will attach the cloud service we have created to the We.Retail site. This will allow Experience Manager to import impression data for these pages from Analytics.

  1. Open a new browser tab and load Experience Manager (http://localhost:4502).

  2. Click on Sites.

  1. Click on the icon for the We.Retail site to select it. Do not click the link for the name of the site as this will open it instead. In the top navigation, click on Properties.

  1. Click on the Cloud Services tab.

  1. In the Add Configuration dropdown, select Adobe Analytics and select the appropriate value. There should only be one framework listed (the one that we created in the previous exercise).

  1. Click Save & Close on the top right of the screen.

Exercise 3.3 - Update the polling configuration

Asset Insights will poll your Analytics environment on a schedule and download new report data whenever this time is reached. By default, new data will be imported every 12 hours. Since we would like to see our impression data while we are still in this lab, we will configure our environments to import data much more often than this.

  1. In AEM, click the Adobe Experience Manager icon to return to the home screen.

  1. Under Tools, click on Operations, then select Web Console.

  1. In the console that opens, locate the item in the list that is named Adobe AEM Managed Polling Configuration. You will see several items listed underneath it that are named com.day.cq.polling.importer.impl.ManagedPollConfigImpl. followed by a unique identifier. Click the pencil icon next to the first item listed to open its configuration.

  1. In the configuration that opens, change the Poll interval to 120. This will cause the import to run once every two minutes. Click Save.

  1. Repeat this process for the other five items.

Exercise 3.4 - Validate Content Insights

In this exercise, we will view the imported content insight data.

  1. Close any open windows and point a new browser window to your AEM author environment at http://localhost:4502.

  2. Click on Sites.

  1. Ensure that you are in List view. Click on the view switcher in the top-right of your screen and select List view from the dropdown.

  1. Click on the view switcher and select View Settings. In the Configure Columns modal, deselect the Template and Workflow checkboxes and select the three checkboxes under Analytics: Page Views, Unique Visitors, and Time on Page. Note that if you do not de-select one of the boxes that is already selected, Experience Manager will not allow you to select all three of these items as it will only allow a maximum of six selections. Click Update.

  1. Click on the name of the We.Retail site to view its children. Do not click on the icon, as this will select the site instead of descending into it.

  1. Do the same for the United__States site.

  1. Note that the English page shows Page Views, Unique Visitors, and Time on Page. Note that the time period for the data can be changed in the action bar. This integration provides data in increments of the last 30 days, the last 90 days, and all data for this year.

  1. Click on the English page's icon to select it.

  1. Click on the Analytics & Recommendations item in the top navigation.

  1. In the Content Insight window that opens, you can see key metrics, average time spent on the page, bounces, and sources.

  1. You can drag the slider on the timeline to change the time frame for which you are viewing data.

Lesson 4 – Experience Fragments

Objective

  1. Configure AEM to export Experience Fragments to Target
  2. Use the Target Visual Experience Composer to author a personalization activity
  3. Use reusable content from AEM in a Target activity

Lesson Context

Experience fragments are groups of one or more authored AEM components that can be reused across experiences. In this lesson, we will be publishing these fragments to Target for use in the Visual Experience Composer (VEC). This allows customers to achieve consistency in experiences between their content authoring and site testing and optimization teams and increase the velocity with which their testing and optimization team operates.

Exercise 4.1 - Configure the Target legacy cloud service

In this exercise, we will configure the Target legacy cloud service to enable the export of experience fragments. It is sometimes confusing as to why we would be implementing both the Launch integration and the Target integration. This is because the Launch integration controls the client-side loading of the Target library and personalized experiences while the Target integration controls the server-side export of experience fragments to Target. For this reason, when configuring the integration, we will select Use Tag Management System to deliver client library to tell AEM that we are managing the delivery of AT.js through a tag manager.

  1. In AEM, click the Adobe Experience Manager icon to return to the home screen.

  1. Under Tools, select Cloud Services, then select Legacy Cloud Services. Note that this is the same area where we configured the Analytics integration previously.

  1. In the list of cloud services, locate Adobe Target and click on Configure Now.

  1. Give your configuration a title of Target Configuration and click Create.

  1. In the configuration dialog, enter the following values:

a. Client Code: summit2019labl725

b. E-Mail: exptargeting@adobe.com

c. Password: Adobe_05

d. API Type: REST

e. Use Tag Management System to deliver client library: true

f. Leave all other fields as default values

  1. Click Connect to Adobe Target and then click OK.

  2. Close this browser tab.

Exercise 4.2 - Attach the Target cloud service to an experience fragment folder

In this exercise, we will create a folder to house our experience fragments and attach the Target cloud service configuration.

  1. Open a new browser window and point it to your AEM author environment (http://localhost:4502).

  2. Click on Experience Fragments.

  1. Click on the blue Create button in the top-right of your screen and then select Folder.

  1. Give your folder a title of Target Fragments and click Create.

  1. Select the Target Fragments folder that was created by clicking on its icon.

  1. Click on Properties in the navigation bar.

  1. In the window that opens, click on the Cloud Services tab.

  1. Select Adobe Target from the Cloud Service Configurations section and leave the Adobe Target Export Format set to its default value of HTML. In AEM 6.5, we have added the ability to export fragments as JSON as well, but we will not be exploring that capability today.

  1. Click Save & Close.

Exercise 4.3 - Create and publish an experience fragment

In this exercise, we will create an experience fragment. While we will be publishing the fragment to Target for use in the VEC, these fragments can also be used on pages in AEM Sites, published to social media networks, or served RESTfully to sites or applications that are served from other platforms.

  1. Navigate into the folder that we created in the previous exercises by clicking on its name.

  1. Click the blue Create button and select Experience Fragment.

  1. Select Experience Fragment Web Variation and click Next.

  1. Title your experience fragment as <SEAT> – <LAST_NAME> – Fragment 1. For example, if my name was Jones and I was sitting in seat 42, I would give my fragment the title of 42 – Jones – Fragment 1. Since we are all sharing the same Target account, this will make it possible for you to find your experience fragment in the Target UI. Click the blue Create button, and then click Open in the Success dialog.

  1. If you are prompted with a tutorial for the different editing modes, select the box that is labeled Don’t show this again and click Close.

  1. In the left navigation, click on Components icon. If the side panel has been collapsed, you can click on the Toggle Side Panel icon to get the side panel into view.

  1. In the Components list that appears, locate the Hero Image component and drag it to the area in the editor that is labeled with Drag components here. If you wish, you can use the Filter field to make it easier to find.

  1. In the left navigation, click on the Assets icon.

  1. In the main content area, select the Hero Image component that we added and then click the Configure icon.

  1. Drag any asset from the Assets rail to the asset drop target.

  1. Click on the Properties tab.

  1. Select the Full width option.

  1. Click the Done icon.

  1. Click on the Page Information icon and select Export to Adobe Target.

  1. When prompted, click Publish, and then OK. AEM will activate any assets to the publish server that are used in the experience fragment to ensure that it can be properly served from Adobe Target. Note that while these assets will be served from our publish environment, any HTML markup will be served directly from Adobe Target.

You will see:

Exercise 4.4 - Create a page to test with

In this exercise, we will create and publish a page in AEM to test our Experience Fragment with. This is so that each student can test on their own page, eliminating any possible collisions that would occur if we had multiple Target activities targeting the same page.

  1. Open a new browser window for your AEM author environment http://localhost:4502 and click on the icon for Sites.

  1. In the List view, click on the title of WeRetail, then United States, English, and finally Experience. Do not click on the icon or AEM will select the page rather than showing you its children.

Your screen should look like this illustration:

  1. Click the blue Create button and then select Page.

  1. Select the Experience Page template and click Next.

  1. Give your page a title of <SEAT> <LASTNAME> Experience Page. For example, if you were sitting in seat 100 and had a last name of Reasor, your page would be named 100 Reasor Experience Page.

  1. Click the blue Create button, then click Open.

  2. Click on the Hero Image component and then click the Configure icon.

  1. Drag an asset from the Asset Finder in the left rail to the Drop an asset here… call to action. Make sure to choose an asset that is different from the one that you used in the last exercise.

  1. Click the Done checkmark icon.

  1. Click on the Page Information icon in the top navigation bar and select Publish Page.

  1. A page will open with a list of referenced assets and configurations to be published along with your page. Click Publish. When the operation has completed, you will be returned to the page editor.

  1. To test that your page has published properly, copy the URL from your web browser into a new browser tab. Remove editor.html from the URL and change the port number from 4502 to 4503. For example, if your URL were http://localhost:4502/editor.html/content/we-retail/us/en/100-reasor-experience-page.html, you would change it to http://localhost:4503/content/we-retail/us/en/100-reasor-experience-page.html

  2. If you see your page without the AEM editor, then your page has correctly activated. Leave this page open as we will need the URL for it in our next exercise.

Exercise 4.5 - Locate the Experience Fragment offer in Target

When publishing Experience Fragments to Target, there can often be a delay before the fragment appears. In this exercise, we will search for our Experience Fragment in the Target offer library. If your fragment is not yet present, we will walk through some workaround steps so that you can use a pre-created Experience Fragment to complete the exercises.

  1. Open your browser and click on the bookmark for Adobe Target.

  2. Click on the Offers link in the top navigation.

  1. In the search box, type your last name. Target will filter the list of offers shown.

  1. If you see the Experience Fragment listed that you published in the previous activity, feel free to use this fragment in the next exercise. You do not need to continue with the rest of this exercise. If you do not see your fragment listed, please continue with the remaining steps in this exercise to install a “universal” fragment that we have provided.

  2. Open a browser tab for your AEM author environment (http://localhost:4502).

  3. Click on Tools > Deployment > Packages.

  1. Locate the universal-fragment-1.0 package and click Install. Click Install again in the dialog box that opens.

  1. Navigate to the AEM home screen via your browser bookmark or by going to (http://localhost:4502).

  2. Click on Experience Fragments.

  1. Click on the name for Target Fragments and then on the name for Universal AEM Experience Fragment. Click on the icon for the Universal AEM Experience Fragment master variation within.

  1. Click the Publish icon in the action bar.

  1. In the next screen that appears, click Publish again. Note that some of the items in the screenshot below may not appear in the list on your environment.

  1. Back in the Experience Fragments console, select the Universal AEM Experience Fragment parent element and publish it as well.

  1. Verify that the fragment has been correctly activated by visiting (http://localhost:4503/content/experience-fragments/target_fragments/universal-aem-experience-fragment/master.html). If you see an image and text appear, you have successfully activated it.

Exercise 4.6 - Use the experience fragment in the Visual Experience Composer

In this exercise, we will log into Target and use the published experience fragment in a Target experience targeting activity. We will use a fairly contrived approach of targeting different content to two different browsers. While this is an easy way to show how this functionality works, in a real-world implementation, you would likely target experiences based on factors such as demographics or past user behavior – often bringing in data from Adobe Analytics or Audience Manager.

  1. Open your browser and click on the bookmark for Adobe Target. Ensure that the Activities tab is selected.

  1. Click on the blue button that is labeled + Create Activity and select Experience Targeting.

  1. In the Enter Activity URL field, enter the URL to the published page that we created in the previous exercise. If you have left the page open, you can copy the URL from the browser window. Click Next.

  1. In your browser's address bar, click on the shield icon and then click on Load Unsafe Scripts. When prompted, choose to Reload.

  1. In the top section of the page, click on Untitled Activity and give your activity a name of <SEAT> – <LAST_NAME> – Experience Activity 1. This will allow you to differentiate your activity from those of other students. For example, for a student named Reasor who is sitting in seat 100, they would name their activity 100 – Reasor – Experience Activity 1.

  1. In the Audiences rail, click + Add Experience Targeting.

  1. In the Audience Library, locate and select the audience called Firefox Browser. Click Done.

  1. Select the image in the content area of the VEC, then click Expand Selection. Your first selection will be the entire area – when you "expand" the selection, it will look smaller. The screenshots below show what your selection areas should look like:

initial selection

expanded selection

  1. Click Replace With and then select Experience Fragment.

  1. In the window that opens, locate the experience fragment that we identified for use in the previous exercise. If your fragment was successfully activated, you can locate it by searching for your name. If you had to activate the “universal” experience fragment, try searching for universal. Click on it and then click Done.

  1. Click the blue Next button twice.

  1. In the Activity Settings screen, scroll down to the MY PRIMARY GOAL section and select a success metric of Conversion > Viewed an mbox > ** any mbox **. In a real-world scenario, you would select a metric to help you determine how effective each experience is but tracking and measuring activity success is beyond the scope of this lab.

  1. Click the blue Save & Close button.

  1. Once the activity finishes syncing, click on the Inactive button and choose to Activate the activity.

  1. Once the activity has finished activating, this indicator will change to Live.

Exercise 4.7 - Verify Target activity

In this section, we will verify that the Target activity we created is working properly on our site.

  1. Navigate to the page that we targeted in the previous exercise with Google Chrome. If you still have the window open, you can just refresh the page. Note that the page looks the same.

  2. Open up Firefox and copy/paste the URL for your test page into it.

  3. Note that the version of your page with the experience fragment is shown.

Appendix

The following exercises were all performed in advance of Summit to prepare our lab environments. If you would like to go through this workbook at home, you will need to go through these steps to prepare your own environment.

Exercise 1: Install Launch Extensions

In this exercise, we will create a property in Launch that is specific to our local AEM environments, install extensions for Target, Analytics, and Context Hub, and then configure all three extensions.

Create a new property in Launch

Launch allows us to have multiple properties per account. This allows customers to have separate properties for each of their websites. For the exercises in this lab, you will need to have a property created in Launch. Feel free to use these instructions to create a new Launch property to go through these exercises with or use them with an existing property if you'd like to use this workbook with your existing site.

  1. Log on to your Experience Cloud account.

  2. Once logged in, click on the solution switcher and select Activation. You can also access this page directly by pointing your browser to https://activation.adobe.com/

  1. On the screen that loads, click Go To Launch. You can also access this page directly at https://launch.adobe.com/.

  1. In Launch, add a new property. If you have existing properties, you can do this by clicking on the New Property button as seen below. Otherwise, you will have a button labeled Add New Property.

  1. Enter a property name that refers to the site that you will be using. Set the Domains property to your site's domain name(s). Click Save.

Install the Analytics extension

Launch provides us with a catalog of extensions that are developed by Adobe and third-party providers. The catalog can be thought of as an app store for tag management. Here, we are installing the Analytics extension and configuring it with some basic properties.

  1. Click on the link for your property to open it.

  1. Click on the Extensions link in the navigation bar and then click on the Catalog icon.

  1. Find the card for Adobe Analytics and click the Install button.

  1. In the Install Extension window, populate the report suite names for your development, staging, and production report suites.

  1. Click Save.

Install the Target extension

  1. Click Catalog to switch back to the catalog view, locate the Adobe Target card and click Install.

  1. In the screen that appears, leave the default settings and click Save.

Install the ContextHub extension

In this section, we will install the ContextHub extension, which is useful for surfacing data layers in Launch. Note that while we have the option to use AEM's default ContextHub data layer, we can also use this extension to map a custom data layer. Thus, this extension can be used for any implementation, even those that don't leverage AEM.

  1. Back in Catalog view, find the card for Adobe ContextHub and click Install.

  1. For this lab, leave the default settings selected and click Save. In a real-world deployment, if you have implemented a custom data layer in AEM, you should select Customized ContextHub Data layer and map it to your actual data layer.

Validation

You should now see four cards showing in the Installed view: Adobe Analytics, Adobe ContextHub, Adobe Target, and Core.

Exercise 2: Configure Launch Data Elements and Rules

In this exercise, we will configure some data elements and rules to map our data layer into Launch and load our Analytics and Target libraries. If you are using an existing Launch property, many of these configurations will already be in place. It is fine to use these existing configurations, but keep in mind when going through the lab exercises that there may be some variation from our steps due to this difference.

Map the page name to a data element

In this step, we will be mapping the page path from our data layer to a pagename data element. This will allow us to use the pagename value wherever we like in Launch. As we use the ContextHub extension in this step, note how the Data item field contains all of the values that are exposed in the AEM Context Hub. Had we mapped this extension to a custom data layer, those values would appear here instead.

  1. While in Launch, click the Data Elements item in the main navigation bar.

  1. Click the button to Create New Data Element.

  1. In the Create New Data Element screen, enter the following values:

a. Name: pagename

b. Extension: Adobe ContextHub

c. Data Element Type: Context Hub

d. Data item: pagedata.path

  1. Click Save.

Add a rule to load Target

While installing the Target extension made Target capabilities available to us in Launch, it doesn't automatically load Target on our site. To do that, we need a rule. In a real customer implementation, it is likely that this rule would also contain some parameter mapping into the global mBox as well. We will load the Target library at Page Top, which along with body hiding, will allow us to avoid flicker on the page. When configuring the Fire Global Mbox action, note the Body Hiding properties that can be used to hide the body until Target has loaded and determined which experiences to show.

  1. Click Rules in the main navigation bar.

  1. Click the Create New Rule button.

  1. Give your rule a name of Page Top.

  1. Under Events, click Add.

  1. In the Event Configuration screen, set the Event Type to Library Loaded (Page Top). Leave the other settings to their default values and click Keep Changes.

  1. Under Actions, click on Add.

  1. Under Extension, select 'Adobe Target'. Under Action Type, select 'Load Target'. You can leave the Name as the default. Click Keep Changes.

  1. Click the + icon to the right of the new action we created to add another action to our Then section.

  1. In the Action Configuration screen, set the Extension to Adobe Target and set the Action Type to Fire Global Mbox. Click Keep Changes.

  1. Click Save to save your rule.

Add a rule to load Analytics

As in the previous section, we will add a rule to load the Analytics library and fire our page load event. It is common to load Analytics at the page bottom, as this allows our page to fully load and our data layer to be fully populated, but we do run the risk of missing some impressions if a user navigates away before the page is fully loaded. For this reason, some customers choose to load their Analytics library at page top as well.

While configuring this rule, we will map our pagename data element to the Analytics page name property. We are mapping this property to illustrate the best practice of mapping a value from a data layer on the page to a Launch data element to the Analytics property. In a real customer implementation, there will be a large number of props and eVars that will be mapped here. They should all follow this practice.

  1. In the Launch Rules tab, click Add Rule.

  1. Give your rule a name of Page Bottom.

  1. Under Events, click Add.

  1. For Event Type, select Page Bottom. Leave all of the other settings at their default values.

  1. Click Keep Changes.

  1. Under Actions, click Add.

  1. Under Extension, choose 'Adobe Analytics'. Under Action Type, select 'Set Variables'.

  1. In the section to the right, scroll down to the Page Name field and click the data icon to the right of the field.

  1. Select the pagename data element that we previously set and choose Select.

  1. Click Keep Changes.

  1. Click the + icon to the right of new action we created, to add another action to our Then section.

  1. Under Extension, choose Adobe Analytics. Under Action Type, choose Send Beacon. Leave all other values as their defaults. This Action will capture and send the data to Analytics for tracking. Click Keep Changes.

  1. Click Save to save your rule.

  1. You should now have two rules in the list of rules – Page Top and Page Bottom.

Publish the Launch library

In this section, we will create our environments in Launch and publish our configurations. In DTM, each environment had only two environments: Stage and Production. In Launch, we also get access to unlimited development environments. We will be pushing our code through each of these environments for expediency, but in a real customer environment, and if you are using an existing Launch property, you should fully test your changes in a development and staging environment before deploying any changes to production.

  1. Open the Launch Environments tab and verify that there are three environments listed: Development, Staging, and Production.

  1. Click on the Publishing tab.

  1. Under the Development column, click the Add New Library button.

  1. Give your library a name of Initial rollout and set your Environment to Development.

  1. Under Library Contents, click on Add All Changed Resources.

  1. You should see all of the changes that we have made appear in the New Resources section: both rules we created, our data element, and all four extensions that we installed (including the Core extension).

  1. Click on the button labeled Save & Build for Development.

  1. After the library has finished building, its icon will turn from a progress indicator to a green circle. In a real-world environment, this is the point at which you would test your changes in your development environment through the use of a tool like Launch Command. Click on the down arrow on the library card and select Submit for Approval. Click Submit in the confirmation modal.

  1. Under the Submitted column, click on your card's down arrow again and select Build for Staging.

  1. Again, in a real-world environment, you would now verify your changes in a staging environment. Once the library finishes building, click on the down arrow and select Approve for Publishing. In the confirmation dialog, click Approve.

  1. Under the Approved column, click on your card's down arrow and select Build and Publish to Production. In the confirmation modal, click on Publish.

  1. Once done, you should see the 'initial rollout' under Published environment with green circle

Exercise 3: Install AEM

To go through this lab, you will need two AEM environments: an author environment and a publish environment. These instructions assume that you have access to an AEM 6.5 JAR file and a developer license.properties file, but the steps to install AEM may differ slightly based on how your AEM environments have been licensed. For information on downloading an AEM JAR file, please contact your Adobe Account Executive or Customer Success Manager.

  1. Create a folder to install your AEM instances in. This can be done anywhere on your computer that you would like. Create two subfolders and name them author and publish.

  2. Place your AEM JAR file in the author folder alongside your license.properties file. Place the same JAR and license.properties file in the publish folder, but rename the JAR file to cq-publish-p4503.jar.

  1. Double-click each JAR file. You will see a crx-quickstart folder created next to each JAR file and windows will appear for your two AEM instances. Once the progress bar in each AEM window reaches the end, a browser window will open for each respective environment.

Exercise 4: Create an IMS Configuration in AEM

AEM integrates with Launch through Adobe I/O. In this exercise, we will use AEM's IMS configurations to configure a certificate that we will be able to use in Adobe I/O for this integration. This certificate will allow Adobe I/O to authenticate the identity of our AEM instance.

  1. Log onto your AEM author environment. The default credentials are admin/admin.
  2. Click on the Tools icon on the left, followed by the Security menu, followed by the Adobe IMS Configurations card.

  1. Click the blue Create button.

  1. Select Adobe Launch as the Cloud Solution and check the box for Create new certificate. Give your certificate a name of local-aem. Click the blue Create certificate button. Click OK when prompted.

  1. Click the Download Public Key link and click Download when prompted.

  1. Locate the downloaded file in your computer's Downloads folder; we will be using it in the next exercise. Leave this browser window open as we go through the next exercise as we will need to revisit this screen soon.

Exercise 5: Create an Adobe I/O Integration

In this exercise, we will create a Launch integration in Adobe I/O.

  1. Log in to Adobe I/O by pointing a web browser to https://console.adobe.io.
  2. From the Integrations tab, click the New Integration button.

  1. Choose to Access an API and click Continue.

  1. From under Adobe Experience Platform, select Experience Platform Launch API and click Continue.

  1. When prompted, choose to create a New integration and click Continue.

  1. In the Create a new integration screen, enter the following values: a. Name: Any name that reflects that this is an integration into Launch.

b. Description: Integration to Launch

c. Permissions: Admin

d. Public keys certificates: The certificate that you downloaded from the IMS configuration that we created in AEM.

  1. Click the blue Create Integration button.

Exercise 6: Add Adobe I/O details to AEM

In this section, we will populate AEM with details of the Adobe I/O configuration that we just created. This will tell AEM how to access and authenticate Adobe I/O. In the screenshots below, we have had to obfuscate many of the values for security reasons.

  1. Return to the AEM browser window where we created our certificate and click the Next button.

  1. Populate the fields on this screen with the corresponding information from Adobe I/O: a. Title: Adobe I/O – Launch Integration

b. Authorization Server: Click the JWT tab in Adobe I/O and copy the server hostname and protocol from the aud property in the JWT payload. We basically want to copy everything after the opening quote mark and before the third slash. In the screenshot below, the authorization server is https://ims-na1.adobelogin.com. See the highlighted string of text below for an illustration of the text that you should copy.

c. API Key: Listed as the API Key (Client ID) in the Overview tab in Adobe I/O.

d. Client secret: Click the Retrieve client secret button in the Overview tab in Adobe I/O.

e. Payload: Copy the JWT payload from the JWT tab in Adobe I/O.

  1. After populating all values, your configuration should look something like this:

  1. Click the blue Create button.

You have now successfully completed the pre-requisites for this lab. In doing so, you have learned how to configure Launch for an Experience Cloud deployment, how to install an AEM environment, and how to integrate AEM with Launch through the Adobe I/O console.