# 8.4 Create your journey and messages

In this exercise, you'll create a journey and several text messages by making use of Adobe Journey Optimizer.

For this use case, the goal is to send different SMS messages based on the weather conditions of the location of your customer. 3 scenarios have been defined:

* Colder than 10° Celsius
* Between 10° and 25° Celsius
* Warmer than 25° Celsius

For these 3 conditions, you'll need to define 3 SMS messages in Adobe Journey Optimizer.

## 8.4.1 Create your journey

Login to Adobe Journey Optimizer by going to [Adobe Experience Cloud](https://experience.adobe.com). Click **Journey Optimizer**.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-8daf9419deef804f9e816efc694a6fe4c6bef3fa%2Facophome.png?alt=media)

You'll be redirected to the **Home** view in Journey Optimizer. First, make sure you're using the correct sandbox. The sandbox to use is called `--aepSandboxId--`. To change from one sandbox to another, click on **PRODUCTION Prod (VA7)** and select the sandbox from the list. In this example, the sandbox is named **AEP Enablement FY22**. You'll then be in the **Home** view of your sandbox `--aepSandboxId--`.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-df76386e3eebdceeccee0f3853f02cdec4b997f1%2Facoptriglp.png?alt=media)

In the left menu, go to **Journeys** and click **Create Journey** to start creating your Journey.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-e24eafbf8ab0c412f6cb270bd5f0be5b3770f8ef%2Fjocreate.png?alt=media)

You should first name your journey.

As a Name for the journey, use `--demoProfileLdap-- - Geofence Entry Journey`. In this example, the journey name is `vangeluw - Geofence Entry Journey`. No other values must be set at this moment. Click **OK**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-e235fcbdf005e8525f9996da15428e4aa14aa7d9%2Fjoname.png?alt=media)

On the left side of your screen, have a look at **Events**. You should see your previously created event in that list. Select it, then drag and drop it on the journey canvas. Your journey then looks like this. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-8f45980600e233e77c1bb5d5ecc9157c954d6275%2Fjoevents.png?alt=media)

Next, click on **Orchestration**. You now see the available **Orchestration** capabilities. Select **Condition**, then drag and drop it on the Journey Canvas.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-5a31aabc0e6740e6d112706662b9a1edfa8bbfd5%2Fjo2.png?alt=media)

You now have to define three conditions:

* It's colder than 10° Celsius
* It's between 10° and 25° Celsius
* It's warmer than 25° Celsius

Let's define the first condition.

### Condition 1: Colder than 10° Celsius

Click on the **Condition**. Click on **Path1** and edit the name of the path to **Colder than 10 C**. Click on the **Edit** icon for the expression of Path1.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-dec2222b6ecf8f2d56d987c091a189400478f660%2Fjo5.png?alt=media)

You'll then see an empty **Simple Editor** screen. Your query will be a bit more advanced, so you'll need the **Advanced Mode**. Click **Advanced Mode**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0e18daf42af526e862a40bc6f656be852d004bc3%2Fjo7.png?alt=media)

You'll then see the **Advanced Editor** which allows code entry.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-1f1f26662887ef76fbbc232dfaa06b08eae2ab3f%2Fjo9.png?alt=media)

Select the below code and paste it in the **Advanced Editor**.

`#{--demoProfileLdap--WeatherApi.--demoProfileLdap--WeatherByCity.main.temp} <= 10`

You'll then see this.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-60c072b091023013fdae05209c4eee39d42a0de0%2Fjo10.png?alt=media)

In order to retrieve the temperature as part of this condition, you need to provide the city in which the customer currently is. The **City** needs to be linked to the dynamic parameter `q`, just like we saw previously in the Open Weather API Documentation.

Click the field **dynamic val: q** as indicated in the screenshot.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-c7d7802c596b7675dda20b9557b41e3421d56880%2Fjo11.png?alt=media)

You then need to find the field that contains the current city of the customer in one of the available Data Sources.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-d2cee81afbf4204ab6991c8b6e4ed2bd37f1016a%2Fjo12.png?alt=media)

You can find the field by navigating to `--demoProfileLdap--GeofenceEntry.placeContext.geo.city`.

By clicking that field, it will be added as the dynamic value for the parameter `q`. This field will be populated by for instance the geolocation-service that you've implemented in your mobile app. In our case we will simulate this with the admin console of the demo website. Click **OK**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-b5b5611780c105ba208cc9121fcdf561217fd675%2Fjo13.png?alt=media)

### Condition 2: Between 10° and 25° Celsius

