This document provides an overview of the backend endpoints for the LMS (Learning Management System) application.
All endpoints are relative to the base URL: http://your-domain.com
Authentication is required for certain endpoints. You need to include the appropriate authentication token in the request headers.
- Method: POST
- URL: /users/register
- Description: Registers a new user.
- Request Body:
email
(string, required): Email of the user.password
(string, required): Password of the user.
- Method: POST
- URL: /users/login
- Description: Logs in an existing user.
- Request Body:
email
(string, required): Email of the user.password
(string, required): Password of the user.
- Method: POST
- URL: /users/logout
- Description: Logs out the current user.
- Method: GET
- URL: /users/me
- Description: Retrieves information about the currently authenticated user.
- Method: PATCH
- URL: /users/me
- Description: Updates information about the currently authenticated user.
- Request Body: Fields to be updated.
- Method: DELETE
- URL: /users/me
- Description: Deletes the currently authenticated user account.
This document provides an overview of the backend endpoints for the LMS (Learning Management System) application.
All endpoints are relative to the base URL: http://your-domain.com
Authentication is required for certain endpoints. You need to include the appropriate authentication token in the request headers.
- Method: POST
- URL: /users/register
- Description: Registers a new user.
- Request Body:
email
(string, required): Email of the user.password
(string, required): Password of the user.
- Method: POST
- URL: /users/login
- Description: Logs in an existing user.
- Request Body:
email
(string, required): Email of the user.password
(string, required): Password of the user.
- Method: POST
- URL: /users/logout
- Description: Logs out the current user.
- Method: GET
- URL: /users/me
- Description: Retrieves information about the currently authenticated user.
- Method: PATCH
- URL: /users/me
- Description: Updates information about the currently authenticated user.
- Request Body: Fields to be updated.
- Method: DELETE
- URL: /users/me
- Description: Deletes the currently authenticated user account.
- Method: POST
- URL: /courses
- Description: Creates a new course.
- Authentication Required: Yes
- Request Body:
- Specify course details.
- Method: GET
- URL: /courses/:courseId
- Description: Retrieves details of a specific course.
- Authentication Required: Yes
- Method: GET
- URL: /courses/:filter?
- Description: Retrieves all courses optionally filtered by a parameter.
- Authentication Required: Yes
- Method: PUT
- URL: /courses/:courseId
- Description: Updates information about a specific course.
- Authentication Required: Yes
- Request Body: Fields to be updated.
- Method: DELETE
- URL: /courses/:courseId
- Description: Deletes a specific course.
- Authentication Required: Yes
- Method: POST
- URL: /courses/:courseId/end-course
- Description: Marks a course as ended.
- Authentication Required: Yes
- Method: POST
- URL: /courses/:courseId/enroll
- Description: Enrolls the current user to a course.
- Authentication Required: Yes
- Method: POST
- URL: /courses/:courseId/un-enroll
- Description: Un-enrolls the current user from a course.
- Authentication Required: Yes
- Method: POST
- URL: /assignment/:courseId/CreateAssignment
- Description: Creates a new assignment for a specific course.
- Authentication Required: Yes
- Request Body: Assignment details.
- Method: GET
- URL: /assignment/:courseId/gettingAllAssignment
- Description: Retrieves all assignments for a specific course.
- Authentication Required: Yes
- Method: GET
- URL: /assignment/:courseId/getAssignment/:assigmentId
- Description: Retrieves details of a specific assignment.
- Authentication Required: Yes
- Method: PATCH
- URL: /assignment/:courseId/editStatus/:assigmentId
- Description: Updates status of a specific assignment.
- Authentication Required: Yes
- Method: PATCH
- URL: /assignment/:courseId/showAssignment/:assigmentId
- Description: Marks an assignment as shown.
- Authentication Required: Yes
- Method: PATCH
- URL: /assignment/:courseId/editDate/:assigmentId
- Description: Updates due date of a specific assignment.
- Authentication Required: Yes
- Method: DELETE
- URL: /assignment/:courseId/deleteAssignment/:assigmentId
- Description: Deletes a specific assignment.
- Authentication Required: Yes
- Method: POST
- URL: /courses/:courseId/modules/:moduleId/module-item
- Description: Creates a new module item for a specific course module.
- Authentication Required: Yes
- Request Body: Module item details.
- Method: PUT
- URL: /courses/:courseId/modules/:moduleId/module-item/:id
- Description: Updates information about a specific module item.
- Authentication Required: Yes
- Request Body: Fields to be updated.
- Method: DELETE
- URL: /courses/:courseId/modules/:moduleId/module-item/:id
- Description: Deletes a specific module item.
- Authentication Required: Yes
- Method: GET
- URL: /lectures
- Description: Retrieves all videos.
- Authentication Required: No
- Method: GET
- URL: /lectures/:moduleItemId/comments
- Description: Retrieves all comments for a specific video.
- Authentication Required: No
- Method: POST
- URL: /lectures/:moduleItemId/comments
- Description: Creates a new comment for a specific video.
- Authentication Required: Yes
- Request Body: Comment details.
- Method: DELETE
- URL: /lectures/:moduleItemId/comments/:commentId
- Description: Deletes a specific comment for a video.
- Authentication Required: Yes