Appearance
Availability
Get real-time slot availability for a business.
GET /v1/availability/{business_id}
Returns available time slots for the given date.
Parameters
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
business_id | path (UUID) | Yes | — | Business identifier |
date | query | Yes | — | Date to check (YYYY-MM-DD) |
capacity | query | No | 1 | Required party size / capacity |
service_id | query | No | — | Filter slots by this service's duration. Pass a service UUID and the engine uses its duration_minutes instead of the default. Only shows time windows where the full service fits. |
resource_id | query | No | all | Filter to a specific resource (table, stylist, room). Only shows slots for that resource. |
Response
json
{
"business_id": "uuid",
"booking_date": "2026-05-15",
"capacity": 1,
"slots": [
{
"time": "09:00",
"available": true,
"remaining_resources": 3
},
{
"time": "09:30",
"available": false,
"remaining_resources": 0
}
]
}How Slots Are Calculated
- Operating hours determine the time window
slot_interval_minutesdivides the day into slots (default: 30 min)- Each slot is checked against existing bookings for that resource
- Buffer time between bookings is subtracted
- Slots that overlap with blackout dates or blocked slots (Google Calendar) are excluded
- Resources with insufficient capacity are marked unavailable
Example
bash
curl "https://api.availengine.com/v1/availability/{business_id}?date=2026-05-15&capacity=2"GET /v1/public/hours/{business_id}
Returns the operating hours for a business. Public endpoint — no auth required.
bash
curl https://api.availengine.com/v1/public/hours/{business_id}Response:
json
[
{"day_of_week": 0, "is_open": false},
{"day_of_week": 1, "is_open": true, "open_time": "09:00", "close_time": "17:00"},
{"day_of_week": 2, "is_open": true, "open_time": "09:00", "close_time": "17:00"}
]GET /v1/public/business/{slug}
Resolve a business slug to its ID and name. Public endpoint.
bash
curl https://api.availengine.com/v1/public/business/demo-salonResponse:
json
{
"id": "uuid",
"name": "Demo Salon",
"slug": "demo-salon"
}GET /v1/public/blackout-dates/{business_id}
Returns upcoming closure dates. Public endpoint.
bash
curl https://api.availengine.com/v1/public/blackout-dates/{business_id}Response:
json
[
{"start_date": "2026-06-01", "end_date": "2026-06-15", "reason": "Summer holiday"}
]