HotelSearch
The Availability Search operation determines availability in each region or specific hotel(s) for the dates and occupancy passed. It returns a list of matching hotels, room options, and prices together with a Quote Id for each hotel room. The Quote Id should then be passed to the BookingPrepare operation to move forwards with the booking.
Availability response times can vary between 3 – 20 seconds depending on the search criteria you have selected. Please discuss with our integrations team if you have any specific requirements for availability response time that are not being met.
Specifying search Target
You can target your search at either:
- One Region Id
- Single or multiple Hotel Id
If some (but not all) of the HotelIds are invalid Ids, then the valid hotels will be processed and the invalid hotels will be ignored (and listed in the Warning parameter) – suggest this be added here as will give more predictability to the results.
Depending on the availability search endpoint used, when both Region ID and Hotel ID are provided the request for the specified endpoint takes precedence, allowing the search to execute correctly.
Example: If the endpoint is RegionSearch and both Region ID and Hotel ID are provided, the Region ID will be used, and the Hotel ID will be ignored.
Request Schema
Request Header
POST /HotelSearch
Content-Type: “application/json”
AuthApiKey: <Your API Key>
Accept-Encoding: “gzip,br”
Request Body Schema
| Field Name | Data Type | Description |
|---|---|---|
|
Nationality |
String |
The two-letter country code of the guests’ nationality. This is required to ensure that the prices and availability returned are valid for the guests who are travelling. |
|
Timeout (optional) |
Integer |
Timeout value, in seconds (e.g., 20 Seconds). |
|
HotelIds |
Integer Array |
A list of hotel IDs (e.g., [46437398]). |
|
ArrivalDate |
String (Date) |
The date of the first night of the stay (e.g., “2025-10-11”). |
|
Nights |
Integer |
The duration of the stay as a number of nights. |
|
Rooms |
Array |
A list of rooms with their details. |
|
Adult |
Integer |
The number of adults in the room (e.g., 2 for the first room). |
|
Child |
Array |
A list of children in the room (e.g., [ {“Age”: 2} ]). |
|
Age |
Integer |
The age of the child (e.g., 2). |
Response Body Schema
| Field Name | Data Type | Description |
|---|---|---|
|
Currency |
String |
The currency code for prices (e.g., “EUR”). All rates will be displayed in the default currency associated with your Stuba account. |
|
HotelAvailability |
Array of Object |
List of hotels with availability information. |
|
Hotel |
Object |
Details of the hotel. |
|
Id |
Integer |
Unique identifier for the hotel. |
|
Name |
String |
Name of the hotel. |
|
Results |
Array of Object |
List of quote options available for the hotel. |
|
Quoteid |
String |
QuoteId for this search result to be passed in a booking create operation. |
|
Rooms |
Array of Object |
List of rooms available under this quote. |
|
RoomType |
Object |
Details about the room type. |
|
Code |
String |
Room type code. |
|
Text |
String |
Description of the room type. |
|
MealType |
Object |
Details about the meal plan. |
|
Code |
String |
Meal type code. |
|
Text |
String |
Description of the meal plan (e.g., “Room only”, “Breakfast”). |
|
Price |
Float |
Price of the room for the specified stay. |
|
CancellationPolicyStatus |
String |
Status of cancellation policy (e.g., “Refundable“, “Nonrefundable”, “Unknown”). Please refer to BookingPrepare response for the complete cancellation policy. |
|
CancelPolicyfrom |
Date |
Date from which the cancellation policy applies. (YYYY-MM-DD) |
HAPI Response Samples
Samples