Developer Guide
BookingFlow is designed to be driven by humans and machines. The Operations API is a REST interface that exposes the same capabilities as the app — search availability, create bookings, manage rates and inventory, record electricity meter readings, generate invoices, and receive signed webhooks — so any AI assistant, script, or integration holding an API key can operate a park end-to-end.
What you can do with the API
- Search availability and price stays for any accommodation type and date range
- Create and manage bookings with server-side inventory checks — the API cannot oversell or undercharge
- Manage inventory — accommodation types, pitches, rates, and allocations
- Record meter readings and generate electricity invoices in one idempotent call
- Sync customers and documents with your own systems
- Receive webhooks for every booking, payment, and invoice event
Getting started
- Get an API key — keys are issued in the BookingFlow dashboard and shown exactly once. Treat them like passwords.
- Read the conventions — authentication, error envelopes, idempotency, pagination, expansion, metadata, and webhooks.
- Pick a resource from the reference below and start building.
API reference
The full reference lives in the Operations API section:
| Resource | What it covers |
|---|---|
| Quickstart | First requests, curl, and the agent workflow (paste meter readings → generate invoices) |
| Conventions | Authentication, errors, idempotency, pagination, expansion, metadata, webhooks |
| Accommodations · Caravans · Pitches | Inventory: what you sell and where guests stay |
| Availability · Rates | Search open capacity and manage pricing |
| Bookings · Customers | The core booking lifecycle and guest records |
| Stats | Read-only operational numbers: arrivals, departures, occupancy, revenue |
| Meter readings · Invoices | Electricity billing: readings in, invoices out |
| Events · Webhook endpoints | Signed notifications for everything that happens |
The machine-readable contract is the
OpenAPI 3.1 specification
in functions/openapi.yaml, which a route-drift test keeps in sync with the
implemented Express routes.