Difference between revisions of "ATC/Current/SDK/Record"

From Genesys Documentation
Jump to: navigation, search
(Published)
Line 2: Line 2:
 
|Standalone=No
 
|Standalone=No
 
|DisplayName=record
 
|DisplayName=record
|Platform=PureEngage, PureConnect, PureCloud
 
 
|TocName=record
 
|TocName=record
 +
|Context=Learn how to use the <tt>record</tt> method to capture website events.
 +
|Dimension=DevTracking
 
|ComingSoon=No
 
|ComingSoon=No
|Dimension=DevTracking
+
|Platform=PureEngage, PureConnect, PureCloud
|Context=Learn how to use the <tt>record</tt> method to capture website events.
 
 
|Section={{Section
 
|Section={{Section
 
|sectionHeading=Description
 
|sectionHeading=Description
|Standalone=No
 
|ComingSoon=No
 
 
|alignment=Vertical
 
|alignment=Vertical
 
|structuredtext=The <tt>record</tt> method records custom website events.
 
|structuredtext=The <tt>record</tt> method records custom website events.
|fullwidth=No
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
 
|sectionHeading=Signature
 
|sectionHeading=Signature
|Standalone=No
 
|ComingSoon=No
 
 
|alignment=Vertical
 
|alignment=Vertical
 
|structuredtext=<tt>ac('record', eventName, [customAttributes], [options])</tt>
 
|structuredtext=<tt>ac('record', eventName, [customAttributes], [options])</tt>
|fullwidth=No
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
 
|sectionHeading=Arguments
 
|sectionHeading=Arguments
|Standalone=No
 
|ComingSoon=No
 
 
|alignment=Vertical
 
|alignment=Vertical
 
|structuredtext=*[[#eventName|eventName]]
 
|structuredtext=*[[#eventName|eventName]]
 
*[[#customAttributes|customAttributes]]
 
*[[#customAttributes|customAttributes]]
 
*[[#options|options]]
 
*[[#options|options]]
|fullwidth=No
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
 
|sectionHeading=eventName
 
|sectionHeading=eventName
 
|anchor=eventName
 
|anchor=eventName
|Standalone=No
 
|ComingSoon=No
 
 
|alignment=Vertical
 
|alignment=Vertical
 
|structuredtext=*Description: name of the custom event
 
|structuredtext=*Description: name of the custom event
 
*Type: string
 
*Type: string
 
*Status: required
 
*Status: required
|fullwidth=No
 
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
 
|sectionHeading=customAttributes
 
|sectionHeading=customAttributes
 
|anchor=customAttributes
 
|anchor=customAttributes
|Standalone=No
 
|ComingSoon=No
 
 
|alignment=Vertical
 
|alignment=Vertical
 
|structuredtext=*Description: adds extra information to <tt>pageview</tt> event
 
|structuredtext=*Description: adds extra information to <tt>pageview</tt> event
Line 54: Line 40:
 
*Status: optional
 
*Status: optional
 
*Restrictions: a flat object with properties of type string, number, or boolean
 
*Restrictions: a flat object with properties of type string, number, or boolean
|fullwidth=No
+
 
 +
==== Example ====
 +
<code>ac('record', 'product_added', { price: 15.99, code: 'CDE-123', name: 'Product', hasBatteries: false });</code>
 
|Status=No
 
|Status=No
 
}}{{Section
 
}}{{Section
 
|sectionHeading=options
 
|sectionHeading=options
|Standalone=No
 
|ComingSoon=No
 
 
|alignment=Vertical
 
|alignment=Vertical
 
|structuredtext=*Description: Used for additional configuration
 
|structuredtext=*Description: Used for additional configuration
Line 92: Line 78:
 
{{!}}{{!}}<br />
 
{{!}}{{!}}<br />
 
{{!}}}
 
{{!}}}
|fullwidth=No
 
 
|Status=No
 
|Status=No
 
}}
 
}}
 
}}
 
}}

Revision as of 18:21, March 13, 2020

This topic is part of the manual Journey JavaScript SDK for version Current of Genesys Predictive Engagement.

Learn how to use the record method to capture website events.

Description

The record method records custom website events.

Signature

ac('record', eventName, [customAttributes], [options])

Arguments

eventName

  • Description: name of the custom event
  • Type: string
  • Status: required

customAttributes

  • Description: adds extra information to pageview event
  • Type: object
  • Status: optional
  • Restrictions: a flat object with properties of type string, number, or boolean

Example

ac('record', 'product_added', { price: 15.99, code: 'CDE-123', name: 'Product', hasBatteries: false });

options

  • Description: Used for additional configuration
  • Type: object
  • Status: optional
  • Properties:
Name Description Type Status Default
traitsMapper used to map custom attributes to traits. For more information, see Traits Mapper. traitsMapper

callback called once beacon is sent function optional
callbackTimeout ms to wait for beacon to send number optional
Retrieved from "https://all.docs.genesys.com/ATC/Current/SDK/Record (2025-07-14 17:41:06)"
Comments or questions about this documentation? Contact us for support!