UPDATE: logout
All checks were successful
Build and Release / release (push) Successful in 1m1s

This commit is contained in:
2026-04-07 18:01:39 +07:00
parent a1d7f2b9ee
commit 5d9db1b150
4 changed files with 107 additions and 0 deletions

View File

@@ -433,6 +433,16 @@ func (h *AuthController) GoogleCallback(c fiber.Ctx) error {
return c.Redirect().To(redirectURL)
}
// Logout godoc
// @Summary Logout user
// @Description Logout current user and revoke tokens
// @Tags auth
// @Security BearerAuth
// @Produce json
// @Success 200 {object} response.CommonResponse
// @Failure 401 {object} response.CommonResponse
// @Failure 500 {object} response.CommonResponse
// @Router /auth/logout [post]
func (h *AuthController) Logout(c fiber.Ctx) error {
ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second)
defer cancel()