You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/engage/journeys/journey-context.md
+11-20Lines changed: 11 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,7 @@ Unlike traditional audience-based journeys, which rely solely on user progress t
17
17
18
18
With journey context, you can:
19
19
20
-
// - Split journeys based on event attributes or outcomes.
20
+
<!-- Split journeys based on event attributes or outcomes.-->
21
21
- Personalize customer experiences using real-time event data.
22
22
- Enable advanced use cases like abandonment recovery, dynamic delays, and more.
23
23
@@ -31,7 +31,6 @@ For example:
31
31
Journey context is a flexible data structure that captures key details about the events and conditions that shape a customer’s journey. Journey context provides a point-in-time snapshot of event properties, making accurate and reliable data available throughout the journey.
32
32
33
33
Journey context stores event property information tied to specific user actions, like `Appointment ID` or `Order ID`.
34
-
// - **Split evaluations**: Results of branch decisions made during the journey, enabling future steps to reference these outcomes.
35
34
36
35
Journey context doesn't store:
37
36
-**Profile traits**, which may change over time.
@@ -57,7 +56,7 @@ Event properties are the foundation of Journey context. Examples of event proper
57
56
58
57
Segment captures each event’s properties as a point-in-time snapshot when the event occurs, ensuring that the data remains consistent for use in personalization.
59
58
60
-
// branching, and other advanced workflow steps.
59
+
<!-- branching, and other advanced workflow steps.-->
61
60
62
61
## Using Journey context in Event-Triggered Journeys
63
62
@@ -67,7 +66,7 @@ This is useful for scenarios like:
67
66
68
67
-**Abandonment recovery:** Checking whether a user completed a follow-up action, like a purchase.
69
68
-**Customizing messages:** Using event properties to include relevant details in communications.
70
-
// - **Scheduling workflows:** Triggering actions based on contextual data, like the time of a scheduled appointment.
69
+
<!-- - **Scheduling workflows:** Triggering actions based on contextual data, like the time of a scheduled appointment.-->
71
70
72
71
By incorporating event-specific data at each step, journey context helps workflows remain relevant and adaptable to user actions.
73
72
@@ -81,11 +80,11 @@ This step checks whether a user performs a specific event within a given time wi
81
80
82
81
For example, a journey may wait to see if a `checkout_completed` event occurs within two hours of a user starting checkout. If the event happens, its properties are added to context and the workflow can proceed; otherwise, it may take an alternate path. The data captured includes event properties (like `Order ID`).
83
82
84
-
// and the results of the split evaluation.
83
+
<!--// and the results of the split evaluation.-->
85
84
86
85
If a Hold Until branch is set to send profiles back to the beginning of the step when the event is performed, those events are also captured in context. Because they may or may not be performed during a journey, they will show as available in future steps but will not be guaranteed for every user's progression through the journey.
87
86
88
-
// #### Context split
87
+
<!--// #### Context split
89
88
90
89
// This step evaluates conditions using data already stored in journey context. Based on the conditions, users are routed to different branches of the journey.
91
90
@@ -107,7 +106,7 @@ If a Hold Until branch is set to send profiles back to the beginning of the step
107
106
108
107
// Function steps process data from journey context through custom logic. The output of the function gets written back to context for use in later steps.
109
108
110
-
// For example, a function might calculate a discount percentage based on an event property, then store that value in journey context for later use. The output gets scoped to a dedicated object (`function_output`) to keep the context structured and reliable.
109
+
// For example, a function might calculate a discount percentage based on an event property, then store that value in journey context for later use. The output gets scoped to a dedicated object (`function_output`) to keep the context structured and reliable.-->
111
110
112
111
#### Send to destination
113
112
@@ -120,7 +119,8 @@ For example, a payload sent to a messaging platform might include `Order ID` and
120
119
The structure of journey context organizes event-specific data gets and makes it accessible throughout the journey workflow. By standardizing how data is stored, Segment makes it easier to reference, use, and send this information at different stages of a journey.
121
120
122
121
Journey context is organized as a collection of key-value pairs, where each key represents a data point or category, and its value holds the associated data.
123
-
// This structure supports various types of information, like event properties, split outcomes, and function outputs.
122
+
123
+
<!-- This structure supports various types of information, like event properties, split outcomes, and function outputs. -->
124
124
125
125
For example, when a user triggers an event like `Appointment Scheduled`, Segment stores its properties (like `Appointment ID`, `Appointment Start Time`) as key-value pairs. You can then reference these values in later journey steps or include them in external payloads.
126
126
@@ -141,13 +141,6 @@ The following example shows how journey context might look during a workflow. In
141
141
"end_time": "2024-12-07T11:00:00Z",
142
142
"provider_name": "Dr. Jameson"
143
143
}
144
-
// "split_decision": {
145
-
// "split_name": "appointment_type_split",
146
-
// "branch_chosen": "existing_patient"
147
-
// },
148
-
// "function_output": {
149
-
// "discount_percentage": 15
150
-
// }
151
144
}
152
145
}
153
146
```
@@ -156,15 +149,13 @@ This payload contains:
156
149
157
150
-**Entry Event properties**: Captured under the `appointment_scheduled` key.
158
151
-**Hold Until Event properties**: Captured under the `appointment_rescheduled` key.
159
-
// - **Split outcomes**: Documented in the `split_decision` object.
160
-
// - **Function results**: Stored in the `function_output` object for use in later steps.
161
152
162
153
## Journey context and Event-Triggered Journeys
163
154
164
155
Journey context underpins the flexibility and precision of Event-Triggered Journeys. By capturing key details about events and decisions as they happen, journey context lets workflows respond dynamically to user actions and conditions.
or personalizing messages with event-specific data, journey context provides the tools to make your workflows more relevant and effective.
157
+
Whether you're orchestrating real-time abandonment recovery or personalizing messages with event-specific data, journey context provides the tools to make your workflows more relevant and effective.
169
158
170
159
To learn more about how Event-Triggered Journeys work, visit the [Event-Triggered Journeys documentation](/docs/engage/journeys/event-triggered-journeys/).
160
+
161
+
<!-- PW, 10 December 2024; on PM request, commented out certain sections with functionalities not yet available during public beta. -->
0 commit comments