Rooms API (1.2)

Contains Rooms API specification

Languages
Servers
Test static response
https://developers.booking.com/_mock/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/
Test using live endpoint
https://supply-xml.booking.com/

rooms-api

Create, update, retrieve and delete property units

Operations

Update unit

Request

Update existing unit for a property

Path
property-idinteger(int32)required
unit-idinteger(int64)required
Bodyapplication/jsonrequired
configurationobject(Configuration)
unit_name_idinteger(int32)
  • The list of available unit names can be found in meta (see $.unit_names)
number_of_unitsinteger(int32)

Number of units must be between 0 and 32000

smoking_policystring

Room smoking policy

Enum"SMOKING""NONSMOKING""SMOKING_AND_NONSMOKING"
sizeobject(Size)
partner_reference_namestring

Internal room name, visible only in API and Extranet

floor_numbers_located_onArray of integers(int32)

One or more floors where the unit is located; 0 is a ground floor

occupancy_detailsobject(OccupancyDetails)
extra_beds_configurationobject(ExtraBedsConfiguration)

Extra bed & crib options

max_children_that_pay_children_rateinteger(int32)[ 0 .. 49 ]

Maximum number of children eligible for the children rate (the rest are charged as adults), must be less than or equal to number of children.

unit_name_fallbackstring

Contains unit name (EN_GB locale) for any unit name ID, including those missing in meta (for debug purposes only; read only)

occupancyobject(Occupancy)Deprecated
curl -i -X PATCH \
  'https://developers.booking.com/_mock/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/properties/{property-id}/units/{unit-id}' \
  -H 'Content-Type: application/json' \
  -d '{
    "configuration": {
      "unit_type_id": 1,
      "rooms": [
        {
          "type": "BEDROOM_SUBROOM",
          "bed_configurations": [
            {
              "beds": [
                {
                  "bed_type_id": 3,
                  "bed_count": 1
                },
                {
                  "bed_type_id": 1,
                  "bed_count": 1
                }
              ],
              "is_default_configuration": true
            }
          ]
        },
        {
          "type": "LIVING_ROOM_SUBROOM",
          "bed_configurations": [
            {
              "beds": [
                {
                  "bed_type_id": 5,
                  "bed_count": 1
                }
              ],
              "is_default_configuration": true
            }
          ]
        }
      ]
    }
  }'

Responses

OK

Bodyapplication/json
dataobject
warningsArray of objects(ApiError)
errorsArray of objects(ApiError)
metaobject(ResponseMeta)
Response
application/json
{ "data": {}, "warnings": [ {} ], "errors": [ {} ], "meta": { "ruid": "string" } }

Get deleted units (read only)

Request

Get all deleted units for a property (read only)

Path
property-idinteger(int32)required
Query
debug_infostring

Enable debug to return $.unit_name_fallback field in response

Default "false"
curl -i -X GET \
  'https://developers.booking.com/_mock/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/properties/{property-id}/deleted-units?debug_info=false'

Responses

OK

Bodyapplication/json
dataArray of objects(Unit)
warningsArray of objects(ApiError)
errorsArray of objects(ApiError)
metaobject(ResponseMeta)
Response
application/json
{ "data": [ {} ], "warnings": [ {} ], "errors": [ {} ], "meta": { "ruid": "string" } }

meta

Retrieve units meta data and translations

Operations

About Try it

Learn how to effectively use the Try it feature in the Rooms API documentation.

Use the Try it feature to send test request examples to the API endpoints directly from the developer portal and depending on the selected environment either see static, pre-built responses or dynamic responses from a test property.