Room Availability
Overview
The Room Availability endpoint returns room availability information for a specified date range. The data is grouped by room type (identified by resourceId which corresponds to the room_type_id), providing availability counts and occupancy details for operational planning and inventory management.
This endpoint is commonly used for availability calendars, forecasting, and distribution management.
Request Endpoint
- HTTP Method:
POST - Secure URL Path:
{{base_url}}/api/room-availability
Authorization
Requires the following permission:
- Permission:
integration-room-availability
Payload Construction and Schema Definition
The request payload is submitted as form-data fields.
Request Body Fields
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
username | string | Yes | API account username provided by GuestPro. | demo_user |
password | string | Yes | API account password provided by GuestPro. | •••••••• |
company_code | string | Yes | Property/company identifier bound to your API account. | gusadidev |
start_date | string (date) | Yes | Start date for availability report (YYYY-MM-DD format). | 2026-04-01 |
end_date | string (date) | Yes | End date for availability report (YYYY-MM-DD format). | 2026-04-30 |
Response Body Fields
| Field | Type | Always present | Description |
|---|---|---|---|
error | boolean | Yes | Indicates whether the request failed. false means success. |
status | string | Yes | Status string. On success the example returns "ok". |
message | string | Yes | Human-readable message. Often empty on success. |
data | array<object> | Yes (on success) | Array of room type availability objects. |
Response data Fields
| Field | Type | Description | Example |
|---|---|---|---|
resourceId | string | Room type identifier (matches room_type_id). | 123fe740-3869-11eb-a57f-950037ff4988 |
resourceName | string | Room type name. | Deluxe Villa |
date | string (date) | Date for this availability record (YYYY-MM-DD format). | 2026-04-01 |
total_rooms | number | Total number of rooms of this type. | 10 |
available_rooms | number | Number of available rooms for this date. | 6 |
occupied_rooms | number | Number of occupied rooms for this date. | 4 |
occupancy_rate | number | Occupancy percentage (0-100). | 40 |
Expected System Responses
The system responds with HTTP 200 OK.
{
"error": false,
"status": "ok",
"message": "",
"data": [
{
"resourceId": "123fe740-3869-11eb-a57f-950037ff4988",
"resourceName": "Deluxe Villa",
"date": "2026-04-01",
"total_rooms": 10,
"available_rooms": 6,
"occupied_rooms": 4,
"occupancy_rate": 40
},
{
"resourceId": "123fe740-3869-11eb-a57f-950037ff4988",
"resourceName": "Deluxe Villa",
"date": "2026-04-02",
"total_rooms": 10,
"available_rooms": 5,
"occupied_rooms": 5,
"occupancy_rate": 50
},
{
"resourceId": "b0cb41b0-ac2f-11ed-a9ac-a72e59437084",
"resourceName": "2 Bedroom",
"date": "2026-04-01",
"total_rooms": 8,
"available_rooms": 3,
"occupied_rooms": 5,
"occupancy_rate": 62.5
},
{
"resourceId": "b0cb41b0-ac2f-11ed-a9ac-a72e59437084",
"resourceName": "2 Bedroom",
"date": "2026-04-02",
"total_rooms": 8,
"available_rooms": 4,
"occupied_rooms": 4,
"occupancy_rate": 50
}
]
}