Triggered when a referring customer is created.
function onReferringCustomerCreated(handler: function): void;
handler(event: ReferringCustomerCreatedEnvelope): void | Promise<void>
import { customers } from "@wix/referral";
customers.onReferringCustomerCreated((event) => {
// handle your event here
});