IndieWeb v0.0.37 IndieWeb.Auth.Adapter behaviour View Source

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) View Source
code_destroy(client_id :: binary(), redirect_uri :: binary(), args :: map()) ::
  :ok

Link to this callback

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

Link to this callback

code_persist(code, client_id, redirect_uri, args) View Source
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) View Source
code_verify(binary(), binary(), binary(), map()) :: :ok | {:error, any()}

Link to this callback

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

Link to this callback

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

Link to this callback

token_generate(binary, binary) View Source
token_generate(binary(), binary()) :: binary()

Link to this callback

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

Link to this callback

token_revoke(binary) View Source
token_revoke(binary()) :: :ok

Link to this callback

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