napkin-0.5.9
Copyright(c) Soostone Inc 2020
LicenseAllRightsReserved
Stabilityexperimental
PortabilityPOSIX
Safe HaskellNone
LanguageHaskell2010

Napkin.Auth.Types

Description

 
Synopsis

Documentation

data AuthEvalError #

Authre related Errors

Instances

Instances details
Eq AuthEvalError # 
Instance details

Defined in Napkin.Auth.Types

Show AuthEvalError # 
Instance details

Defined in Napkin.Auth.Types

Generic AuthEvalError # 
Instance details

Defined in Napkin.Auth.Types

Associated Types

type Rep AuthEvalError :: Type -> Type #

Exception AuthEvalError # 
Instance details

Defined in Napkin.Auth.Types

ToText AuthEvalError # 
Instance details

Defined in Napkin.Auth.Types

Methods

toText :: AuthEvalError -> Text #

ToLText AuthEvalError # 
Instance details

Defined in Napkin.Auth.Types

HasO2codeStore OAuth2Env O2CodeStore # 
Instance details

Defined in Napkin.Auth.Types

type Rep AuthEvalError # 
Instance details

Defined in Napkin.Auth.Types

type Rep AuthEvalError = D1 ('MetaData "AuthEvalError" "Napkin.Auth.Types" "napkin-0.5.9-9RVzJKhltBGIJ4XYUA68gX" 'False) (((C1 ('MetaCons "AuthError" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)) :+: (C1 ('MetaCons "AuthenticationFailed" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)) :+: C1 ('MetaCons "DatabaseFailure" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)))) :+: ((C1 ('MetaCons "AuthFileNotFound" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)) :+: C1 ('MetaCons "AuthToAuthorizedUser" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError))) :+: (C1 ('MetaCons "AuthWWWBrowserError" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)) :+: C1 ('MetaCons "GoogleAuthCodeError" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError))))) :+: (((C1 ('MetaCons "NoClientInfo" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)) :+: C1 ('MetaCons "UnsupportedBackend" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError))) :+: (C1 ('MetaCons "NoNapkinGeneratedAuthFile" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)) :+: C1 ('MetaCons "NotSupported" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)))) :+: ((C1 ('MetaCons "OSCommandError" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)) :+: C1 ('MetaCons "ParseCredentialsError" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError))) :+: (C1 ('MetaCons "UserProvidedAuthFileNotFound" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError)) :+: C1 ('MetaCons "SpecRelatedError" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 AuthEvalError))))))

data OAuth2 #

Constructors

OAuth2 

Instances

Instances details
Eq OAuth2 # 
Instance details

Defined in Napkin.Auth.Types

Methods

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

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

Show OAuth2 # 
Instance details

Defined in Napkin.Auth.Types

HasClientSecret OAuth2 Text # 
Instance details

Defined in Napkin.Auth.Types

HasClientId OAuth2 Text # 
Instance details

Defined in Napkin.Auth.Types

HasOAuth2 NapkinOAuth2 OAuth2 # 
Instance details

Defined in Napkin.Auth.Types

class HasClientId s a | s -> a where #

Methods

clientId :: Lens' s a #

Instances

Instances details
HasClientId OAuth2 Text # 
Instance details

Defined in Napkin.Auth.Types

HasClientId GCredentials Text # 
Instance details

Defined in Napkin.Auth.Types

class HasClientSecret s a | s -> a where #

Methods

clientSecret :: Lens' s a #

Instances

Instances details
HasClientSecret OAuth2 Text # 
Instance details

Defined in Napkin.Auth.Types

HasClientSecret GCredentials Text # 
Instance details

Defined in Napkin.Auth.Types

newtype OAuth2CacheIndex #

Constructors

OAuth2CacheIndex 

Fields

Instances

Instances details
Eq OAuth2CacheIndex # 
Instance details

Defined in Napkin.Auth.Types

Show OAuth2CacheIndex # 
Instance details

Defined in Napkin.Auth.Types

newtype SpecFile #

Constructors

SpecFile 

Fields

Instances

Instances details
Eq SpecFile # 
Instance details

Defined in Napkin.Auth.Types

Show SpecFile # 
Instance details

Defined in Napkin.Auth.Types

HasSpecFile OAuth2CorrelatedKey SpecFile # 
Instance details

Defined in Napkin.Auth.Types

HasSpecFile OAuth2Context SpecFile # 
Instance details

Defined in Napkin.Auth.Types

newtype DbUri #

Constructors

DbUri 

Fields

Instances

Instances details
Eq DbUri # 
Instance details

Defined in Napkin.Auth.Types

Methods

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

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

Show DbUri # 
Instance details

Defined in Napkin.Auth.Types

Methods

showsPrec :: Int -> DbUri -> ShowS #

show :: DbUri -> String #

showList :: [DbUri] -> ShowS #

HasDbUri OAuth2CorrelatedKey DbUri # 
Instance details

Defined in Napkin.Auth.Types

class HasAppName s a | s -> a where #

Methods

appName :: Lens' s a #

Instances

Instances details
HasAppName OAuth2CorrelatedKey (Maybe AppName) # 
Instance details

Defined in Napkin.Auth.Types

class HasDbUri s a | s -> a where #

Methods

dbUri :: Lens' s a #

Instances

Instances details
HasDbUri OAuth2CorrelatedKey DbUri # 
Instance details

Defined in Napkin.Auth.Types

class HasSpecFile s a | s -> a where #

Methods

specFile :: Lens' s a #

Instances

Instances details
HasSpecFile OAuth2CorrelatedKey SpecFile # 
Instance details

Defined in Napkin.Auth.Types

HasSpecFile OAuth2Context SpecFile # 
Instance details

Defined in Napkin.Auth.Types

class HasCallbackPort s a | s -> a where #

Methods

callbackPort :: Lens' s a #

Instances

Instances details
HasCallbackPort OAuth2Context CallbackPort # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2dbPath s a | s -> a where #

Methods

oAuth2dbPath :: Lens' s a #

Instances

Instances details
HasOAuth2dbPath OAuth2Context FilePath # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2 s a | s -> a where #

Methods

oAuth2 :: Lens' s a #

Instances

Instances details
HasOAuth2 NapkinOAuth2 OAuth2 # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2context s a | s -> a where #

Methods

oAuth2context :: Lens' s a #

Instances

Instances details
HasOAuth2context NapkinOAuth2 OAuth2Context # 
Instance details

Defined in Napkin.Auth.Types

newtype FromUser #

Constructors

FromUser FilePath 

Instances

Instances details
Eq FromUser # 
Instance details

Defined in Napkin.Auth.Types

Show FromUser # 
Instance details

Defined in Napkin.Auth.Types

class ManySymbolVal (xs :: [Symbol]) where #

Methods

manySymbolVal :: proxy xs -> [String] #

Instances

Instances details
ManySymbolVal ('[] :: [Symbol]) # 
Instance details

Defined in Napkin.Auth.Types

Methods

manySymbolVal :: proxy '[] -> [String] #

(KnownSymbol a, ManySymbolVal as) => ManySymbolVal (a ': as) # 
Instance details

Defined in Napkin.Auth.Types

Methods

manySymbolVal :: proxy (a ': as) -> [String] #

type URIQueryParams = [(ByteString, ByteString)] #

OAuth2 and bigquery related scopes. for additional detail see: https://developers.google.com/identity/protocols/oauth2/scopes

type BigQueryScopes = '["https://www.googleapis.com/auth/bigquery", "https://www.googleapis.com/auth/cloud-platform", "https://www.googleapis.com/auth/cloud-platform.read-only", "https://www.googleapis.com/auth/devstorage.full_control", "https://www.googleapis.com/auth/devstorage.read_only", "https://www.googleapis.com/auth/devstorage.read_write"] #

authScopeType :: Proxy '["openid", "https://www.googleapis.com/auth/userinfo.email", "https://www.googleapis.com/auth/cloud-platform", "https://www.googleapis.com/auth/appengine.admin", "https://www.googleapis.com/auth/compute", "https://www.googleapis.com/auth/accounts.reauth"] #

type CredentialDir = FilePath #

directroy path to napkin credential path

data OAuth2Conf #

Constructors

OAuth2Conf 

Fields

Instances

Instances details
Eq OAuth2Conf # 
Instance details

Defined in Napkin.Auth.Types

Show OAuth2Conf # 
Instance details

Defined in Napkin.Auth.Types

HasOAuth2requestUri OAuth2Conf URI # 
Instance details

Defined in Napkin.Auth.Types

HasOAuth2grantType OAuth2Conf GrantType # 
Instance details

Defined in Napkin.Auth.Types

HasOAuth2encodingAlgorithm OAuth2Conf EncodingMethod # 
Instance details

Defined in Napkin.Auth.Types

HasOAuth2accessTokenRequestUri OAuth2Conf Text # 
Instance details

Defined in Napkin.Auth.Types

HasNapkinOAuth2 OAuth2Conf NapkinOAuth2 # 
Instance details

Defined in Napkin.Auth.Types

HasO2conf OAuth2Env OAuth2Conf # 
Instance details

Defined in Napkin.Auth.Types

HasOAuth2scope OAuth2Conf (Proxy '["openid", "https://www.googleapis.com/auth/userinfo.email", "https://www.googleapis.com/auth/cloud-platform", "https://www.googleapis.com/auth/appengine.admin", "https://www.googleapis.com/auth/compute", "https://www.googleapis.com/auth/accounts.reauth"]) # 
Instance details

Defined in Napkin.Auth.Types

Methods

oAuth2scope :: Lens' OAuth2Conf (Proxy '["openid", "https://www.googleapis.com/auth/userinfo.email", "https://www.googleapis.com/auth/cloud-platform", "https://www.googleapis.com/auth/appengine.admin", "https://www.googleapis.com/auth/compute", "https://www.googleapis.com/auth/accounts.reauth"]) #

class HasNapkinOAuth2 s a | s -> a where #

Methods

napkinOAuth2 :: Lens' s a #

Instances

Instances details
HasNapkinOAuth2 OAuth2Conf NapkinOAuth2 # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2accessTokenRequestUri s a | s -> a where #

Instances

Instances details
HasOAuth2accessTokenRequestUri OAuth2Conf Text # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2grantType s a | s -> a where #

Methods

oAuth2grantType :: Lens' s a #

Instances

Instances details
HasOAuth2grantType OAuth2Conf GrantType # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2requestUri s a | s -> a where #

Methods

oAuth2requestUri :: Lens' s a #

Instances

Instances details
HasOAuth2requestUri OAuth2Conf URI # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2scope s a | s -> a where #

Methods

oAuth2scope :: Lens' s a #

Instances

Instances details
HasOAuth2scope OAuth2Conf (Proxy '["openid", "https://www.googleapis.com/auth/userinfo.email", "https://www.googleapis.com/auth/cloud-platform", "https://www.googleapis.com/auth/appengine.admin", "https://www.googleapis.com/auth/compute", "https://www.googleapis.com/auth/accounts.reauth"]) # 
Instance details

Defined in Napkin.Auth.Types

Methods

oAuth2scope :: Lens' OAuth2Conf (Proxy '["openid", "https://www.googleapis.com/auth/userinfo.email", "https://www.googleapis.com/auth/cloud-platform", "https://www.googleapis.com/auth/appengine.admin", "https://www.googleapis.com/auth/compute", "https://www.googleapis.com/auth/accounts.reauth"]) #

class HasOAuth2callbackUrl s a | s -> a where #

Methods

oAuth2callbackUrl :: Lens' s a #

Instances

Instances details
HasOAuth2callbackUrl OAuth2RunTime Text # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2codeChallenge s a | s -> a where #

Instances

Instances details
HasOAuth2codeChallenge OAuth2RunTime ByteString # 
Instance details

Defined in Napkin.Auth.Types

class HasOAuth2codeVerifier s a | s -> a where #

Methods

oAuth2codeVerifier :: Lens' s a #

Instances

Instances details
HasOAuth2codeVerifier OAuth2RunTime ByteString # 
Instance details

Defined in Napkin.Auth.Types

data OAuth2Token #

class HasAccessToken s a | s -> a where #

Methods

accessToken :: Lens' s a #

Instances

Instances details
HasAccessToken OAuth2Token Text # 
Instance details

Defined in Napkin.Auth.Types

class HasExpiresIn s a | s -> a where #

Methods

expiresIn :: Lens' s a #

Instances

Instances details
HasExpiresIn OAuth2Token Int # 
Instance details

Defined in Napkin.Auth.Types

class HasIdToken s a | s -> a where #

Methods

idToken :: Lens' s a #

Instances

Instances details
HasIdToken OAuth2Token Text # 
Instance details

Defined in Napkin.Auth.Types

class HasRefreshToken s a | s -> a where #

Methods

refreshToken :: Lens' s a #

Instances

Instances details
HasRefreshToken OAuth2Token Text # 
Instance details

Defined in Napkin.Auth.Types

HasRefreshToken GCredentials Text # 
Instance details

Defined in Napkin.Auth.Types

class HasScope s a | s -> a where #

Methods

scope :: Lens' s a #

Instances

Instances details
HasScope OAuth2Token Text # 
Instance details

Defined in Napkin.Auth.Types

class HasTokenType s a | s -> a where #

Methods

tokenType :: Lens' s a #

Instances

Instances details
HasTokenType OAuth2Token Text # 
Instance details

Defined in Napkin.Auth.Types

data OAuth2CodeWithSource #

Constructors

WWW OAuth2Code 
CLI OAuth2Code 

Instances

Instances details
HasO2codeStore OAuth2Env O2CodeStore # 
Instance details

Defined in Napkin.Auth.Types

class HasO2codeStore s a | s -> a where #

Methods

o2codeStore :: Lens' s a #

Instances

Instances details
HasO2codeStore OAuth2Env O2CodeStore # 
Instance details

Defined in Napkin.Auth.Types

class HasO2conf s a | s -> a where #

Methods

o2conf :: Lens' s a #

Instances

Instances details
HasO2conf OAuth2Env OAuth2Conf # 
Instance details

Defined in Napkin.Auth.Types

class HasO2runTime s a | s -> a where #

Methods

o2runTime :: Lens' s a #

Instances

Instances details
HasO2runTime OAuth2Env OAuth2RunTime # 
Instance details

Defined in Napkin.Auth.Types

class HasCtype s a | s -> a where #

Methods

ctype :: Lens' s a #

Instances

Instances details
HasCtype GCredentials Text # 
Instance details

Defined in Napkin.Auth.Types