โจ Why I Built This
I wanted a dashboard that automatically parses bank transactions from my email, stores them neatly, and visualizes insights using charts โ all with FastAPI, MongoDB, and React.
๐ Features
- ๐ง AI-based detection of bank transactions from emails
- ๐ Frontend dashboard with Pie Chart summary
- ๐ ๏ธ FastAPI backend with MongoDB aggregation
- โก Deployed on Render.com
๐งฑ Tech Stack
- Backend: FastAPI, MongoDB
- Frontend: React
- Email Parsing: Postmark Inbound Webhooks + LLM
- Deployment: Render.com (single service, no Docker needed)
๐ Project Structure
.
โโโ backend
โ โโโ main.py
โ โโโ routers/
โ โโโ frontend/ # frontend build (dist folder goes here)
โโโ frontend
โโโ postmark-dashboard
โโโ public/
โโโ src/
โโโ dist/ # built files (copied to backend/frontend)
๐งช Sample MongoDB Data
You can use the following test data to populate your MongoDB:
[
{
"is_transaction": true,
"bank_name": "ICICI Bank",
"amount": 2590,
"currency": "INR",
"transaction_type": "debit",
"description": "UPI RRN :904123451122",
"confidence": 100,
"created_at": "2025-04-07T07:05:32.997Z"
},
{
"is_transaction": true,
"bank_name": "Bank Of Maharashtra",
"amount": 1920,
"currency": "INR",
"transaction_type": "debit",
"description": "UPI RRN :708312128688",
"confidence": 98,
"created_at": "2025-04-10T10:21:18.234Z"
}
]
๐ How to Run
๐ Setup Webhook using ngrok
To receive emails via webhook in local FastAPI:
ngrok http 8000
Copy the public URL shown (e.g. https://abcd1234.ngrok.io)
Set Postmark inbound webhook to
https://abcd1234.ngrok.io/inbound-webhook
Make sure the FastAPI server is running when using ngrok.
๐ง Backend
git clone https://github.com/Johnnaidu619/PostmarkChallenge.git
cd PostmarkChallenge/backend
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
uvicorn app.main:app --reload
โ ๏ธ Make sure MongoDB is running and connection string is set in
.envwith keys LLM_API_KEY,MONGO_URL,MONGO_DB_NAME
and for frontend .env key is VITE_SITE_URL.
๐ Frontend
cd frontend/postmark-dashboard
npm install
npm run dev
โ Live Demo
๐ Check it here
Top comments (1)
pretty cool setup, feels like something i'd use to get my mess together - you ever run into stuff that surprised you after seeing the data laid out?