StudyNotion is a scalable, production-deployed EdTech platform where instructors publish courses and students enroll, pay, and learn โ with full RBAC, payment gateway, and cloud media management.
| Feature | Detail |
|---|---|
| ๐ JWT Auth + RBAC | 3 roles (Student, Instructor, Admin) with 15+ protected API endpoints |
| ๐ณ Payment Gateway | Full Razorpay checkout flow with order creation & webhook verification |
| โ๏ธ Cloud Media | Cloudinary integration for video/image storage with CDN delivery |
| ๐ Production Deployed | Vercel (frontend) + Render (backend) โ 99% uptime |
| ๐๏ธ Scalable Architecture | MVC pattern, modular routers, and service-layer separation |
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ CLIENT (React.js) โ
โ Redux Toolkit โ Tailwind CSS โ Axios โ React Router โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ REST API (JSON / HTTPS)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ SERVER (Node + Express) โ
โ Auth Middleware โ RBAC Guards โ MVC Controllers โ
โ JWT Verification โ Razorpay SDK โ Cloudinary SDK โ
โโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโ
โ โ
โโโโโโโโโโโโผโโโโโโโโโโโ โโโโโโโโโโโโโโผโโโโโโโโโโโโโ
โ MongoDB Atlas โ โ Cloudinary CDN โ
โ (Primary Database) โ โ (Media Storage) โ
โโโโโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโโ
- Browse and search course catalog with filters
- Secure Razorpay checkout for course enrollment
- Video player with progress tracking per lecture
- Profile management with avatar upload
- Wishlist and cart functionality
- Create / edit / delete courses with rich content editor
- Upload videos directly to Cloudinary
- Dashboard with revenue insights and enrollment stats
- Manage course sections and sub-sections dynamically
- Platform-level analytics overview
- Instructor and student account management
- Course approval and moderation controls
- JWT Access Tokens with secure httpOnly cookie support
- Password hashing with bcrypt (salt rounds: 10)
- OTP-based email verification via NodeMailer
- Role-based route protection on both frontend & backend
| Technology | Purpose |
|---|---|
| React.js 18 | UI library with component-based architecture |
| Redux Toolkit | Global state management (auth, cart, course) |
| Tailwind CSS | Utility-first styling |
| React Router v6 | Client-side navigation with protected routes |
| Axios | HTTP client with request/response interceptors |
| Vite | Lightning-fast dev server and build tool |
| Technology | Purpose |
|---|---|
| Node.js + Express.js | RESTful API server with MVC architecture |
| MongoDB + Mongoose | NoSQL database with schema validation |
| JWT (jsonwebtoken) | Stateless authentication |
| Bcrypt | Secure password hashing |
| NodeMailer | OTP and notification emails |
| Multer | File upload middleware |
| Service | Role |
|---|---|
| MongoDB Atlas | Managed cloud database |
| Cloudinary | Video/image CDN and storage |
| Razorpay | Payment processing |
| Vercel | Frontend hosting |
| Render | Backend hosting |
StudyNotion/
โโโ ๐ src/ # React Frontend
โ โโโ ๐ components/
โ โ โโโ ๐ Auth/ # Login, Signup, OTP forms
โ โ โโโ ๐ Dashboard/ # Role-specific dashboards
โ โ โโโ ๐ Course/ # Course cards, player, catalog
โ โ โโโ ๐ Common/ # Navbar, Footer, Spinner
โ โโโ ๐ pages/ # Route-level page components
โ โโโ ๐ services/ # API call functions (apiConnector)
โ โโโ ๐ slices/ # Redux Toolkit slices
โ โโโ ๐ utils/ # Helper functions
โ
โโโ ๐ server/ # Express Backend
โ โโโ ๐ controllers/ # Route handler logic
โ โ โโโ Auth.js
โ โ โโโ Course.js
โ โ โโโ Payment.js
โ โ โโโ Profile.js
โ โโโ ๐ middlewares/ # Auth, RBAC, file upload
โ โโโ ๐ models/ # Mongoose schemas
โ โ โโโ User.js
โ โ โโโ Course.js
โ โ โโโ Section.js
โ โ โโโ SubSection.js
โ โโโ ๐ routes/ # Express route definitions
โ โโโ ๐ utils/ # Mailer, Cloudinary helpers
โ โโโ index.js # Server entry point
โ
โโโ ๐ README.md
// User Model (simplified)
{
firstName, lastName, email,
password, // bcrypt hashed
accountType, // "Student" | "Instructor" | "Admin"
courses, // ref โ Course[]
courseProgress, // ref โ CourseProgress[]
image // Cloudinary URL
}
// Course Model (simplified)
{
courseName, courseDescription, price,
instructor, // ref โ User
studentsEnrolled: [ref โ User],
courseContent: [ref โ Section],
thumbnail, // Cloudinary URL
status // "Draft" | "Published"
}- Node.js v18+
- MongoDB Atlas account
- Cloudinary account
- Razorpay account (test mode works)
git clone https://github.com/prashantsaraswat1/Study_Notion.git
cd Study_Notioncd server
npm installCreate server/.env:
MONGODB_URL=your_mongodb_atlas_uri
JWT_SECRET=your_super_secret_key
JWT_EXPIRE=24h
# Cloudinary
CLOUD_NAME=your_cloud_name
API_KEY=your_api_key
API_SECRET=your_api_secret
# Razorpay
RAZORPAY_KEY=your_razorpay_key
RAZORPAY_SECRET=your_razorpay_secret
# NodeMailer
MAIL_HOST=smtp.gmail.com
MAIL_USER=your_email@gmail.com
MAIL_PASS=your_app_password
PORT=4000cd .. # back to root
npm installCreate .env:
REACT_APP_BASE_URL=http://localhost:4000/api/v1
REACT_APP_RAZORPAY_KEY=your_razorpay_key# Terminal 1 โ Backend
cd server && npm run dev
# Terminal 2 โ Frontend
npm startOpen http://localhost:3000 in your browser. ๐
| Method | Endpoint | Auth | Description |
|---|---|---|---|
POST |
/api/v1/auth/signup |
Public | Register new user |
POST |
/api/v1/auth/login |
Public | Login + JWT |
POST |
/api/v1/auth/sendotp |
Public | Send OTP to email |
GET |
/api/v1/course/getAllCourses |
Public | Fetch all courses |
POST |
/api/v1/course/createCourse |
Instructor | Create new course |
PUT |
/api/v1/course/editCourse |
Instructor | Edit course |
DELETE |
/api/v1/course/deleteCourse |
Instructor | Delete course |
POST |
/api/v1/payment/capturePayment |
Student | Initiate payment |
POST |
/api/v1/payment/verifyPayment |
Student | Verify & enroll |
GET |
/api/v1/profile/getUserDetails |
Any Auth | Get profile |
PUT |
/api/v1/profile/updateProfile |
Any Auth | Update profile |
Full API documentation: Postman Collection (add your exported collection)
- 20+ REST APIs with consistent error handling and response structure
- 15+ protected routes secured via JWT middleware + RBAC guards
- Cloudinary CDN for sub-200ms media delivery
- MongoDB indexing on frequently queried fields (email, courseId)
- Redux Toolkit for zero-redundancy API calls via cached state
# Run backend tests (if configured)
cd server && npm test
# Lint frontend
npm run lintManual testing done via Postman โ collection available in
/postman_collection.json
| Layer | Platform | Status |
|---|---|---|
| Frontend | Vercel | |
| Backend | Render | |
| Database | MongoDB Atlas | โ Live |
| Media | Cloudinary | โ Live |
- Next.js migration โ SSR for SEO and performance
- TypeScript โ End-to-end type safety
- Docker โ Containerized deployment
- Redis caching โ Course catalog caching layer
- WebSocket notifications โ Real-time enrollment alerts
- AI-powered quiz generator โ Auto-generate MCQs from course content
- Mobile app โ React Native companion app
Contributions are welcome! Please follow these steps:
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Commit your changes:
git commit -m 'feat: add amazing feature' - Push to branch:
git push origin feature/amazing-feature - Open a Pull Request
Please read CONTRIBUTING.md for details on our code of conduct.
Distributed under the MIT License. See LICENSE for more information.
If this project helped you or impressed you, please โญ star the repo โ it means a lot!
Made with โค๏ธ and a lot of โ by Prashant Saraswat





