Skip to content

Add auth to user routes - #54

Open
nrktkt wants to merge 1 commit into
swagger-api:masterfrom
nrktkt:user-auth
Open

Add auth to user routes#54
nrktkt wants to merge 1 commit into
swagger-api:masterfrom
nrktkt:user-auth

Conversation

@nrktkt

@nrktkt nrktkt commented Feb 23, 2021

Copy link
Copy Markdown

Removed the description on createUser that said only a logged in user can create a user.
Added auth with no required scopes to log out, update user, and delete user.

It's not clear to me how security is supposed to work across the API, but these things should at least make it more consistent and sensical. I made a guess that createUser would fill the role of signing up, but it could just as easily been intended to keep the description and make it so that only a logged in user can create another user.
Requiring a token to log out makes sense, because you'd have to be logged in first.
Requiring a token to update and delete user makes the security consistent with the operation description.

Removed the description on createUser that said only a logged in user can create a user. 
Added auth with no required scopes to log out, update user, and delete user. 

It's not clear to me how security is supposed to work across the API, but these things should at least make it more consistent and sensical. I made a guess that createUser would fill the role of signing up, but it could just as easily been intended to keep the description and make it so that only a logged in user can create another user.   
Requiring a token to log out makes sense, because you'd have to be logged in first.   
Requiring a token to update and delete user makes the security consistent with the operation description.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant