Room Type
Room type describes the specific rooms in the hotel based on their room names, classifications, occupancy, sizes, and facilities, amenities or view provided to the guests.
For example, you might offer a Deluxe Room with double occupancy with pool view or beach access.
Create or Update Room Type
You can create a new Room Type or update an existing Room Type in your property. There are a few steps to perform when you create or update any property.
Process to create your room type:
For creating or updating a room type, send request with STAAH Room-Level build data.
If your request is valid, you get a success response that means you have successfully created your room type.
Request (RQ) Sent with STAAH Room-Level Build Data
OTA_HotelRoom POST method provides an object SellableProducts
in the request which is sent to the server and the success response creates or modify the Room Type.
Endpoint
POST

https://connect-sandbox.su-api.com/SUAPI/jservice/OTA_HotelRoom
The SellableProducts object
You can create different sellable products under one room id or specific room. In other words, you can sell one room with multiple parameters by creating different room types with different amenities.
This is an object representing your sellable product which is a room type. With this object you can POST this object to create a specific room type with all the desired details.
You can also provide the hotel address, positioning, occupancy, and address. Further, room type is broken down based on the occupancy and the facilities.
Attributes
hotelid
/ HotelCode
/ ClientID
string (Required)
The existing Property/Client ID.
Required existing id to create or update room types.
Maximum 20 characters allowed.
SellableProduct
[InvStatusType]
string (Required)
Indicates whether the call is meant to create new room type or update an existing one for property.
Accepts values: Initial, Modify, Active, Deactivated, and Delete.
To create a new
SellableProduct
use Initial.To Modify, Activate / Deactivate room type, see Modify, Active, Deactivate and Delete.
SellableProduct
[InvNotifType]
string (Required)
Indicates the call is meant to modify room type for property.
Accepts values: Overlay
Occupancy
[MaxOccupancy]
integer (Required)
Maximum number of guests allowed to stay in a room type.
Maximum occupancy of 999 guests per room type supported.
Occupancy
[MaxChildOccupancy]
integer (Required)
Maximum number of children allowed to stay in a room type.
Value must be less than Maximum Occupancy of the room type.
The Room object
This is an object representing your particular room with all details. You can specify different room rates, occupancy, quantity, and size.
Attributes
Room.[roomid
/ RoomID
/ InvCode
/ ListingID]
string (Required)
The room ID / Listing ID as assigned by the provider.
roomid, RoomID, ListingID & InvCode defines the same field.
Accepts alphanumeric values and hyphen ( - ).
Space and other special characters are not allowed.
Maximum 20 characters allowed.
Room.RoomRate
double (Required)
The default saleable rates of room.
Rate should be greater than 0.
Room.Quantity
integer (Optional or auto update)
Number of rooms available in the property.
Room type quantity is not a static value. If not passed when creating, default value will be passed as 0 and system automatically compares inventory values received with this value. It will override and replace it with the higher inventory value (if received).
Room.RoomType
string (Required)
Name of the room type. See Room Type Code
Accepts both code and name listed under RTC.
Room.SizeMeasurement
double (Optional)
Size of guest room in square meters (by default).
Use SizeMeasurementUnit to indicate square feet unit.
Room.SizeMeasurementUnit
enum (Optional)
The measurement unit ("sqm" or "sqft") for the value specified in SizeMeasurement.
This cannot be defined if the SizeMeasurement attribute is missing. Default: sqm
The Facilities object
This is an object representing your facility with its group and the particular name of the facility.
Facilities included in the room type can be assigned using this node. Both Group and Facility are free text - can create group and assign facilities on fly. No special characters allowed.
Attributes
Facility.Group
string (Optional)
Group name of the facility.
Facility.name
string (Optional)
Name of the facility under a group, multiple facility name can come under one group.
The Position object
This is an object representing Latitude and Longitude.
Position.Latitude
latitude-value (Optional)
Latitude of the property's location.
A valid Latitude value (-90) to 90.
Position.Longitude
longitude-value (Optional)
Longitude of the property's location.
A valid Longitude value (-180) to 180.
The Address object
This is an object representing a structured address of the property. Address object consists of all the address details such as street name, street number, city name, postal or zip code of the city, and country name.
Address.AddressLine
string (Optional)
The full street name and number.
Address.CityName
string (Optional)
The name of the city, town, or village.
Only editable through Extranet.
Address.PostalCode
string (Optional)
The postal or zip code.
Address.CountryName
string (Optional)
The two-letters code for the country.
Only editable through Extranet listed under Country Codes.
The Description object
Description.Text
string (Required)
The room type name.
Description.RoomDescription
Free Text (Optional)
Description of room type.
Maximum 2000 characters. If exceeded, system will simply accept and will not return an error.
Sample Request
{
"SellableProducts": {
"hotelid": "KC",
"SellableProduct": [{
"InvStatusType": "Initial",
"GuestRoom": {
"Occupancy": {
"MaxOccupancy": "2",
"MaxChildOccupancy": "1"
},
"Room": {
"roomid": "123444",
"RoomRate": "2000",
"Quantity": "2",
"RoomType": "Apartment",
"SizeMeasurement": "16",
"SizeMeasurementUnit": "sqm"
},
"Facilities": {
"Facility": [{
"Group": "Amenities",
"name": "Hairdyer"
},
{
"Group": "Amenities",
"name": "Free Wifi"
},
{
"Group": "Amenities",
"name": "Iron Facilities"
},
{
"Group": "Kitchen",
"name": "Microwave"
},
{
"Group": "Kitchen",
"name": "Coffee Maker"
}
]
},
"Position": {
"Latitude": "49.4092",
"Longitude": "1.0900"
},
"Address": {
"AddressLine": "15 Station Street",
"CityName": "London",
"CountryName": "GB",
"PostalCode": "M16JD"
},
"Description": {
"Text": "Deluxe Double Room with Sea View",
"RoomDescription": "hello"
}
}
},
{
"InvStatusType": "Initial",
"GuestRoom": {
"Occupancy": {
"MaxOccupancy": "2",
"MaxChildOccupancy": "1"
},
"Room": {
"roomid": "1234441",
"RoomRate": "2000",
"RoomType": "Double",
"SizeMeasurement": "16"
},
"Description": {
"Text": "Deluxe Double Room"
}
}
}
]
}
}
Response
If the API call returns the success as the status, this indicates the request was successful. You have created or modified your Room Type successfully.
Upon creating a Room Type / Listing successfully, the status will be as "Incomplete" as there is no inventory available for it. Once inventory have been updated for the room type / listing, the status will be changed to "Active" automatically and it will appear as an option to map in channel mapping page.
Sample Success Response
{
"Status": "Success"
}
Error
As with every standard STAAH response, an "ID" is necessary for any JSON troubleshooting of requests to STAAH.
you cannot create a room with the same id as a previous room. This will return an error.
Sample Error Response (906)
{
"Status": "Fail",
"Errors": [
{
"Code": "906",
"ShortText": "Requested room does not qualify. Room with id '123444198' already exists"
}
]
}
Update or Modify Room Type
If you want to update the room type, set the InvStatusType
attribute to “Modify“ in the header request and call the Update/Modify Room Type API. Updating or modifying a room type involves several key steps and considerations. This procedure is essential for maintaining accurate room inventory, optimizing pricing strategies, and ensuring a positive guest experience.
Sample Request
{
"SellableProducts": {
"hotelid": "KC",
"SellableProduct": [{
"InvNotifType": "Overlay",
"InvStatusType": "Modify",
"roomid": "STD",
"GuestRoom": {
"Room": {
"RoomRate": "200",
"RoomType": "Double",
"SizeMeasurement": "20",
"SizeMeasurementUnit": "sqm"
},
"Facilities": {
"Facility": [{
"Group": "Amenities",
"name": "Jacuzzi Tub"
},
{
"Group": "Amenities",
"name": "Radio"
},
{
"Group": "Amenities",
"name": "Hairdryer"
},
{
"Group": "Kitchen",
"name": "Refrigerator"
},
{
"Group": "Kitchen",
"name": "Garden view"
}
]
},
"Description": {
"RoomDescription": "Each room comes with a flat-screen TV with cable channels.",
"Text": "Superior Room with Balcony"
}
}
}]
}
}
Deactivate Room Type
If you want to deactivate the room type, set the InvStatusType
attribute to “Deactivated“ in the header request and call the Update/Modify Room Type API.
Sample Request
{
"SellableProducts": {
"hotelid": "KC",
"SellableProduct": [{
"InvNotifType": "Overlay",
"InvStatusType": "Deactivated",
"roomid": "STD"
}]
}
}
Activate Room Type
If you want to activate the room type, set the InvStatusType attribute to “Active“ in the header request and call the Activate Room Type API.
Sample Request
{
"SellableProducts": {
"hotelid": "KC",
"SellableProduct": [{
"InvNotifType": "Overlay",
"InvStatusType": "Active",
"roomid": "STD"
}]
}
}
Delete Room Type
If you want to delete the room type, set the InvStatusType attribute to “Delete“ in the header request and call the Update/Modify Room Type API.
Sample Request
{
"SellableProducts": {
"hotelid": "KC",
"SellableProduct": [{
"InvNotifType": "Overlay",
"InvStatusType": "Delete",
"roomid": "STD"
}]
}
}
Last updated
Was this helpful?