-
Notifications
You must be signed in to change notification settings - Fork 7
Architecture
hieuck edited this page Jul 5, 2026
·
1 revision
Smart ERP Next is a pnpm/Turbo monorepo.
| Path | Responsibility |
|---|---|
apps/api |
NestJS REST API, business logic, database migrations |
apps/web |
Next.js PWA dashboard and storefront |
packages/database |
Drizzle schema, migrations, shared DB client |
packages/shared |
Shared constants, types, utilities |
packages/types |
Common TypeScript definitions |
packages/utils |
Helpers (currency, date, string, sanitize) |
packages/validation |
Zod schemas for domain models |
- API versioning via
X-API-Versionheader and URL path (/api/v1/...). - Global response format via
ResponseFormatInterceptor. - JWT access + refresh tokens; API keys for service integrations.
- Swagger/OpenAPI available at
/api/docswhen running locally.
See docs/adr/ for architecture decision records.