Discover Packages
github.com/amalmadhu06/go-jwt-bearer-token
pkg
domain
package
Version:
v0.0.0-...-3810be4
Opens a new window with list of versions in this module.
Published: Mar 28, 2023
License: MIT
Opens a new window with license information.
Imports: 3
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
Documentation
¶
type Admin struct {
ID uint `gorm:"primaryKey"`
Email string `gorm:"unique;not null" validate:"email"`
Password string `gorm:"not null" validate:"min=8"`
CreatedAt time .Time
UpdatedAt time .Time
DeletedAt time .Time
}
type JWTError struct {
Code int
Message string
}
JWTError represents an error related to JWT token processing
type SignedDetails struct {
ID int `json:"id"`
Email string `json:"email"`
Role string `json:"role"`
Source string `json:"source"`
Exp int64 `json:"exp"`
jwt.StandardClaims
}
SignedDetails represents the JWT token details
type User struct {
ID uint `gorm:"primaryKey"`
Email string `gorm:"unique;not null" validate:"email"`
Password string `gorm:"not null" validate:"min=8"`
CreatedAt time .Time
UpdatedAt time .Time
DeletedAt time .Time
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.