Edit in GitHubLog an issue

Analytics event reference

Internal events for Adobe Analytics

The Adobe Experience Platform SDKs also track some internal events that are based on the communication with other extensions in addition to the Analytics hits that are sent as a result of the track call.

Adobe Analytics events are supported in the following extensions:

  • Lifecycle
  • Identity
  • Messages
  • Target

Lifecycle extension

The following Adobe Analytics events are supported in the Lifecycle extension:

Install event

The SDK tracks the application install details when Lifecycle is enabled. These details include the install date and the daily engaged/monthly engaged user badges.

Launch event

The SDK tracks every new launch of the application when lifecycle is enabled.

A launch is considered to be new when the following conditions are met:

  • The application is reopened from the background after the configured session timeout.
  • The application is opened after a force close.

Launch data includes information about the application's number of launches, days since first run, days since last use, user daily/monthly engaged badges, and other lifecycle metrics. The application version upgrades are also tracked.

Crash event

If your application is terminated without having first been backgrounded, the SDK reports a crash the next time your app is launched. If the backdateSessionInfo flag is enabled in your configuration, this crash is sent as an individual hit. If the flag is not enabled, the crash is sent as part of the launch event.

SessionInfo

The SessionInfo contains information about the previously launched session, such as the session length. This information is sent as an individual hit if the backdateSessionInfo flag is enabled in your configuration. If the flag is not enabled, the information is sent as part of the launch event.

Identity extension

The following Analytics event is triggered when the Identity extension is enabled:

Push

The SDK tracks changes in the user's push notifications preference, and a new hit is sent after the user opts in or opts out for push notifications.

Messages extension

The following Analytics event is triggered when the Messages extension is enabled:

In-app message

The SDK tracks the following metrics for your in-app messages:

  • For full screen and alert style in-app messages:
    • Impressions: when user triggers an in-app message.
    • Click throughs: when user presses the Click-through button.
    • Cancels: when user presses the Cancel button.
  • For local (remote) notifications:
    • Impressions: when user triggers the notification.
    • Opens: when user opens app from the notification. This will be tracked with the trackAdobeDeepLink method.

Target extension

The Analytics event in the Target extension is AnalyticsForTarget. The SDK forwards Target's data to Analytics when A4T is enabled in Target Services.

Events handled by Analytics

The following events are handled by the Adobe Analytics extension:

Generic track content request

This event is a request to complete processing on the Analytics hits queue. The event will be created when either of the trackAction or trackState APIs is called.

The Analytics extension receives and processes the following keys in a generic track content request event:

  • action - action name to attribute to the Analytics request being processed.
  • state - state name (page name) to attribute to the Analytics request being processed.
  • contextdata - key-value pairs that add context to the Analytics request being processed.

Event details

Event typeEvent sourcePaired
com.adobe.eventType.generic.track
com.adobe.eventSource.requestContent
No

Data payload definition

The payload definition is composed of the following:

KeyValue typeOptionalDescription
action
String
Yes
The action name value.
state
String
Yes
The state name value.
contextdata
Map<String, String>
Yes
The additional context data parameters.
trackinternal
Bool
Yes
Bool indicating whether this is an internal Analytics hit that is generated by the SDK. Default value is false.

Event data examples

Track request

The following code sample shows an example of event data for a track request:

Copied to your clipboard
{
"action": "clicked add button",
"state": "cart page",
"contextdata": {
"key1": "value1",
"key2": "value2"
},
"trackinternal": false
}

Analytics content request

An Analytics content request is a request to complete processing on the Analytics hits queue and can be used in one of the following situations:

  • When a request is received to send the Analytics hits in the queue, regardless of the batching settings.
  • When a request is received to clear all unsent Analytics hits from the queue.
  • When a request is received to get the current number of Analytics hits in the queue.

The Analytics extension receives this event with the following keys, and the extension processes the keys:

  • clearhitsqueue - clears the Analytics hit database.
  • forcekick - sends all the hits in database.
  • getqueuesize - retrieves the current number of queued hits in the database. This is a paired event that is associated with a response callback.

This event is generated by calling one of the following Analytics APIs:

Event details

Event typeEvent sourcePaired
com.adobe.eventType.analytics
com.adobe.eventSource.requestContent
No

Data payload definition

The payload definition is composed of the following elements:

KeyValue typeOptionalDescription
forcekick
Boolean
Yes
Boolean indicating whether this is a request for sending all Analytics hits.
clearhitsqueue
Boolean
Yes
Boolean indicating whether this is a clear hits queue event.
getqueuesize
Boolean
Yes
Boolean indicating whether this is a request for getting current number of queued hits.

Event data examples

The following examples show how to use the event data:

Send all Analytics hits request

Copied to your clipboard
{
"forcekick": true
}

Clear all the Analytics hits request

Copied to your clipboard
{
"clearhitsqueue": true
}

Get queue size request

Copied to your clipboard
{
"getqueuesize": true
}

Analytics request identity

The Analytics request identity event is responsible for fetching the Analytics tracking identifier (AID) and custom visitor identifier (VID) from the Analytics extension and is generated in the Analytics getTrackingIdentifier and getCustomVisitorIdentifier calls.

