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/connections/auto-instrumentation/configuration.md
+40-6Lines changed: 40 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,15 +23,30 @@ After you set up the Signals SDK to capture the signals you want to target, you
23
23
24
24
### Getting started with rule creation
25
25
26
-
1. In your Segment workspace, go to to **Connections > Auto-Instrumentation** and click on a source.
27
-
2.Click**Create Rules**.
26
+
1. In your Segment workspace, go to **Sources** and select a source.
27
+
2.Open the **Event Builder**, then click**Create Rules**.
28
28
29
29
> info "Where's the Event Builder tab?"
30
30
> The Event Builder tab only appears after you've installed the Auto-Instrumentation snippet in your site or app. If you don’t see the tab, double check your implementation or reach out to your Segment CSM.
31
31
32
32
### Using the Rules Editor
33
33
34
-
The Rules Editor is where you define rules that transform raw signal data into analytics events. In the editor, you write functions that convert signals into events and then call them in the `processSignal()` function.
34
+
The Rules Editor is where you define rules that transform raw signal data into analytics events. Using the dropdown-based editor, you can:
35
+
36
+
- Combine multiple signals into a single event (for example, a click followed by a navigation)
37
+
- Set conditions to control when events should be triggered
38
+
- Assign custom event names
39
+
40
+
#### Adding event properties
41
+
42
+
You can enrich your events by adding properties based on signal metadata. For example:
43
+
44
+
- Capture `product.price` in your **Add to Cart** event
45
+
- Add a boolean field like `couponApplied` to your **Order Completed** event
46
+
47
+
These properties are sent alongside your event, giving your team deeper insights without requiring any manual instrumentation.
48
+
49
+
<!-- PW, 6 August 2025: Commenting this section out for now
35
50
36
51
The Rules Editor also lets you test your rules with recent signals to verify that they produce the data you need before you deploy.
37
52
@@ -49,6 +64,9 @@ function processSignal(signal) {
49
64
}
50
65
```
51
66
67
+
-->
68
+
69
+
<!-- PW, 6 August 2025: Also commenting the Signal definitions page out on PM request
52
70
## Signal definitions
53
71
54
72
Signals come in various types, each associated with specific data that you can use to create analytics events. This section contains code samples that detail each signal type. Because Segment has standardized these definitions across both the Signals-Swift and Signals-Kotlin libraries, they're useful when you create rules in your Segment workspace.
@@ -209,12 +227,23 @@ class MyCustomSignal extends RawSignal<MyCustomData> {
209
227
}
210
228
```
211
229
230
+
231
+
232
+
-->
212
233
## Example rule implementations
213
234
214
-
You can use the Signals data definitions on this page to create tracking rules.
235
+
You can use Signals to create tracking rules using the event builder.
215
236
216
237
### Example: Identify users
217
238
239
+
The following screenshot shows an Identify event rule that combines a button click with a successful network response to extract user data and trigger an identify call.
240
+
241
+

242
+
243
+
244
+
245
+
<!-- PW: more commenting out>
246
+
218
247
Building off of the screen tracking example, you could create a rule that identifies users:
219
248
220
249
```javascript
@@ -247,11 +276,15 @@ function processSignal(signal) {
247
276
detectIdentify(signal); // Process the Identify call based on incoming signals
248
277
}
249
278
```
250
-
279
+
-->
251
280
252
281
### Example: Track `Add to Cart` events
253
282
254
-
This rule shows how you could implement the core ordering events from [the e-commerce Spec](/docs/connections/spec/ecommerce/v2/#core-ordering-overview):
283
+
This rule implements a core ordering event from [the e-commerce Spec](/docs/connections/spec/ecommerce/v2/#core-ordering-overview). It shows a Track event triggered by a button click and a network response, with product details from the response mapped to event properties.
284
+
285
+

286
+
287
+
<!-- PW: even more commenting out
255
288
256
289
```javascript
257
290
function trackAddToCart(currentSignal) {
@@ -284,3 +317,4 @@ function ProcessSignals(signal) {
284
317
trackAddToCart(signal); // Process the "Add To Cart" tracking based on incoming signals
0 commit comments