yesod-auth-oauth2/src/Yesod/Auth/OAuth2/Upcase.hs
patrick brisbin b1181298ba
WIP: Provider interface
TODO: write detailed commit message / CHANGELOG.

Highlights:

- The "Provider" abstraction, which leads to
- Way tinier definitions, also aided by
- Stop fetching full profiles (#71)
- Drop GHC < 7.10 support (and CPP)
- Extract clarified Dispatch module
2018-01-23 10:33:29 -05:00

16 lines
459 B
Haskell

{-# LANGUAGE OverloadedStrings #-}
module Yesod.Auth.OAuth2.Upcase
( oauth2Upcase
) where
import Yesod.Auth.OAuth2.Provider
import Yesod.Auth.OAuth2.UserId
oauth2Upcase :: Provider m UserId
oauth2Upcase = Provider
{ pName = "upcase"
, pAuthorizeEndpoint = const "http://upcase.com/oauth/authorize"
, pAccessTokenEndpoint = "http://upcase.com/oauth/token"
, pFetchUserProfile = authGetProfile "http://upcase.com/api/v1/me.json"
}