Documentation
¶
Overview ¶
Package user defines the User entity: the identity that authenticates.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidEmail = errors.New("user: invalid email address")
ErrInvalidEmail is returned when an email address cannot be parsed.
Functions ¶
func NormalizeEmail ¶
NormalizeEmail trims and lowercases an email address and validates that it is a bare address (no display name). Normalization guarantees that lookups and uniqueness constraints behave consistently across store adapters.
Types ¶
type User ¶
type User struct {
ID string `json:"id"`
Email string `json:"email"`
EmailVerified bool `json:"email_verified"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
User represents a user identity. Plugins extend the model with their own stores keyed by User.ID instead of adding fields to the core entity.
Click to show internal directories.
Click to hide internal directories.