DigitalGuest provides a modern, RESTful API for one-way integration with our guest journey platform. Our open API supports creating and modifying booking objects, using JSON as the data format.
If you would like to inquire about integrating towards our API, then please send your request to integrations@digitalguest.com and we will get back to you.
For development you should use the sandbox environment at
api-dev.digitalguest.com. If you run
into any issues, contact our API support and remember to include the
eventId
from the error response.
To register a new booking, send a POST
request with the booking
information. This should be done before sending any update requests, but it
is not a hard requirement. When the guest checks in, or out, send a PUT
request with state
changed. To cancel the booking, send a DELETE
request. Many of the booking and guest fields are optional, but they should
be filled out if possible.
Standard HTTP status codes along with objects are used to return statuses.
Responses may include additional information in the optional data
field.
All requests may return 400, 401, 403, or 500, so they're excluded from the
examples for brevity.
Code | Message |
---|---|
200 | Success. |
201 | Resource created. |
400 | Bad request, likely due to missing or invalid input. |
401 | Missing or invalid authentication. |
403 | Forbidden. |
404 | The requested resource doesn't exist. |
500 | Internal server error. Contact us if the issue persists. |
propertyId required | string non-empty Example: TheHendrixHotel Property ID. |
bookingId required | string non-empty Example: 8324792 Unique ID used to reference bookings. |
{- "type": "accommodation",
- "state": "expected",
- "arrival": "2020-12-13T14:00:00.000Z",
- "departure": "2020-12-21T11:00:00.000Z",
- "guest": {
- "type": "person",
- "firstName": "First",
- "lastName": "Last",
- "email": "em@il.dk",
- "phone": "+4588888888",
- "language": "da"
}, - "attributes": {
- "bookingNumber": "2b665899-580d-4339-8f43-8ac2a7dbec02",
- "lastUpdate": "2020-12-13T14:15:03.000Z"
}, - "unit": {
- "code": "101-A",
- "type": "Suite"
}, - "rateCode": "BAR2"
}
propertyId required | string non-empty Example: TheHendrixHotel Property ID. |
bookingId required | string non-empty Example: 8324792 Unique ID used to reference bookings. |
type required | string |
state required | string Enum: "expected" "arrived" "departed" "cancelled" Booking state. |
arrival | string <date-time> Arrival date. |
departure | string <date-time> Departure date. |
required | object (Guest) Contact person for the booking.
|
object (Attributes) | |
object | |
rateCode | string Code identifying the booking's rate plan. |
{- "type": "accommodation",
- "state": "expected",
- "arrival": "2020-12-13T14:00:00.000Z",
- "departure": "2020-12-21T11:00:00.000Z",
- "guest": {
- "type": "person",
- "firstName": "First",
- "lastName": "Last",
- "email": "em@il.dk",
- "phone": "+4588888888",
- "language": "da"
}, - "attributes": {
- "bookingNumber": "2b665899-580d-4339-8f43-8ac2a7dbec02",
- "lastUpdate": "2020-12-13T14:15:03.000Z"
}, - "unit": {
- "code": "101-A",
- "type": "Suite"
}, - "rateCode": "BAR2"
}
{- "code": 200,
- "message": "Booking updated.",
- "eventId": "3d4570c3",
- "data": {
- "booking": {
- "type": "accommodation",
- "state": "expected",
- "arrival": "2020-12-13T14:00:00.000Z",
- "departure": "2020-12-21T11:00:00.000Z",
- "guest": {
- "type": "person",
- "firstName": "First",
- "lastName": "Last",
- "email": "em@il.dk",
- "phone": "+4588888888",
- "language": "da"
}, - "attributes": {
- "bookingNumber": "2b665899-580d-4339-8f43-8ac2a7dbec02",
- "lastUpdate": "2020-12-13T14:15:03.000Z"
}, - "unit": {
- "code": "101-A",
- "type": "Suite"
}, - "rateCode": "BAR2"
}
}
}
This endpoint is used to update existing bookings. If the booking doesn't exist, it will be implicitly created, but this should be done with a POST
request if possible.
This endpoint is primarily for changing the booking state. When the guest checks in, state
must be changed to arrived
, and likewise departed
when the guest checks out. Updating the booking is also supported, such as the room number, contact info, and arrival/departure date. The entire booking object gets replaced, so you must include every field that was in the original booking, excluding any fields that should be removed.
If a message needs to be re-sent with different contact info, after state
has already been updated (e.g. if the email contained a typo but the guest already checked in), the booking must be recreated by cancelling it first.
There is a cancelled
state, but should only be used if sending a DELETE request to cancel the booking isn't possible.
propertyId required | string non-empty Example: TheHendrixHotel Property ID. |
bookingId required | string non-empty Example: 8324792 Unique ID used to reference bookings. |
type required | string |
state required | string Enum: "expected" "arrived" "departed" "cancelled" Booking state. |
arrival | string <date-time> Arrival date. |
departure | string <date-time> Departure date. |
required | object (Guest) Contact person for the booking.
|
object (Attributes) | |
object | |
rateCode | string Code identifying the booking's rate plan. |
{- "type": "accommodation",
- "state": "expected",
- "arrival": "2020-12-13T14:00:00.000Z",
- "departure": "2020-12-21T11:00:00.000Z",
- "guest": {
- "type": "person",
- "firstName": "First",
- "lastName": "Last",
- "email": "em@il.dk",
- "phone": "+4588888888",
- "language": "da"
}, - "attributes": {
- "bookingNumber": "2b665899-580d-4339-8f43-8ac2a7dbec02",
- "lastUpdate": "2020-12-13T14:15:03.000Z"
}, - "unit": {
- "code": "101-A",
- "type": "Suite"
}, - "rateCode": "BAR2"
}
{- "code": 200,
- "message": "Booking updated.",
- "eventId": "3d4570c3",
- "data": {
- "booking": {
- "type": "accommodation",
- "state": "expected",
- "arrival": "2020-12-13T14:00:00.000Z",
- "departure": "2020-12-21T11:00:00.000Z",
- "guest": {
- "type": "person",
- "firstName": "First",
- "lastName": "Last",
- "email": "em@il.dk",
- "phone": "+4588888888",
- "language": "da"
}, - "attributes": {
- "bookingNumber": "2b665899-580d-4339-8f43-8ac2a7dbec02",
- "lastUpdate": "2020-12-13T14:15:03.000Z"
}, - "unit": {
- "code": "101-A",
- "type": "Suite"
}, - "rateCode": "BAR2"
}
}
}
This endpoint is for cancelling bookings only, not departures.
propertyId required | string non-empty Example: TheHendrixHotel Property ID. |
bookingId required | string non-empty Example: 8324792 Unique ID used to reference bookings. |
{- "code": 200,
- "message": "Booking deleted.",
- "eventId": "3d4570c3",
- "data": {
- "booking": {
- "type": "accommodation",
- "state": "expected",
- "arrival": "2020-12-13T14:00:00.000Z",
- "departure": "2020-12-21T11:00:00.000Z",
- "guest": {
- "type": "person",
- "firstName": "First",
- "lastName": "Last",
- "email": "em@il.dk",
- "phone": "+4588888888",
- "language": "da"
}, - "attributes": {
- "bookingNumber": "2b665899-580d-4339-8f43-8ac2a7dbec02",
- "lastUpdate": "2020-12-13T14:15:03.000Z"
}, - "unit": {
- "code": "101-A",
- "type": "Suite"
}, - "rateCode": "BAR2"
}
}
}