chilly-television-36470
10/27/2023, 7:23 PMmillions-activity-52391
10/27/2023, 7:23 PMchilly-television-36470
10/27/2023, 7:23 PM/***
* This transformation allows events to reach a downstream destination only if a specific property
* contains certain values, e.g., allow only Product Added, or Order Completed events, or send
* certain event types to a particular destination, or only send events that do not have
* tracking plan to a specific destination
***/
export function transformEvent(event, metadata) {
const property = event.event; // Edit event name
const allowlist = ["registered", "identify", "Order Completed", "added_to_cart", "attended", "call_to_action" ]; // Edit allowlist contents
if (!property || !allowlist.includes(property)) return;
return event;
}chilly-television-36470
10/27/2023, 8:05 PMmillions-activity-52391
10/30/2023, 12:14 PM const property = event.event; // Edit event name`
` if (property === "identify") return event;`
` const allowlist = ["registered", "identify", "Order Completed", "added``_to_``cart", "attended", "call``_to_``action" ]; // Edit allowlist contents`
` if (!property || !allowlist.includes(property)) return;`
` return event;`
`}`millions-activity-52391
10/30/2023, 12:16 PMchilly-television-36470
11/03/2023, 9:18 PMshy-kite-21035
11/06/2023, 11:01 AMexport function transformEvent(event, metadata) {
const property = event.event; // Edit event name
if (property === "identify") return event;
const allowlist = ["registered", "identify", "Order Completed", "addedtocart", "attended", "calltoaction"]; // Edit allowlist contents
if (!property || !allowlist.includes(property)) return;
return event;
}shy-kite-21035
11/06/2023, 11:11 AM" to similar to double quotes. Though they look similar they are not the same.chilly-television-36470
11/14/2023, 7:31 PMmillions-activity-52391
11/15/2023, 1:03 PM