-
User Registration and Login:
- Traditional username and password authentication.
- Google Sign-In for seamless login.
-
Account Management:
- Add, view, and manage accounts with real-time balance updates.
-
Transaction Management:
- Add, view, and categorize transactions.
- Supports income and expense tracking with auto-balance adjustment.
-
Secure Backend:
- JWT-based authentication with token refresh support.
- Secure API endpoints for managing users, accounts, and transactions.
-
Responsive Design:
- Optimized for web, desktop, and mobile platforms.
- Flutter (Dart) for building the UI.
- Provider for state management.
- google_sign_in for Google OAuth2 authentication.
- Flask for the REST API.
- Flask-JWT-Extended for JWT-based authentication.
- SQLAlchemy for database interactions.
- Google Auth Library for Google OAuth2 validation.
- Install Flutter on your machine.
- Clone the repository:
git clone https://github.com/MyKl-Y/MYAssets cd client
- Install dependencies:
flutter pub get
- Run the app:
flutter run
- Install Python 3.9 or higher.
- Clone the repository:
git clone https://github.com/MyKl-Y/MYAssets cd server
- Create a virtual environment:
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
- Create environment variables (in a
.env
file):SECRET_KEY=<your_secret_key> DATABASE_URL=<your_database_url> JWT_SECRET_KEY=<your_jwt_secret_key>
- Install dependencies:
pip install -r requirements.txt
- Run the server:
flask run
- Launch the Backend:
- Run the Flask server:
flask run
- Run the Flask server:
- Run the Frontend:
- Open a terminal in the client directory and run:
flutter run
- Open a terminal in the client directory and run:
- Login/Register:
- Use the app to create an account or log in using Google OAuth2.
- Add Accounts, Transactions, etc.
- Navigate to the "Add" tab to manage accounts and transactions.
POST /login
: User login with username and password.POST /register
: User registration.POST /google-login
: Google OAuth2 login.POST /refresh
: Refresh JWT access token.
GET /user
: Fetch the logged-in user.
GET /accounts
: Retrieve all user accounts.POST /accounts
: Add a new account.PUT /account/<id>
: Updates an account by its ID.DELETE /account/<id>
: Deletes an account by its ID.
GET /transactions
: Retrieve all user transactions.GET /transactions/<account>
: Retrieve all transactions for a given account.POST /transactions
: Add a new transaction.PUT /transaction/<id>
: Updates a transaction by its ID.DELETE /transaction/<id>
: Deletes a transaction by uts ID.
- Create a new project in the Google Cloud Console.
- Enable the Google Identity Services API.
- Configure OAuth2 credentials and authorized redirect URIs:
- Backend:
http://127.0.0.1:42069
- Frontend: Add any necessary mobile or web platform configurations.
- Backend:
- Replace
"YOUR_GOOGLE_CLIENT_ID"
in the backend code with your client ID.
project/
├── client/ # Flutter frontend
│ ├── lib/
│ │ ├── screens/ # UI screens
│ │ ├── widgets/ # Reusable components
│ │ ├── services/ # API service integration
│ │ └── utils/ # State management and helpers
│ ├── pubspec.yaml # Frontend dependencies
│ └── assets/ # Assets
│ └── images/ # Images
├── server/ # Flask backend
│ ├── app/
│ │ ├── api.py # API routes
│ │ ├── models.py # Database models
│ │ └── utils.py # Utility functions
│ └── requirements.txt # Backend dependencies
├── README.md # Project documentation
└── todo.md # List of features to implement
- Fork the repository
- Create a new branch:
git checkout -b feature-name
- Commit your changes:
git commit -m "Add feature-name..."
- Push to the branch:
git push origin feature-name
- Open a pull request.
For questions or support, please reach out to the maintainer(s):
- Email: michaelyyim@gmail.com
- GitHub: MyKl-Y