Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PasswordConfig ¶
type PasswordConfig struct {
// contains filtered or unexported fields
}
PasswordConfig is used to generate the argon2 password hash
type SignupData ¶
type SignupData struct {
ID string `json:"id,omitempty"`
Email string `json:"email" validate:"required,email,max=30,min=6"`
Tenant string `json:"tenantID"`
Password string `json:"password" validate:"required,max=30,min=6"`
AppMetaData string `json:"appMetaData"`
UserMetaData string `json:"userMetaData"`
Confirmed bool `json:"confirmed"`
IsAdmin bool `json:"isAdmin"`
Disabled bool `json:"disabled"`
Roles []string `json:"roles"`
}
SignupData is what's sent to the signup endpoint and used to create the User model
type User ¶
type User struct {
Email string `json:"name"`
Tenant string `json:"tenantID"`
Password string `json:"password"`
AppMetaData string `json:"appMetaData"`
UserMetaData string `json:"userMetaData"`
Confirmed bool `json:"confirmed"`
IsAdmin bool `json:"isAdmin"`
Disabled bool `json:"disabled"`
Roles []string `json:"roles"`
}
func CreateUser ¶
func CreateUser(signupData SignupData) (*User, error)
Click to show internal directories.
Click to hide internal directories.