After having added the first condition, you'll see this screen. Click **Add Path**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-c5d88a5d0c48c79a28e917558b1e231c6060e7e6%2Fjoc2.png?alt=media)

Double click on **Path1** and edit the path name to **Between 10 and 25 C**. Click the **Edit** icon for the expression this path.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-831289dedca0435f8c44110ec9f2572b169faa3e%2Fjoc6.png?alt=media)

You'll then see an empty **Simple Editor** screen. Your query will be a bit more advanced, so you'll need the **Advanced Mode**. Click **Advanced Mode**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0e18daf42af526e862a40bc6f656be852d004bc3%2Fjo7.png?alt=media)

You'll then see the **Advanced Editor** which allows code entry.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-1f1f26662887ef76fbbc232dfaa06b08eae2ab3f%2Fjo9.png?alt=media)

Select the below code and paste it in the **Advanced Editor**.

`#{--demoProfileLdap--WeatherApi.--demoProfileLdap--WeatherByCity.main.temp} > 10 and #{--demoProfileLdap--WeatherApi.--demoProfileLdap--WeatherByCity.main.temp} <= 25`

You'll then see this.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-719efb653b15b7988f7a6c1252f8c38a473f242b%2Fjoc10.png?alt=media)

In order to retrieve the temperature as part of this Condition, you need to provide the city in which the customer currently is. The **City** needs to be linked to the dynamic parameter **q**, just like we saw previously in the Open Weather API Documentation.

Click the field **dynamic val: q** as indicated in the screenshot.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-e87d91d62519e96f1e5e552d1377e84304013f77%2Fjoc11.png?alt=media)

You then need to find the field that contains the current city of the customer in one of the available Data Sources.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-d2cee81afbf4204ab6991c8b6e4ed2bd37f1016a%2Fjo12.png?alt=media)

You can find the field by navigating to `--demoProfileLdap--GeofenceEntry.placeContext.geo.city`. By clicking that field, it will be added as the dynamic value for the parameter **q**. This field will be populated by for instance the geolocation-service that you've implemented in your mobile app. In our case we will simulate this with the admin console of the demo website. Click **OK**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-b5b5611780c105ba208cc9121fcdf561217fd675%2Fjo13.png?alt=media)

Next, you'll add the 3rd condition.

### Condition 3: Warmer than 25° Celsius

After having added the second condition, you'll see this screen. Click **Add Path**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-9500201d793ae43eccd0ac31f80c45fd5cb82424%2Fjoct2.png?alt=media)

Double click on Path1 to change the name to **Warmer than 25 C**. Then click on the **Edit** icon for the expression this path.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0e1a782a288fbeb0361266335037050ef2527f7e%2Fjoct6.png?alt=media)

You'll then see an empty **Simple Editor** screen. Your query will be a bit more advanced, so you'll need the **Advanced Mode**. Click **Advanced Mode**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0e18daf42af526e862a40bc6f656be852d004bc3%2Fjo7.png?alt=media)

You'll then see the **Advanced Editor** which allows code entry.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-1f1f26662887ef76fbbc232dfaa06b08eae2ab3f%2Fjo9.png?alt=media)

Select the below code and paste it in the **Advanced Editor**.

`#{--demoProfileLdap--WeatherApi.--demoProfileLdap--WeatherByCity.main.temp} > 25`

You'll then see this.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-f01ebca4705b23a97938e432500b47d91cd186c2%2Fjoct10.png?alt=media)

In order to retrieve the temperature as part of this Condition, you need to provide the city in which the customer currently is. The **City** needs to be linked to the dynamic parameter **q**, just like we saw previously in the Open Weather API Documentation.

Click the field **dynamic val: q** as indicated in the screenshot.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-a6607ebde60c0e1b607d6112317e94b4b2aca0f9%2Fjoct11.png?alt=media)

You then need to find the field that contains the current city of the customer in one of the available Data Sources.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-d2cee81afbf4204ab6991c8b6e4ed2bd37f1016a%2Fjo12.png?alt=media)

You can find the field by navigating to `--demoProfileLdap--GeofenceEntry.placeContext.geo.city`. By clicking that field, it will be added as the dynamic value for the parameter **q**. This field will be populated by for instance the geolocation-service that you've implemented in your mobile app. In our case we will simulate this with the admin console of the demo website. Click **OK**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-b5b5611780c105ba208cc9121fcdf561217fd675%2Fjo13.png?alt=media)

You now have three configured paths. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-48475ecabc14b635c84a1ea66201ace4ac7c4652%2Fjo3path.png?alt=media)

As this is a journey for learning purpose, we'll now configure a couple of actions to showcase the variety of options marketeers now have to deliver messages.

