# Project Case Study: SAMS SCHOOL LMS

> Built by Gyanranjan Priyam (https://www.priyam.tech)
> Tech Stack: Next.js 15, TypeScript, Prisma, PostgreSQL, TailwindCSS, Shadcn UI, Stripe
> Timeline: 2025 | Category/Company: EdTech / LMS

- Canonical URL: https://www.priyam.tech/projects/lms
- Live Demo: https://lms-gyanranjan.vercel.app/
- Source Code: https://github.com/Gyanranjan-Priyam/lms
- Role: Full Stack Developer — Sole developer responsible for architecture, implementation, and deployment of the entire platform.

---

## Overview

A full-stack Learning Management System that lets educators create, organize, and sell courses online — with structured chapters, video lessons, and Stripe-powered payments built in. Students get a clean dashboard to browse courses, enroll, and track their progress lesson by lesson.

The admin panel provides a complete course management workflow: rich text descriptions via Tiptap, drag-and-drop chapter/lesson reordering with dnd-kit, thumbnail and video uploads to AWS S3, and automatic Stripe product creation when pricing is set. Courses can be published, archived, or kept as drafts.

Authentication supports email/password with verification, plus GitHub and Google OAuth, all through Better Auth with role-based access control. Arcjet handles rate limiting and bot protection. The platform is designed to mirror production-grade EdTech products with a focus on real payment flows and scalable architecture.

--- 

## Key Highlights

- End-to-end Stripe integration with webhook-driven auto-enrollment
- Drag-and-drop course builder with chapter and lesson reordering
- Video and image uploads to AWS S3 with presigned URLs
- Multi-provider OAuth (GitHub + Google) alongside email/password auth
- Rich text course descriptions powered by Tiptap editor
- Per-lesson progress tracking across enrolled courses
- Admin analytics dashboard with data tables and Recharts
- Rate limiting and bot protection via Arcjet middleware


--- 

## Feature Breakdown

### Student Experience
- Browse and search courses by category and level
- Stripe-powered enrollment and checkout
- Per-lesson progress tracking
- Organized chapters with video content
- Personal dashboard for enrollments and progress

### Admin / Instructor
- Course CRUD with Tiptap rich text editor
- Drag-and-drop chapter & lesson reordering
- AWS S3 file uploads for thumbnails and videos
- Automatic Stripe product/price creation
- Publish, archive, or draft courses
- Analytics panel with data tables and charts

### Auth & Security
- Email/password auth with email verification
- GitHub and Google OAuth via Better Auth
- Role-based access control (Admin / User)
- Route protection via Next.js middleware
- Arcjet rate limiting and bot protection

### Payments
- Stripe Checkout for secure purchases
- Webhook handling for payment confirmation
- Automatic enrollment on successful payment


--- 

## Architecture & Tech Stack

- **Framework**: Next.js 15 (App Router, Turbopack)
- **Language**: TypeScript
- **Styling**: Tailwind CSS v4 + shadcn/ui
- **Database**: PostgreSQL + Prisma ORM (Accelerate)
- **Authentication**: Better Auth (Email, GitHub, Google OAuth)
- **Payments**: Stripe (Checkout + Webhooks)
- **File Storage**: AWS S3
- **Rich Text**: Tiptap Editor
- **Forms**: React Hook Form + Zod
- **Data Tables**: TanStack React Table
- **Charts**: Recharts
- **Drag & Drop**: dnd-kit
- **Email**: Nodemailer + React Email (Gmail SMTP)
- **Security**: Arcjet (rate limiting & bot protection)
- **Deployment**: Vercel


---

## Author & Creator

- Developer: Gyanranjan Priyam
- Portfolio: https://www.priyam.tech
- GitHub: https://github.com/gyanranjan-priyam
- LinkedIn: https://linkedin.com/in/gyanranjan-priyam
- Twitter: https://x.com/gr_priyam