FinGuard is a full-stack transaction risk monitoring platform that simulates how financial analysts can investigate suspicious transactions, review risk factors, and make approval or blocking decisions.
The project combines a Next.js + TypeScript frontend, FastAPI + Python backend, PostgreSQL, Redis, JWT authentication, SQLAlchemy, Docker, and a deterministic rule-based risk engine.
Note: FinGuard is an educational portfolio project. Its risk engine is a deterministic demonstration and is not intended for real banking or production fraud-detection decisions.
FinGuard provides an end-to-end transaction investigation workflow:
Transaction
↓
Risk Analysis
↓
Risk Factors
↓
Analyst Investigation
↓
Approve / Block
↓
Status Updated
An analyst can open a transaction, review its risk information, investigate individual risk factors, and update the final transaction decision.
- JWT-based authentication
- Interactive transaction dashboard
- Transaction history and filtering
- Rule-based risk scoring
- Explainable risk factors
- Suspicious and high-risk transaction detection
- Transaction investigation modal
- Approve or block transaction workflow
- Persistent transaction status updates
- Dashboard statistics
- PostgreSQL data persistence
- Redis caching
- FastAPI OpenAPI documentation
- Pytest backend testing
- Docker Compose development environment
- Responsive Next.js/TypeScript UI
FinGuard uses a deterministic rule-based risk engine so that every score can be reproduced and explained.
The engine considers signals such as:
- Large transaction amounts
- New or unfamiliar devices
- Unusual transaction hours
- Unusual locations
- Rapid repeated transactions
Each transaction receives:
Risk Score
Risk Level
Risk Factors
Transaction Status
This makes the demonstration easy to test and understand without relying on a black-box model.
The transaction review interface allows an analyst to investigate a flagged transaction before making a decision.
For example:
Luxury Retailer
$7,600.00
Unknown location
New device
High risk
95/100
The analyst can then choose:
Approve transaction
OR
Keep blocked
After the decision:
- The transaction status is updated through the backend API.
- The updated transaction is reflected in the dashboard.
- The investigation modal displays the new status.
- A confirmation notification informs the analyst that the decision was recorded.
┌──────────────────────────┐
│ Next.js + TypeScript │
│ Frontend UI │
└────────────┬─────────────┘
│
REST API
│
▼
┌──────────────────────────┐
│ FastAPI + Python │
│ Backend API │
└────────────┬─────────────┘
│
┌───────────────┼───────────────┐
│ │ │
▼ ▼ ▼
┌────────────┐ ┌────────────┐ ┌──────────────┐
│ PostgreSQL │ │ Redis │ │ Risk Engine │
│ │ │ │ │ │
│ Users │ │ Dashboard │ │ Risk Score │
│ Transactions│ │ Cache │ │ Risk Factors │
│ Alerts │ │ │ │ │
└────────────┘ └────────────┘ └──────────────┘
Layer Technologies
Frontend Next.js, React, TypeScript Backend Python, FastAPI ORM SQLAlchemy Database PostgreSQL Caching Redis Authentication JWT, password hashing Testing Pytest Infrastructure Docker, Docker Compose
FinGuard/
├── backend/ # FastAPI API, database, authentication & risk engine
├── frontend/ # Next.js dashboard and transaction UI
├── screenshots/ # Application screenshots
├── .env.example # Environment variable template
├── .gitignore
├── docker-compose.yml
└── README.md
- Docker Desktop
- Git
git clone https://github.com/Aaryan1265/FinGuard.git
cd FinGuardCreate a local .env file from the provided example.
On Windows PowerShell:
Copy-Item .env.example .envOn macOS/Linux:
cp .env.example .envDo not commit .env to Git.
From the project root:
docker compose up --buildOpen another terminal:
docker compose exec backend python -m app.seedUse the demo credentials displayed on the FinGuard login page:
Email: demo@finguard.com
Password: DemoPass123!
Service URL
Frontend http://localhost:3000 Backend http://localhost:8000 API Documentation http://localhost:8000/docs
The FastAPI documentation provides an interactive view of the available backend endpoints.
POST /api/auth/register
POST /api/auth/login
GET /api/dashboard/stats
GET /api/transactions
POST /api/transactions
GET /api/transactions/{id}
PATCH /api/transactions/{id}/status
GET /api/health
Run the backend tests with:
cd backend
pytestThe test suite verifies the deterministic behavior of the risk engine.
cd backend
python -m venv .venvWindows:
.venv\Scripts\activatemacOS/Linux:
source .venv/bin/activateInstall dependencies:
pip install -r requirements.txtRun FastAPI:
uvicorn app.main:app --reloadIn another terminal:
cd frontend
npm install
npm run devThe frontend will run at:
http://localhost:3000
This project demonstrates practical experience with:
- Full-stack application architecture
- REST API development
- React and TypeScript
- FastAPI backend development
- JWT authentication
- Relational database design
- SQLAlchemy ORM
- Redis caching
- Explainable rule-based risk scoring
- Interactive analyst workflows
- API error handling
- Docker containerization
- Automated backend testing
Potential future enhancements include:
- Historical transaction charts
- More advanced anomaly detection
- Machine-learning-based risk scoring
- Role-based access control
- Analyst audit logs
- Email and notification alerts
- Advanced transaction analytics
- CI/CD integration
- Production monitoring and observability
These are planned ideas and are not presented as currently implemented features.
Aaryan Shukla
Computer Programming & Analysis
Seneca Polytechnic
FinGuard was created as a student portfolio project for educational and demonstration purposes.
The application uses simulated transaction data and a deterministic rule-based risk engine. It should not be used to make real financial, banking, credit, or fraud-detection decisions.





