Webhooks

Receive real-time notifications when events occur in your business.

Introduction

Webhooks allow you to receive HTTP notifications on your server when important events occur, such as:

  • A new booking is created
  • A booking is cancelled
  • A payment is completed
  • A new customer registers

Instead of periodically querying the API (polling), your server automatically receives data when events occur.

1

Event occurs

A customer makes a booking

2

SalonBookIt notifies

We send POST to your URL

3

Your server processes

Updates your system

Configuration

Configure your webhooks from the Dashboard:

  1. Go to Configuration → Integrations
  2. In the section Webhooks, click on Add Webhook
  3. Enter your endpoint URL (must be HTTPS)
  4. Select the events you want to receive
  5. Save and copy the Secret to verify signatures
URL requirements
  • Must use HTTPS (not HTTP)
  • Must be publicly accessible
  • Must respond in less than 10 seconds

Payload format

Each webhook includes the following structure:

JSON
{
    "id": "evt_abc123xyz789",
    "type": "booking.created",
    "created": "2024-01-20T10:30:00Z",
    "tenant_id": "uuid-del-tenant",
    "data": {
        // Event data (varies by type)
    }
}

Webhook fields

Field Type Description
id string Unique event ID (for idempotency)
type string Event type (e.g.: booking.created)
created string ISO 8601 event timestamp
tenant_id string Business UUID
data object Event-specific data

Request headers

Each webhook includes these headers:

Header Description
Content-Type application/json
X-SalonBookIt-Signature HMAC signature to verify authenticity
X-SalonBookIt-Event Event type
X-SalonBookIt-Delivery Delivery ID (for debugging)
X-SalonBookIt-Timestamp Timestamp of when it was sent

Expected response

Your server must respond with a 2xx code (200, 201, 202, 204) to indicate the webhook was received correctly.

HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{"received": true}
Respond quickly

Respond within 10 seconds. If you need to process heavy data, save the event and process it asynchronously.

Retry policy

If your server doesn't respond or returns an error (4xx or 5xx), we automatically retry:

Attempt Wait
1 Immediate
2 5 minutes
3 30 minutes
4 2 hours
5 24 hours (final)

After 5 failed attempts, the webhook is marked as failed and won't be retried. You can see failed webhooks in the Dashboard.

Next steps