Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

View a user's profile #3

Open
mazma1 opened this issue Jul 5, 2020 · 1 comment
Open

View a user's profile #3

mazma1 opened this issue Jul 5, 2020 · 1 comment
Labels
beginner Good for beginners good first issue Good for newcomers intermediate Open to intermediates

Comments

@mazma1
Copy link
Collaborator

mazma1 commented Jul 5, 2020

This is to implement an endpoint that will enable a logged in user access his/her profile information.

This endpoint is expected to return a user object that contains the username and email of the authenticated user.

Endpoint:
GET /profile/:id

Response spec:

{ ​ 
   "user":​ {
      "username": "...",
      "email": "..."
   }
}

Edge cases to keep in mind:

  • Do not include the password in the response object.
  • An authenticated user should only be authorized to view his/her own profile information
  • Responses should be sent with the appropriate status codes
  • Handle errors properly and return appropriate error messages like so:
     { ​ 
        "error":​ ​"appropriate error message"
     }
    
@mazma1 mazma1 added beginner Good for beginners good first issue Good for newcomers intermediate Open to intermediates labels Jul 7, 2020
@asi309
Copy link

asi309 commented Sep 17, 2020

I want to contribute

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beginner Good for beginners good first issue Good for newcomers intermediate Open to intermediates
Projects
None yet
Development

No branches or pull requests

2 participants