yesod-auth-oauth2-0.1.0: OAuth 2.0 authentication plugins

Safe HaskellNone
LanguageHaskell98

Yesod.Auth.OAuth2

Description

Generic OAuth2 plugin for Yesod

  • See Yesod.Auth.OAuth2.GitHub for example usage.

Synopsis

Documentation

authOAuth2 Source

Arguments

:: YesodAuth m 
=> Text

Service name

-> OAuth2

Service details

-> (Manager -> AccessToken -> IO (Creds m))

This function defines how to take an AccessToken and retrieve additional information about the user, to be set in the session as Creds. Usually this means a second authorized request to api/me.json.

-> AuthPlugin m