## 8.4.2 Send messages for path: Colder than 10° Celsius

For each of the temperature contexts, we'll attempt to send a text message to our customer. We can only send a text message if we have a Mobile Number available for a customer, so we'll first have to verify that we do.

Let's focus on **Colder than 10 C**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-9e9163d3c45dcf3e24ef4e146d35e1ba35249166%2Fp1steps.png?alt=media)

Let's take another **Condition** element and drag it as indicated in the screenshot below. We'll verify if for this customer, we have a mobile number available.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-cef57200432878e001f6d1221a7dc96528e58928%2Fjoa1.png?alt=media)

As this is just an example, we are only configuring the option where the customer has a mobile number available. Add a label of **Has mobile?**.

Click on the **Edit** icon for the Expression for the **Path1** path.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-083e39e43e377142d3fea748167b878b6320455b%2Fjoa2.png?alt=media)

In the Data Sources shown on the left, navigate to **ExperiencePlatform.ProfileFieldGroup.profile.mobilePhone.number**. You're now reading the mobile phone number directly from Adobe Experience Platform's Real-time Customer Profile.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-5ee394cc0a6331da32d615bf3a98cbd3d169c1dc%2Fjoa3.png?alt=media)

Select the field **Number**, then drag and drop it to the Condition Canvas.

Select the operator **is not empty**. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0a78d5abeaceb85c624e7f550c72ae4becc20265%2Fjoa4.png?alt=media)

You'll then see this. Click **OK** again.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-bd14c8901d2ab15ba1bd341e8c26f4761e20319c%2Fjoa6.png?alt=media)

Your journey will then look like this. Click on **Actions** as indicated in the screenshot.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-beb0efdc05a938f173dcdc18cb4bab1d1b3d7867%2Fjoa8.png?alt=media)

Select the action **SMS**, then drag and drop it after the condition you just added.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-669ad996fe7c28325befe28d5ad7366a92b13887%2Fjoa9.png?alt=media)

Set the **Category** to **Marketing** and select an SMS surface that enables you to send SMS. In this case, the email surface to select is **SMS**.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-38e12e9e202a862b62aa9c4c373336af3a42c8c3%2Fjourneyactions1.png?alt=media)

The next step is to create your message. To do that, click **Edit content**.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-256c1fffe31337d155b16a241217f512eb57320c%2Fjourneyactions2.png?alt=media)

You now see the message dashboard, where you can configure the text of your SMS. Click the **Compose message** area to create your message.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-38fc5b8a1d63902e411d0e07a382211230627798%2Fsms3.png?alt=media)

Enter the following text: `Brrrr... {{profile.person.name.firstName}}, it's freezing. 20% discount on jackets today!`. Click **Save**.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-f6040b812ad7689eef1f360c967e777cbceec2c3%2Fsms4.png?alt=media)

You'll then see this. Click the arrow in the top left corner to go back to your journey.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-674b86a828833081bf9def3a874d44c2c1f9d8e4%2Fsms4a.png?alt=media)

You'll then be back here. Click **Ok**.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0fdffc632d774b863b514133ec9e8574e089ecca%2Fsms4b.png?alt=media)

In the left menu, go back to **Actions**, select the Action `--demoProfileLdap--TextSlack`, then drag and drop it after the **Message** action.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-3e2375132bbf6d4a21fa394fec4e79e832387a86%2Fjoa18.png?alt=media)

Go to **Action Parameters** and click the **Edit** icon for the parameter `TEXTTOSLACK`.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-8bdcd592dfa1c1c663fe53cb60bc4e3e1bb602ef%2Fjoa19.png?alt=media)

In the popup-window, click **Advanced Mode**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-31a4db1a289f2de899dd6e32c3adbf10187fe5ff%2Fjoa20.png?alt=media)

Select the below code, copy it and paste it in the **Advanced Mode Editor**. Click **Ok**.

`"Brrrr..." + #{ExperiencePlatform.ProfileFieldGroup.profile.person.name.firstName} + " It's freezing. 20% discount on Jackets today!"`

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0ed8446150d87929ace6c97b7b6406ef2bbdbe76%2Fjoa21.png?alt=media)

You will see your completed action. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-9f6a956cf3c959f73f2bd5a1e93ae40b6986efbf%2Fjoa22.png?alt=media)

This path of the journey is now ready.

## 8.4.3 Send messages for path: Between 10° and 25° Celsius

For each of the temperature contexts, we'll attempt to send a text message to our customer. We can only send a text message if we have a Mobile Number available for a customer, so we'll first have to verify that we do.

