Multifile hook to realise the actual login. Normally this hook
shall create a session and associate the session with the
identity of the user. This hook may keep track of a user
profile.
If this hook fails, oauth2_reply/2 returns a text/plain
document with the obtained information. This can be used for
debugging and development purposes.
- Arguments:
-
Request | - is the HTTP request dealing with the redirect back
from the identity provider. |
ServerID | - identifies the identity provider. |
TokenInfo | - is a dict containing information about the access
token. |
UserInfo | - is a dict containing information about the user. |