Retrieve Unit Calendars
Returns availability calendar and availability configuration for the Inventory
Overview
Retrieve Unit Calendars endpoint returns real-time calendar data for one or more units, including availability status, stay restrictions, and configuration settings. This enables partners to efficiently manage inventory and maintain accurate availability across platforms.
Endpoints Available
Method | Endpoint | Description |
---|---|---|
GET | v2024.07.31/unit_calendars | Returns availability calendar and configuration for Inventory |
GET | v2024.07.31/unit_calendars/{unit_id} | Returns availability calendar and configuration for Unit in Inventory |
Path Parameters
Path Parameter | Required / Optional | Description |
---|---|---|
{unit_id} | Required | Unique Identifier for Unit in Inventory |
Query String Parameters
Parameter | Required / Optional | Description | Data Type |
---|---|---|---|
page | Optional | The page number to display (default: 1). | int |
page_size | Optional | Limits the number of results (default: 25). | int |
no_total | Optional | If true , omits total page count for faster responses (default: false ). | boolean |
last_unit_update_date | Optional | Returns units modified after the specified date. | date-time |
last_reservation_update_date | Optional | Returns units that have received a booking after the specified date. | date-time |
last_agent_module_property_update_date | Optional | Returns units with modified agent module property settings. | date-time |
last_agent_module_agent_update_date | Optional | Returns units with modified agent module agent settings. | date-time |
unit_id | Optional | Filter results to a specific unit ID. | int |
unit_ids | Optional | Filter results to multiple unit IDs. | array[int] |
management_company_user_id | Optional | Filter results to a specific supplier. | int |
management_company_user_ids | Optional | Filter results to multiple suppliers. | array[int] |
enabled | Optional | Return only enabled or disabled units. | boolean |
deleted | Optional | Return only deleted or non-deleted units. | boolean |
display_on_website | Optional | Return only units enabled for the website. | boolean |
allocation_on_arrival | Optional | Return allocation-on-arrival details. | boolean |
allocation_on_arrival_unit | Optional | Return only representative units in their group. | boolean |
fallback_rates | Optional | Use length-of-stay pricing if available. | boolean |
start | Required | Start date for retrieving availability. | date |
end | Required | End date for retrieving availability. | date |
reservation_id | Optional | Unique identifier for a reservation. | int |
allocated_reservations | Optional | List of unallocated reservations for virtual allocation. | array[int] |
category_to_ignore | Optional | If present or true, will enforce gap day restrictions in the calendar | boolean |
channel | Optional | The desired start for the availability check | date-time |
Response Definition
Response Item | Description | Data Type |
---|---|---|
"unit_id" | Unique identifier for the unit. | int |
"management_company_user_id" | Unique identifier for the management company. | int |
"start_date" | The beginning of the requested availability range. | date-time |
"end_date" | The end of the requested availability range. | date-time |
"days" | Array containing daily availability details. | array |
"days"
Object
"days"
ObjectResponse Item | Description | Data Type |
---|---|---|
"date" | The date of availability. | date |
"availability" | The availability status (e.g., available, unavailable). | string |
"availability_type" | The type of unavailability (e.g., available, reservation). | string |
"closed_to_arrival" | Indicates if check-in is restricted on this day. | boolean |
"closed_to_departure" | Indicates if check-out is restricted on this day. | boolean |
"minimum_nights" | Minimum nights required for a booking. | int |
"maximum_nights" | Maximum nights allowed for a booking. | int |
"settings" | Object containing additional stay settings. | object |
"settings"
Object
"settings"
ObjectResponse Item | Description | Data Type |
---|---|---|
"booking_fence" | Minimum days in advance required for booking. | int |
"gap_days" | Minimum number of gap days required between reservations. | int |
"minimum_nights" | Minimum stay allowed for this day. | int |
"maximum_nights" | Maximum stay allowed for this day. | int |
"arrival_days" | Array of allowed check-in days. | array |
"departure_days" | Array of allowed check-out days. | array |
"stay_durations"
Array
"stay_durations"
ArrayResponse Item | Description | Data Type |
---|---|---|
integer | List of allowed stay durations (in nights) for this unit. | array |
Sample Request
curl --location 'https://api.ciiruspartners.com/v2024.07.31/unit_calendars?page=1&page_size=25&no_total=true&enabled=true&start=2025-03-04&end=2026-03-03' \
--header 'Content-Type: application/json'
Sample Response
{
"unit_calendars": [
{
"unit_id": 104798,
"management_company_user_id": 11006,
"start_date": "2025-03-04T17:00:00",
"end_date": "2026-03-03T12:00:00",
"days": [
{
"date": "2025-03-04",
"availability": "available",
"availability_type": "available",
"closed_to_arrival": false,
"closed_to_departure": false,
"minimum_nights": 2,
"maximum_nights": 1763,
"settings": {
"booking_fence": 0,
"gap_days": 0,
"minimum_nights": 2,
"maximum_nights": 1763,
"arrival_days": [
"monday",
"tuesday",
"wednesday",
"thursday",
"friday",
"saturday",
"sunday"
],
"departure_days": [
"monday",
"tuesday",
"wednesday",
"thursday",
"friday",
"saturday",
"sunday"
]
},
"stay_durations": [
2,
3,
4,
5,
6,
7,
8,
9,
10,
...
]
},
{
"unit_id": 0,
"management_company_user_id": 0,
"start_date": "0001-01-01T00:00:00",
"end_date": "0001-01-01T00:00:00",
"error": {
"message": "{\"message\":\"Unit quote options could not be found.\"}"
}
}
],
"paging": {
"next_page_url": "https://api.ciiruspartners.com/2024.07.31/units?page=2&page_size=25&channel=all&enabled=true&no_total=false",
"total_page_count": 3,
"page": 1,
"page_size": 25
}
}
Updated about 2 months ago