a contribution project that incorporates both FastAPI and flutter and dart
# Changa
> Group Contribution Management Platform
Flutter + FastAPI + PostgreSQL | M-Pesa Daraja + Airtel Money
---
## What is Changa?
Changa lets groups pool money for shared projects. Each member sees real-time funding progress, their percentage contribution, and how much is still needed. Projects can be public or private, and teams can be formed within a project.
It comes with premium features like budgeting and more.
---
## Stack
| Layer | Technology |
|-------|-----------|
| Mobile | Flutter 3.41 + Dart 3.11 |
| State | Riverpod 2.x |
| HTTP | Dio 5.x |
| Backend | FastAPI 0.111 (Python 3.11) |
| Database | PostgreSQL 15 |
| Auth | JWT + bcrypt |
| Payments | M-Pesa Daraja + Airtel Money |
| DevOps | Docker + Docker Compose |
---
## Project Structure
```
CHANGA/
├── backend/ # FastAPI Python API
│ ├── app/
│ │ ├── core/ # Config, security, JWT
│ │ ├── models/ # Database tables
│ │ ├── routers/ # API endpoints
│ │ ├── schemas/ # Request/response shapes
│ │ └── services/ # M-Pesa, Airtel integrations
│ ├── tests/
│ ├── requirements.txt
│ └── .env.example
├── mobile/ # Flutter app (Clean Architecture)
│ └── lib/
│ ├── core/
│ └── features/ # auth, projects, payments, profile
├── infrastructure/ # Docker, Nginx
├── docs/
└── scripts/
```
---
## Quick Start
### Backend
```bash
cd backend
python3 -m venv venv && source venv/bin/activate
pip install -r requirements.txt
cp .env.example .env # fill in your values
uvicorn app.main:app --reload --port 8000
# Docs →
localhost
```
### Flutter
```bash
cd mobile
flutter pub get
flutter pub run build_runner build --delete-conflicting-outputs
flutter run
```
### Full Stack (Docker)
```bash
docker-compose up --build
```
---
## Key API Endpoints
| Method | Endpoint | Description |
|--------|----------|-------------|
| POST | /auth/register | Create account |
| POST | /auth/login | Login → JWT tokens |
| GET | /projects | List p …