Order Failed

Event Key

ootb_order_failed

This event should be sent when a payment or order submission fails—typically due to invalid payment details, declined card, system errors, etc.

Event KeyEvent NameType
ootb_order_failedOrder/Payment FailedSimple 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 Order Failed event:

{
  "context": {
    "ootb_session_id": "248rhdbuw2her1",
    "ootb_userid": "ExampleUser1234",
    "ootb_eventdatetime": "2024-03-09T07:12:00.000Z",
    "ootb_cart_id": "C-8830225XYZ",
    "ootb_order_attempt_id": "ORD-ATT-234235",
    "ootb_failure_reason": "payment_declined",
    "ootb_payment_method": "credit_card",
    "ootb_total_attempted_amount": 50.00,
    "ootb_currency": "USD",
    "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 TimeTimestampTime when the failure occurred.
ootb_cart_idCart IDStringCart associated with the failed attempt.
ootb_order_attempt_idOrder Attempt IDStringUnique ID of the failed order attempt.
ootb_failure_reasonFailure ReasonStringHigh-level reason for failure (e.g., payment_declined, timeout).
ootb_payment_methodPayment MethodStringMethod attempted for payment (e.g., credit_card, paypal).
ootb_total_attempted_amountTotal Attempted AmountNumberTotal value attempted for payment.
ootb_currencyCurrencyStringCurrency used during the attempt (e.g., USD).
ootb_fullfillment_typeFulfillment TypeEnumbopis or standard_delivery — used for follow-up actions.

Explanation

  • event: Set to ootb_order_failed to indicate an order or payment submission has failed.
  • context:
    • ootb_session_id, ootb_userid: Link the failure to the user’s session and identity.
    • ootb_eventdatetime: Timestamp when the failure occurred.
    • ootb_cart_id, ootb_order_attempt_id: Identify which cart and which attempt failed.
    • ootb_failure_reason: Provides the code or message explaining why the order failed.
    • ootb_payment_method, ootb_total_attempted_amount, ootb_currency: Capture the attempted payment method, amount, and currency.
    • ootb_fullfillment_type: Indicates whether the intended order was for in-store pickup (bopis) or standard delivery.