Skip to content

Raam751/VibeEdu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

VibeEdu 🎓

Real-time classroom engagement platform built with Spring Boot.

What is this?

A backend API for teachers to create interactive sessions and students to respond in real-time. Think Kahoot but simpler.

Features

  • JWT Authentication - Secure login for teachers and students
  • Session Management - Teachers create sessions with 6-digit join codes
  • Question Types - MCQ, Rating (1-5), Open Text
  • Role-Based Access - Teachers create, students respond
  • Swagger Docs - Interactive API documentation

Tech Stack

  • Java 21
  • Spring Boot 4.x
  • Spring Security + JWT
  • H2 Database (in-memory, for testing)
  • Maven

Quick Start

# clone
git clone https://github.com/Raam751/VibeEdu.git
cd VibeEdu

# run
./mvnw spring-boot:run

App runs at http://localhost:8080

API Endpoints

Auth (Public)

Method Endpoint Description
POST /api/auth/register Register new user
POST /api/auth/login Login, get JWT token

Sessions (Teacher Only for create/update)

Method Endpoint Description
POST /api/sessions Create session
GET /api/sessions List all sessions
GET /api/sessions/code/{code} Join by code (public)
PUT /api/sessions/{id}/start Start session
PUT /api/sessions/{id}/end End session

Questions (Teacher Only)

Method Endpoint Description
POST /api/questions Create question
GET /api/questions/session/{id} Get questions for session

Responses (Students submit, Teachers view)

Method Endpoint Description
POST /api/responses Submit response (Student)
GET /api/responses/question/{id} View responses (Teacher)

Testing with Postman

Import VibeEdu-Postman.json into Postman for ready-to-use API collection.

Swagger UI

Visit http://localhost:8080/swagger-ui.html after starting the app.

H2 Console

Database viewer at http://localhost:8080/h2

  • JDBC URL: jdbc:h2:mem:vibeedu
  • Username: sa
  • Password: (empty)

Project Structure

src/main/java/com/vibeedu/vibeedu/
├── controller/   # REST endpoints
├── service/      # Business logic
├── repository/   # Database access
├── entity/       # JPA entities
├── dto/          # Request/Response objects
├── security/     # JWT auth
├── config/       # App configuration
└── exception/    # Error handling

Sample Requests

Register:

POST /api/auth/register
{
  "name": "John Doe",
  "email": "john@test.com",
  "password": "password123",
  "role": "TEACHER"
}

Create Session:

POST /api/sessions
Authorization: Bearer <token>
{
  "title": "Intro to Java"
}

Create Question:

POST /api/questions
Authorization: Bearer <token>
{
  "sessionId": 1,
  "text": "What is 2+2?",
  "type": "MCQ",
  "options": ["3", "4", "5", "22"]
}

Made for learning purposes 📚

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages