Items in Cart

Event Key

ootb_items_in_cart

This event should be sent periodically or during key interactions (e.g., session refresh, product page visit, scroll) to capture the current state of the user’s cart.

Event KeyEvent NameType
ootb_items_in_cartItems in CartSimple event

Event Structure

The mandatory properties (tenant, timestamp, event, and customer) are required for all events and documented in detail on the Mandatory Properties page. Below is the JSON structure for the context-specific properties of the Items in Cart event:

[
  {
    "context": {
      "ootb_session_id": "248rhdbuw2her1",
      "ootb_userid": "ExampleUser1234",
      "ootb_eventdatetime": "2024-03-09T06:55:00.000Z",
      "ootb_cart_id": "C-20244030X",
      "ootb_item_count": 3,
      "ootb_currency": "USD",
      "ootb_total_cart_value": 92.5,
      "ootb_discount_percentage": 5,
      "ootb_tax_amount": 6,
      "ootb_delivery_fee": 4.99,
      "ootb_fullfillment_type": "standard_delivery"
    }
  }
]

Parameters

Parameter KeyParameter NameTypeDescription
ootb_session_idSession IDStringUser’s browser session identifier.
ootb_useridUser IDStringUnique key identifying the user.
ootb_eventdatetimeEvent Date TimeTimestampTimestamp when this cart snapshot was sent.
ootb_cart_idCart IDStringIdentifier for the cart.
ootb_item_countItem CountNumberNumber of items in the cart.
ootb_currencyCurrencyStringCurrency code used for prices (e.g., USD).
ootb_total_cart_valueTotal Cart ValueNumberCurrent total value of the cart.
ootb_discount_percentageDiscount PercentageNumberDiscount applied to cart, if any.
ootb_tax_amountTax AmountNumberEstimated tax on the cart.
ootb_delivery_feeDelivery FeeNumberEstimated delivery or shipping fee.
ootb_fullfillment_typeFulfillment TypeEnumbopis or standard_delivery to indicate fulfillment method.

Explanation

  • event: Set to ootb_items_in_cart to indicate a snapshot of the user’s shopping cart.
  • context:
    • ootb_session_id, ootb_userid: Link the cart snapshot to the user’s session and identity.
    • ootb_eventdatetime: When this cart state was recorded.
    • ootb_cart_id, ootb_item_count, ootb_total_cart_value: Core cart identifiers and metrics.
    • ootb_currency, ootb_discount_percentage, ootb_tax_amount, ootb_delivery_fee: Pricing context including discounts, tax, and shipping estimates.
    • ootb_fullfillment_type: Captures whether the cart is for in-store pickup (bopis) or standard delivery.