Mig.Extra.Plugin.Auth
Description
Plugin to handle authorization. Just a sketch for now.
data WithAuth m token resp Source #
Authorization plugin interface
Constructors
Fields
check that token is valid
how to respond on failure
withHeaderAuth :: forall m token resp. (IsResp resp, MonadIO m) => WithAuth m token resp -> Header "auth" token -> Plugin m Source #
Creates plugin that applies check of auth credentials which are passed as HTTP Header with name auth.