# Recos analytics event format

### Custom Event Name in Analytics Tool: `ab_recos` <a href="#id-149a697be06b8099ab3fd1005e7e4e9e" id="id-149a697be06b8099ab3fd1005e7e4e9e"></a>

### Recos Analytics Event properties

<table><thead><tr><th width="105.4140625">Name</th><th width="174.59765625">Description</th><th width="123.16015625">Possible values</th><th width="184.48828125">Reco analytic events action name</th><th width="130.5">Potions analytics event action name</th><th>Comments</th></tr></thead><tbody><tr><td><code>action_id</code></td><td>The action that led to sending the event</td><td>An Action ID</td><td><code>show</code>, <code>set_experiment_audience</code>, <code>add_to_cart_items</code>, <code>add_to_cart_item</code>, <code>go_to_page</code>, <code>convert_XXX</code></td><td></td><td>See 'Recos Analytic Events Actions' below to find the list of possible values for <code>action_id</code></td></tr><tr><td><code>reco_id</code></td><td>The id of the experience concerned by the action</td><td>A Reco UUID</td><td><code>show</code>, <code>add_to_cart_items</code>, <code>add_to_cart_item</code>, <code>go_to_page</code>, <code>convert_XXX</code>, <code>close</code></td><td></td><td></td></tr><tr><td><code>item_id</code></td><td>The specific item concerned by the action (like the item added to cart in an “add_to_cart_item” action)</td><td>An Item ID</td><td><code>add_to_cart_item</code>, <code>got_to_page</code></td><td></td><td></td></tr><tr><td><code>item_ids</code></td><td>A list of items concerned by the action (like the items shown in a “show” action)</td><td>An Array of Item ID</td><td><code>show</code>, <code>add_to_cart_items</code></td><td><code>go_to_page</code>, <code>add_to_cart_item</code></td><td></td></tr></tbody></table>

### Recos Analytic Events Actions

<table><thead><tr><th width="217.859375">action_id</th><th width="175.34375">Description</th><th>Required properties</th><th>Optional properties</th><th>Click action</th></tr></thead><tbody><tr><td><code>show</code></td><td>when an experience is shown to the user.</td><td><code>reco_id</code>,  <code>action_id</code>, <code>item_ids</code></td><td></td><td>❌</td></tr><tr><td><code>go_to_page</code></td><td>when an item is clicked</td><td><code>reco_id</code>, <code>action_id</code>, <code>item_id</code></td><td><code>item_ids</code></td><td>✅</td></tr><tr><td><code>add_to_cart_item</code></td><td>when an item is added to cart in a recommendation</td><td><code>reco_id</code>, <code>action_id</code>, <code>item_id</code></td><td><code>item_ids</code></td><td>✅</td></tr><tr><td><code>add_to_cart_items</code></td><td>when alls the items recommended are added to cart (like in bundles)</td><td><code>reco_id</code>,  <code>action_id</code>, <code>item_ids</code></td><td></td><td>✅</td></tr><tr><td><code>set_experiment_audience</code></td><td>when an experiment audience is set</td><td><code>action_id</code></td><td></td><td>❌</td></tr><tr><td><code>close</code></td><td>when an experience is closed</td><td><code>reco_id</code></td><td></td><td>✅</td></tr><tr><td><code>convert_XXX</code></td><td>when a conversion button is clicked (XXX can be anything)</td><td><code>reco_id</code>, <code>action_id</code></td><td></td><td>✅</td></tr></tbody></table>

### Example: Event Logs in the DataLayer

When a recommendation banner appears:

```json
{
  "event": "ab_recos_[uuid]",
  "recos": {
    "reco_id": "[RECO_ID]",
    "action_id": "show",
    "item_id": "",
    "item_ids": "[\"21222\",\"12073\",\"21464\",\"6762\"]",
    "debug_mode": false,
    "non_interaction": false
  }
}
```

When a product card is clicked:

```json
{
  "event": "ab_recos_[uuid]",
  "recos": {
    "reco_id": "[RECO_ID]",
    "action_id": "go_to_page",
    "item_id": "21222",
    "item_ids": "[\"21222\",\"12073\",\"21464\",\"6762\"]",
    "debug_mode": false,
    "non_interaction": false
  }
}
```

Each event includes a unique `uuid` to prevent collisions in the dataLayer.


---

# 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.abtasty.com/recommendations-and-merchandising/how-tos/how-to-deploy-a-strategy/how-to-deploy-a-recommendation-strategy-on-web/mix-front-end-integration-using-the-tag-and-custom-javascript/recos-analytics-event-format.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.
