Documentation ¶
Overview ¶
Package tokens implements various user and admin tokens generation methods.
Index ¶
- Constants
- func NewAdminAuthToken(app core.App, admin *models.Admin) (string, error)
- func NewAdminFileToken(app core.App, admin *models.Admin) (string, error)
- func NewAdminResetPasswordToken(app core.App, admin *models.Admin) (string, error)
- func NewRecordAuthToken(app core.App, record *models.Record) (string, error)
- func NewRecordChangeEmailToken(app core.App, record *models.Record, newEmail string) (string, error)
- func NewRecordFileToken(app core.App, record *models.Record) (string, error)
- func NewRecordResetPasswordToken(app core.App, record *models.Record) (string, error)
- func NewRecordVerifyToken(app core.App, record *models.Record) (string, error)
Constants ¶
const ( TypeAdmin = "admin" TypeAuthRecord = "authRecord" )
Variables ¶
This section is empty.
Functions ¶
func NewAdminAuthToken ¶
NewAdminAuthToken generates and returns a new admin authentication token.
func NewAdminFileToken ¶
NewAdminFileToken generates and returns a new admin private file access token.
func NewAdminResetPasswordToken ¶
NewAdminResetPasswordToken generates and returns a new admin password reset request token.
func NewRecordAuthToken ¶
NewRecordAuthToken generates and returns a new auth record authentication token.
func NewRecordChangeEmailToken ¶
func NewRecordChangeEmailToken(app core.App, record *models.Record, newEmail string) (string, error)
NewRecordChangeEmailToken generates and returns a new auth record change email request token.
func NewRecordFileToken ¶
NewRecordFileToken generates and returns a new record private file access token.
func NewRecordResetPasswordToken ¶
NewRecordResetPasswordToken generates and returns a new auth record password reset request token.
Types ¶
This section is empty.