Search availability
Find the availability of multiple products for a given date range. Filter by occupancy and attribute options.
Body
intervalrequired{ start: string, end: string } | nullThe interval to search for availability in. If not provided, search will check each product for a match with the other parameters.
occupancyrequiredRecord<uuid, integer>Filter search results by occupancy.
option_idsrequiredArray<uuid>Filter search results by attribute_options.
product_idsArray<uuid>Filter search results by product IDs.
show_booked_asrequiredShowBookedAsHow to interpret booked events. Defaults to unavailable
show_closed_asrequiredShowClosedAsHow to interpret closed events. Defaults to unavailable
show_pending_asrequired"CONFIRMED" | "TENTATIVE" | "CANCELLED"How to interpret pending events. Defaults to TENTATIVE
Responses
200Search results
TypeScript
Array<{
availability: "available" | "booked" | "closed" | "pending" | "unavailable" | null;
match: boolean;
occupancyMatches: boolean;
optionsMatch: boolean;
price: {
max: number;
min: number;
} | null;
productId: uuid;
}>POST /searchcurl -X POST "https://api.bookingmood.com/v1/search" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'Example response
JSON
[
{
"availability": "unavailable",
"match": false,
"occupancyMatches": true,
"optionsMatch": true,
"price": {
"min": 100,
"max": 200
},
"productId": "00000000-0000-0000-0000-000000000000"
}
]