Guardian v0.14.5 Guardian.Hooks behaviour

This module helps to hook into the lifecycle of authentication.

Summary

Callbacks

after_encode_and_sign(resource, type, claims, token)
after_encode_and_sign(resource :: term, type :: atom, claims :: map, token :: String.t) ::
  {:ok, {term, atom, map, String.t}} |
  {:error, any}
after_sign_in(conn, location)
after_sign_in(conn :: Plug.Conn.t, location :: atom | nil) :: Plug.Conn.t
before_encode_and_sign(resource, type, claims)
before_encode_and_sign(resource :: term, type :: atom, claims :: map) ::
  {:ok, {term, atom, map}} |
  {:error, any}
before_sign_out(conn, location)
before_sign_out(conn :: Plug.Conn.t, location :: atom | nil) :: Plug.Conn.t
on_revoke(claims, jwt)
on_revoke(claims :: map, jwt :: String.t) ::
  {:ok, {map, String.t}} |
  {:error, any}
on_verify(claims, jwt)
on_verify(claims :: map, jwt :: String.t) ::
  {:ok, {map, String.t}} |
  {:error, any}