Available House Units

2 min. readlast update: 11.28.2024

Available House Units

The Available House Units endpoint is designed to retrieve a list of house units available for a specified date range and number of persons.

If the request does not specify a start date, end date, or the number of adults, children, or pets, the response defaults to a stay for 2 adults, no children, no pets, for a duration of 2 nights. The default start date is set to at least 4 days from today, depending on availability.

Endpoint

GET /bungalow/api/v1/booking/availableHouseUnits

Purpose

This endpoint allows you to check the availability of house units within a park for a given date range, based on the number and composition of guests (adults, children, and pets).

Response

The response is an array of objects, with each object containing details of a house unit. Below is the structure of the response model:

Response Model

[
  {
    "unitId": 12345,
    "unitNumber": "A102",
    "houseId": 789,
    "startDate": "2024-11-27T17:24:13.829Z",
    "endDate": "2024-11-30T17:24:13.829Z",
    "nrPets": 1,
  },
  {
    "unitId": 12346,
    "unitNumber": "A103",
    "houseId": 789,
    "startDate": "2024-11-27T17:24:13.829Z",
    "endDate": "2024-11-30T17:24:13.829Z",
    "nrPets": 0,
  }
]
 

Model Description

Field Type Description
unitId integer Unique identifier for the unit (optional).
unitNumber string Unit number assigned to the house (optional).
houseId integer Unique identifier for the house (optional).
startDate string Start date of the rental period in ISO 8601 format (optional).
endDate string End date of the rental period in ISO 8601 format (optional).
numberOfPets integer Number of pets allowed for this unit (optional).

Notes

  • All date fields use the ISO 8601 format with UTC timezone (e.g., 2024-11-14T17:24:13.832Z).
  • Ensure that the startDate and endDate fields cover a valid time range; otherwise, the API will return an error.

This endpoint facilitates flexible searches for house unit availability, allowing you to tailor the search to different guest profiles and booking periods, ultimately enhancing the booking experience.

Was this article helpful?