A blockchain-powered platform for transparent and efficient disaster relief coordination and aid distribution.
AidChain leverages blockchain technology to bring transparency, accountability, and efficiency to disaster response efforts. By utilizing the Stellar network, the platform enables real-time tracking of aid distribution, donor verification, and ensures that resources reach those who need them most.
- Transparent Aid Tracking: Real-time monitoring of aid distribution from donor to beneficiary using blockchain ledger
- Smart Contract Automation: Automated distribution triggers based on verified disaster events and recipient verification
- Donor Dashboard: Complete visibility into where donations go and their impact
- Beneficiary Management: Secure verification and registration system for aid recipients
- Multi-Asset Support: Handle various forms of aid including monetary donations, supplies, and services
- Geolocation Integration: Map-based visualization of disaster zones and distribution centers
- Mobile-First Design: Accessible interface for field workers and beneficiaries in affected areas
- NestJS: Enterprise-grade Node.js framework for building scalable server-side applications
- TypeScript: Type-safe development
- PostgreSQL: Primary database for application data
- Redis: Caching and session management
- React: Modern UI library for building interactive user interfaces
- TypeScript: Type-safe frontend development
- Tailwind CSS: Utility-first styling
- React Query: Data fetching and state management
- Stellar: Fast, low-cost blockchain network for asset transfers
- Stellar SDK: Integration with Stellar network
- Soroban: Smart contract platform on Stellar (optional for advanced logic)
- Docker: Containerization for consistent deployment
- JWT: Secure authentication
- WebSocket: Real-time updates
- Google Maps API: Geolocation services
- Node.js (v18 or higher)
- PostgreSQL (v14 or higher)
- Redis (v6 or higher)
- Docker (optional)
- Stellar account (testnet for development)
# Clone the repository
git clone https://github.com/Servora/aidchain.git
cd aidchain
# Install backend dependencies
cd backend
npm install
# Install frontend dependencies
cd ../frontend
npm installCreate a .env file in the backend directory:
# Database
DATABASE_URL=postgresql://user:password@localhost:5432/aidchain
REDIS_URL=redis://localhost:6379
# Stellar Network
STELLAR_NETWORK=testnet
STELLAR_HORIZON_URL=https://horizon-testnet.stellar.org
STELLAR_DISTRIBUTION_SECRET=YOUR_SECRET_KEY
# JWT
JWT_SECRET=your-secret-key
JWT_EXPIRATION=7d
# API Keys
GOOGLE_MAPS_API_KEY=your-api-keyCreate a .env file in the frontend directory:
REACT_APP_API_URL=http://localhost:3000
REACT_APP_STELLAR_NETWORK=testnet
REACT_APP_GOOGLE_MAPS_API_KEY=your-api-key# Start backend server
cd backend
npm run start:dev
# Start frontend development server
cd frontend
npm startThe backend will run on http://localhost:3000 and the frontend on http://localhost:3001.
# Build and run with Docker Compose
docker-compose up -daidchain/
├── backend/
│ ├── src/
│ │ ├── auth/
│ │ ├── donors/
│ │ ├── beneficiaries/
│ │ ├── distributions/
│ │ ├── stellar/
│ │ ├── common/
│ │ └── main.ts
│ ├── test/
│ └── package.json
├── frontend/
│ ├── src/
│ │ ├── components/
│ │ ├── pages/
│ │ ├── services/
│ │ ├── hooks/
│ │ ├── utils/
│ │ └── App.tsx
│ └── package.json
├── docker-compose.yml
└── README.md
- Auth Module: User authentication and authorization
- Donors Module: Donor registration and donation management
- Beneficiaries Module: Recipient verification and registration
- Distributions Module: Aid distribution coordination and tracking
- Stellar Module: Blockchain integration and transaction handling
- Analytics Module: Reporting and impact metrics
- Dashboard: Overview of active disasters and distribution status
- Donation Portal: Interface for donors to contribute
- Distribution Map: Geographic visualization of aid delivery
- Beneficiary Portal: Registration and aid claim interface
- Admin Panel: Platform management and verification tools
API documentation is available at http://localhost:3000/api/docs when running the backend server.
# Backend unit tests
cd backend
npm run test
# Backend e2e tests
npm run test:e2e
# Frontend tests
cd frontend
npm testWe welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
- All sensitive data is encrypted
- Stellar keys are stored securely using environment variables
- API endpoints are protected with JWT authentication
- Regular security audits recommended for production deployment
This project is licensed under the MIT License - see the LICENSE file for details.
- Mobile application (React Native)
- AI-powered disaster prediction
- Integration with IoT sensors for real-time disaster monitoring
- Multi-language support
- Offline-first capabilities for disaster zones
- Integration with traditional banking systems
- Stellar Development Foundation for blockchain infrastructure
- Open-source community for various tools and libraries
- Disaster relief organizations for domain expertise