hoauth2-providers-tutorial-0.8.0: tutorial for hoauth2-providers module
Safe HaskellSafe-Inferred
LanguageHaskell2010

HOAuth2ProvidersTutorial

Synopsis

Configuration

randomStateValue :: Text Source #

You'll need to find out an better way to create state which is recommended in https://www.rfc-editor.org/rfc/rfc6749#section-10.12

Web server

data DemoUser Source #

Constructors

DemoUser 

Fields

Instances

Instances details
Show DemoUser Source # 
Instance details

Defined in HOAuth2ProvidersTutorial

Eq DemoUser Source # 
Instance details

Defined in HOAuth2ProvidersTutorial

app :: IO () Source #

The scotty application

indexH :: IORef (Maybe DemoUser) -> ActionM () Source #

/ endpoint handler

logoutH :: IORef (Maybe DemoUser) -> ActionM () Source #

/logout endpoint handler

Utilities

paramValue Source #

Arguments

:: Text

Parameter key

-> [Param]

All parameters

-> Either Text Text 

excepttToActionM :: Show a => ExceptT Text IO a -> ActionM a Source #

Lift ExceptT to ActionM which is basically the handler Monad in Scotty.