Downloading the project
- git clone https://github.com/piyushnanwani/rest-api-django.git
- cd sampleproject Creating a virtual environment
- virtualenv venv
Activate virtual environment- source venv/bin/activate
Installing all dependencies- pip3 install -r requirements.txt
Running the project- django-admin manage.py runserver
- GET /api/users : This returns list of users You can also search user by name as a substring in First Name or Last Name
/api/users - GET - To list the users /api/users?page=1&limit=10&name=James&sort=-age
-
POST /api/users/
-
PUT /api/users/
-
DELETE /api/users/{id}
Test Cases are also added in test.py