Adobe DPS - JavaScript Library API

Class adobeDPS-AnalyticsService

Extends:
adobeDPS-AnalyticsService -> adobeDPS-Service -> adobeDPS-Class

Service for sending custom analytics events.
Accessible from adobeDPS.analyticsService

Constructor

adobeDPS-AnalyticsService()
[inner] Create an instance of the AnalyticsService.

Static Fields

Field Defined By
adobeDPS-AnalyticsService.ALLOWED_VARIABLES
The list of allowed variables for use within analytics events.
AnalyticsService
adobeDPS-AnalyticsService.ALLOWED_EVENTS
The list of allowed custom events.
AnalyticsService
adobeDPS-AnalyticsService.PURCHASE_CATEGORIES
The list of allowed categories for all purchase events.
AnalyticsService
adobeDPS-AnalyticsService.instance
The singleton of the AnalyticsService.
AnalyticsService

Fields

Field Defined By
variables : Object
Variables that are added to this object will be sent with all subsequent analytics calls.
AnalyticsService

Methods

Method Defined By
setCustomVariableAlias(realName:String, alias:String)
Function used to set a custom alias for an analytics property.
AnalyticsService
setCustomEventAlias(realName:String, alias:String)
Function used to set a custom alias for an analytics event.
AnalyticsService
trackPurchaseStart(category:String, productId:String, variables:String)
Function used to track a purchase start event.
AnalyticsService
trackPurchaseComplete(category:String, productId:String, price:String, variables:String, variables)
Function used to track a purchase complete event.
AnalyticsService
trackCustomEvent(eventName:String, variables:String)
Function used to track a custom event.
AnalyticsService
Inherited from adobeDPS-Class
Gets the string representation of this instance.
Class Detail
adobeDPS-AnalyticsService()
[inner] Create an instance of the AnalyticsService.
- This is an internal constructor and shouldn't be called by regular users.
Static Field Details
adobeDPS-AnalyticsService.ALLOWED_VARIABLES
The list of allowed variables for use within analytics events. These variables can be aliased or used within the variables object.
adobeDPS-AnalyticsService.ALLOWED_EVENTS
The list of allowed custom events. These events can be aliased but you must use one of these events when sending custom events.
adobeDPS-AnalyticsService.PURCHASE_CATEGORIES
The list of allowed categories for all purchase events.
adobeDPS-AnalyticsService.instance
The singleton of the AnalyticsService.
Field Details
variables : Object
Variables that are added to this object will be sent with all subsequent analytics calls. I.E. analyticsService.variables['productId'] = 'test1234' will cause all subsequent analytics tracking calls to have the productId variable set to 'test1234'. The only exception would be if the event that is sent after the variable is sent contains the variable as well. In this case, the variable value will be overridden by the value sent in the event.
Method Details
setCustomVariableAlias(realName:String, alias:String)
Function used to set a custom alias for an analytics property. After setting the new alias, that alias can be used in subsequent calls to track events when sending properties.
Parameters
realName String The real name of the analytics event property as defined in ALLOWED_VARIABLES.
alias String The alias to use for the real property.
See:
adobeDPS-AnalyticsService#ALLOWED_VARIABLES
setCustomEventAlias(realName:String, alias:String)
Function used to set a custom alias for an analytics event. After setting the new alias, that alias can be used in subsequent calls to track events.
Parameters
realName String The real name of the analytics event as defined in ALLOWED_EVENTS.
alias String The alias to use for the real property.
See:
adobeDPS-AnalyticsService#ALLOWED_EVENTS
trackPurchaseStart(category:String, productId:String, variables:String)
Function used to track a purchase start event.
WARNING: Purchase events will be tracked automatically for purchases of Folios through the API. This function should only be used to track purchases outside of the API
Parameters
category String The type of purchase event this is. Must be valued defined in PURCHASE_CATEGORIES
productId String The productId of the item being purchased
variables String OTher variables to be assigned to the event
See:
adobeDPS-AnalyticsService#ALLOWED_VARIABLES
adobeDPS-AnalyticsService#PURCHASE_CATEGORIES
trackPurchaseComplete(category:String, productId:String, price:String, variables:String, variables)
Function used to track a purchase complete event.
WARNING: Purchase events will be tracked automatically for purchases of Folios through the API. This function should only be used to track purchases outside of the API
Parameters
category String The type of purchase event this is. Must be valued defined in PURCHASE_CATEGORIES
productId String The productId of the item being purchased
price String The price of the item that was purchased
variables String Other variables to be assigned to the event
variables
See:
adobeDPS-AnalyticsService#ALLOWED_VARIABLES
adobeDPS-AnalyticsService#PURCHASE_CATEGORIES
trackCustomEvent(eventName:String, variables:String)
Function used to track a custom event.
Parameters
eventName String The name of this event
variables String Other variables to be assigned to the event
See:
adobeDPS-AnalyticsService#ALLOWED_VARIABLES
adobeDPS-AnalyticsService#PURCHASE_CATEGORIES
©2012 Adobe Systems, inc
Documentation generated by JsDoc Toolkit 2.4.0 on Wed Aug 01 2012 12:15:45 GMT-0700 (PDT)