All Collections
Technical Documentation
The enterprise booking widget
Listening for events in the enterprise booking widget
Listening for events in the enterprise booking widget
Jubrine Fortuno avatar
Written by Jubrine Fortuno
Updated over a week ago

Find further details of the enterprise widget here. The enterprise booking widget cannot be created at so is currently available only through account management. If you would like to use the enterprise widget, get in touch through the support messenger.

You can listen for some events which are emitted by the widget iframe. 

Events which can be listened for include:

  1. booking_created
    Triggered when a booking is created in the widget.

  2. ready
    Triggered when the booking flow has been injected into the website and finished loading.

  3. user_engaged
    Triggered the first time the user engages with the booking flow.  It is considered an engagement when the user clicks or taps on anything within the flow.


appointeddWidget.on('booking_created', function(data){
// will contain booking information

booking_created can be used for a variety of reasons e.g. where you want to perform your own conversion tracking, or redirect to a new page when a booking is made.  

With the booking_created event, the booking data is passed back to the event callback. This allows you to access data about the booking.  An example of what this booking object can look like:

"booking": {
"id": "5c7f809db04deeaaad473af2",
"organisation_name": "Mamas & Papas - Fort Kinnaird",
"organisation_id": "55c36b5edda1dd93b7d63af1",
"service_id": "5bae0d0bb04deedd034788f2",
"service_name": "Personal shopping",
"resource_id": "595501f247ade12f2da26b07",
"start_time": "2019-02-17T01:30:00+00:00",
"end_time": "2019-02-17T02:00:00+00:00",
"timezone": "Europe/London",
"customer": {
"id": "598d8b2f9e8dd9d9530041a7",
"profile": {
"firstname": "Greg",
"lastname": "Dickson",
"email": "",
"mobile": "447594942941"
"custom_fields": { "membership_id": 12345 },
"questions": [
{ "Where did you hear about us?": "Social media" }

Please note: The widget needs to load first, before the tracking code is loaded. This note is important in particular when you load your scripts through Google Tag Manager that is in the header of your webpage.

If you have any feedback we would love to hear it 👂

Did this answer your question?