Use the bathroom endpoints in the Facilities API to manage bathroom facilities in a property.
You can:
- create, update or delete bathroom facilities.
- retrieve bathroom facility details for a property.
PUT
https://supply-xml.booking.com/facilities-api/properties/{propertyId}/rooms/{roomId}/bathroomsWhen creating or updating a bathroom facility, the request body differs based on whether the property is one of the following types:
- Hotels
- Homes
- Hostels
For example, Apartment is classified as a Homes property type. To determine whether a property is classified as a hotel or home and get their respective OTA and Booking.com property codes, see Booking.com property codes.
When creating, updating or deleting bathroom facilities for properties that are categorised as Hotels, consider the following:
- You cannot edit specific bathrooms using IDs because you cannot create multiple bathroom instances.
- You can select only two bathroom states:
shared_bathroom_state(PRESENT or MISSING)private_bathroom_state(PRESENT or MISSING)
- Specify the total number of bathrooms attached to the room using
hotel_bathroom_details.number_of_bathrooms.
The following table describes the elements you must specify in the path:
| Element | Description | Type | Required/ Optional | Notes |
|---|---|---|---|---|
propertyId | Specifies the unique ID of the property. | integer | required | Must be valid and connected to your account. |
roomID | Specifies the unique ID of the room to which the bathroom facility is added or updated. | integer | required | Must belong to the property. |
{
"hotel_bathroom_details": {
"shared_bathroom_state": "MISSING",
"private_bathroom_state": "PRESENT",
"private_bathroom_details": {
"type": "EXTERNAL_BATHROOM",
"location_type": "OTHER",
"location_other": "outside of the room"
},
"number_of_bathrooms": 2
}
}For more examples, see the Bathrooms Open API specification under the Try it section.
The following is a response snippet with a success message:
{
"data": {
"success": true
},
"warnings": [],
"errors": [],
"meta": {
"ruid": "g497d724-54bb-4b48-8274-fafb59le127"
}
}To delete all bathroom facilities for a hotel:
- Set both
hotel_bathroom_details.shared_bathroom_stateandhotel_bathroom_details.private_bathroom_statetoMISSING. - Set
hotel_bathroom_details.number_of_bathroomsto0.
For example:
{
"hotel_bathroom_details": {
"shared_bathroom_state": "MISSING",
"private_bathroom_state": "MISSING",
"number_of_bathrooms": 0
}
}When creating or updating bathroom facilities for properties that are categorised as Homes and Hostels, consider the following:
- You can create multiple bathroom instances.
- If
bathrooms[0].id:{{ID}}is specified, then the endpoint updates the specified bathroom corresponding to the ID. - If
bathrooms[].idis not specified, then the endpoint creates a new bathroom.
{
"property_bathroom_details": {
"bathrooms": [
{
"bathroom_type": "PRIVATE",
"bathroom_location": "ENSUITE"
},
{
"bathroom_type": "SHARED",
"bathroom_location": "OPPOSITE_THE_ROOM"
}
]
}
}For more request body examples, see the Bathrooms Open API specification under the Try it section.
{
"property_bathroom_details": {
"bathrooms": [
{
"id": 4823,
"bathroom_type": "PRIVATE",
"bathroom_location": "ENSUITE",
"hostel_bathroom_details": {
"bathroom_facilities": [
{
"type": "SHOWER",
"count": 1
},
{
"type": "TOILET",
"count": 1
},
{
"type": "SINK",
"count": 1
},
{
"type": "TOILET_PAPER"
},
{
"type": "SHAMPOO",
"is_paid": false
}
]
}
}
]
}
}For more request body examples, see the Bathrooms Open API specification under the Try it section.
Note that the endpoint deletes any missing bathroom configuration in the request body. For example, if bathrooms[0].id:12345 is missing from the payload, then the endpoint deletes the bathroom facility with the ID 12345.
When you update bathroom facilities make sure to provide all existing bathroom definitions. Note that because the endpoint uses the overlay mode, failing to specify any existing definitions will lead to the endpoint overwriting the existing definition with what you provide.
To delete all bathrooms: Provide an empty list in the payload. For example, property_bathroom_details.bathrooms:[]
This section lists the validation rules you should keep in mind when managing bathroom facilities.
Make sure to specify the following required fields:
hotel_bathroom_detailshotel_bathroom_details.shared_bathroom_state: [PRESENT | MISSING]hotel_bathroom_details.private_bathroom_state: [PRESENT | MISSING]hotel_bathroom_details.number_of_bathrooms
Constraints:
- The
number_of_bathroomsmust be within (0-20) - If
bathroom_stateis all MISSING,number_of_bathroomsshould be 0 - If
bathroom_statecontains PRESENT,number_of_bathroomsshould be > 0
Make sure to specify the following required fields:
property_bathroom_detailsproperty_bathroom_details.bathrooms[*].bathroom_type: [SHARED | PRIVATE]property_bathroom_details.bathrooms[].size: must be (0-20)property_bathroom_details.bathrooms[*].bathroom_locationis optional and if specified allowed options depends on unit_type (room_type) please refer to /meta endpoint to checkbathroom_configurations[*].allowed_options
Make sure to specify the following required fields:
property_bathroom_detailsproperty_bathroom_details.bathrooms[*].bathroom_type: [SHARED | PRIVATE]property_bathroom_details.bathrooms[*].bathroom_location: [ENSUITE | NEXT_DOOR | DOWN_THE_HALL | OPPOSITE_THE_ROOM | IN_THE_HALLWAY | OTHER]property_bathroom_details.bathrooms[*].hostel_bathroom_detailsproperty_bathroom_details.bathrooms[*].hostel_bathroom_details.bathroom_facilities[*]
Constraints:
- Property type
HOSTELonly allows:- 0-1 private bathrooms
- 0-5 shared bathrooms
property_bathroom_details.bathrooms[*].hostel_bathroom_details.bathroom_facilities[*]requires at least 1 of [SHOWER, TOILET, SINK, BATH]property_bathroom_details.bathrooms[*].hostel_bathroom_details.bathroom_facilities[*].countrequired for [SHOWER, TOILET, SINK, BATH]property_bathroom_details.bathrooms[*].hostel_bathroom_details.bathroom_facilities[*].countonly allowed forbathroom_facilities[*].type: [SHOWER, TOILET, SINK, BATH]property_bathroom_details.bathrooms[*].hostel_bathroom_details.bathroom_facilities[*].is_paidonly allowed forbathroom_facilities[*].type: [SLIPPERS, TOOTHBRUSH, SHAMPOO, CONDITIONER, BODY_SOAP, TOWEL]- For private bathrooms:
num_guests_with_access_typenot allowedgendernot allowed
- For shared bathrooms:
num_guests_with_access_typerequiredgenderrequired
Click to view the parameter descriptions and their details. You can also see more information under the Body section of the API specification.
| Element | Description | Type | Required/ Optional | Notes | Root parameter in HDCN |
|---|---|---|---|---|---|
property_bathroom_details | Container for property-type bathroom details. | object | Optional | Used for property-type accommodations | - |
> bathrooms | Contains a list of bathroom configurations. | array | Required if using property_bathroom_details | Maximum 20 bathrooms | - |
>> bathroom_type | Specifies if bathroom is private or shared. | string | Required | Enum: PRIVATE, SHARED | - |
>> bathroom_location | Specifies the location of the bathroom. | string | Optional | Enum: ENSUITE, NEXT_DOOR, DOWN_THE_HALL, OPPOSITE_THE_ROOM, IN_THE_HALLWAY, OTHER, INSIDE_THE_UNIT | - |
>>hostel_bathroom_details | Contains hostel-specific bathroom details. | object | Optional | Only applicable for hostel properties | - |
>>>gender | Specifies the gender designation for the bathroom. | string | Optional | Enum: FEMALE, MALE, MIXED | - |
>>>num_guests_with_access_type | Specifies the number of guests with access. | string | Optional | Enum: NUMBER_LESS_THAN_5, NUMBER_5_TO_10, NUMBER_11_TO_20, NUMBER_21_TO_30, NUMBER_31_TO_40, NUMBER_41_TO_50, NUMBER_MORE_THAN_50 | - |
>>>bathroom_facilities | Specifies the list of facilities in the bathroom. | array | Required if using hostel_bathroom_details | - | - |
>>>>>> type | Specifies the type of facility. | string | Required | Enum: SHOWER, TOILET, SINK, BATH, TOILET_PAPER, HAIR_DRYER, SLIPPERS, BIDET, TOOTHBRUSH, SHAMPOO, CONDITIONER, BODY_SOAP, TOWEL, HOT_WATER | - |
>>>>>> count | Specifies the number of this facility type. | integer | Optional | Min: 1, Max: 100 | - |
>>>>>> is_paid | Specifies whether the facility is paid. | boolean | Optional | - | - |
hotel_bathroom_details | Container for hotel-type bathroom details. | object | Optional | Used for hotel-type accommodations | - |
> shared_bathroom_state | Indicates if shared bathroom is available. | string | Required if using hotel_bathroom_details | Enum: MISSING, PRESENT | - |
> private_bathroom_state | Indicates if private bathroom is available. | string | Required if using hotel_bathroom_details | Possible values are: MISSING, PRESENT | - |
> number_of_bathrooms | Specifies the total number of bathrooms. | integer | Required if using hotel_bathroom_details | Min: 0, Max: 20 | - |
> private_bathroom_details | Container for private bathroom details. | object | Optional | - | - |
>>type | Specifies the type of private bathroom. | string | Optional | Possible values are: DEFAULT, EXTERNAL_BATHROOM, ATTACHED_BATHROOM | - |
>>location_type | Specifies the location of private bathroom. | string | Optional | Possible values are: DEFAULT, NEXT_DOOR, DOWN_THE_HALL, ACROSS_FROM_THE_ROOM, IN_THE_LOBBY, OTHER | - |
>>location_other | Specifies the custom location description. | string | Optional | Used when location_type is OTHER | - |
The following table describes the response elements:
| Element | Description | Type | Notes |
|---|---|---|---|
data | Contains the response body | object | - |
success | Specifies whether the request completed successfully. | boolean | - |
warnings | Contains any warnings in the request. | object | - |
errors | Contains any errors in the request. | object | - |
meta | Contains metadata information about the response. | object | - |
> ruid | Specifies the unique request ID. | string | You can share this ID with Booking.com customer support when you run into an issue. This can help in understanding what went wrong. |
GET
https://supply-xml.booking.com/facilities-api/properties/{propertyId}/rooms/{roomId}/bathroomsUse this endpoint to retrieve the bathroom facilities for the specified listing.
The following table describes the elements you must specify in the path:
| Element | Description | Type | Required/ Optional | Notes |
|---|---|---|---|---|
propertyId | Specifies the unique ID of the property. | integer | required | Must be valid and connected to your account. |
roomID | Specifies the unique ID of the room to get the bathroom facility details. | integer | required | Must belong to the property. |
The following is a response body snippet:
{
"data": {
"property_bathroom_details": {
"bathrooms": [
{
"id": 325662717,
"bathroom_type": "PRIVATE",
"bathroom_location": "ENSUITE"
},
{
"id": 325662718,
"bathroom_type": "SHARED",
"bathroom_location": "OPPOSITE_THE_ROOM"
}
]
}
},
"warnings": [],
"errors": [],
"meta": {
"ruid": "94kk241-149f-4ec5-8632-3035cfb1l9b4"
}
}| Field Path | Description | Type | Notes |
|---|---|---|---|
> data | Contains the bathroom configuration details. | object | |
>> property_bathroom_details | Contains bathroom details for property-type rooms. | object | |
>>> bathrooms | Contains a list of bathroom configurations. | array of objects | Maximum 20 bathrooms |
>>>> bathroom_type | Specifies if bathroom is private or shared. | enumerated string | Required. Supports: PRIVATE, SHARED |
>>>> bathroom_location | Specifies the location of the bathroom. | enumerated string | Supports: ENSUITE, NEXT_DOOR, DOWN_THE_HALL, OPPOSITE_THE_ROOM, IN_THE_HALLWAY, OTHER, INSIDE_THE_UNIT |
>>>> hostel_bathroom_details | Contains details specific to hostel bathrooms. | object | |
>>>>> gender | Specifies the gender designation for the bathroom. | enumerated string | Supports: FEMALE, MALE, MIXED |
>>>>> num_guests_with_access_type | Specifies the number of guests with access. | enumerated string | Supports: NUMBER_LESS_THAN_5, NUMBER_5_TO_10, NUMBER_11_TO_20, NUMBER_21_TO_30, NUMBER_31_TO_40, NUMBER_41_TO_50, NUMBER_MORE_THAN_50 |
>>>>> bathroom_facilities | Contains the list of facilities in the bathroom. | array of objects | Required |
>>>>>> type | Specifies the type of facility. | enumerated string | Required. Supports: SHOWER, TOILET, SINK, BATH, TOILET_PAPER, HAIR_DRYER, SLIPPERS, BIDET, TOOTHBRUSH, SHAMPOO, CONDITIONER, BODY_SOAP, TOWEL, HOT_WATER |
>>>>>> count | Specifies the number of this facility type. | integer | Min: 1, Max: 100 |
>>>>>> is_paid | Specifies whether the facility is paid. | boolean | |
>> hotel_bathroom_details | Contains bathroom details for hotel-type rooms. | object | |
>>> shared_bathroom_state | Indicates if shared bathroom is available. | enumerated string | Required. Supports: MISSING, PRESENT |
>>> private_bathroom_state | Indicates if private bathroom is available. | enumerated string | Required. Supports: MISSING, PRESENT |
>>> number_of_bathrooms | Specifies the total number of bathrooms. | integer | Required. Min: 0, Max: 20 |
>>> private_bathroom_details | Contains the details about private bathroom. | object | |
>>>> type | Specifies the type of private bathroom. | enumerated string | Supports: DEFAULT, EXTERNAL_BATHROOM, ATTACHED_BATHROOM |
>>>> location_type | Specifies the location of the private bathroom. | enumerated string | Supports: DEFAULT, NEXT_DOOR, DOWN_THE_HALL, ACROSS_FROM_THE_ROOM, IN_THE_LOBBY, OTHER |
>>>> location_other | Specifies the custom location description. | string |