UPDATE: Auth module, User module
Some checks failed
Build and Release / release (push) Failing after 1m25s
Some checks failed
Build and Release / release (push) Failing after 1m25s
This commit is contained in:
@@ -1,11 +1,36 @@
|
||||
package request
|
||||
|
||||
import "history-api/pkg/constants"
|
||||
|
||||
type SignUpDto struct {
|
||||
Email string `json:"email" validate:"required,min=5,max=255,email"`
|
||||
Password string `json:"password" validate:"required,min=8,max=64"`
|
||||
DisplayName string `json:"display_name" validate:"required,min=2,max=50"`
|
||||
TokenID string `json:"token_id" validate:"required,uuid"`
|
||||
}
|
||||
type SignInDto struct {
|
||||
Email string `json:"email" validate:"required,min=5,max=255,email"`
|
||||
Password string `json:"password" validate:"required,min=8,max=64"`
|
||||
}
|
||||
|
||||
type CreateTokenDto struct {
|
||||
Email string `json:"email" validate:"required,email"`
|
||||
TokenType constants.TokenType `json:"token_type" validate:"required,oneof=1 2 3 4"`
|
||||
}
|
||||
|
||||
type VerifyTokenDto struct {
|
||||
Email string `json:"email" validate:"required,email"`
|
||||
TokenType constants.TokenType `json:"token_type" validate:"required,oneof=1 2 3 4"`
|
||||
Token string `json:"token" validate:"required,len=6,numeric"`
|
||||
}
|
||||
|
||||
type ForgotPasswordDto struct {
|
||||
TokenID string `json:"token_id" validate:"required,uuid"`
|
||||
Email string `json:"email" validate:"required,min=5,max=255,email"`
|
||||
NewPassword string `json:"new_password" validate:"required,min=8,max=64"`
|
||||
}
|
||||
|
||||
type SigninWith3rdDto struct {
|
||||
Provider string `json:"provider" validate:"required,oneof=google github facebook"`
|
||||
AccessToken string `json:"access_token" validate:"required"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user