This guide is for setting up Webhooks to receive data from Repairy.Why use Webhooks#
Webhooks are a powerful way to receive updates about events that occur in Repairy. Webhooks allow you to automate responses to specific events without the need for continuous polling.
This document will guide you through setting up and using webhooks effectively.To enable webhook events, you need to configure and enable webhook endpoints. After registration, Repairy will push real-time event data to your webhook endpoint when events happen in your Repairy account.HTTP Methods#
Webhooks can be sent using available Http Methods as follows:The following headers are sent with every webhook:Content-Type: Will always be application/json
x-request-id: A unique identifier for this delivery
x-webhook-id: A unique identifier for this webhook delivery attempt
x-webhook-signature: The webhook security signature for this delivery (see Secure your Webhook below)
x-webhook-timestamp: The webhook timestamp in seconds since epoch
x-webhook-version: The Repairy webhook version specification. Currently, will be 3.
HTTP Request Body#
The payload has the following top level JSON properties:id: webhook event unique id
action: webhook action event key
timestamp: timestamp to help you produce signature for request verification
Webhook Actions#
Every webhook events will have their own unique actions that you can subscribe and configure it based on your prefered destination URL and Http Method.
The following actions are supported:bookingCreate: Webhook event when a new booking is created
bookingUpdated: Webhook event when an existing booking is updated
bookingCancelled: Webhook event when an existing booking is cancelled
bookingCompleted: Webhook event when an existing booking is marked as completed
Webhook Payload#
HTTP Timeout#
Repairy will send the webhook event with a 10 seconds timeout.
It is highly recommended that you acknowledge the request first before processing the webhook events to avoid timeout failure.Secure your Webhook#
To verify the authenticity of webhooks delivered by Repairy we use hashed signature with pre-shared secret key which can be obtained from your Webhook Settings in Repairy Dashboard.Signature scheme#
We sign and put the signature in every webhook request headers using the key x-webhook-signature.In order to verify you need to recompute your own hash and copmare it with the signature in the header.To recompute and produce your own signature hash you must build a simple string using this format.
Keep in mind that the order is important and should not contained white spaces.key|action|id|bookingId|workshopId|timestamp
with details on how to get each values as follows,key: secret key which can be obtained from Repairy Dashboard
action: webhook action obtained from request body
id: webhook id obtained from request body
bookingId: booking ID obtained from payload.id
workshopId: obtained from payload.workshopId
timestamp: webhook action obtained from request body
Once you combine the string value, you have to hash it using MD5 hash algorithm.This is a high level example on how to verify signature using javascript// your webhook key
const key = 'webhookKey';
// populate the payload string (order is important)
const body = await request.json();
const { id, action, payload, timestamp } = body;
const { bookingId, workshopId } = payload;
const payloadString = [
key,
action,
id,
bookingId,
workshopId,
timestamp,
].join('|')
// calculate the signature
const signature = crypto
.createHash('md5')
.update(payloadString)
.digest('hex')
.toString()
// verify the signature
if (signature !== request.headers['x-repairy-signature']) {
return new Response('Unauthorized', { status: 401 });
}
To configure webhooks use Repairy Dashboard Settings page and go to the Webhook section under the Integrations submenu.Webhook Logs#
Inspect your webhooks events by using the Webhook Logs page from the settings page.Testing your Webhook#
For testing, we recommend one of the following services to test webhook delivery payloads: Modified at 2025-06-12 08:22:56