https://github.com/aritrac1/expenseflow-backend
Backend REST API for expense tracking, built with Node.js, Express, TypeScript, and MongoDB. Purpose: To learn Mongodb aggregation pipeline and RBAC
https://github.com/aritrac1/expenseflow-backend
aggregation-pipeline backend-api expense-tracker expense-tracking express jwt mongodb mongodb-aggregation-pipelines nodejs rate-limiting rbac rest-api role-based-access-control swagger-docs typescript
Last synced: 8 days ago
JSON representation
Backend REST API for expense tracking, built with Node.js, Express, TypeScript, and MongoDB. Purpose: To learn Mongodb aggregation pipeline and RBAC
- Host: GitHub
- URL: https://github.com/aritrac1/expenseflow-backend
- Owner: AritraC1
- Created: 2026-06-13T13:13:54.000Z (about 1 month ago)
- Default Branch: master
- Last Pushed: 2026-06-13T17:44:09.000Z (about 1 month ago)
- Last Synced: 2026-06-13T19:07:23.267Z (about 1 month ago)
- Topics: aggregation-pipeline, backend-api, expense-tracker, expense-tracking, express, jwt, mongodb, mongodb-aggregation-pipelines, nodejs, rate-limiting, rbac, rest-api, role-based-access-control, swagger-docs, typescript
- Language: TypeScript
- Homepage:
- Size: 81.1 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ExpenseFlow
ExpenseFlow is a role-based Expense Management REST API built with **Node.js**, **Express.js**, **TypeScript**, and **MongoDB**.
The application allows users to manage their expenses while administrators can access system-wide analytics and management features.
## Features
* JWT Authentication
* Role-Based Access Control (Admin/User)
* Expense CRUD Operations
* MongoDB Aggregation Pipelines
* Rate Limiting
* Swagger API Documentation
* Docker Support
* Docker Compose Setup
* Pagination & Filtering
* Secure Password Hashing with bcrypt
## Tech Stack
* Node.js
* Express.js
* TypeScript
* MongoDB
* Mongoose
* JWT
* bcrypt
* Swagger
* Docker
* Docker Compose
## Analytics
Implemented MongoDB Aggregation Pipelines for:
* Total Expense by Category
* Top Spending Users
* Average Expense Amount
* Monthly Expense Reports
## Getting Started
### Install Dependencies
```bash
npm install
```
### Run Development Server
```bash
npm run dev
```
### Build Project
```bash
npm run build
```
### Start Production Build
```bash
npm start
```
## Run with Docker
```bash
docker compose up --build -d
```
## API Documentation
Swagger documentation is available at:
```text
http://localhost:3000/api-docs
```
---