Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNotFound = appCommon.NewCustomError( errors.New("token not found"), "token not found", "ErrNotFound", ) ErrEncodingToken = appCommon.NewCustomError(errors.New("error encoding the token"), "error encoding the token", "ErrEncodingToken", ) ErrInvalidToken = appCommon.NewCustomError(errors.New("invalid token provided"), "invalid token provided", "ErrInvalidToken", ) )
Functions ¶
This section is empty.
Types ¶
type Provider ¶
type Provider interface { Generate(data TokenPayload, expiry int) (*Token, error) Validate(token string) (*TokenPayload, error) }
type TokenPayload ¶
Click to show internal directories.
Click to hide internal directories.