Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data Idp (i :: k) = Idp {}
- data IdpApplication (i :: k) a = IdpApplication {
- idp :: Idp i
- application :: a
- newtype Scope = Scope {}
- data GrantTypeValue
- data ResponseType = Code
- newtype ClientId = ClientId {
- unClientId :: Text
- newtype ClientSecret = ClientSecret {}
- toOAuth2Key :: ClientId -> ClientSecret -> OAuth2
- newtype RedirectUri = RedirectUri {
- unRedirectUri :: URI
- newtype AuthorizeState = AuthorizeState {}
- newtype Username = Username {
- unUsername :: Text
- newtype Password = Password {
- unPassword :: Text
- class ToQueryParam a where
- toQueryParam :: a -> Map Text Text
- class HasOAuth2Key a where
- mkOAuth2Key :: a -> OAuth2
Idp App
Idp i
consists various endpoints endpoints.
The i
is actually phantom type for information only (Idp name) at this moment.
And it is PolyKinds.
Hence whenever Idp i
or IdpApplication i a
is used as function parameter,
PolyKinds need to be enabled.
Idp | |
|
data IdpApplication (i :: k) a Source #
An OAuth2 Application "a" of IdP "i". "a" can be one of following type:
IdpApplication | |
|
Scope
Grant Type value
data GrantTypeValue Source #
Grant type query parameter has association with different GrantType flows but not completely strict.
e.g. Both AuthorizationCode and ResourceOwnerPassword flow could support refresh token flow.
Instances
Show GrantTypeValue Source # | |
Defined in Network.OAuth2.Experiment.Types showsPrec :: Int -> GrantTypeValue -> ShowS # show :: GrantTypeValue -> String # showList :: [GrantTypeValue] -> ShowS # | |
Eq GrantTypeValue Source # | |
Defined in Network.OAuth2.Experiment.Types (==) :: GrantTypeValue -> GrantTypeValue -> Bool # (/=) :: GrantTypeValue -> GrantTypeValue -> Bool # | |
ToQueryParam GrantTypeValue Source # | |
Defined in Network.OAuth2.Experiment.Types toQueryParam :: GrantTypeValue -> Map Text Text Source # |
data ResponseType Source #
Instances
ToQueryParam ResponseType Source # | |
Defined in Network.OAuth2.Experiment.Types toQueryParam :: ResponseType -> Map Text Text Source # |
Credentials
newtype ClientSecret Source #
Can be either "Client Secret" or JWT base on client authentication method
Instances
IsString ClientSecret Source # | |
Defined in Network.OAuth2.Experiment.Types fromString :: String -> ClientSecret # | |
Eq ClientSecret Source # | |
Defined in Network.OAuth2.Experiment.Types (==) :: ClientSecret -> ClientSecret -> Bool # (/=) :: ClientSecret -> ClientSecret -> Bool # | |
ToQueryParam ClientSecret Source # | |
Defined in Network.OAuth2.Experiment.Types toQueryParam :: ClientSecret -> Map Text Text Source # |
toOAuth2Key :: ClientId -> ClientSecret -> OAuth2 Source #
In order to reuse some methods from legacy Network.OAuth.OAuth2. Will be removed when Experiment module becomes default.
newtype RedirectUri Source #
Instances
Eq RedirectUri Source # | |
Defined in Network.OAuth2.Experiment.Types (==) :: RedirectUri -> RedirectUri -> Bool # (/=) :: RedirectUri -> RedirectUri -> Bool # | |
ToQueryParam RedirectUri Source # | |
Defined in Network.OAuth2.Experiment.Types toQueryParam :: RedirectUri -> Map Text Text Source # |
newtype AuthorizeState Source #
Instances
IsString AuthorizeState Source # | |
Defined in Network.OAuth2.Experiment.Types fromString :: String -> AuthorizeState # | |
Eq AuthorizeState Source # | |
Defined in Network.OAuth2.Experiment.Types (==) :: AuthorizeState -> AuthorizeState -> Bool # (/=) :: AuthorizeState -> AuthorizeState -> Bool # | |
ToQueryParam AuthorizeState Source # | |
Defined in Network.OAuth2.Experiment.Types toQueryParam :: AuthorizeState -> Map Text Text Source # |
Instances
IsString Username Source # | |
Defined in Network.OAuth2.Experiment.Types fromString :: String -> Username # | |
Eq Username Source # | |
ToQueryParam Username Source # | |
Defined in Network.OAuth2.Experiment.Types |
Instances
IsString Password Source # | |
Defined in Network.OAuth2.Experiment.Types fromString :: String -> Password # | |
Eq Password Source # | |
ToQueryParam Password Source # | |
Defined in Network.OAuth2.Experiment.Types |
Query parameters
class ToQueryParam a where Source #
Instances
class HasOAuth2Key a where Source #
mkOAuth2Key :: a -> OAuth2 Source #