Public Holidays API
Overview
Adds public holiday calendar records affecting hotel pricing rules and day-type categorization (PUBLIC_HOLIDAY).
- Endpoint:
/api/availability/holidays - Method:
POST
Request Body Schema
| Field | Type | Required | Description |
|---|---|---|---|
name | String | Yes | Name of the public holiday |
recurrence | Enum | No | NONE, YEARLY (Default: NONE) |
hotelId | String (UUID) | No | Optional hotel binding (Global if omitted) |
dates | Array of Strings | Yes | List of holiday dates (YYYY-MM-DD) |
Request Body Example
{
"name": "Diwali Festival Holiday",
"recurrence": "NONE",
"dates": ["2026-11-08", "2026-11-09"]
}
Response Example (201 Created)
{
"success": true,
"data": {
"id": "hol_55443322",
"name": "Diwali Festival Holiday",
"recurrence": "NONE",
"active": true,
"dates": [
{ "id": "hd_1", "date": "2026-11-08T00:00:00.000Z", "status": "ACTIVE" },
{ "id": "hd_2", "date": "2026-11-09T00:00:00.000Z", "status": "ACTIVE" }
]
},
"message": "Public holiday created successfully"
}