hoauth2-2.6.0: Haskell OAuth2 authentication client
Safe HaskellSafe-Inferred
LanguageHaskell2010

Network.OAuth.OAuth2.Internal

Synopsis

Data Types

data OAuth2 Source #

Query Parameter Representation

Instances

Instances details
Show OAuth2 Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Default OAuth2 Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Methods

def :: OAuth2 #

Eq OAuth2 Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Methods

(==) :: OAuth2 -> OAuth2 -> Bool #

(/=) :: OAuth2 -> OAuth2 -> Bool #

newtype IdToken Source #

Constructors

IdToken 

Fields

Instances

Instances details
FromJSON IdToken Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

ToJSON IdToken Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Show IdToken Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Binary IdToken Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Methods

put :: IdToken -> Put #

get :: Get IdToken #

putList :: [IdToken] -> Put #

Eq IdToken Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Methods

(==) :: IdToken -> IdToken -> Bool #

(/=) :: IdToken -> IdToken -> Bool #

data OAuth2Token Source #

Constructors

OAuth2Token 

Fields

Instances

Instances details
FromJSON OAuth2Token Source #

Parse JSON data into OAuth2Token

Instance details

Defined in Network.OAuth.OAuth2.Internal

ToJSON OAuth2Token Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Generic OAuth2Token Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Associated Types

type Rep OAuth2Token :: Type -> Type #

Show OAuth2Token Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Binary OAuth2Token Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Eq OAuth2Token Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

type Rep OAuth2Token Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

type Rep OAuth2Token = D1 ('MetaData "OAuth2Token" "Network.OAuth.OAuth2.Internal" "hoauth2-2.6.0-B6PU9XFvhi0G80sxl5r9bL" 'False) (C1 ('MetaCons "OAuth2Token" 'PrefixI 'True) ((S1 ('MetaSel ('Just "accessToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AccessToken) :*: S1 ('MetaSel ('Just "refreshToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe RefreshToken))) :*: (S1 ('MetaSel ('Just "expiresIn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Int)) :*: (S1 ('MetaSel ('Just "tokenType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "idToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe IdToken))))))

data OAuth2Error a Source #

Instances

Instances details
FromJSON err => FromJSON (OAuth2Error err) Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

ToJSON err => ToJSON (OAuth2Error err) Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Generic (OAuth2Error a) Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Associated Types

type Rep (OAuth2Error a) :: Type -> Type #

Methods

from :: OAuth2Error a -> Rep (OAuth2Error a) x #

to :: Rep (OAuth2Error a) x -> OAuth2Error a #

Show a => Show (OAuth2Error a) Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

Eq a => Eq (OAuth2Error a) Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

type Rep (OAuth2Error a) Source # 
Instance details

Defined in Network.OAuth.OAuth2.Internal

type Rep (OAuth2Error a) = D1 ('MetaData "OAuth2Error" "Network.OAuth.OAuth2.Internal" "hoauth2-2.6.0-B6PU9XFvhi0G80sxl5r9bL" 'False) (C1 ('MetaCons "OAuth2Error" 'PrefixI 'True) (S1 ('MetaSel ('Just "error") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Either Text a)) :*: (S1 ('MetaSel ('Just "errorDescription") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "errorUri") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe (URIRef Absolute))))))

data ClientAuthenticationMethod Source #

https://www.rfc-editor.org/rfc/rfc6749#section-2.3 According to spec:

The client MUST NOT use more than one authentication method in each request.

Which means use Authorization header or Post body.

However, in reality, I always have to include authentication in the header.

In other words, ClientSecrectBasic is always assured. ClientSecretPost is optional.

Maybe consider an alternative implementation that boolean kind of data type is good enough.

Types Synonym

type PostBody = [(ByteString, ByteString)] Source #

type synonym of post body content

Utilies