AuthController

This is one of the Controllers linked to the Api of MafiaSDG

This controller handles all actions relating to the AWS Cognito user pool for the game. The UserPool contains the user accounts, but is only used to authenticate Users.

Routes

All AuthController routes prefixed with '/auth/ are authenticated via the Cognito Authorizer and will apply their actions to the account associated with the provided access token. Routes prefixed with '/noauth' will be authenticated.

[!success]- POST /auth/login (Login)

[!success]- POST /auth/logout (Logout)

[!success]- POST /noauth/signup (SignUp)

body = {
	# details required for cognito
}

[!success]- POST /noauth/resetPassword (ResetPassword)

body = {
    'email': str,
}

[!success]- PATCH /auth/user (EditDetails)

body = {
	# fields to change
}

[!info]- GET /auth/user (GetDetails)

[!success]- POST /auth/changePassword (ChangePassword)

body = {
	'oldPassword': str,
	'newPassword': str
}
Tags

#technical