Skip to content

Frontend playbook — how to build screens

Job: build guest and owner UI. Each step is how to build that screen: one winner URL, headers, body, what to store, next screen.

This is the Vue 3 app at frontend-bookdirect-user-app. Live product still talks to Convex; build new screens from these playbooks. Archived Next.js is _legacy/.

API keys: the key in the browser for listing properties is public. Implement proper route guards for security. Core Backend path settings and Middleware Backend should enforce access. See Security and IDOR.

Properties

Hotels, shortlets, and apartments are all Core Backend property rows. Set property_category to hotel | shortlet | apartment.

TypeHow the guest booksHow to build
HotelRoom type + rate planRooms + rate_plan
ShortletUsually the whole placeRates on the property
ApartmentBy unit or whole flatHotel or shortlet pattern — not a third API

Screens

How to buildWinnerPlaybook
Sign up / loginCore BackendSign up and login
Owner lists a propertyCore Backend (+ Middleware Backend file-manager)Owner — set up a property
Guest search / detailPublic key + Core Backend list; Middleware Backend availabilityGuest — search and book
CheckoutCore Backend booking + Middleware Backend payCheckout and pay
Manage / cancelCore Backend list + JWT; Middleware Backend if money movesManage booking

API-first. Middleware Backend wins over Core Backend when both exist.