| Safe Haskell | None | 
|---|---|
| Language | Haskell2010 | 
Servant.Client.Experimental.Auth
Description
Authentication for clients
- newtype AuthenticateReq a = AuthenticateReq {- unAuthReq :: (AuthClientData a, AuthClientData a -> Req -> Req)
 
- type family AuthClientData a :: *
- mkAuthenticateReq :: AuthClientData a -> (AuthClientData a -> Req -> Req) -> AuthenticateReq a
Documentation
newtype AuthenticateReq a Source
For better type inference and to avoid usage of a data family, we newtype
 wrap the combination of some AuthClientData and a function to add authentication
 data to a request
NOTE: THIS API IS EXPERIMENTAL AND SUBJECT TO CHANGE
Constructors
| AuthenticateReq | |
| Fields 
 | |
type family AuthClientData a :: * Source
For a resource protected by authentication (e.g. AuthProtect), we need to provide the client with some data used to add authentication data to a request
NOTE: THIS API IS EXPERIMENTAL AND SUBJECT TO CHANGE
mkAuthenticateReq :: AuthClientData a -> (AuthClientData a -> Req -> Req) -> AuthenticateReq a Source
Handy helper to avoid wrapping datatypes in tuples everywhere.
NOTE: THIS API IS EXPERIMENTAL AND SUBJECT TO CHANGE