Technical overview
Nội dung này hiện chưa có sẵn bằng ngôn ngữ của bạn.
This section is for engineers and operators integrating or deploying the system.
Monorepo layout
Section titled “Monorepo layout”- Orchestration: Turborepo — root
package.jsonscripts callturbo run …forapps/*andpackages/*(seeturbo.json). - Workspaces:
apps/backend,apps/admin-web,apps/vendor-web,apps/docs,packages/shared.
Components
Section titled “Components”| Layer | Location | Notes |
|---|---|---|
| API | apps/backend | NestJS, TypeORM, MySQL, Swagger |
| Admin UI | apps/admin-web | Vite, React, React Router |
| Vendor UI | apps/vendor-web | Vite, React, POS + dashboard |
| Shared UI | packages/shared | Components and helpers |
| Docs | apps/docs | This Starlight site (Astro + Starlight) |
API truth source
Section titled “API truth source”- Interactive OpenAPI and Swagger UI ship with the backend. Default UI path:
/docs(configurable viaSWAGGER_PATH). REST routes use global prefix/api/v1(Swagger UI and OpenAPI JSON are excluded from that prefix). - Set
SWAGGER_ENABLED=falseto disable Swagger (e.g. hardened production).
Where to go next
Section titled “Where to go next”- Architecture — processes, static SPAs, Docker, deploy script.
- Backend architecture (NestJS) — bootstrap, globals, Throttler, ValidationPipe, module layout.
- Backend modules —
auth/admin/vendor/pos/healthroute map. - Backend API catalog — full endpoint list from OpenAPI (regenerate with
npm run openapi:exportinapps/backend). - System test cases (index) — happy/unhappy scenario catalogue by module, coverage checklist, E2E mapping.
- API conventions — prefixes, Swagger URLs, production base URL placeholder.
- Authentication — admin, vendor, and customer auth entrypoints.
- Environment — backend
.env.exampleindex.