Challenges

Repo for All the Assignments I have to submit for Internship Application !😅

View on GitHub

Task Assigment

Create an API with Login and Register functionality.

Solution

Download the Assignment Folder
Setting Up the server

image

Task Completed - Created 2 APis

1. Login

image

Here you can login and logout

Construct a json post with data as

{
    "username":"kabir",
    "password":"pass"
}

2. Register

Shows all the registered accounts so far !

Construct a json post with data as

{
    "username":"kabir",
    "password":"pass",
    "first name":"kabir",
    "last name":"Sharma",
    "phone number":"8528425675",
    "profile pic": ""
}

A Default user with default profile pic is created (Bcoz No profile was mentioned) image

Here you need to upload profile pic using Pillow in Django so If you can send pic in request, It will put it as profile pic!