📤JavaScript Events
RevenueHero JavaScript events are sent from the scheduler at different stages. Learn about those events that can be used to trigger downstream activities.
window.addEventListener("message", (ev) => {
if (ev.data.type == "MEETING_BOOKED") {
// Send to Google Analytics
dataLayer.push({ event: "meeting_booked" });
// Send to pixel
fbq("track", "RevenueHero", { event: "meeting_booked" });
}
});MEETING_BOOKED
{
"type": "MEETING_BOOKED",
"meeting": {
"id": "1234",
"attributes": {
"booker_name": "John Smith",
"booker_email": "[email protected]",
"phone_number": "+11234567890",
"booker_company_name": "Acme, Inc",
"country_code": "US",
"calendar_type": "calendly",
"meeting_time": "2023-11-24T05:30:00.000Z",
"created_at": "2023-11-24T05:30:00.000Z",
"booking_guests": ["[email protected]"],
"booked_with_name": "Jane Doe",
"booked_with_email": "[email protected]"
}
}
}Last updated
Was this helpful?