new SharedProductEvent(source, medium, propertiesopt, transactionIdopt)
Creates an instance of SharedProductEvent with a predefined name and known
properties. Differs from other RetailEvents in that value
must be set after
creation if needed.
- See:
-
CustomEvent.templates.retail.RetailEvent
for available properties.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
source |
String
|
e.g. 'facebook' |
||
medium |
String
|
e.g. 'social' |
||
properties |
Object
|
<optional> |
{} | |
transactionId |
String
|
<optional> |
Example
const sharedEvent = new sdk.CustomEvent.templates.retail.SharedProductEvent(
'facebook',
'social',
{
category: 'mens shoes',
brand: 'Special Brand',
id: '23413'
})
sharedEvent.value = 23
sharedEvent.track()
Extends
- CustomEvent.templates.retail.RetailEvent