Authentication & Common Response

Request Headers

Every request must include a valid Authorization header with a JWT token (Bearer <token>). POST requests also require Content-Type: application/json.

Response Envelope Fields
FieldTypeDescription
timestringServer timestamp (ISO-8601)
statusintegerHTTP-style status code
messagestringShort human-readable message
errorCodelong | nullInternal error code on failure; null on success
errorMessagestring | nullDetailed error description on failure
dataobject | nullEndpoint-specific payload


2

Calendar Availability API

Returns day-by-day availability and for a property over a date range.

GET /v1/cozycozy/calendar-availability
Request — Query Parameters
Validation: startDate must be today or later · endDate must be ≥ startDate
ParameterTypeRequiredDescription
propertyIdstringYesWhimstay property ID
startDatestringNoInclusive range start Format: yyyy-MM-dd · Default: today
endDatestringNoInclusive range end Format: yyyy-MM-dd
Response — data
FieldTypeDescription
propertyIdstringWhimstay property ID
daysarrayOne entry per day in the requested range (see Day Object below)
errorMessagestring | nullError message if any or null
Response — Day Object (days[])
FieldTypeDescription
datestringCalendar date Format: yyyy-MM-dd
arrivalbooleanGuest may check in on this date
departurebooleanGuest may check out on this date
availablebooleanDate is open (not blocked or booked)
minStayintMinimum nights from this date
maxStayintMaximum nights from this date

3

Quote API

Returns a real-time price quote for a stay.

POST /v1/cozycozy/quote
Request
Validation: checkIn must be today or later · checkOut must be after checkIn · Stay length must not exceed property's maxStay
FieldTypeRequiredDescription
propertyIdstringYesWhimstay property ID
checkInstringYesCheck-in date Format: yyyy-MM-dd
checkOutstringYesCheck-out date Format: yyyy-MM-dd
adultsintYesNumber of adults, ≥ 1
childrenintNoNumber of children
petsintNoNumber of pets
Response — data
FieldTypeDescription
propertyIdstringWhimstay property ID
currencystringCurrency code (USD only)
totaldoubleFinal total amount payable for the stay
errorMessagestring | nullPopulated on validation or availability errors

4

Property Detail Page (PDP) API

Returns the full dataset for a single property — descriptions, images, amenities info.

GET /v1/cozycozy/property/{propertyId}
Request — Path Parameter
ParameterTypeRequiredDescription
propertyIdstringYesWhimstay property ID (e.g. 6f15e9964d13cca9a68a8965c7dbca2h)
Response — Identity
FieldTypeDescription
propertyIdstringWhimstay property ID
propertyNamestringProperty display name
propertyTypestringProperty type (e.g. House, Apartment)
maxGuestsintMaximum guest capacity
bedroomsintNumber of bedrooms
bathroomsfloatNumber of bathrooms
bedsintNumber of beds
checkInTimestringCheck-in time
checkOutTimestringCheck-out time
descriptionstringFull property description
imageslist<string>List of image URLs
amenitieslist<string>List of feature names (e.g. "WiFi", "Kitchen")
petsAllowedbooleanIf property is pet-friendly or not
partiesAllowedbooleanIf parties are allowed or not
smokingAllowedbooleanIf smoking is allowed or not
childFriendlyboolean If children are allowed or not
wheelchairAccessiblebooleanIf wheelchair access is available or not