Skip to content

Munaelekwa/Student-Management-System

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Student-Management-System

Student Management System is a web api built with flask. It contains functionality that enables an admin manage student accounts, create courses and also allows students register and unregister courses.

Note: This is currently under active development

Table of Contents

Live ( deployed version )

Visit website

Testing Locally

Clone the repository

git clone https://github.com/Munaelekwa/Student-Management-System.git

Change directory to the cloned folder

cd Student-Management-System

Install necessary dependencies to run the project

pip install -r requirements.txt

Create database from migration files

flask db migrate -m "your description"
flask db upgrade

Run application

flask run

To test routes:

  • Create a new admin account with the auth/register route. Registration code for creating admin (reg_code) is 'ADM990'.
  • Log in with admin email and password and copy access token
  • Enter access token in the authorization header as bearer
  • Proceed to test out admin functions ie create new students, create new courses, delete students etc
  • Log in as a student (note: use a valid email address to create the student account to enable you recieve the login password)
  • Test out student functions ie register courses, calculate gpa etc

Continue testing......

Available Endpoints

Auth Endpoint

ROUTE METHOD DESCRIPTION AUTHORIZATION USER TYPE PLACEHOLDER
auth/register POST It allows the creation of an admin account Any Any ----
auth/register/student POST It allows an admin create a student account Authenticated Admin ----
auth/login POST It allows user authentication Any Any ----
auth/refresh POST It allows user refresh their tokens Authenticated Any ----
auth/logout POST It allows user refresh their tokens Authenticated Any ----

Students Endpoint

ROUTE METHOD DESCRIPTION AUTHORIZATION USER TYPE PLACEHOLDER
students/courses/grade GET It allows student retrieve all registered courses grade Authenticated Student ----
students/courses GET It allows the retrieval of a student courses Authenticated ---- A student ID
students/gpa GET Calculate a student gpa score Authenticated Any A student ID
students/course<course_id>/add_and_drop POST It allows student register a course Authenticated Student ----
students/course<course_id>/add_and_drop DELETE It allows student unregister a course Authenticated Student ----

Admin Endpoint

ROUTE METHOD DESCRIPTION AUTHORIZATION USER TYPE PLACEHOLDER
admin/courses GET It allows the retrieval of all available courses Authenticated Any ----
admin/courses POST It allows the creation of a new course Authenticated Admin ----
admin/courses/<course_id> DELETE It allows deleting a course Authenticated Admin ----
admin/courses/<course_id> GET It allows the retrieval of a particular course Authenticated Admin A course ID
admin/courses/<course_id> PUT It allows the update of a particular course Authenticated Admin A course ID
admin/course<course_id>/students GET It allows the retrieval of all students registered for a course Authenticated Admin A course ID
admin/course<course_id>/students/add_and_drop POST It allows admin to add a student to a course Authenticated Admin A course ID
admin/course<course_id>/students/add_and_drop DELETE It allows admin to remove a student from a course Authenticated Admin A course ID
admin/student<student_id> GET It allows admin to retrieve a particular student Authenticated Admin A Student ID
admin/student<student_id> DELETE It allows admin to remove a particular student Authenticated Admin A Student ID
admin/student<student_id> PUT It allows admin to update details for a particular student Authenticated Admin A Student ID
admin/all_students GET It allows admin to retrieve all students in the school Authenticated Admin ----
admin/student/course/add_score PUT It allows admin add a student score in a course Authenticated Admin A course ID, A student ID
admin/student<student_id>/courses/grade GET It allows the admin retrieve a student all courses grade Authenticated Admin A student ID

About

A Web Api for Student Management, built with Flask Restx

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published