Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoAppToken = errors.New("No X-APP-TOKEN was found. This app is not authorized to use Partisan API") ErrAppTokenRevoked = errors.New("This App Token has been revoked.") ErrNoToken = errors.New("No X-AUTH-TOKEN header was found") )
View Source
var ErrNoUser = errors.New("User ID not set")
ErrNoUser signifies that the user couldn't be found in the context
Functions ¶
func AppToken ¶
func AppToken() gin.HandlerFunc
AppToken is middleware to make sure only Partisan approved products are accessing the API
func CurrentUser ¶
CurrentUser gets the current user from the session
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.