A modern cloud-based solution for digitizing government permit and licensing services, built with TypeScript, Node.js, and PostgreSQL.
Cloud Government is a comprehensive backend solution designed to modernize government services by providing a secure, efficient, and user-friendly platform for managing permits, licenses, and other government-related applications. Built with scalability and security in mind, it aims to streamline the interaction between citizens and government agencies.
- Digital Permit Applications: Streamlined application process for various permits and licenses
- Document Management: Secure upload and verification of required documents
- User Management: Role-based access control for citizens, staff, and administrators
- Application Tracking: Real-time status updates and notifications
- Secure File Storage: AWS S3 integration for document storage
- API Documentation: Comprehensive API documentation for frontend integration
- Node.js (v14 or higher)
- PostgreSQL (v12 or higher)
- AWS Account (for S3 storage)
- npm or yarn
- Clone the repository
git clone https://github.com/al0olo/cloud-government.git
cd cloud-government
- Install dependencies
npm install
- Set up environment variables
cp .env.example .env
# Edit .env with your configuration
- Run database migrations
npm run migrate
- Start the development server
npm run dev
Create a .env
file in the root directory with the following variables:
# Application
PORT=3000
NODE_ENV=development
# Database
DB_HOST=localhost
DB_PORT=5432
DB_NAME=your_database_name
DB_USER=your_database_user
DB_PASSWORD=your_database_password
# JWT
JWT_SECRET=your_jwt_secret
JWT_EXPIRES_IN=24h
# AWS
AWS_ACCESS_KEY_ID=your_access_key
AWS_SECRET_ACCESS_KEY=your_secret_key
AWS_REGION=your_region
S3_BUCKET=your_bucket_name
src/
├── config/ # Configuration files
├── controllers/ # Request handlers
├── middleware/ # Custom middleware
├── models/ # Database models
├── routes/ # API routes
├── services/ # Business logic
├── types/ # TypeScript type definitions
├── utils/ # Utility functions
└── database/ # Migrations and seeds
API documentation is available at /api/docs
when running the server in development mode.
-
Auth
POST /api/v1/auth/register
- Register new userPOST /api/v1/auth/login
- User login
-
Applications
POST /api/v1/applications
- Create new applicationGET /api/v1/applications
- List applicationsGET /api/v1/applications/:id
- Get application details
-
Documents
POST /api/v1/documents
- Upload documentGET /api/v1/documents/:id
- Get document details
- JWT authentication
- Role-based access control
- Request validation
- Rate limiting
- Secure file upload
- Input sanitization
Run the test suite:
npm run test
Run tests with coverage:
npm run test:coverage
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Abdullah Farag (al0olo)
- GitHub: @al0olo
- Express.js - Web framework
- TypeScript - Programming language
- PostgreSQL - Database
- AWS S3 - File storage
⭐️ If you find this project useful, please consider giving it a star!