Skip to content

Commit

Permalink
Change endpoints to lowercase
Browse files Browse the repository at this point in the history
Signed-off-by: William <[email protected]>
  • Loading branch information
kwesidev committed Dec 11, 2023
1 parent 8fa107b commit 86beba8
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions internal/apiserver/api_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ func (ap *APIServer) Run() {
func (ap *APIServer) registerGlobalFunctions() {
authController := controllers.NewAuthController(ap.db)
http.HandleFunc("/api/auth/login", middlewares.Method("POST", authController.Login))
http.HandleFunc("/api/auth/passwordLesslogin", middlewares.Method("POST", authController.PasswordlessLogin))
http.HandleFunc("/api/auth/completePasswordlessLogin", middlewares.Method("POST", authController.CompletePasswordlessLogin))
http.HandleFunc("/api/auth/tokenRefresh", middlewares.Method("POST", authController.RefreshToken))
http.HandleFunc("/api/auth/passwordlesslogin", middlewares.Method("POST", authController.PasswordlessLogin))
http.HandleFunc("/api/auth/completepasswordlesslogin", middlewares.Method("POST", authController.CompletePasswordlessLogin))
http.HandleFunc("/api/auth/refreshtoken", middlewares.Method("POST", authController.RefreshToken))
http.HandleFunc("/api/auth/register", middlewares.Method("POST", authController.Register))
http.HandleFunc("/api/auth/passwordResetRequest", middlewares.Method("POST", authController.PasswordResetRequest))
http.HandleFunc("/api/auth/verifyAndResetPassword", middlewares.Method("POST", authController.VerifyAndChangePassword))
http.HandleFunc("/api/auth/verifyTwoFactor", middlewares.Method("POST", authController.ValidateTwoFactor))
http.HandleFunc("/api/auth/resetpasswordrequest", middlewares.Method("POST", authController.PasswordResetRequest))
http.HandleFunc("/api/auth/verifyandresetpassword", middlewares.Method("POST", authController.VerifyAndChangePassword))
http.HandleFunc("/api/auth/verifytwofactor", middlewares.Method("POST", authController.ValidateTwoFactor))
http.HandleFunc("/health", authController.Health)
}

Expand All @@ -63,8 +63,8 @@ func (ap *APIServer) registerUserFunctions() {
http.HandleFunc("/api/user", middlewares.Method("GET", middlewares.JwtAuth(userController.Index)))
http.HandleFunc("/api/user/logout", middlewares.Method("POST", middlewares.JwtAuth(userController.Logout)))
http.HandleFunc("/api/user/update", middlewares.Method("POST", middlewares.JwtAuth(userController.Update)))
http.HandleFunc("/api/user/enableTwoFactor", middlewares.Method("POST", middlewares.JwtAuth(userController.EnableTwoFactor)))
http.HandleFunc("/api/user/verifyPassCode", middlewares.Method("POST", middlewares.JwtAuth(userController.VerifyPassCode)))
http.HandleFunc("/api/user/enabletwofactor", middlewares.Method("POST", middlewares.JwtAuth(userController.EnableTwoFactor)))
http.HandleFunc("/api/user/verifytotpcode", middlewares.Method("POST", middlewares.JwtAuth(userController.VerifyPassCode)))

}

Expand Down

0 comments on commit 86beba8

Please sign in to comment.