Note that in Emercury you can define any custom website action as an event, and it will get reported in your stats.

However, we do have some pre-defined events to get you started. and these are for some common things that you might want to see in your reports.

Note: These trigger on-page-load and are only for analytic purposes. You can see these events in the reports, but you can not trigger automations off of them. For that you will need to define your own custom events.

clicktrack - defines which tags do we track

emer("param", "clicktrack", {
tags: ['a', 'button', 'span.btn']
});

With this cool little snippet you can tell Emercury to keep track of all clicks on a page. You just tell it which element types to keep track of. So, keeping track of all clicks on links requires that you just add 'a'. Clicks on images would require adding 'img', and so on.

login

emer("param", "login", {
identity : {
user_id : "12345",
email : "user@example.com"
}
});

This event needs to be fired only when the visitor completes a log-in to the site.

signup - similar event to login

emer("param", "signup", {
identity : {
user_id : "12345",
email : "user@example.com",
first_name : "Test 1",
last_name : "Test 2"
}
});

This event needs to be fired only when the visitor has completed a sign up.

order_created - new order is created

emer("param", "order_created", {
user_id : "123456",
email : "testorder@email.com",
first_name : "fname",
last_name : "lname",
order_total : 120.25,
products : [
{
name : 'test product 1',
price : 20.25,
sku : '001',
},
{
name : 'test product 2',
price : 100.00,
sku : '002',
}
]
});

Did this answer your question?