This project is a user management system that allows users to sign up, log in, update their profile, and log out securely. It utilizes FastAPI for the backend and Streamlit for the frontend, ensuring a seamless and modern user experience.
- User authentication (signup, login, logout)
- Profile management (update user details)
- Secure API with JWT authentication
- Streamlit-powered frontend for a smooth UI
- Backend: FastAPI, SQLAlchemy, Pydantic
- Frontend: Streamlit
- Database: PostgreSQL (or SQLite for development)
- Authentication: JWT Tokens
📦 project-directory
┣ 📂 backend
┃ ┣ 📜 main.py # FastAPI application
┃ ┣ 📜 models.py # Database models
┃ ┣ 📜 routes.py # API endpoints
┃ ┣ 📜 auth.py # Authentication logic
┃ ┗ 📜 database.py # Database connection
┣ 📂 frontend
┃ ┣ 📜 app.py # Streamlit UI
┃ ┗ 📜 components.py # UI Components
┣ 📜 README.md # Project documentation
┣ 📜 requirements.txt # Dependencies
┗ 📜 .env # Environment variables
git clone https://github.com/Kingflow-23/Expense-Tracker.gitpython -m venv .
source ./bin/activate # On Linux/Mac
.\Scripts\activate # On Windows python -m pip install --upgrade pip
pip install -r requirements.txtCreate a .env file and add the required configuration:
DATABASE_URL=postgresql://user:password@localhost/db_name
SECRET_KEY=your_secret_key
ACCESS_TOKEN_EXPIRE_MINUTES=30uvicorn backend.main:app --reloadstreamlit run frontend/app.pyBelow is a quick preview of the application in action:
🚪➡️ Click the logout button to securely exit.
| Method | Endpoint | Description |
|---|---|---|
| POST | /auth/signup | Register a new user |
| POST | /auth/login | Authenticate user |
| PUT | /auth/update | Update user profile |
| DELETE | /auth/delete | Delete user |
| POST | /expenses | Register new expense |
| GET | /expenses | Retrieve all expenses |
| GET | /expenses/{id} | Retrieve a specific expense |
| PATCH | /expenses/{id} | Update an existing expense |
| DELETE | /expenses/{id} | Delete an expense |
This project is licensed under the MIT License.
Pull requests are welcome! For major changes, please open an issue first to discuss what you’d like to change.
Made with ❤️ by KingFlow-23

