Webhooks and the API
Send leads, bookings and finished conversations to your own systems, and check each message is really from Frontling.
Where this stands: Webhooks and the Webhooks page are built and work on Growth and Agency. There is no public API for reading or changing your data yet: webhooks are how data leaves Frontling.
What it does
A webhook sends a message to a web address of yours each time something happens, for example a new lead. Use it to put leads in your CRM or a spreadsheet, or to start an automation in a tool like Zapier.
Webhooks need the Growth or Agency plan. Only owners and admins can use the Webhooks page. You can have up to 10 endpoints: the page shows how many you have used, for example "1 of 10 endpoints used".
On a plan without webhooks the page still opens, with a yellow note: "Your plan does not include webhooks, so endpoints cannot be added or tested." Add endpoint and Send test event are greyed out. Press See plans to change plan.
The events
| Event | Sent when |
|---|---|
lead.created |
The assistant takes down a new lead |
booking.created |
A booking is made |
booking.rescheduled |
A visitor moves a booking |
booking.cancelled |
A booking is cancelled |
conversation.ended |
A chat has been quiet for 30 minutes |
webhook.test |
You press Send test event |
Add an endpoint

- Open Webhooks in the sidebar. You land on the Webhooks page, with a box called Endpoints.
- Press Add endpoint.
- Fill in Endpoint URL: the web address of your CRM, script or Zapier hook. It must start
https://. - Add a Description if you like, for example "Lettings CRM".
- Under Events to send, untick anything you don't want. All of them start ticked.
- Press Add endpoint.
A box called Your signing secret opens. The secret starts whsec_. It is shown once: press Copy secret, put it in your password manager, then press I have saved it.
The endpoint now shows in the list with its events as tags, and three buttons: Delivery log, Send test event and Edit.
If the address is refused, the box tells you why:
- "The URL points at a private, local or reserved address." Use a public address.
- "hooks.harlowfinch.example could not be found." Check the spelling.
How to try it
- On the Webhooks page, press Send test event under your endpoint.
- Wait a few seconds.
You should see a green note: "Test event delivered. Your endpoint answered 200 in 120 ms." Your system gets a webhook.test message.
If your system didn't accept it, the note is red and says what it answered, for example "Test event failed. Your endpoint answered 405." The start of its answer is shown underneath.
The delivery log
Press Delivery log under an endpoint. It lists every message sent there, newest first, each tagged Delivered, Failed or Retrying. Use the buttons at the top to show only one kind.
Press a message to open it. You see:
- its Event id, how many Attempts and when it was Last tried;
- What we sent: the headers and the message itself;
- What your endpoint answered: the status and the start of its answer.
Press Send again to resend it. You see "Sent again, and your endpoint accepted it." or "Sent again, but it failed."
Press All endpoints to go back.
Change, pause or remove an endpoint
Press Edit under an endpoint. You can change the address, the description and the events, then press Save.
- Send events to this endpoint: switch it off to pause the endpoint. It shows Switched off in the list.
- Renew secret: makes a new secret. You are asked "Renew the signing secret?" first, because the old one stops working at once. The new one is shown once, like the first.
- Remove endpoint: you are asked "Remove this endpoint?" first. Its secret and delivery log are deleted too.
What a message looks like
Every message is JSON, with a type, a unique id, a created_at time and the record in data. Headers say which event it is and carry a signature.
Check it's from us
Each message has a Frontling-Signature header: a time, and a code made from that time and the exact message with your signing secret. To check it:
- Read the raw message body before doing anything else with it.
- Make the code yourself with your secret and compare.
- Refuse a message whose time is more than 5 minutes from your clock.
Sample code in PHP and Node is in the developer guide, in docs/webhooks.md.
If your system is down
Answer with any 2xx within 10 seconds. If you don't, Frontling tries again after 1 minute, 5 minutes, 30 minutes, 2 hours, 6 hours and 15 hours. After that it is marked failed and owners and admins are emailed, at most once a day for each endpoint. You can send a failed one again with Send again in the delivery log. Keep the same id in mind: a resend has the same id, so ignore ids you have already handled.
Messages aren't guaranteed to arrive in order. Use the times inside data.
Good to know
- Only
httpsaddresses on the public internet are accepted. Addresses inside a private network are refused. - The delivery log keeps 30 days.
- Renewing a secret stops the old one working at once.
Something not working in Frontling, or an idea for it? Report a problem from your dashboard.