Skip to main content
All CollectionsIntegrationsAdvanced
Using Webhooks with Appointlet
Using Webhooks with Appointlet

Create advanced automations by integrating with webhooks.

Updated over 7 months ago

One of the most powerful ways to integrate with Appointlet is by using webhooks. If you've ever wanted a custom action to occur after someone books with you, or keep your database in sync with what's happening in Appointlet, webhooks can make it happen.

If you aren't familiar with how webhooks work, you'll want to check out this handy guide from our friends at SendGrid.

What events do webhooks fire for?

We'll send webhooks for a variety of events, such as new bookings, cancelations, and even non-booking events such as when you create/delete/update a meeting type, member or field. Webhooks are fired for many events, you'll want to make sure you inspect the payload to know which event type you're dealing with. More on that below.

How do I setup my webhook URL in Appointlet?

Once you have your webhook URL in hand, you'll need to register it with Appointlet so we know how to reach you. You can do this by going to "Settings" > "Webhooks" > "Add Webhook".

What does the webhook request look like?

The request we send to your registered URL will come in the form of an HTTP POST. The payload will be stored in the body as a JSON-encoded blob.
โ€‹

Here is a sample of what that payload will look like (you can also use a service like webhook.site to setup a URL that will help you inspect the payload):
โ€‹

  "id": 14224744,
"type": "Activity",
"created_at": "2024-05-29T18:56:43.249804Z",
"action": "Meeting.scheduled",
"message": null,
"metadata": null,
"entity": {
"id": 2751918,
"type": "Meeting",
"created_at": "2024-05-29T18:56:43.192873Z",
"name": "Example Meeting Type (Group)",
"location": "123 Address Street",
"location_type": "place",
"start": "2024-06-03T14:00:00Z",
"end": "2024-06-03T14:30:00Z",
"approved": null,
"confirmed": false,
"cancelled": false,
"conference_password": null,
"conference_url": null,
"meeting_type": {
"id": 303445,
"type": "MeetingType",
"name": "Example Meeting Type (Group)"
},
"host": {
"id": 6293498,
"type": "Attendee",
"created_at": "2024-05-29T18:56:43.204913Z",
"email": "email@appointlet.com",
"first_name": "Host First Name",
"last_name": "Host Last Name",
"timezone": "America/Los_Angeles",
"status": "confirmed",
"external_id": "4zL9Q9glF2",
"cancel_url": "https://appt.link/m/4zL9Q9glF2/cancel",
"reschedule_url": "https://appt.link/m/4zL9Q9glF2/reschedule",
"conference_url": "https://appt.link/m/4zL9Q9glF2/conference"
},
"attendees": [
{
"id": 6293499,
"type": "Attendee",
"created_at": "2024-05-29T18:56:43.213943Z",
"email": "test@appointlet.com",
"first_name": "Attendee First Name",
"last_name": "Attendee Last Name",
"timezone": "America/New_York",
"status": "requested",
"external_id": "eORQKVaz88",
"utm_source": "",
"utm_medium": "",
"utm_campaign": "",
"utm_content": "",
"utm_term": "",
"cancel_url": "https://appt.link/m/eORQKVaz88/cancel",
"reschedule_url": "https://appt.link/m/eORQKVaz88/reschedule",
"conference_url": "https://appt.link/m/eORQKVaz88/conference",
"field_submissions": [
{
"name": "Custom Field 1",
"field_type": "text",
"help_text": "Example Help Text",
"required": true,
"choices": null,
"visible": true,
"value": "Answer 1"
},
{
"name": "Custom Field 2",
"field_type": "text",
"help_text": "Example Help Text",
"required": true,
"choices": null,
"visible": true,
"value": "Answer 2"
},
{
"name": "Example Choice Field",
"field_type": "choice",
"help_text": null,
"required": true,
"choices": [
"Choice 1",
"Choice 2",
"Choice 3"
],
"visible": true,
"value": "Choice 3"
}
]
},
{
"id": 6293498,
"type": "Attendee",
"created_at": "2024-05-29T18:56:43.204913Z",
"email": "attendee@appointlet.com",
"first_name": "Attendee First Name",
"last_name": "Attendee Last Name",
"timezone": "America/Los_Angeles",
"status": "confirmed",
"external_id": "4zL9Q9glF2",
"utm_source": null,
"utm_medium": null,
"utm_campaign": null,
"utm_content": null,
"utm_term": null,
"cancel_url": "https://appt.link/m/4zL9Q9glF2/cancel",
"reschedule_url": "https://appt.link/m/4zL9Q9glF2/reschedule",
"conference_url": "https://appt.link/m/4zL9Q9glF2/conference",
"field_submissions": []
}
]
}
}

Take special note of the type and action attributes as they will tell you what event this webhook is related to. If, for example, you only need to take action after new meetings, make sure type === 'Meeting' and action === 'Meeting.scheduled'.

Why am I not receiving my webhook?

If you are expecting webhooks and they aren't coming in, here are a few things to check:

  • Make sure you have your URL entered correctly.

  • Ensure that you're looking at the request's body for the JSON payload and not in your web framework's POST variables (e.g. $_POST)

  • Check your HTTP server logs to see if the requests are getting to your server. They might be getting that far but not all the way to your view or .php file.

  • Remember you can't receive webhooks in your local development environment as it's not web accessible.

Did this answer your question?