Rooms
Query Overview
The roomsSetUp
query returns the rooms added to a hotel rate in Inventory. The returned fields include:
code
master
id
code
name
active
externalCode
standard
uses
numberOfGuests
minAge
maxAge
paxType
1. Criteria
When building your query, you need to provide the following input fields:
Mandatory Input
clientCode
supplierCode
hotelCode
rateCode
Optional Input
contextCode
roomCodes
2. Settings
To retrieve room details, ensure that all mandatory fields are properly provided, and associate the query with the correct hotel and rate.
Response Considerations
The query returns the room setup details along with success status and possible advise messages.
RoomsSetUpRs
(OBJECT)
rooms
(InventoryRoomSetUp) - A collection of retrieved rooms.code
(String) - The room code.master
(InventoryMasterRoom) - The master room details.id
(Int) - The master room ID.code
(String) - The master room code.name
(String) - The master room name.
active
(Boolean) - Indicates if the room is active.externalCode
(String) - The external code associated with the room.standard
(Int) - The standard occupancy of the room.uses
(InventoryRoomUse) - The list of guest types allowed in the room.numberOfGuests
(Int) - The number of guests allowed.minAge
(Int) - The minimum age allowed for guests.maxAge
(Int) - The maximum age allowed for guests.paxType
(Enum of InventoryPaxType) - The type of guests allowed.- Possible values:
INFANT
,CHILD
,ADULT
- Possible values:
success
(Boolean) - Indicates if the operation was successful.adviseMessages
(AdviseMessage) - Messages related to the operation.
Query Inputs
InventoryRoomsSetupFilterInput (INPUT_OBJECT)
Rooms setup filter input.
Rooms setup filter input.
Returned Fields
RoomsSetUpRs (OBJECT)
Represents the response object for room setup operations.
Represents the response object for room setup operations.
Examples
Retrieve all rooms from a rate
xxxxxxxxxx
query ($criteria: InventoryRoomsSetupFilterInput!) {
inventory {
roomsSetup(roomsSetupFilterInput: $criteria) {
rooms {
code
master {
id
code
name
}
active
externalCode
standard
uses {
numberOfGuests
paxType
}
}
success
adviseMessages {
code
description
level
external {
code
message
}
}
}
}
}
9
{
"criteria": {
"clientCode": "CDOC",
"supplierCode": "PDOC",
"hotelCode": "2",
"contextCode": "TGX_PUSH",
"rateCode": "BAR"
}
}
x
Retrieve specific rooms from a rate
xxxxxxxxxx
query ($criteria: InventoryRoomsSetupFilterInput!) {
inventory {
roomsSetup(roomsSetupFilterInput: $criteria) {
rooms {
code
master {
id
code
name
}
active
externalCode
standard
uses {
numberOfGuests
paxType
}
}
success
adviseMessages {
code
description
level
external {
code
message
}
}
}
}
}
10
{
"criteria": {
"clientCode": "CDOC",
"supplierCode": "PDOC",
"hotelCode": "2",
"contextCode": "TGX_PUSH",
"rateCode": "BAR",
"roomCodes": ["STD2"]
}
}
xxxxxxxxxx