Event

Track an event

POSTtracking/event

GoSquared events are a versatile way of tracking anything that is happening on your site or app. User actions, application errors, state transitions, and activity of all kinds can be tracked as an event.

Popular events are aggregated by name in the Trends dashboard.

You can search and filter by the top level event name in GoSquared People. Optionally, you can include extra data in the event body. However, event body data is not currently searchable, but it can be viewed on a per profile basis in GoSquared People.

How many unique event types/names can I track?

Take some time to think about the name you give to your events. You can name them anything you like, but it's best to use a clear, concise name.

Each GoSquared project can track up to 1000 custom events. Above this limit, events with new names will be ignored.

POST Body

person_id

String

The People person ID that this action is associated with.

If the identifier used is an email it should be prefixed with email: like this: email:jon@example.com

visitor_id

String

The anonymous visitor ID that this action is associated with.

timestamp

String

A valid ISO 8601 timestamp of when this event happened

page

Object

index

Number

The page index that this event is associated with

event

ObjectRequired

name

StringRequired

data

Object

Properties associated with this event

Run in PostmanPostman is a useful developer tool for experimenting with and managing APIs that you work with

Definition

POST https://api.gosquared.com/tracking/v1/event

Example Request

curl -X POST -H "Content-Type: application/json" \
  "https://api.gosquared.com/tracking/v1/event?api_key=demo&site_token=GSN-106863-S" 

Live Responseundefined undefined

Your API Key is not authorised for this endpoint