- Python
- Django
- Django-REST-Framework
- Django-Jazzmin
- Pandas
git clone https://github.com/nditc/nditcDB.git
cd nditcDB
python3 -m pip install -r requirements.txt
python3 manage.py collectstatic
python3 manage.py runserver
- Admin Panel
- Token Authentication
- Fetch all Students data
- Fetch Students data by year
- Fetch data of a specific student
- Add Student data
- Update Student data
- Delete Student data
- Run query
You can add , edit , delete , view student by logging in on Admin Panel
- To get token,you have to post valid username and password in https://nditcdb.pythonanywhere.com/api/v1/getToken/ .It will return a JSON response
- To authenticate, the token key should be included in the Authorization HTTP header. The key should be prefixed by the string literal "Token", with whitespace separating the two strings. For example:
{
Authorization: 'Token 9944b09199c62bcf9418ad846dd0e4bbdfc6ee4b'
}
- You have to add authentication credentials to perform anything
Send a GET request to https://nditcdb.pythonanywhere.com/api/v1/
Send a GET request to the server and add the year in the URL
Example of URL : https://nditcdb.pythonanywhere.com/api/v1/year/2025/
Send a GET request to the server and add the id of the student in the URL
Example of URL : https://nditcdb.pythonanywhere.com/api/v1/3666/
Send a POST request with data to https://nditcdb.pythonanywhere.com/api/v1/
Include data in the HTTP Body.For example:
{
year : 0000,
name : '',
admission_serial : '',
college_roll : '',
serial : '',
contact_number : '',
email : '',
father : '',
mother : '',
present_address : ''
permanent_address : ''
blood_group : ''
institutional_background : ''
background_club_Activities : ''
competitions : ''
}
Send a PUT/PATCH request with updated data to the server and add the id of the student in the URL . Include updated data in the HTTP Body
Example of URL : https://nditcdb.pythonanywhere.com/api/v1/3666/
Send a DELETE request to the server and add the id of the student in the URL
Example of URL : https://nditcdb.pythonanywhere.com/api/v1/3666/
- You can run query only for the Table named CORE_MEMBER
- The fields of the Table CORE_MEMBER are :
- ID
- YEAR
- NAME
- ADMISSION_SERIAL
- COLLEGE_ROLL
- SERIAL
- CONTACT_NUMBER
- TRANSECTION_ID
- FATHER
- MOTHER
- PRESENT_ADDRESS
- PERMANENT_ADDRESS
- BLOOD_GROUP
- INSTITUTOINAL_BACKGROUND
- BACKGROUND_CLUB_ACTIVITIES
- COMPETITIONS
- Create Table and add fields by only using django Model
- You have to post the query in https://nditcdb.pythonanywhere.com/api/v1/query/ . Include the post data in the HTTP Body. For example:
{
query : 'SELECT * FROM CORE_MEMBER'
}
- When adding new data , you have to get id from https://nditcdb.pythonanywhere.com/api/v1/getID/ and use it as the id for the student. Don't put id as your wish.
Note : Running query with this is not recommended . It may cause unusual internal errors.