Developed a scalable and secure backend API for Zairza App, built using Node.js and Express.js, to handle user authentication, events/projects management, resources sharing, and media uploads for admins and users.
- User Authentication: Register, login, and manage user sessions.
- Events/Projects Management: Admins can upload and update events/projects while users can view them.
- Profile Management: Users can update and retrieve their profiles.
- Resource Sharing: Admins can upload resources (roadmaps, videos, presentations), and users can access them.
- Media Upload: Authenticated users can upload photos, visible to all.
- Open the app directory in CMD or Terminal.
- Type
npm install
to install dependencies. - Turn on your web server (use tools like XAMPP for MySQL).
- Open Postman or any HTTP client to interact with the API endpoints.
Register (POST Request)
/zairza/register
Fields: name, registration_number, branch, phone_number, email, password, batch
Login (POST Request)
/zairza/login
Fields: email, password
Upload Event/Project (POST Request)
/zairza/uploadEvent
Fields: title, date_and_time, wing(Hardware/Software/Design), event_img, description, senior_incharge
Retrieve Events/Projects (GET Request)
/zairza/retrieveEvent
Update Event/Project (PUT Request)
/zairza/updateEvent/{id}
Fields: title, date_and_time, wing(Hardware/Software/Design), event_img, description, senior_incharge
Upload Profile (POST Request)
/zairza/uploadProfile
Fields: See the image format in the project link.
Get Profile (GET Request)
/zairza/getProfile
Upload Resources (POST Request)
/zairza/uploadResources
Fields:
- roadmaps: [Single/List of drive links in this Square bracket],
- videos: [Single/List of Video Links in this Square bracket like "https://www.youtube.com/gateway/roboflow"],
- session_presentations,
- domain: "Web Development", "App Development", "Design", "Machine Learning"
Retrieve Resources (GET Request)
/zairza/retrieveResources
Update Resources (PUT Request)
/zairza/updateResources/{id}
Fields:
- roadmaps: [Single/List of drive links in this Square bracket],
- videos: [Single/List of Video Links in this Square bracket],
- session_presentations,
- domain: "Web Development", "App Development", "Design", "Machine Learning"
Upload Photo (POST Request)
/zairza/upload
Field: image (file upload like abhinaba.jpeg
)
Get All Uploaded Photos (GET Request)
/zairza/getPhotos
Use tools like Postman or cURL to interact with the API:
- To Register:
POST/zairza/register
{
"name": "John Doe",
"registration_number": "12345",
"branch": "CSE",
"phone_number": "9876543210",
"email": "[email protected]",
"password": "password123",
"batch": "2024"
}