Create webhook

Webhooks

post/api/webhooks/{pcode}x-api-key

Register a URL to be called when an event happens. It starts receiving deliveries immediately. What to expect on your endpoint: a POST with a JSON body, Content-Type: application/json, and an Authorization: Basic header when you configure credentials here. Redirects are not followed — register the final URL, not one that redirects to it — and **a failed delivery is not retried**: it is recorded in the delivery log and dropped, so treat the webhook as a notification to act on, not as a guaranteed feed. There is no delivery timeout, and the deliveries of one property go out one after another, so a slow answer delays the next webhook: answer quickly and do your work afterwards. Use /test once the webhook exists to check its URL is reachable before relying on it.

Console

Runs against the API from your browser, with the same request your server will send.

Environment

Production

https://uni-api.hotelgest.com

Calls hit live data with your own API key. A POST, PUT, PATCH or DELETE here changes a real property.

Credentials

The API key, sent on every request. A property admin creates it in the PMS under Settings → API keys; a partner receives one per property when the property activates its integration. It works only for the property it was issued for, and only on the endpoints granted to it.

This endpoint needs a credential. Without it you will get a 401.

Stored in this browser only. Never sent anywhere but the API host above.

Path parameters

Body

Arm production

Writing methods are locked until you arm them. This is live hotel data.

POST is locked on production. Arm it above if you mean it.

posthttps://uni-api.hotelgest.com/api/webhooks/123456

Send the request to see the real response here.

Nothing is mocked. What comes back is what the API returned.

Requests go straight from your browser to the API host above — nothing is proxied through this site.

Path parameters

pcode
number

Property code. Identifies the property (hotel, apartment building, hostel) the request applies to. It must match the property your API key was issued for.

Request body

name
string

Name

url
string

Url

eventTypes
enum[]

List of event types

One of:bookings-added

Authentication

Authentication details

Example
1{
2 "name": "My Webhook",
3 "url": "https://mywebhook.com",
4 "eventTypes": [
5 "bookings-added"
6 ],
7 "authentication": {
8 "status": true,
9 "username": "myUser",
10 "password": "myPassword"
11 }
12}

Responses

Created.

—

What is a pcode?

The property code. Every endpoint is scoped to one property, and your API key only works for the property it was issued for.

Rate limits

100 requests per minute per source IP, 120 per API key and 300 per property, each counted across every endpoint together — not per endpoint. Over any of them you get a 429 with the seconds to wait in Retry-After-<limit> (apikey-ip, apikey or apikey-pcode): stop and wait it out. Repeat offences on a key or a property are blocked for longer each time, up to 7 days.