Admin Booking Lifecycle
Admin-specific booking operations: status changes, check-in/out, and document generation.
For customer booking management, see Customer Booking Lifecycle. For creating bookings, see Admin Booking Creation. For general conventions, see JSON-API Conventions.
Prerequisites
- A valid Bearer token with admin access — see Authentication
- Organization context (
?o={organization_id})
Status Changes
Request path documentation:
paths/admin/bookings.yamlforPATCH /api/v1/bookings/{booking_id}paths/admin/bookings.yamlforGET /api/v1/bookings/{booking_id}/cancel
Accept a Requested Booking
When a booking has status requested, accept it by updating the booking status:
PATCH /api/v1/bookings/{booking_id}?o={org_id}
Example payload:
{
"data": {
"id": "{booking_id}",
"type": "bookings",
"attributes": {
"status": "accepted"
}
}
}
Reject a Requested Booking
Reject a requested booking with the same update endpoint:
PATCH /api/v1/bookings/{booking_id}?o={org_id}
Example payload:
{
"data": {
"id": "{booking_id}",
"type": "bookings",
"attributes": {
"status": "rejected"
}
}
}
Cancel a Booking
Cancel an accepted or requested booking with the dedicated cancel action:
GET /api/v1/bookings/{booking_id}/cancel?o={org_id}
This runs the booking cancellation flow. Refunds and invoice adjustments follow the configured cancellation policy.
Check-In / Check-Out
Request path documentation:
paths/admin/bookings.yamlforPOST /api/v1/bookings/{booking_id}/check-inpaths/admin/bookings.yamlforPOST /api/v1/bookings/{booking_id}/check-out
Record customer arrivals and departures.
Check-In
POST /api/v1/bookings/{booking_id}/check-in?o={org_id}
Check-Out
POST /api/v1/bookings/{booking_id}/check-out?o={org_id}
Both endpoints:
- Log a
Scanrecord with the timestamp - Update the booking's check-in/check-out status
- Can be triggered by admin users or via self-service terminals
Note: Resources can be configured with auto-expiry — if a customer doesn't check in within a configured window, the booking expires automatically.
Generating Documents
Generate a PDF or ticket from a document template:
GET /api/v1/bookings/{booking_id}/generate-file/{template_id}?o={org_id}
| Parameter | Description |
|---|---|
template_id |
UUID of the document template to use |
override (query) |
true to regenerate if a file already exists |
Returns a files resource with the generated document.
Booking exports are documented with the other admin export endpoints in Exports.
Common Errors
| Error | Cause | Solution |
|---|---|---|
403 — unauthorized |
Insufficient admin permissions | Verify role has booking management permission |
422 — already checked in |
Duplicate check-in attempt | Check booking status before check-in |
404 — template not found |
Invalid document template UUID | Verify template exists in the organization |