First step is to Clone the repo in your system and run the project. General Endpoint: http://localhost:8080
- Request Type: POST
- Endpoint:
/admin/
- Request Example:
{
"admin_UserName": "thisIsYourAdmin",
"admin_Email": "[email protected]",
"admin_FirstName": "First",
"admin_LastName": "Last",
"admin_Password": "yourAdmin123"
}
- Response Example:
{
"admin_UserName": "thisIsYourAdmin",
"admin_Email": "[email protected]",
"admin_FirstName": "First",
"admin_LastName": "Last"
}
- Request Type: PATCH
- Endpoint:
/admin/
- Request Example:
{
"admin_UserName": "thisIsYourAdmin",
"admin_Email": "[email protected]",
"admin_FirstName": "New name",
"admin_LastName": "new Last name",
"admin_Password": "yourAdmin123"
}
- Response Example:
{
"admin_UserName": "thisIsYourAdmin",
"admin_Email": "[email protected]",
"admin_FirstName": "New name",
"admin_LastName": "new Last name"
}
- Request Type: GET
- Endpoint:
/admin/{username}
- Request Example: Fill admin username in
{username}
in the endpoint - Response Example:
{
"admin_UserName": "thisIsYourAdmin",
"admin_Email": "[email protected]",
"admin_FirstName": "First",
"admin_LastName": "Last"
}
- Request Type: DELETE
- Endpoint:
/admin/
- Request Example:
{
"admin_UserName": "thisIsYourAdmin",
"admin_Email": "[email protected]",
"admin_FirstName": "New name",
"admin_LastName": "new Last name",
"admin_Password": "yourAdmin123"
}
- Response Example: No response
- Request Type: POST
- Endpoint:
/courses/
- Request Example:
{
"courseId": "",
"name": "New course",
"description": "Course on web3",
"credits": "100",
"departmentId": "1",
"adminUsername": "Mein_Hoon_Giyan",
"password": "admin1123"
}
- Response Example:
{
"courseId": 9,
"name": "New course",
"description": "Course on web3",
"credits": 100,
"department": null,
"students": [],
"instructor": "Kshitij"
}
- Request Type: PUT
- Endpoint:
/courses/
- Request Example:
{
"courseId": "9",
"name": "course",
"description": "Course on web3",
"credits": "100",
"departmentId": "1",
"adminUsername": "Mein_Hoon_Giyan",
"password": "admin1123"
}
- Response Example:
{
"courseId": 9,
"name": "course",
"description": "Course on web3",
"credits": 100,
"department": null,
"students": [],
"instructor": "Kshitij"
}
- Request Type: DELETE
- Endpoint:
/courses/{id}
- Request Example: Replace
{id}
with the course ID in the endpoint - Response Example: No response
- Request Type: GET
- Endpoint:
/instructor/{id}
- Request Example: Replace
{id}
with the instructor ID in the endpoint - Response Example: Returns details of the instructor with the specified ID.
- Request Type: GET
- Endpoint:
/instructor
- Response Example: Returns details of all instructors.
- Request Type: GET
- Endpoint:
/instructor/courses/{id}
- Request Example: Replace
{id}
with the course ID in the endpoint - Response Example: Returns details of the instructor associated with the specified course ID.
- Request Type: GET
- Endpoint:
/instructor/department/{id}
- Request Example: Replace
{id}
with the department ID in the endpoint - Response Example: Returns details of all instructors associated with the specified department ID.
- Request Type: POST
- Endpoint:
/instructor
- Request Example:
{
"name": "John Doe",
"title": "Professor",
"departmentId": 1,
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns details of the newly created instructor.
- Request Type: PUT
- Endpoint:
/instructor
- Request Example:
{
"instructorId": 1,
"name": "John Doe",
"title": "Associate Professor",
"departmentId": 1,
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns details of the updated instructor.
- Request Type: DELETE
- Endpoint:
/instructor
- Request Example:
{
"instructorId": 1,
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: No response
- Request Type: GET
- Endpoint:
/department/{id}
- Request Example: Replace
{id}
with the department ID in the endpoint - Response Example: Returns details of the department with the specified ID.
- Request Type: POST
- Endpoint:
/department/
- Request Example:
{
"name": "Department of Computer Science",
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns details of the newly created department.
- Request Type: PUT
- Endpoint:
/department/
- Request Example:
{
"departmentId": 1,
"name": "New Department Name",
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns details of the updated department.
- Request Type: DELETE
- Endpoint:
/department/
- Request Example:
{
"departmentId": 1,
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns a success message indicating the department deletion.
- Request Type: POST
- Endpoint:
/students
- Request Example:
{
"name": "John Doe",
"email": "[email protected]",
"courseId": 1,
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns details of the newly added student.
- Request Type: POST
- Endpoint:
/students/enroll
- Request Example:
{
"name": "John Doe",
"email": "[email protected]",
"courseId": 1,
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns details of the enrolled student.
- Request Type: GET
- Endpoint:
/students/{id}
- Request Example: Replace
{id}
with the student ID in the endpoint - Response Example: Returns details of the student with the specified ID.
- Request Type: GET
- Endpoint:
/students/course/{id}
- Request Example: Replace
{id}
with the course ID in the endpoint - Response Example: Returns details of all students enrolled in the course with the specified ID.
- Request Type: PUT
- Endpoint:
/students
- Request Example:
{
"studentId": 1,
"name": "John Doe",
"email": "[email protected]",
"adminUsername": "admin",
"password": "admin123"
}
- Response Example: Returns details of the updated student.
- Request Type: DELETE
- Endpoint:
/students/{id}
- Request Example: Replace
{id}
with the student ID in the endpoint - Response Example: No response