Skip to main content
All CollectionsDashboardConnections
How to Trigger Third-Party Notifications Using Webhooks
How to Trigger Third-Party Notifications Using Webhooks

Send custom emails created in third-party apps using webhooks.

Lucia Burin Sestakova avatar
Written by Lucia Burin Sestakova
Updated over a week ago

Ventrata's webhook functionality enables third-party apps to receive real-time notifications whenever a booking is updated, cancelled, rescheduled or changed. These events can then be used to trigger emails from external platforms.

πŸ“— TIP

Ventrata has direct integration with Postmark and Mailjet, which can be used with the campaigns feature. If you are using any of these services, you can send some transactional emails without setting up webhooks.


Order and Booking Emails

To send booking-related emails via a third-party app, use the booking_update webhook.

This webhook contains a diff object, which highlights changes made to the booking:

{ 
"diff": [
{
"op": "replace",
"was": "ON_HOLD",
"path": "/status",
"value": "CONFIRMED"
}
],
"booking":
{
..the booking object..
}
}

By checking /status in the diff object, different types of emails can be triggered.

Email Type

/status Value

Description

Order Confirmation Email

"CONFIRMED"

status changing from any value to confirmed should be treated as a new confirmation

Order Cancellation Email

"CANCELLED"

status changing from any value to cancelled should be treated as a cancellation

Order Update Email

"CONFIRMED"

any booking where /status does not change, but booking.status=CONFIRMED, can be used to trigger a booking update email

Order Recovery Email

"EXPIRED"

status changing from any value to expired should be treated as a newly expired booking;

if contact details on the booking exist, you can contact the customer to recover the order

πŸ“— TIP

You can also create email templates directly within Ventrata's built-in editor without the use of webhooks.


Transactions & Ticket Changes

To send notifications about refunds and ticket changes, use the order_update webhook.

This webhook's payload contains transactional and ticket changes data within its diff object:

{ 
"diff": [
{
"op": "remove",
"was": {
..the cancelled boo object..
},
"path": "/bookings/0"
},
{
"op": "remove",
"was": {
..cancelled voucher object..
},
"path": "/voucher/deliveryOptions/1"
}
]

πŸ“— TIP

Since the response body contains a host of information, we recommend setting up the webhook and running some tests transactions in the backoffice. Based on the response data, you can decide which fields to use to trigger your messaging workflows.


Methods

1. Using the OCTO API

Ventrata uses the OCTO API standard, which allows you to configure webhooks programmatically.

Refer to the Ventrata OCTO API documentation for implementation details.

2. Using the Ventrata Dashboard

If you have at least one connection configured in the Ventrata dashboard, you can set up a new webhook using the dashboard interface.

You can configure a webhook using one of the following events:

  • Order Update - triggered when a transaction is added to an order or customer details are updated

  • Booking Update - triggered when a booking is confirmed, updated or cancelled

  • Availability Update - triggered when availability changes

  • Product Update - triggered when product details are modified

Learn more about setting up webhook in the Ventrata dashboard in this article.

Did this answer your question?