# Rooms API

Use the Rooms API to create, update, delete and retrieve the units of a property, and to retrieve the metadata (unit types, unit names, bed types and property categories) you need to configure them.

A unit is a sellable inventory item. It can contain one room, such as a Double room, or several rooms, such as an apartment, suite or villa. For more information, see [Understanding Rooms API terminology](/connectivity/docs/rooms-api/introduction-to-rooms-api#understanding-rooms-api-terminology) and [Managing units](/connectivity/docs/rooms-api/managing-units).

Version: 1.2

## Servers

Test using live endpoint
```
https://supply-xml.booking.com/
```

## Security

### BearerAuth

Bearer token for authentication. Use your API credentials to obtain a token.

Type: http
Scheme: bearer
Bearer Format: JWT

## Download OpenAPI description

[Rooms API](/_bundle/connectivity/docs/openapispecs/rooms-api/rooms-api-specification.json)

## rooms-api

- [GET /rooms-api/properties/{property-id}/units](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/getunits.md): Retrieves all active units of a property, with their configuration, occupancy, extra beds and other details. To update a unit, you can copy the relevant part of a unit in this response and use it as t
- [POST /rooms-api/properties/{property-id}/units](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/createunit.md): Creates a unit for a property. `configuration` and `unit_name_id` are required. Optional fields you leave out get their default values. Before you create a unit, use the [meta endpoint](/connectivity/
- [DELETE /rooms-api/properties/{property-id}/units/{unit-id}](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/deleteunit.md): Deletes a unit of a property. The unit is no longer returned by [get units](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/getunits) and is listed by [get deleted units](/
- [PATCH /rooms-api/properties/{property-id}/units/{unit-id}](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/updateunit.md): Updates a unit. The API overlays the existing unit with the fields in the request body. Fields you leave out keep their values. Every root-level field is optional, but when you send an object (for exa
- [GET /rooms-api/properties/{property-id}/deleted-units](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/getdeletedunits.md): Retrieves the units of a property that were deleted. The units have the same structure as in [get units](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/rooms-api/getunits). Deleted

## meta

- [GET /rooms-api/meta](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/meta/getroommeta.md): Retrieves the metadata you need to create and update units, translated into the language you set in `language_code`. The Rooms API identifies unit types, unit names and bed types by numeric IDs. Use t

## About Try it

- [Environment](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/environment.md): ## Environment You can select between two different environments (top right corner in the UI): **Mock (schema only)** (default): - Helps to understand the response data schema - Recommended for all wr
- [Request](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/request.md): ## Request You can click on any unresolved placeholders to add a value or edit an existing placeholder value. The portal loads the default request body. Where the specification supports multiple reque
- [Response](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/response.md): ## Response The Try it feature provides comprehensive response information to the extent supported by the Open API specification:
- [Status code](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/status-code.md): ### Status code - **2xx**: Success responses (200) - **4xx**: Client errors (400 Bad Request, 401 Unauthorized, 404 Not Found) - **5xx**: Server errors (500 Internal Server Error)
- [Response body](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/response-body.md): ### Response body - JSON formatted response data If the returned response, by default, is unformatted, select the supported Response body format in the UI.
- [Response headers](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/response-headers.md): ### Response headers - Content-Type, Content-Length.
- [Environments](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/environments.md): ## Environments The **Environments** tab allows you to create variables specific to the environment. For example, you can add a variable to hold the value of the `property-id` placeholder. The portal 
- [Variables](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/variables.md): ### Variables Most of the endpoints (especially POST/PUT/DELETE) require you to add a path or query parameter before sending the request. The Open API specification marks these parameters with placeho
- [Path parameters](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/path-parameters.md): #### Path parameters - **Required**: Must be provided to make the request - **Type validation**: Ensures correct data types (integer, string, etc.) - **Example**: `property-id` in `/rooms-api/properti
- [Query parameters](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/query-parameters.md): #### Query parameters - **Optional**: Usually have default values - **Example**: `debug_info` with boolean values
- [Request body](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/request-body.md): #### Request body - **Schema validation**: Follows OpenAPI schema definitions - **Example data**: Prepopulated with sample values
- [Best practices](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/best-practices.md): ## Best practices This section provides some basic practice guidelines.
- [Authentication](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/authentication.md): ### Authentication - Always use separate machine accounts for test properties vs. properties in production. - When testing with production endpoint, make sure to use only test properties.
- [For Read operations (GET)](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/for-read-operations-(get).md): ### For Read operations (GET) - Safe to test in any environment - Use valid IDs that exist in your system - Check response structure for integration planning
- [For Write operations (POST, PUT)](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/for-write-operations-(post-put).md): ### For Write operations (POST, PUT) - **Always use Mock (schema only) environment first** - Verify request payload structure - Check response for success confirmation - Test error scenarios with inva
- [For Delete operations (DELETE)](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/for-delete-operations-(delete).md): ### For Delete operations (DELETE) - **Preferable to use Mock (schema only) environment only** - Understand the operation is irreversible - Have backup data when testing using test properties
- [Troubleshooting](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/troubleshooting.md): ## Troubleshooting
- [Common issues](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/common-issues.md): ### Common issues **401 Unauthorized** - Check authentication credentials - Verify API key is valid and not expired - Ensure credentials match the selected environment **400 Bad Request** - Validate r
- [Getting help](/connectivity/docs/openapispecs/rooms-api/rooms-api-specification/about-try-it/getting-help.md): ### Getting help If you encounter issues: 1. Check the response error message for details 2. Verify your request matches the API specification 3. Contact the Connectivity Team for support --- _This do
