Question:
Hi All,
I’m trying to capture an event when an order is being paid (in my case i’m using Wix Bookings). I want first to capture event when an order is marked as PAID from the backend… i tried all possible Api events, so far nothing is firing… please help
// Place this code in the events.js file
// of your site's Backend section.
// export function <wixAppName>_<eventName>(event) { }
//import wixStoresBackend from 'wix-stores-backend';
//import wixData from 'wix-data';
export function wixPricingPlans_onPlanPurchased(event) {console.log("wixPricingPlans_onPlanPurchased Fired! : ", event)}
export function wixPricingPlans_onOrderPurchased(event) {console.log("wixPricingPlans_onOrderPurchased Fired! : ", event)}
export function wixPricingPlans_onOrderMarkedAsPaid(event) {console.log("wixPricingPlans_onOrderMarkedAsPaid Fired! : ", event)}
export function wixPricingPlans_onOrderStarted(event) {console.log("wixPricingPlans_onOrderStarted Fired! : ", event)}
export function wixPricingPlans_onOrderEnded(event) {console.log("wixPricingPlans_onOrderEnded Fired! : ", event)}
export function wixBookingsBackend_onBookingConfirmed(event) {console.log("wixBookingsBackend_onBookingConfirmed Fired! : ", event)}
export function wixPricingPlansBackend_onOrderMarkedAsPaid(event) {console.log("wixPricingPlansBackend_onOrderMarkedAsPaid Fired! : ", event)}
export function wixBillingBackend_onInvoicePaid(event) {console.log("wixBillingBackend_onInvoicePaid Fired! : ", event)}
export function wixPricingPlansBackend_onOrderPurchased(event) {console.log("wixPricingPlansBackend_onOrderPurchased Fired! : ", event)}
export function wixStoresBackend_onOrderPaid (event) {console.log("wixStoresBackend_onOrderPaid Fired! : ", event)}
export function wixEcomBackend_onOrderPaymentStatusUpdated(event) {
try {
console.log('wixEcomBackend_onOrderPaymentStatusUpdated Fired! - Order payment status updated', event)
} catch (error) {
console.log("Error creating Review", error);
}
}