SDK Event Details

This articles provides details and descriptions for the event JSON objects.

Required attributes are in bold.

monetate:context:ipAddress

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
ipAddress: StringThe IP address to send.

Example

{
  "eventType": "monetate:context:IpAddress",
  "ipAddress": "198.51.100.0"
}

monetate:context:PageView

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
url: StringThe complete URL for the page viewed. Optional if pageType is specified.
pageType: StringThe path of the URL for the page viewed. Optional if URL is specified.
categories: ArrayCategories to filter against. Only matching actions are evaluated.
breadcrumbs: ArrayBreadcrumbs to filter against. Only matching actions are evaluated.

Example

{
  "eventType": "monetate:context:PageView",
  "url": "http://www.monetate.com/index.html",
  "pageType": "home",
  "categories": ["category"],
  "breadcrumbs": ["breadcrumb"]
}

monetate:context:Cart

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
cartLines: Array[cartLine]The contents of the cart. Refer to cartLine for details.

Example

{
  "eventType": "monetate:context:Cart",
  "cartLines": [{
    "sku": "SKU1",
    "pid": "PID1",
    "quantity": 2,
    "currency": "USD",
    "value": "24.00"
  }]
}

monetate:context:AddToCart

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
cartLines: Array[cartLine]The item to add to the cart. Refer to cartLine for details.

Example

{
  "eventType": "monetate:context:Cart",
  "cartLines": [{
    "sku": "SKU1",
    "pid": "PID1",
    "quantity": 2,
    "currency": "USD",
    "value": "24.00"
  }]
}

monetate:context:Purchase

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
account: StringThe account ID.
domain: StringThe account domain.
instance: StringThe type of instance.
purchaseId: StringThe unique identifier for the purchase.
purchaseLines: Array[purchaseLine]The contents of the purchase. Refer to purchaseLine for details.

Example

{
  "eventType": "monetate:context:Purchase",
  "account": "3",
  "domain": "example.com",
  "instance": "p",
  "purchaseId": "1b2c3d",
  "purchaseLines": [{
    "sku": "SKU1",
    "pid": "PID1"
    "quantity": 2,
    "currency": "USD",
    "value": "24.00"
  }]
}

monetate:context:Metadata

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
metadata: ObjectAdditional custom data to send.
language: StringThe language of the device or app.

Example

{
  "eventType": "monetate:context:Metadata",
  "metadata": {
    "language": "en-GB"
  }
}

monetate:context:ProductView

AttributeDescription
eventType: String
Identifies the type of event. Use the name of this event.
products: Array[product]
The list of products to display. Refer to product for details.

Example

{
  "eventType": "monetate:context:ProductView",
  "products": ["product72", "product43", "product42"]
}

monetate:context:ProductDetailView

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
products: Array[product]The list of products to display. Refer to product for details.

Example

{
  "eventType": "monetate:context:ProductView",
  "products": ["product72", "product43", "product42"]
}

monetate:context:ProductThumbnailView

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
products: Array[product]The list of products to display. Refer to product for details.

Example

{
  "eventType": "monetate:context:ProductThumbnailView",
  "products": ["product72", "product43", "product42"]
}

monetate:context:Coordinates

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
latitude: StringThe latitude of the user.
longitutde: StringThe longitude of the user.

Example

{
  "eventType": "monetate:context:Coordinates",
  "latitude": "49.566667",
  "longitude": "10.883333" 
}

monetate:context:ScreenSize

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
height: NumberThe height of the device.
width: NumberThe width of the device.

Example

{
  "eventType": "monetate:context:ScreenSize",
  "height": 762,
  "width": 1024
}

monetate:context:CustomVariables

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
customVariables: Array[CustomVariables]An array of custom variables.
variable: StringThe name of the custom variable
value: StringThe value of the custom variable.

Example

{
  "eventType": "monetate:context:CustomVariables",
  "customVariables": [{
    "variable": "favoriteTeam",
    "value": "Blue Hens"
  }]
}

monetate:context:UserAgent

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
userAgent: StringThe user agent header value.

Example

{
  "eventType": "monetate:context:UserAgent",
  "userAgent": "Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en) AppleWebKit/522.11 (KHTML, like Gecko) Safari/3.0.2"
}

monetate:context:Referrer

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
referrer: StringThe referring URL.

Example

{
  "eventType": "monetate:context:Referrer",
  "referrer": "http://www.example.com"
}

monetate:context:ClosedSession

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
closedSession: ObjectThe closed session object retrieved from the closed session stream.
version: StringThe version of the closed session object.

Example

{
  "eventType": "monetate:context:ClosedSession",
  "closedSession": {"account_id": 123, "has_cart": "t", "has_purchase": "f", ...}
  "version": "2.0"
}

monetate:record:PageEvents

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
pageEvents: Array[String]The array of page events.

Example

{
  "eventType": "monetate:record:PageEvents",
  "pageEvents": ["myEvent"]
}

monetate:record:Impressions

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
impressionsIds: Array[String]The list of impression identifier strings.

Example

{
  "eventType": "monetate:record:Impressions",
  "impressionIds": [
    "3.MS4xLjE1MTQ4MDg5MDAuMDAwMDAw"
  ]
}

monetate:record:RecClicks

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
recClicks: Array[String]The array of recommendation click tokens to record.

Example

{
  "eventType": "monetate:record:RecClicks",
  "recClicks": ["rt.1.xxx", "rt.1.yyy"]
}

monetate:record:RecImpressions

AttributeDescription
eventType: StringIdentifies the type of event. Use the name of this event.
recImpressions: Array[String]The array of recommendation impression tokens to be recorded.

Example

{
  "eventType": "monetate:record:RecImpressions",
  "recImpressions": ["rt.1.xxx", "rt.1.yyy"]
}

cartLine

AttributeDescription
sku: StringThe unique identifier for the product.
pid: StringThe parent identifier for a related set of SKUs.
quantity: NumberThe number of items in the cart.
currency: StringThe currency type of the purchase value.
value: StringThe total value of the items in the specified currency.

purchaseLine

AttributeDescription
sku: StringThe unique identifier for the product.
pid: StringThe parent identifier for a related set of SKUs.
quantity: NumberThe number of items in the cart.
currency: StringThe currency type of the purchase value.
value: StringThe total value of the items in the specified currency.

product

AttributeDescription
productId: StringThe product ID.
sku: StringThe unique identifier for the product.