Discover Packages
github.com/bhankey/pharmacy-automatization-api-gateway
internal
entities
package
Version:
v0.0.0-...-c42784e
Opens a new window with list of versions in this module.
Published: Mar 24, 2022
License: GPL-3.0
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
Documentation
¶
type Claims struct {
jwt.RegisteredClaims
Email string `json:"email"`
UserID int `json:"user_id"`
Role Role `json:"role"`
PharmacyID int `json:"pharmacy_id"`
}
const (
UserID ContextKey = iota
Email
DeviceFingerPrint
RequestID
PharmacyID
)
const (
All Role = "all"
Admin Role = "admin"
Apothecary Role = "apothecary"
)
type Tokens struct {
AccessToken string
RefreshToken string
}
TODO use this for all auth operations.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.