USSD + WhatsApp health check-in system for Eswatini"
# Sibonga Health π₯
**USSD + WhatsApp Health Check-in System for Eswatini**
Patient dials `*123#` β Reports health status β Nurse dashboard shows red alerts instantly β Export data for MOH.
Built for **Mbabane Clinic**, Eswatini. Works on Nokia phones. Zero data required.
---
## π― Features
| Feature | What It Does | User |
|---------|-------------|------|
| **USSD Menu** | Patient dials `*123#` β Answers 3 questions in siSwati | Patient (any phone) |
| **Red Alerts** | Chest pain β Alert on nurse dashboard in real-time | Nurse (laptop) |
| **SMS Reminders** | Auto-SMS at 7am day before appointment | Patient |
| **Nurse Dashboard** | See all patients who checked in + urgent cases | Nurse (web) |
| **CSV Export** | Download daily report for MOH | Clinic manager |
| **Self-Registration** | Patient dials `*123*4#` to register themselves | Patient |
---
## β‘ Quick Start (5 minutes)
### 1. Install Dependencies
```bash
pip install -r requirements.txt
```
### 2. Setup Database
**Option A: Local PostgreSQL**
```bash
creatdb sibonga_db
psql sibonga_db OK
curl -X POST
localhost \
-d "phoneNumber=26876123456&text=1*1"
# Check-in -> Urgent
curl -X POST
localhost \
-d "phoneNumber=26876123456&text=1*3"
```
### Test with Africa's Talking Sandbox
1. Sign up:
africastalking.com
2. Go to USSD β Create app
3. Set callback URL: `
your-railway-url`
4. Use Africa's Talking simulator to test
### Test Dashboard
1. Create patient in database: `INSERT INTO patient (phone, name, next_appointment) VALUES ('+26876123456', 'Test', '2026-04-20');`
2. Generate check-in: `curl -X POST
localhost -d "phoneNumber=26876123456&text=1*3"`
3. Visit:
localhost
4. You should see red alert
---
## π Deployment to Production
### Deploy on Railway.app (Recommended)
1. **Push to GitHub** (if not already)
```bash
git push origin main
```
2. **Create Railway project**
- Go to
railway.app
- Click β¦