Welcome to BankChase
Relevant source files
The following files were used as context for generating this wiki page:
BankChase is a comprehensive, production-ready banking platform built using Next.js 16 (App Router), React 19, and Tailwind CSS. The system integrates advanced features such as secure Role-Based Access Control (RBAC), multi-channel durable workflows, and a hybrid database architecture combining PostgreSQL (via Supabase) and MongoDB Atlas. It provides a complete banking experience including dashboard management, real-time transfers, and financial goal tracking.
The project is structured to support both desktop and mobile viewports, featuring an 8-layer security architecture and deep third-party integrations with Plaid and Paystack. Developers can leverage the platform for production-grade fintech applications, utilizing its built-in session management, audit logging, and automated CI/CD pipelines.
Sources: README_START_HERE.md:1-40, COMPLETE_APP_READY.md:3-20, SYSTEM_STATUS_REPORT.md:1-15
Core System Architecture
BankChase utilizes a hybrid approach to data management and application logic. PostgreSQL serves as the primary engine for structured data, ACID compliance, and RBAC enforcement, while MongoDB handles flexible data such as notifications and analytics.
Technical Stack Summary
| Category | Technology |
|---|---|
| Framework | Next.js 16.2 (App Router) |
| Frontend | React 19, Tailwind CSS 4, shadcn/ui |
| Authentication | Clerk, JWT, Bcrypt hashing |
| Primary Database | PostgreSQL (Supabase) |
| Secondary Database | MongoDB Atlas |
| Workflows | Upstash Workflow SDK + QStash |
| Integrations | Plaid (Banking), Paystack (Payments) |
Sources: PROJECT_COMPLETION_SUMMARY.md:144-155, COMPLETE_APP_READY.md:144-155, COMPLETE_APP_README.md:160-170
Application Flow
The following diagram illustrates the high-level request flow from the user interface through the security layers to the hybrid data stores.
The diagram shows the 8-layer security approach where every request must pass through authentication and RBAC guards before accessing specialized API routes or durable workflows.
Sources: README_START_HERE.md:42-55, PROJECT_COMPLETION_SUMMARY.md:85-110
Authentication and RBAC
The system implements a strict Role-Based Access Control (RBAC) model with three primary roles: Customer, Admin, and Auditor. Security is enforced through Bcrypt password hashing, JWT token signing, and SQL-level Row-Level Security (RLS).
User Roles and Permissions
- Customer: Access restricted to their own profile, accounts, and transaction history.
- Admin: Full access to user management, system health, and immutable audit logs.
- Auditor: Read-only access specifically for compliance data and audit trails.
Sources: README_START_HERE.md:95-103, SYSTEM_STATUS_REPORT.md:85-95
Authentication Sequence
This sequence highlights the 2FA requirement during the login process, ensuring that session tokens are only issued after a successful second-factor verification.
Sources: README_START_HERE.md:105-112, SYSTEM_STATUS_REPORT.md:25-45
Banking Modules and Features
BankChase is divided into several functional modules accessible via a responsive dashboard and navigation system.
Account and Transaction Management
Users can manage multiple bank accounts (Checking, Savings) and perform real-time transfers. The system includes a "Zero-Balance Guarantee" where all new accounts are verified at $0.00 upon registration to prevent initial data drift.
Sources: README_START_HERE.md:105-108, COMPLETE_APP_READY.md:17-45
Durable Workflows
The application employs Upstash Workflow SDK to handle long-running and critical operations with automatic retries and state persistence.
- Transaction Workflow: Validates, processes, updates balances, and logs activity.
- Signup Workflow: Handles account creation, immediate welcome emails, and delayed onboarding tips (1-day sleep).
- Notification Workflow: Distributes multi-channel alerts (Email, Push, SMS) based on priority.
Sources: PROJECT_COMPLETION_SUMMARY.md:87-118, README_FINAL.md:30-45
Data Model: Financial Goals
The ER diagram displays the relationship between users and their financial goals, which include tracking target amounts against deadlines.
Sources: COMPLETE_APP_README.md:65-85, BUILD_SUMMARY.md:85-105
API Reference
The project exposes over 98 working endpoints categorized by their functional scope.
Authentication Endpoints
| Endpoint | Method | Description |
|---|---|---|
/api/auth/register | POST | User registration and default account setup |
/api/auth/login | POST | Initial credential check; returns 2FA requirement |
/api/auth/verify-2fa | POST | Validates 6-digit code and issues JWT |
/api/auth/reset-password/request | POST | Triggers token-based password recovery |
Sources: README_START_HERE.md:115-130, PROJECT_COMPLETION_SUMMARY.md:120-135
Financial Operations Endpoints
| Endpoint | Method | Description |
|---|---|---|
/api/banking/accounts | GET | Lists user accounts and real-time balances |
/api/workflows/transaction | POST | Triggers the durable transaction workflow |
/api/plaid/create-link-token | POST | Initiates Plaid Link for external accounts |
/api/customer/transactions | GET | Retrieves paginated transaction history |
Sources: COMPLETE_APP_READY.md:120-140, SYSTEM_STATUS_REPORT.md:120-140
Deployment and Performance
BankChase is production-ready with optimized build metrics and comprehensive CI/CD support through Docker and GitHub Actions.
Deployment Process
- Database Initialization: Run
scripts/init-db.sqlor visit/api/admin/init-dbto set up RLS and tables. - Environment Configuration: Set
MONGODB_URI,NEXT_PUBLIC_SUPABASE_URL, andJWT_SECRET. - Build: Execute
npm run build(average time: 11.3 seconds). - Containerization: Deploy using the multi-stage
Dockerfileanddocker-compose.yml.
Sources: SETUP_COMPLETE.md:15-80, DEPLOYMENT.md:5-50, FINAL_DEPLOYMENT_SUMMARY.md:10-30
Performance Benchmarks
- Login/2FA Response: 20ms - 50ms.
- Dashboard Load: < 1 second.
- Throughput: Supports up to 50K transactions per second and 100K notifications per second.
- Cost Efficiency: Estimated at $0.0045 per user per month for 1M users.
Sources: README_START_HERE.md:205-215, FINAL_DEPLOYMENT_SUMMARY.md:55-70
BankChase provides a robust, scalable, and secure foundation for modern digital banking, ensuring high availability through durable workflows and rigorous security protocols.
Sources: EXECUTIVE_SUMMARY.md:1-25, PROJECT_STATUS_REPORT.md:1-20