License | BSD-3-Clause |
---|---|
Maintainer | Oleg Grenrus <oleg.grenrus@iki.fi> |
Safe Haskell | None |
Language | Haskell2010 |
Synopsis
- data Auth
- = BasicAuth ByteString ByteString
- | OAuth Token
- | EnterpriseOAuth Text Token
- class AuthMethod a
- endpoint :: AuthMethod a => a -> Maybe Text
- setAuthRequest :: AuthMethod a => a -> Request -> Request
Documentation
The Github auth data type
BasicAuth ByteString ByteString | Username and password |
OAuth Token | OAuth token |
EnterpriseOAuth Text Token | Custom endpoint and OAuth token |
Instances
Eq Auth Source # | |
Data Auth Source # | |
Defined in GitHub.Auth gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Auth -> c Auth # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Auth # dataTypeOf :: Auth -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Auth) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Auth) # gmapT :: (forall b. Data b => b -> b) -> Auth -> Auth # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Auth -> r # gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Auth -> r # gmapQ :: (forall d. Data d => d -> u) -> Auth -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> Auth -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> Auth -> m Auth # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Auth -> m Auth # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Auth -> m Auth # | |
Ord Auth Source # | |
Show Auth Source # | |
Generic Auth Source # | |
Hashable Auth Source # | |
Defined in GitHub.Auth | |
Binary Auth Source # | |
NFData Auth Source # | |
Defined in GitHub.Auth | |
AuthMethod Auth Source # | |
type Rep Auth Source # | |
Defined in GitHub.Auth |
class AuthMethod a Source #
A type class for different authentication methods
Note the ()
intance, which doee nothing, i.e. is unauthenticated.
setAuthRequest :: AuthMethod a => a -> Request -> Request Source #
A function which sets authorisation on an HTTP request