Let's focus on **Between 10 and 25 C** path.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-c1789e4c54e67782aadddc14874dc62f9cfbfd7c%2Fp2steps.png?alt=media)

Let's take another **Condition** element and drag it as indicated in the screenshot below. We'll verify if for this customer, we have a mobile number available.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-7d3a595ae9cadf8588b679bb628b35b5e7833843%2Fjop1.png?alt=media)

As this is just an example, we are only configuring the option where the customer has a mobile number available. Add a label of **Has mobile?**.

Click on the **Edit** icon for the Expression for the **Path1** path.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-45b34fb7a3cd7af60a302c1c32afbd3231f5f75d%2Fjoa2p2.png?alt=media)

In the Data Sources shown on the left, navigate to **ExperiencePlatform.ProfileFieldGroup.profile.mobilePhone.number**. You're now reading the mobile phone number directly from Adobe Experience Platform's Real-time Customer Profile.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-5ee394cc0a6331da32d615bf3a98cbd3d169c1dc%2Fjoa3.png?alt=media)

Select the field **Number**, then drag and drop it to the Condition Canvas.

Select the operator **is not empty**. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0a78d5abeaceb85c624e7f550c72ae4becc20265%2Fjoa4.png?alt=media)

You'll then see this. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-bd14c8901d2ab15ba1bd341e8c26f4761e20319c%2Fjoa6.png?alt=media)

Your journey will then look like this. Click on **Actions** as indicated in the screenshot.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-127b8f2aa2c3782399c4c0495d261c9aa6afa995%2Fjop8.png?alt=media)

Select the action **SMS**, then drag and drop it after the condition you just added.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-666f057e6d58db405f71c241717c1c58c72253b1%2Fjop9.png?alt=media)

Set the **Category** to **Marketing** and select an SMS surface that enables you to send SMS. In this case, the email surface to select is **SMS**.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-af8cb5092dd1bd69a224e1a8ad885889b8ea4cba%2Fjourneyactions1z.png?alt=media)

The next step is to create your message. To do that, click **Edit content**.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-1491e2b5f080fe76ff5acd4fcef8bef96fc2a062%2Fjourneyactions2z.png?alt=media)

You now see the message dashboard, where you can configure the text of your SMS. Click the **Compose message** area to create your message.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-a723441c0a9fef49947110e22d7049c98c1b2efe%2Fsms3a.png?alt=media)

Enter the following text: `What a nice weather for the time of year, {{profile.person.name.firstName}} - 20% discount on Sweaters today!`. Click **Save**.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-aad6114678b91d1db99ad454b6cdd4963e4cef28%2Fsms4az.png?alt=media)

You'll then see this. Click the arrow in the top left corner to go back to your journey.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-149e6c35704bc2778a77c668818a7f219e9a1511%2Fsms4azz.png?alt=media)

You'll now see your completed action. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-ebf48b5cc1a2cfc657019a0bfaa3286a0bdfbdb4%2Fjop17.png?alt=media)

In the left menu, go back to **Actions**, select the Action `--demoProfileLdap--TextSlack`, then drag and drop it after the **Message** action.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-61931f588b807cb3e59669c1574bd72c39df005b%2Fjop18.png?alt=media)

Go to **Action Parameters** and click the **Edit** icon for the parameter `TEXTTOSLACK`.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-21ca17fc36fc780443456c5596b083e142ea0381%2Fjoa19z.png?alt=media)

In the popup-window, click **Advanced Mode**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-31a4db1a289f2de899dd6e32c3adbf10187fe5ff%2Fjoa20.png?alt=media)

Select the below code, copy it and paste it in the **Advanced Mode Editor**. Click **Ok**.

`"What nice weather for the time of year, " + #{ExperiencePlatform.ProfileFieldGroup.profile.person.name.firstName} + " 20% discount on Sweaters today!"`

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-6fe490320f13b73341d75e2c4d8b8b588f17c5a5%2Fjop21.png?alt=media)

You will see your completed action. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-04a39a8a77d95661d7cfc2aed71c3c44c5b5d392%2Fjop22.png?alt=media)

This path of the journey is now ready.

## 8.4.4 Send messages for path: Warmer than 25° Celsius

For each of the temperature contexts, we'll attempt to send a text message to our customer. We can only send a text message if we have a Mobile Number available for a customer, so we'll first have to verify that we do.

Let's focus on **Warmer than 25 C** path.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-5cd117f38d500b8ed137244b96f5ab6887088212%2Fp3steps.png?alt=media)

