Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HeaderMiddleware ¶
HeaderMiddleware sets default headers
func RequireAdmin ¶
func RequireAdmin(next http.HandlerFunc) http.HandlerFunc
RequireAdmin only continues if the logged in user is an administrator
func WithSession ¶
func WithSession(next http.HandlerFunc) http.HandlerFunc
WithSession requires the client to have a valid session (to be logged in)
func WithToken ¶
func WithToken(next http.HandlerFunc) http.HandlerFunc
WithToken makes sure that, if enabled, a client must provide his API key within an HTTP header
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.