Get the door key of a checked-in booking

Bookings

get/api/integrations/{pcode}/kiosk/door-keys/{bookingId}x-api-key

The key of the booking room door, for the kiosk to give the guest at the end of the check-in: whichever lock system the property has, the PIN it issued for this booking is stored here. Only once the booking is checked in: check it in first with PUT /api/bookings/{pcode}/check-in-out/{bookingId}; before that it answers 409 kioskBookingNotCheckedIn, whatever the booking holds, so it never tells whether a booking still to arrive has a PIN. status says what there is: pin with the PIN in pin, as a string with its leading zeros; keyWithoutPin when the booking has a key but no PIN to give (a card, a link, the fixed code of the room, or a lock system that did not return one), so send the guest to reception; and none when no key was issued for the booking or its room has no lock. pin is null unless status is pin. A PIN is usually issued on the arrival day, so a booking checked in without one may get it later: read it again rather than keep it. One booking is one room: in a group, read each booking with its own id. Answers 409 kioskBookingCheckedOut once the booking is checked out, and 409 kioskBookingNotActive for a cancelled booking, a no-show or a block. Every read is recorded in the booking history under your partner name, with the status and never the PIN. The answer is never cached (Cache-Control: no-store): do not store the PIN beyond handing it to the guest. Partner keys only, with this endpoint granted to the connection.

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/integrations/123456/kiosk/door-keys/789

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.

bookingId
number

Booking ID. Obtained from the search endpoints (GET /api/v2/bookings/{pcode}/search) or returned by the booking creation endpoint.

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

bookingId
number

ID of the booking, as it was asked for

KioskDoorKeyStatus

pin: the PIN of the room door is in pin. keyWithoutPin: the booking has a key but no PIN to give the guest (a card, a link, the fixed code of the room, or a lock system that did not return one): reception hands it. none: no key was issued for the booking, or its room has no lock

pin
string

The PIN as the lock system issued it: a string, digits with their leading zeros. Null unless status is pin

Example response
1{
2 "bookingId": 789,
3 "status": "pin",
4 "pin": "0482"
5}

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.