Let's take another **Condition** element and drag it as indicated in the screenshot below. You'll verify if for this customer, you have a mobile number available.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-fc609c56d7b54e88c788dd9409577f197981f5da%2Fjod1.png?alt=media)

As this is just an example, we are only configuring the option where the customer has a mobile number available. Add a label of **Has mobile?**.

Click on the **Edit** icon for the Expression for the **Path1** path.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-86e3e3386209bcdae9e40ef61865dfd77ebb3170%2Fjoa2p3.png?alt=media)

In the Data Sources shown on the left, navigate to **ExperiencePlatform.ProfileFieldGroup.profile.mobilePhone.number**. You're now reading the mobile phone number directly from Adobe Experience Platform's Real-time Customer Profile.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-5ee394cc0a6331da32d615bf3a98cbd3d169c1dc%2Fjoa3.png?alt=media)

Select the field **Number**, then drag and drop it to the Condition Canvas.

Select the operator **is not empty**. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-0a78d5abeaceb85c624e7f550c72ae4becc20265%2Fjoa4.png?alt=media)

You'll then see this. Click **OK**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-bd14c8901d2ab15ba1bd341e8c26f4761e20319c%2Fjoa6.png?alt=media)

Your journey will then look like this. Click on **Actions** as indicated in the screenshot.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-905f12bcb8859d44efd18c2a23367519c55bae3f%2Fjod8.png?alt=media)

Select the action **SMS**, then drag and drop it after the condition you just added.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-7d415c3a49162fdb618ff2b01e581f1921f4ca95%2Fjod9.png?alt=media)

Set the **Category** to **Marketing** and select an SMS surface that enables you to send SMS. In this case, the email surface to select is **SMS**.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-08e052682ba73b56848fc790c79135c83f58127c%2Fjourneyactions1zy.png?alt=media)

The next step is to create your message. To do that, click **Edit content**.

![ACOP](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-6feded1c62e2f380bf667dc94e0c6c0fc57d2362%2Fjourneyactions2zy.png?alt=media)

You now see the message dashboard, where you can configure the text of your SMS. Click the **Compose message** area to create your message.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-da0fd8b3d5e47f3013c1075bccf9cff2dbcb295b%2Fsms3ab.png?alt=media)

Enter the following text: `So warm, {{profile.person.name.firstName}}! 20% discount on swimwear today!`. Click **Save**.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-ce49c4c077963bd403b3b1db05368435bfb176a0%2Fsms4ab.png?alt=media)

You'll then see this. Click the arrow in the top left corner to go back to your journey.

![Journey Optimizer](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-f89d291680cad498d229e05e1884c4120f8316fc%2Fsms4azzz.png?alt=media)

You'll now see your completed action. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-36b794b2b5507a3a0c64d79556ee6b5cfacbba5a%2Fjod17.png?alt=media)

In the left menu, go back to **Actions**, select the Action `--demoProfileLdap--TextSlack`, then drag and drop it after the **Messages** action.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-8a1cde9695616a1f127253eab5f811a443f6a4ac%2Fjod18.png?alt=media)

Go to **Action Parameters** and click the **Edit** icon for the parameter `TEXTTOSLACK`.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-500f855b786725b481afd7dea459170a36f3c6d5%2Fjoa19zzz.png?alt=media)

In the popup-window, click **Advanced Mode**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-31a4db1a289f2de899dd6e32c3adbf10187fe5ff%2Fjoa20.png?alt=media)

Select the below code, copy it and paste it in the **Advanced Mode Editor**. Click **Ok**.

`"So warm, " + #{ExperiencePlatform.ProfileFieldGroup.profile.person.name.firstName} + "! 20% discount on swimwear today!"`

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-c8039673501b35ca37989910510a47f6f611dd59%2Fjod21.png?alt=media)

You will see your completed action. Click **Ok**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-8ba07a2e9e1bea07545117e652676fbb14eaecb6%2Fjod22.png?alt=media)

This path of the journey is now ready.

## 8.4.5 Publish your journey

Your journey is now fully configured. Click **Publish**.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-421965275c33a54cc59c64285aacd47885a48b26%2Fjodone.png?alt=media)

Click **Publish** again.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-9cdace13ca2782913dc40c59f191d878fd9bd0b6%2Fjopublish1.png?alt=media)

Your journey is now published.

![Demo](https://858372621-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpBC8bA57il8Sj47B7QPJ%2Fuploads%2Fgit-blob-ed53c05943f1206ee5b3bc8b8314c6cd62a6739b%2Fjopublish2.png?alt=media)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.adobesandbox.com/comprehensive-technical-tutorial-archive/module8/ex4.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