After the Analytics identity request event is received, the Analytics extension completes one of the following tasks:

  • Checks the persistence for the saved AID and VID.
  • If AID and VID are set, dispatches an Analytics Identity Response Event with the AID and VID value.

Data payload definition

No keys are required for the Analytics request event.

Event details

Event typeEvent sourcePaired
com.adobe.eventType.analytics
com.adobe.eventSource.requestIdentity
Yes

Configuration response content

The data property in this event is used by each extension to modify its current settings. Each extension is responsible for reading the part of the data property in which it is concerned.

This event will be generated in the following scenarios:

  • Initial config requested by the customer.
  • Configuration modified (remote update or local developer action).
  • In response to a configuration request event with the config.getData data key.

For more information about the data payload definition for this event, see the Data payload definition section for each extension.

Data payload definition

The Analytics extension will read the following keys from the configuration event:

KeyValue typeOptionalDescription
analytics.server
String
No
The Analytics server
analytics.rsids
String
No
The Analytics report suites separated by commas.
analytics.batchLimit
Int
Yes
The hit batching settings. By default, this value is 0.
analytics.aamForwardingEnabled
Bool
Yes
Indicates whether Audience Manager forwarding is enabled in the SDK. By default, this option is disabled.
analytics.offlineEnabled
Bool
Yes
Indicates whether Analytics offline batching is enabled. By default, this option is disabled.
lifecycle.backdateSessionInfo
Bool
Yes
Indicates whether Analytics should backdate the lifecycle SessionInfo hit. This flag is used when analytics.offlineEnabled is also enabled. By default, this option is disabled.
analytics.referrerTimeout
Int
Yes
Indicates the number of seconds that the SDK will wait for referrer information to arrive. By default, this value is 0.
experienceCloud.org
String
No
The Experience Cloud organization ID.
global.privacy
String
Yes
Contains the mobile privacy status settings.

Event data example

Copied to your clipboard
{
"experienceCloud.org": "orgsample@AdobeOrg",
"analytics.rsids": "mobilesamplersid",
"analytics.server": "serversample.sc.omtrdc.net",
"analytics.aamForwardingEnabled": false,
"analytics.offlineEnabled": true,
"analytics.batchLimit": 0,
"global.privacy": "optedin",
"lifecycle.sessionTimeout": 300,
"lifecycle.backdateSessionInfo": false
}

Acquisition referrer information response

The Acquisition referrer information response is generated by the Acquisition extension after the request event for the referrer information is received by the extension. This information is retrieved by the extension. Analytics listens to the referrer information and creates a analytics hit with data from the install lifecycle event.

Event details

Event typeEvent sourcePaired
com.adobe.eventType.acquisition
com.adobe.eventSource.responseContent
No

Data payload definition

The payload definition is comprised of the following element:

KeyValue typeOptionalDescription
contextdata
Map
No
The data value contains the key-value pairs that define the referrer information that is collected by the Acquisition extension.

The following lists the standard key-value pairs that are defined in the SDK:

  • campaign
  • source
  • medium
  • term
  • content
  • trackingCode
  • contextData
  • adobeData

Note that the data may contain other custom key-value pairs that are not defined in the standard.

Sample event payload

Copied to your clipboard
{
"contextdata": {
"campaign": "testCampaign",
"source": "sampleSource",
"contextData": {
"contextDatakey": "contextDataValue"
},
"adobeData": {
"adobeDataKey": "adobeDataValue"
},
"mycustomkey": "mycustomValue"
}
}

Lifecycle request content

This event represents a request to the Lifecycle extension to start or stop collecting data and is generated when lifecycleStart and lifecyclePause() are used.

The Analytics extension only listens for the Lifecycle start event, and the Analytics database queue should be paused for up to 1000 milliseconds, which is the default value for DEFAULT_LIFECYCLE_RESPONSE_WAIT_TIMEOUT.

Event details

Event typeEvent sourcePaired
com.adobe.eventType.lifecycle
com.adobe.eventSource.requestContent
No

Data payload definition

The payload definition is composed of the following elements:

KeyValue typeOptionalDescription
type
String
No
Can be one of these values: Start, Stop, or Pause
contextdata
Map
Yes
Map that contains the user-supplied context data.
Copied to your clipboard
{
"type": "start",
"contextData": {
"contextDataKey": "contextDataValue"
}
}

Lifecycle response

This event is a response from the Lifecycle extension to notify a client/extension about Lifecycle context data in which the extension/client might be interested. The event is generated by the Lifecycle extension, and the API is called after a lifecycle start, stop, or pause.

The Analytics extension waits for the lifecycle data and appends it to an exiting hit. Otherwise, a new hit is sent for lifecycle data, and the lifecycle timer is cancelled to mark that the lifecycle data has been received and processed. If the backdate session option is enabled, use the timestamp of the last session as the timestamp of the current Analytics request and insert the data to the Analytics queue before another request is received in the current session.

Event details

