Generic widget events
Generic widget events include widget appear
and widget click
events. Sitecore Discover uses these events to calculate the performance metrics of widgets on your site.
This topic describes generic widget appear
and widget click
events. Refer to Recommendation widget events, Full page search widget events, or Preview search widget events for event specification for those widgets.
Widget appear events
The widget appear
(widget:appear
) event must be sent when the user sees a Sitecore Discover widget on your site. Use this event to capture appears for all widgets, including HTML content blocks, Discover widgets, or other types of widgets.
The widget:appear
event is also referred to as track:appear
in the old convention.
The information provided in this event object is used to calculate the following:
-
Sitecore Discover view-assisted attributions, such as view-assisted revenue, orders, and conversions. These attributions are calculated at the domain, widget type, and widget levels.
-
Click-through rate (CTR) for site, widget type, or widget.
The following table lists properties for the generic widget appear
event object:
Name |
Type |
Description |
Value |
---|---|---|---|
|
string |
Required. Type of the event. |
|
|
string |
Required. Name of the event. |
|
|
string |
Required. Used to associate this event with a widget that is set up in the Customer Engagement Console (CEC). Important This must match the corresponding |
n/a |
|
object |
Required if the site is set up with locale configuration. Adds page-specific information (including locale information) under the the page object. |
n/a |
The following is an example of a generic widget appear
event object. This example is in the new format, which means it contains a context
object.
{
"type": "widget",
"name": "appear",
"value": {
"context": <context object>,
"rfkid": "<widget rfkid>",
"f": "<widget type>"
}
}
Widget click events
The widget click
event (widget:click
) must be sent when the user clicks anywhere on a Sitecore Discover widget. Use this event to capture button clicks on HTML content block widgets and embedded buttons such as Add to cart or Quick view, and so on.
The information provided in this event object is used to calculate the following:
-
Sitecore Discover click-assisted attributions, such as click-assisted revenue, orders, and conversions. These attributions are calculated at the domain, widget type, and widget levels.
-
Click-through rate (CTR) for the site, widget type, or widget.
-
Direct attributions, such as Direct Order Revenu.e (DOR), Direct Purchase Revenue (DPR), Direct Orders (DO), and Direct Purchase Units (DPU).
The following table lists the properties of the generic widget click
event object:
Name |
Type |
Description |
Value |
---|---|---|---|
|
string |
Required. Type of the event. |
|
|
string |
Required. Name of the event. |
|
|
string |
Required. Used to associate this event with a widget that is set up in the CEC. Important This must match the corresponding |
n/a |
|
string |
Optional. Type of widget. |
|
|
number |
Required for product and facet links. Position of the product or link that the user clicked in a widget. Indexing starts at 0. |
n/a |
|
string |
Required. Original keyword or search text that the user entered in the search box. Calculates attribution to the keyword entered by the user. Used to compute keyword analytic metrics |
n/a |
|
string |
Required only if back end returned modified keyword Modified keyword that was returned as part of the search response. Calculates attribution to a modified keyword returned by Search API. Used to compute keyword analytic metrics. |
n/a |
|
string |
Required for clicks on HTML content or embedded action buttons The type of link or button that is associated with this click event. |
n/a |
|
string |
Optional. Additional subtype of the link or button that the user clicked. |
n/a |
|
string |
Required for clicks on HTML content or embedded buttons. Label value of the link/button associated with the preceding click type. Example values are |
n/a |
|
string |
Optional. Normalized text ID of a label value associated with the link or button that the user clicked. |
n/a |
|
string |
Required if the clicked link has a URI associated with it. URI associated with the click. |
n/a |
|
array |
Required for product clicks. Array with a single product object that the user clicked in a widget. |
n/a |
|
string |
Required for product clicks. SKU of the product the user clicked in a widget. |
n/a |
|
object |
Required if the site is set up with locale. Adds page-specific information (including locale information) under page object. |
n/a |
|
object |
Optional. A locale object. Deprecated. We recommend that you use |
n/a |