Analytics Integration
The client-side API extends the default Accelerate behavior beyond page views. Use it when custom interactions, endpoint data, or additional metrics need to be recorded.
Setup functions#
Use Altis.Analytics.onReady( callback <function> ) to ensure analytics has loaded before making calls to Altis.Analytics.registerAttribute() or Altis.Analytics.record().
Tracking functions#
Use Altis.Analytics.record( eventType <string> [, data <object>] ) to record an event.
The optional data object can include attributes and metrics:
{
attributes: {
name: 'value'
},
metrics: {
name: 1
}
}Attributes and metrics can be used later in custom queries.
Endpoint functions#
In Accelerate, an endpoint is the visitor's browser or device.
Use Altis.Analytics.updateEndpoint( data <object> ) to update the data associated with the current endpoint. This is useful for custom user attributes, metrics, user IDs, demographic data, and audience definitions.
Accelerate automatically collects and updates some endpoint data, including:
- UTM parameters:
utm_campaign,utm_source,utm_content,utm_medium, andutm_term. - Operating system.
- Device brand.
- Browser.
- Location, country, and region.
- Number of page views.
- Number of sessions.
Updated endpoint data is merged into new event records associated with the endpoint.