GET /shoppers/:id/events

Get a shopper's timeline events

get
Shopper Journey Events

https://app.fera.ai/api/v2/shoppers/:id/events
Get the shopper's event list sorted by most recent to oldest. You will get max 50 events per request paginated.
Request
Response
Path Parameters
id
required
string
ID token of the shopper
Query Parameters
page
optional
number
Current page you want to get. Default: 1 (first page)
public_key
required
string
Your public key found in your store settings API tab.
200: OK
Shopper found.
[
{
"event_name": "campaign_engagement",
"event_ids": [2341,2343,2345,2347,2349],
"associated_ids": ["479","556","569","587"], // Skill ids
"started_at": "2019-03-12T21:02:30.000Z",
"ended_at": "2019-03-12T21:05:59.000Z",
"times": 5
},
{
"event_name": "page_view",
"event_ids": [2320],
"associated_ids": null, // Product, collection or similar ID.
"page": {
"url": "https://brita-filters-r-us.myshopify.com/collections/all",
"referrer": "https://www.google.com?q=brita+filters",
"title": "Products – Brita Filters R Us",
"window_width": "863",
"window_height": "562"
},
"started_at": "2019-03-12T17:36:29.000Z",
},
{
"event_name": "element_click",
"event_ids": [2318],
"associated_ids": null, // Product, collection or similar ID.
"element_text": "Expand navigation",
"element_html": "<span class=\"burger-icon burger-icon--top\"></span> <span class=\"burger-icon burger-icon--mid\"></span> <span class=\"burger-icon burger-icon--bottom\"></span> <span class=\"icon__fallback-text\">Expand navigation</span>",
"element_css_path": "BUTTON.site-header__navigation.btn.btn--clear.btn--square[aria-expanded=\"false\"][role=\"navigation\"] > DIV.site-header__section.site-header__section--button > DIV.site-header-sections.page-width > HEADER.site-header__wrapper > DIV.site-header.site-header--transparent.site-header--homepage[data-drawer-push=\"\"][data-section-type=\"header-section\"][data-section-id=\"header\"] > DIV#shopify-section-header.shopify-section > BODY#brita-filters-r-us.template-index.data-animations.site-footer--parallax > HTML.outline-disabled[lang=\"en\"]",
"started_at": "2019-03-12T17:36:28.000Z",
"query_params": {}
}
]
404: Not Found
Could not find shopper.
{
message: "Shopper not found"
}

Event Types

Type

Description

page_view

Shopper viewed a specific page.

element_click

Shopper clicked on a clickable element on the page.

order_create

Shopper placed an order or a sales conversion event occured.

campaign_engagement

This is whenever the shopper was engaged in some way by Fera, meaning Fera showed the shopper some content that was visible to them.