onOrderCanceled( )


An event that triggers when an order is canceled.

The onOrderCanceled() event handler runs either immediately when an order is canceled IMMEDIATELY or at the end of the current payment cycle when an order is set to cancel at the NEXT_PAYMENT_DATE. The received OrderCanceledEvent object contains information about the canceled order.

The onOrderCanceled() event will not trigger immediately when the order is canceled with effectiveAt as NEXT_PAYMENT_DATE. In that case, the onOrderAutoRenewCanceled() event will trigger immediately and the onOrderCanceled() event will trigger following the current payment cycle.

Note: Backend events don't work when previewing your site.

Method Declaration
Copy
Method Parameters
eventOrderCanceledEventRequired

Information about the canceled order and metadata for the event.

Was this helpful?
Yes
No