Add to Wishlist

Reports that a user added a product to their wishlist.

Optional event. Use if your users can add items to a wishlist, and you want to track this behavior.

Parameters

  • name: Human-readable name, not used to identify an event type
  • properties: A container for the event properties as specified in the following table:
PropertyDescriptionType
dyTypeMust be "add-to-wishlist-v1"String
productIdThe product SKUString
size
Optional
Product sizeString

Example: Implementation via script

DY.API("event", {
  name: "Add to Wishlist",
  properties: {
    dyType: "add-to-wishlist-v1",
    productId: "item-34454",
    size: "XL"
  }
});

Example: Implementation via Experience API (server-side)

״events״:[
{           
  "name": "Add to Wishlist",           
  "properties": {
    "dyType": "add-to-wishlist-v1",
    "productId": "item-34454",
    "size": "XL"
  }
} 
]  

👍

Go to the API reference for the Events endpoint to learn more.