Backend API
ThePlugg backend is a Node.js/Express REST API built with TypeScript and Prisma ORM.
Overview
The backend API provides:
- User authentication and authorization
- Job management
- Provider and service seeker profiles
- Real-time messaging
- Payment processing
- Admin functionality
- SMS notifications via BulkSMS
Tech Stack
- Runtime: Node.js
- Framework: Express.js
- Language: TypeScript
- ORM: Prisma
- Database: PostgreSQL
- Storage: AWS S3
- Push Notifications: OneSignal
Project Structure
ThePlugg-backend/
├── src/
│ ├── controllers/ # Request handlers
│ ├── services/ # Business logic
│ ├── routes/ # API routes
│ ├── middleware/ # Express middleware
│ └── lib/ # Utilities
├── prisma/
│ ├── schema.prisma # Database schema
│ └── migrations/ # Database migrations
└── dist/ # Compiled JavaScript
Key Features
- RESTful API design
- JWT-based authentication
- Role-based access control (Provider, Service Seeker, Admin)
- Rate limiting
- Error handling
- Input validation
- Database migrations