This is the backend for the Infinitum Registration Website. It provides APIs for user authentication, event management, and student-related functionalities.
-
Pull the Docker Image
docker pull darshan122205/infinitum-backend:latest
-
Run the Docker Container
docker run -p 5500:5500 --env-file .env darshan122205/infinitum-backend:latest
http://localhost:3000/api
Method | Endpoint | Description | Headers | Body Example |
---|---|---|---|---|
POST | /auth/register |
Register a new student | ❌ | { "name": "John Doe", "roll_no": "CS101", "department": "CSE", "year": 3, "phn_no": "9876543210", "password": "securepass" } |
POST | /auth/login |
Login using Roll No & Password | ❌ | { "roll_no": "CS101", "password": "securepass" } |
POST | /auth/logout |
Logout the current user | ✅ Authorization: Bearer <token> |
❌ |
Method | Endpoint | Description | Headers | Body Example |
---|---|---|---|---|
GET | /student/profile |
Fetch the logged-in student profile | ✅ Authorization: Bearer <token> |
{} |
GET | /student/registeredEvents |
Fetch registered events for a student | ✅ Authorization: Bearer <token> |
{} |
Method | Endpoint | Description | Headers | Body Example |
---|---|---|---|---|
GET | /event |
Fetch all available events | ❌ | {} |
POST | /event/create |
Create a new event (Admin only) | ✅ Authorization: Bearer <token> |
{ "event_name": "Tech Summit 2024", "description": { "location": "PSG Tech Auditorium", "date": "2024-06-15", "details": "A conference on the latest technology trends." } } |
GET | /event/register |
Register a student for an event | ✅ Authorization: Bearer <token> |
{} |
GET | /event/fetch/:eventid |
Fetch students registered for an event | ✅ Authorization: Bearer <token> |
{} |