Event TypeEvent SourcePaired
com.adobe.eventType.lifecycle
com.adobe.eventSource.responseContent
No

Data payload definition

The payload definition is composed of the following elements:

KeyValue typeOptionalDescription
lifecyclecontextdata
Map
No
starttimestampmillis
Long
No
previoussessionpausetimestampmillis
Long
No
maxsessionlength
Long
No
Copied to your clipboard
{
"lifecyclecontextdata": {
"installdate": "22/05/2014",
"hourofday": 6,
"dayofweek": 2,
"osversion": "iOS 12.3",
"appID": "contextDataValue",
"resolution": "600x1345",
"devicename": "iPhoneX",
"launchevent": "LaunchEvent",
"prevsessionlength": 345,
"locale": "en-US",
"runmode": "Application",
"launches": 42
},
"starttimestampmillis": 44,
"maxsessionlength": 22
}

Install event

After Lifecycle is enabled, the SDK tracks the application install details, which includes the install date and the daily engaged/monthly engaged user badges.

Copied to your clipboard
{
"lifecyclecontextdata": {
"installevent": "InstallEvent",
"dailyenguserevent": "DailyEngUserEvent",
"monthlyenguserevent": "MonthlyEngUserEvent",
"installdate": "22/05/2014"
}
}

Launch event

After Lifecycle is enabled, the SDK tracks every new launch of the application.

A launch is considered new when either of the following conditions are met:

  • The application is reopened from the background after the configured session timeout.
  • The application is opened after a force close.

Launch data includes information about the application's number of launches, days since first run, days since last use, user daily/monthly engaged badges, and other lifecycle metrics. Application version upgrades are also tracked.

Copied to your clipboard
{
"lifecyclecontextdata": {
"launchevent": "LaunchEvent",
"dailyenguserevent": "DailyEngUserEvent",
"monthlyenguserevent": "MonthlyEngUserEvent",
"installdate": "22/05/2014",
"launches": 42,
"dayssincelastuse": 4,
"dayssincefirstuse": 28
}
}

Crash event

If your application is terminated without having first been backgrounded, the SDK reports a crash the next time your app is launched. If the backdateSessionInfo flag is enabled in your configuration, this information is sent as an individual hit. For more information, please read the backdate previous session info tutorial. If the flag is not enabled, the information is sent as part of the launch event.

Copied to your clipboard
{
"lifecyclecontextdata": {
"crashevent": "CrashEvent",
"launchevent": "LaunchEvent",
"dailyenguserevent": "DailyEngUserEvent",
"monthlyenguserevent": "MonthlyEngUserEvent",
"installdate": "22/05/2014",
"launches": 42,
"dayssincelastuse": 4,
"dayssincefirstuse": 28
}
}

SessionInfo

This hit contains information, such as the session length, about the previous launch session. If the backdateSessionInfo flag is enabled in your configuration, this information is sent as an individual hit. If the flag is not enabled, the information sent as part of the launch event.

Events dispatched by Analytics

The following events are dispatched by the Analytics extension:

Analytics response content

This event is a response from the Analytics extension to notify the result of the track calls or to return the analytics hits queue size.

This event is generated in the following situations:

  • If the Analytics server returns a response content, the Analytics extension after the com.adobe.eventSource.requestContent is processed, and the hit is sent to the server.
  • The Analytics extension as a response for the GetQueueSize API requests.

Event details

Event TypeEvent SourcePaired
com.adobe.eventType.analytics
com.adobe.eventSource.responseContent
No

Data payload definition

The payload definition is composed of the following elements:

KeyValue typeOptionalDescription
analyticsserverresponse
String
Yes
The Analytics server response that is used for forwarding by the Audience Manager extension.
queuesize
Long
Yes
The Analytics queue size value.
hitHost
String
Yes
The Analytics host that was used for the Analytics hit.
hitUrl
String
Yes
The Analytics url that was used for the Analytics hit.

Event data example

The following examples show how event data is used by the Analytics response content:

Forwarding the Analytics server response

Copied to your clipboard
{
"analyticsserverresponse": "example response to be forwarded",
"hitHost": "the sever for the analytics hit",
"hitUrl": "the url for the analytics hit"
}

Analytics queue size

Copied to your clipboard
{
"queuesize": 42
}

Analytics response identity

This event is a response from the Analytics extension that contains the unique tracking identifier. This value may be null if the Identity extension is enabled and a valid MID was generated. This event is generated as a paired response for the getTrackingIdentifier and getVisitorIdentifier APIs.

Event details

Event TypeEvent SourcePairedPaired Event
com.adobe.eventType.analytics
com.adobe.eventSource.responseIdentity
Yes

Data payload definition

The payload definition is composed of the following elements:

KeyValue TypeOptionalDescription
aid
String
No
The Analytics tracking identifier value.
vid
String
Yes
The custom visitor identifier value.

Event data example

Copied to your clipboard
{
"aid" : "aidValue", "vid": "vidValue"
}
Was this helpful?
  • Privacy
  • Terms of Use
  • Do not sell or share my personal information
  • AdChoices
Copyright © 2024 Adobe. All rights reserved.