A production-ready SaaS boilerplate built with Express.js, designed to help developers kickstart their projects with authentication, authorization, background job processing, caching, and more.
✅ JWT Authentication – Secure user authentication out of the box.
✅ Role-Based Access Control (RBAC) – Multi-tenant support with role & permission management.
✅ Bull Queue Manager – Handle background jobs efficiently with BullMQ.
✅ Scheduled Jobs with Agenda.js – Manage cron jobs, periodic tasks, and delayed executions.
✅ Redis Integration – Supercharge performance with caching and queue processing.
✅ Security Best Practices – Includes helmet, CORS, rate limiting, and more.
✅ Scalable Modular Architecture – Easily extend and manage features.
git clone https://github.com/nitish754/express-starter-kit.git
cd express-starter-kit
2️⃣ Install Dependencies
npm install
3️⃣ Configure Environment Variables
Create a .env file in the root directory and add the following:
PORT=3000
JWT_SECRET=your-secret-key
REDIS_URL=redis://localhost:6379
DATABASE_URL=mongodb://localhost:27017/yourdb
4️⃣ Start the Local Server
npm run dev
5️⃣ Seed Initial Roles and Permissions
npm run db:seed
📁 Project Structure
📂 express-starter-kit
├── 📂 src
│ ├── 📂 modules # All features are organized as modules
│ │ ├── 📂 auth # Authentication module
│ │ │ ├── controllers # Request handlers for authentication
│ │ │ ├── routes # API routes for authentication
│ │ │ ├── services # Business logic for authentication
│ │ │ ├── models # Database models for authentication
│ │ │ ├── utils # Helper functions for authentication
│ │ ├── 📂 user # User module (similar structure)
│ │ ├── 📂 jobs # Queue jobs & scheduled tasks module
│ ├── 📂 config # Global configurations (DB, Redis, etc.)
│ ├── 📂 middlewares # Global middlewares (Auth, CORS, etc.)
│ ├── 📂 utils # Global utility functions
│ ├── server.js # Main server file
├── .env.example # Environment variable template
├── package.json # Dependencies and scripts
├── README.md # Project documentation
📌 Contributing
Contributions are welcome! Please follow these steps:
Fork the repository.
Create a new branch (feature/new-feature).
Commit your changes and push the branch.
Open a pull request.
📌 License
This project is open-source and available under the MIT License.
🌟 If you find this useful, give it a ⭐ on GitHub!
🔗 GitHub Repository: https://github.com/nitish754/express-starter-kit
Happy coding! 🚀