Documentation ¶
Index ¶
- type RoleController
- type UserController
- func (u *UserController) CreateUserController(ctx *gin.Context)
- func (u *UserController) GenerateOTP(ctx *gin.Context)
- func (u *UserController) GetCurrentUserController(ctx *gin.Context)
- func (u *UserController) LoginController(ctx *gin.Context)
- func (u *UserController) VerifyEmailController(ctx *gin.Context)
- func (u *UserController) VerifyOTP(ctx *gin.Context)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RoleController ¶
type RoleController struct {
RoleService services.RoleService
}
func NewRoleController ¶
func NewRoleController(RoleService services.RoleService) *RoleController
func (*RoleController) CreateRoleController ¶
func (u *RoleController) CreateRoleController(ctx *gin.Context)
CreateRoleController @BasePath /api/v1 @Summary Create Role. @Param role body serializers.Role true "Role Info" @Tags Role @Accept json @Produce json @Success 200 {string} sent verify init. @Router /role/create [post]
func (*RoleController) GetALLRoleController ¶
func (u *RoleController) GetALLRoleController(ctx *gin.Context)
GetALLRoleController @BasePath /api/v1 @Summary GET roles. @Tags Role @Accept json @Produce json @Success 200 {string} sent verify init. @Router /role/list [get]
type UserController ¶
type UserController struct {
UserService services.UserService
}
func NewUserController ¶
func NewUserController(service services.UserService) *UserController
func (*UserController) CreateUserController ¶
func (u *UserController) CreateUserController(ctx *gin.Context)
CreateUserController UserRegistration controllers @Summary Register User. @Schemes http https @Description User Registration @Tags User @Param user body serializers.RegisterSerializer true "User info" @Accept json @Produce json @Success 200 {string} successfully login @failure 400 {string} string "error" @Router /user/create [post]
func (*UserController) GenerateOTP ¶
func (u *UserController) GenerateOTP(ctx *gin.Context)
GenerateOTP @BasePath /api/v1 @Summary Generate OTP. @Param user body serializers.LoginSerializer true "Generate OTP" @Tags User @Accept json @Produce json @Success 200 {string} successfully generate OTP @Router /user/generate-otp [get]
func (*UserController) GetCurrentUserController ¶
func (u *UserController) GetCurrentUserController(ctx *gin.Context)
GetCurrentUserController @Summary Get authenticated user. @Schemes @Description do ping @Tags User @Accept json @Produce json @Success 200 {string} get user successfully. @Router /user [get]
func (*UserController) LoginController ¶
func (u *UserController) LoginController(ctx *gin.Context)
LoginController @Summary Login user. @Schemes http https @Description User login @Tags User @Param user body serializers.LoginSerializer true "User info" @Accept json @Produce json @Success 200 {string} successfully login. @failure 400 {string} string "error" @Router /user/login [post]
func (*UserController) VerifyEmailController ¶
func (u *UserController) VerifyEmailController(ctx *gin.Context)
VerifyEmailController @BasePath /api/v1 @Summary Verify email controller. @Schemes @Param token query string true "Email to be verified" Format(email) @Tags User @Accept json @Produce json @Success 200 {string} successfully verify email. @Router /user/email-verify [get]
func (*UserController) VerifyOTP ¶
func (u *UserController) VerifyOTP(ctx *gin.Context)
VerifyOTP @BasePath /api/v1 @Summary Verify OTP. @Schemes @Param user body serializers.VerifyOTPSerializer true "OTP info" @Tags User @Accept json @Produce json @Success 200 {string} sent verify init. @Router /user/verify-otp [get]