Aller au contenu principal

Introduction

This document outlines the complete fullstack architecture for EMTB Tax Claim Management System, including backend systems, frontend implementation, and their integration. It serves as the single source of truth for AI-driven development, ensuring consistency across the entire technology stack.

This unified approach combines what would traditionally be separate backend and frontend architecture documents, streamlining the development process for modern fullstack applications where these concerns are increasingly intertwined.

Starter Template or Existing Project​

Based on the PRD analysis, this is a brownfield enhancement project built on:

Current Architecture Foundation:

  • Backend: Existing NestJS API with TypeScript, TypeORM, PostgreSQL database, Swagger documentation
  • Frontend: Next.js 14 with App Router, React 18, Material-UI (MUI), Auth0 authentication
  • Infrastructure: Cloud deployment with independent API and frontend services
  • Repository: Monorepo structure with apps/api and apps/frontend

Pre-configured Constraints:

  • Must maintain existing Auth0 authentication integration
  • Database schema enhancement required (adding minimal RBAC tables)
  • Current PostgreSQL + TypeORM setup must be preserved
  • Material-UI components and existing user experience patterns must be maintained
  • Zero-downtime deployment requirements

Architectural Decisions Already Made:

  • TypeScript across both frontend and backend
  • TypeORM for type-safe database operations
  • Independent service deployment model
  • Auth0 for user authentication (extending to authorization)

Change Log​

DateVersionDescriptionAuthor
2025-09-09v1.0Initial fullstack architecture for RBAC implementationWinston (Architect)