Booki
Overview
Overview of the Booki web applications — frontend and backend architecture.
The Booki web app is made up of four Nuxt SPA frontends sharing a common backend API. Each frontend is scoped to a specific audience and role.
Applications
| App | Audience | Auth | Tenancy |
|---|---|---|---|
customer-booki-web-app | Customers | Cookie JWT | Subdomain slug |
owner-booki-web-app | Business owners | Cookie JWT | Org from user profile |
admin-booki-web-app | Super admins | Cookie JWT + admin role | None |
cms-booki-web-app | Public | None | None |
Frontend Architecture
All frontend apps are Single-Page Applications built with Nuxt and deployed to Cloudflare Pages. They share:
- A common Nuxt layer (
codi-layer) providing composables, plugins, and types - Tailwind CSS v4 + DaisyUI for UI
- Phosphor Icons for iconography
- JWT in cookies for authentication
- Nuxt route rules to proxy all
/api/**calls — the browser never sees the real API URL
Backend Architecture
booki-api uses a strict layered architecture:
Route → Middleware → Controller → Service → Repository → MongoDB + Redis
- No Mongoose — MongoDB native driver for performance and flexibility
- Joi for request validation
- Redis for caching (TTL-based, invalidated on writes)
- JWT with revoked-token tracking
- Soft deletes —
deletedAt: nullon all records
Documentation Structure
- Frontend — Component conventions, composables, pages, middleware, plugins, state, and TypeScript
- Backend — Controllers, services, repositories, models, routes, middleware, validation, and error handling