Search.../

onOrderCanceled( )

Developer Preview

Triggered when an order is canceled.

Description

This webhook is triggered either immediately or at the end of the current payment cycle, as follows:

  • If the order is canceled and effectiveAt is set to IMMEDIATELY, the webhook is triggered immediately when canceled.
  • If the order is canceled and effectiveAt is set to NEXT_PAYMENT_DATE, the webhook is triggered at the end of the current payment cycle. In this case, the Order Auto Renew Canceled Webhook is triggered immediately.

Syntax

function wixPricingPlans_onOrderCanceled(event: OrderCanceledEvent): void

onOrderCanceled Parameters

NAME
TYPE
DESCRIPTION
event
Optional
OrderCanceledEvent

Returns

This function does not return anything.

Return Type:

void

Was this helpful?

onOrderCanceled example

Copy Code
1
2 export function wixPricingPlans_onOrderCanceled(event) {
3 const eventId = event.metadata.id
4 const entityId = event.data.order._id;
5 }
6
7