/auth RoutePOST request to the /auth route.{username, password}
POST request to the /auth/register route.{username, password, role, first_name, last_name, email, phone}
GET request to the /auth/refresh route.
GET request to the /auth/logout route./users RoutesFetches all users from the database.
/usersFetches a user by their ID from the database.
/users/:idid (required): The ID of the user to retrieve.Creates a new user.
/usersusername (required): The username of the new user.password (required): The password of the new user.role (required): The role of the new user.first_name (required): The first name of the new user.last_name (required): The last name of the new user.email (optional): The email of the new user. If not provided, it will default to "N/A".
phone (optional): The phone number of the new user. If not provided, it will default to
"N/A".Updates an existing user.
/usersid (required): The ID of the user to update.username (required): The new username for the user.password (optional): The new password for the user.role (required): The new role for the user.first_name (required): The new first name for the user.last_name (required): The new last name for the user.email (required): The new email for the user.phone (required): The new phone number for the user.Updates a user's children.
/users/:idid (required): The ID of the user to update.children (required): An array of children objects containing their names and ages.Deletes a user from the database.
/users/:idid (required): The ID of the user to delete./students RoutesFetches all students from the database.
/studentsFetches a student by their ID from the database.
/students/:idid (required): The ID of the student to retrieve.Creates a new student.
/studentsfirst_name (required): The first name of the new student.last_name (required): The last name of the new student.parent_id (required): The ID of the parent user.email (required): The email of the new student.phone (required): The phone number of the new student.Updates an existing student.
/studentsid (required): The ID of the student to update.first_name (required): The new first name for the student.last_name (required): The new last name for the student.parent_id (required): The new ID of the parent user.email (required): The new email for the student.phone (required): The new phone number for the student.changed_classes_count (required): The number of changed classes for the student.Updates a student's enrolled classes.
/students/:idid (required): The ID of the student to update.class_id (required): The ID of the class to add or remove.action (required): The action to perform, either "add" or "remove".Deletes a student from the database.
/studentsid (required): The ID of the student to delete./classes RoutesFetches all classes from the database.
/classesFetches a class by its ID from the database.
/classes/:idid (required): The ID of the class to retrieve.Creates a new class.
/classesname (required): The name of the new class.teacher (required): The name of the teacher for the new class.timing (required): The timing of the new class.Updates an existing class.
/classesid (required): The ID of the class to update.name (required): The new name for the class.teacher (required): The new teacher for the class.timing (required): The new timing for the class.Updates a class's enrollments.
/classes/:idid (required): The ID of the class to update.studentId (required): The ID of the student to add or remove.action (required): The action to perform, either "add" or "remove".Deletes a class from the database.
/classesid (required): The ID of the class to delete.