Vexar API

Public Booking

These endpoints power the public booking form on a published profile. They need no authentication{username} is the profile’s public username. Times are interpreted in the profile’s timezone.

GET /api/v1/profile/{username}/available-dates Public

Dates that have free slots within the booking window, plus days off with reasons.

ParamTypeInDescription
service_idintqueryOptional — narrow by service duration
Response
{
  "success": true,
  "dates": [ { "date": "2026-07-01", "slots_count": 6 } ],
  "days_off": { "2026-07-04": "Holiday" }
}
GET /api/v1/profile/{username}/slots Public

Free time slots for a specific date.

ParamTypeInDescription
datedatequeryRequired, YYYY-MM-DD
service_idintqueryOptional
Response
{
  "success": true,
  "date": "2026-07-01",
  "slots": [ "10:00", "11:00", "12:00" ],
  "settings": { "slot_duration": 60, "require_payment": false }
}
GET /api/v1/profile/{username}/bookable-services Public

Services/objects that can be booked, with formatted prices and assigned staff.

Response
{
  "success": true,
  "services": [ { "id": 8, "name": "Haircut", "duration_minutes": 60, "formatted_price": "$50.00", "staff": [ … ] } ],
  "staff_selection_mode": "optional"
}
POST /api/v1/profile/{username}/book Public

Submit a booking. Rate-limited to 3/min per IP. For rentals send checkout_date instead of start_time. Returns confirmed or pending depending on the profile’s auto-confirm setting.

Request body
{
  "visitor_name": "Jane",
  "visitor_email": "[email protected]",
  "visitor_phone": "+1…",
  "visitor_note": "",
  "booking_date": "2026-07-01",
  "start_time": "10:00",
  "service_id": 8,
  "operator_id": null
}
Response
{
  "success": true,
  "booking": { "id": 21, "date": "2026-07-01", "time": "10:00", "status": "pending" },
  "message": "Your booking request has been submitted…"
}
GET /api/v1/profile/{username}/rental-availability Public

Booked date ranges for a rental object (to disable them in a date picker).

ParamTypeInDescription
object_idintqueryRental object (service) id
Response
{
  "success": true,
  "booked": [ { "booking_date": "2026-07-01", "checkout_date": "2026-07-05" } ]
}
GET /api/v1/profile/{username}/staff Public

Public list of bookable staff members.

Response
{
  "success": true,
  "staff": [ { "id": 4, "name": "Alex", "avatar_url": "https://…", "job_title": "Barber", "color": "#3390EC" } ]
}
GET /api/v1/profile/{username}/staff/{id}/slots Public

Free slots for a specific staff member on a date.

ParamTypeInDescription
datedatequeryRequired, YYYY-MM-DD
durationintqueryOptional service duration in minutes
Response
{ "success": true, "slots": [ "10:00", "11:30" ] }