trial_started or order_completed. A goal is an event that counts as a conversion, like a purchase, sign-up or booking. A goal can carry a money value.
Events and goals let you:
- see a contact’s Lifetime value, Purchases and Last goal on their contact page
- build segments such as “bought in the last 30 days” or “spent over 1,000 this year”
- start automations when an event happens
Goal types
A negative value records a refund, which lowers the contact’s lifetime value.
Ways to record events
From your server (recommended for goals)
Send events to the public API with the contact’s email address. Each event can include:
You can send up to 50 events in one import call. Endpoints, authentication and examples are in the API reference. You need an API key with permission to write events.
An event is linked to a contact only if a contact with that email address already exists. Events for unknown addresses are stored without a contact and don’t count towards anyone’s lifetime value or segments.
From your website
1
Create a tracking token
Go to Settings → Tracking tokens, click New Token and create the token. Tracking tokens (
ict_…) can only send events, so they are safe to put in public pages.2
Add the snippet
After you create the token, the dialog shows the token and its Embed Snippet. Copy them now: the token is shown only once. Paste the snippet into the Use the exact snippet from the dialog, as the address may differ for your workspace.
<head> of your site:3
Send events
page_view event on every page load. ICTrack.goal(type, { value, currency, externalId }) records a goal named goal.<type> unless you pass a name.
An event from the website is credited to a contact when the visit is known. A visit becomes known when the visitor arrives from one of your emails, submits one of your InstantCampaign forms, or, with Settings → Tracking tokens → Trust identity declared by your site code turned on, when your site calls ICTrack.identify("jane@example.com") or sends a goal with its own email (ICTrack.goal("lead", { email: "bob@example.com" })). A credited event adds to lifetime value and goal segments and can start event-triggered automations. ICTrack.reset() forgets the declared visitor, for example when they log out.
The snippet keeps no cookie or local storage, so a declared identity lasts for the page only: call
ICTrack.identify() on every page where you know who the visitor is, before the events you want credited. With the trust setting off, an email from the browser is ignored and only an email link or a form submission identifies the visit. Events recorded while the visit was anonymous are merged into the contact’s history once it becomes known, but they do not start journeys retroactively. As with events from your server, the address must belong to an existing contact.From Shopify
With the Shopify integration connected, each paid order is recorded as apurchase goal named order.completed with the order total. When a cancelled order has refunds, an order.refunded goal with the negative refunded amount is recorded. Both use the Shopify order ID for de-duplication, so an order is never counted twice.
Where events and goals appear
Troubleshooting
A purchase doesn't show on the contact
A purchase doesn't show on the contact
Check that the event was sent with an
email that matches an existing contact. From the website snippet, the visit must be known: the visitor came from one of your emails, submitted one of your forms, or, with Trust identity declared by your site code on, ICTrack.identify() ran on the same page before ICTrack.goal() or the goal was given its own email.The API rejects an event
The API rejects an event
Common causes: the event name has capitals or spaces; a
purchase or subscription goal has no value; a value was sent without a goalType; the currency isn’t a 3-letter code.A Custom Event segment rule doesn't match
A Custom Event segment rule doesn't match
The rule matches the event name exactly, including dots and capitals. Type it as it appears on the Events tab of Analytics → Website or on the contact’s Activity tab, for example
order.completed.