jagritbhatia / userapi2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

userapi2

Run in Postman

Getting started

First clone the repository from Github and switch to the new directory:

$ git clone git@github.com/USERNAME/{{ project_name }}.git

$ cd {{ project_name }}

Activate the virtualenv for your project.

Install project dependencies:

$ pip install -r requirements/local.txt Then simply apply the migrations:

$ python manage.py migrate You can now run the development server:

$ python manage.py runserver

CREATING A SUPERUSER

python manage.py createsuperuser

Run apis

http://127.0.0.1:8000/users -Returns a list of all users.

http://127.0.0.1:8000/users/1 -Returns the user with the ID 1.

http://127.0.0.1:8000/users/create -Creates a new user with the specified data.

http://127.0.0.1:8000/users/delete/9 -Deletes the user with the ID 9 .

Screenshots

GET /users - Returns a list of all users. userapi1ss

GET /users/ - Returns the user with the specified ID. userapi3ss

POST /users - Creates a new user with the specified data userapi2ss

DELETE /users/ - Deletes the user with the specified ID. userapi4ss

About


Languages

Language:Python 98.1%Language:HTML 1.9%