IndieWeb v0.0.28 IndieWeb.Auth.Adapter behaviour

Provides an abstraction regarding stateful actions in IndieAuth.

Link to this section Summary

Link to this section Callbacks

Link to this callback

code_destroy(client_id, redirect_uri, args)
code_destroy(client_id :: binary(), redirect_uri :: binary(), args :: map()) ::
  :ok

Link to this callback

code_generate(client_id, redirect_uri, data)
code_generate(client_id :: binary(), redirect_uri :: binary(), data :: map()) ::
  binary()

Link to this callback

code_persist(code, client_id, redirect_uri, args)
code_persist(
  code :: binary(),
  client_id :: binary(),
  redirect_uri :: binary(),
  args :: map()
) :: :ok | {:error, any()}

Link to this callback

code_verify(binary, binary, binary, map)
code_verify(binary(), binary(), binary(), map()) :: :ok | {:error, any()}

Link to this callback

scope_get(code)
scope_get(code :: binary()) :: binary() | nil

Link to this callback

scope_persist(code, scope)
scope_persist(code :: binary(), scope :: binary()) :: :ok | {:error, any()}

Link to this callback

token_generate(binary, binary)
token_generate(binary(), binary()) :: binary()

Link to this callback

token_info(binary)
token_info(binary()) :: nil | {:error, any()} | map()

Link to this callback

token_revoke(binary)
token_revoke(binary()) :: :ok

Link to this callback

valid_user?(uri)
valid_user?(uri :: binary()) :: boolean()