Get custom cancellation policies

Properties

get/api/properties/{pcode}/settings/custom-policiesx-api-key

The cancellation policies this property has defined for itself, each with its ID and its name in every language the panel supports (all nine keys always present; an empty string where it has no translation). Use an ID from here as the policy of a room when creating a booking, and to resolve the policy that bookings come back with. The two built-in policies are NOT listed, because every property always has them: 4 (flexible cancellation) and 6 (non-refundable). Expect to see those two IDs on bookings even though they never appear in this response. Policies change rarely — fetch once and keep.

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

gethttps://uni-api.hotelgest.com/api/properties/123456/settings/custom-policies

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.

Responses

Ok. If your API key answers encrypted — every key issued now does, and every partner credential — this body arrives as the encryption envelope ({ crypto, protected, wrappedKey, iv, payload, tag }, a compact JWE), and the schema below is what its payload decrypts to. See https://public-api.hotelgest.com/public/guides/encryption

policy
string

Unique identifier of the custom cancellation policy. Note: built-in policies "4" (Flexible Cancellation) and "6" (Non-Refundable) are always available and will not appear in this list.

PolicyDescriptionDto

Policy name in every panel language. All nine keys are always present; a language with no translation is an empty string

Example response
1[
2 {
3 "policy": "7",
4 "name": {
5 "ca": "Cancel·lació gratuïta fins a 7 dies abans",
6 "de": "Kostenlose Stornierung bis 7 Tage vorher",
7 "en": "Free cancellation up to 7 days before",
8 "es": "Cancelación gratuita hasta 7 días antes",
9 "eu": "Doan gabeko bertan behera uztea 7 egun lehenago",
10 "fr": "Annulation gratuite jusqu'à 7 jours avant",
11 "gl": "Cancelación gratuíta ata 7 días antes",
12 "it": "Cancellazione gratuita fino a 7 giorni prima",
13 "ru": "Бесплатная отмена за 7 дней"
14 }
15 }
16]

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.