Project-Stage-Academy / UA1198ForumSB

UA-1198 Project Stage Forum SandBox
0 stars 0 forks source link

Implement User Sign In #16

Open mehalyna opened 2 weeks ago

mehalyna commented 2 weeks ago

Objective: Enable users to log in (sign in) to the application and receive a JWT for authentication.

Sub-Tasks:

  1. Create Sign In API Endpoint:

    • Develop an API endpoint for user login. This endpoint will authenticate the user and return a JWT.
  2. User Authentication:

    • Authenticate the user against the credentials provided. Use DRF's built-in authentication mechanisms for this.
  3. Generate JWT:

    • Upon successful authentication, generate a JWT and include user-specific data (like user ID, username).
  4. Return JWT to User:

    • Send the JWT back to the user in the response.

US #1