Hotel Categories
Query Overviewβ
The hotelCategories query returns a list of the categories that a hotel can have assigned in Inventory. The returned fields include:
idname
1. Criteriaβ
When building your query, you can provide the following input field:
Optional Inputβ
categoryIds- A list of category IDs to retrieve specific hotel categories.
2. Settingsβ
This query allows retrieving all hotel categories or filtering specific ones by providing category IDs.
The categoryIds field can be used to filter categories based on specific requirements.
{
"input": {
"categoryIds": [1, 2, 3]
}
}
Response Considerationsβ
The query returns a collection of hotel categories along with success status and possible advise messages.
CategoriesRs (OBJECT)β
categories(InventoryCategory) - A collection of retrieved hotel categories.id(Int) - Unique identifier for the category.name(String) - Name of the category.
success(Boolean) - Indicates whether the operation was successful.adviseMessages(AdviseMessage) - Messages related to the operation.code(ID) - AM code.type(String) - Error type.description(String) - Error description.level(Enum of AdviseMessageLevel) - Importance level (ERROR, WARN, INFO).external(ExternalMessage) - External message details.correlationID(ID) - Identifier for debugging.
Query Inputsβ
InventoryHotelCategoriesFilterInput (INPUT_OBJECT)
Hotel categories filter input.
Hotel categories filter input.
categoryIds(Int)
Category ids of the categories to retrieve.
Returned Fieldsβ
CategoriesRs (OBJECT)
Represents a response object for categories.
Represents a response object for categories.
adviseMessages(AdviseMessage)
List of advise messages.
AdviseMessage codeΒ *Β (ID) AM code: The following codes can be returned: descriptionΒ *Β (String) Error description levelΒ *Β (AdviseMessageLevel) Indicates the level of importance of the message.
Possible values: ERROR, WARN, INFO.
Possible values: Specify the external message. External code. messageΒ *Β (String) External message. correlationIDΒ *Β (ID) Identifier to investigate the cause of the error.WARN: Warning message.ERROR: Error message.INFO: Info message.external(ExternalMessage)
code(String)
categories(InventoryCategory)
List of categories.
Category idΒ *Β (Int) Category Id. Category Name.name(String)
successΒ *Β (Boolean)
Indicates whether the operation was successful.
Examplesβ
Retrieve full list of Hotel Categoriesβ
Retrieve a specific list of Hotel Categoriesβ
When utilizing the hotelCategories query, for more personalized results, filter specific categories based on your interests. For example, to retrieve only the Hotel Categories stars-related, add the categoryIds field with the following codes in your input: