IndieWeb.Auth.Code.Adapter behaviour (IndieWeb v0.0.66) View Source

Provides an abstraction regarding code actions for IndieAuth.

Link to this section Summary

Link to this section Callbacks

Specs

destroy(code :: binary(), options :: keyword()) :: :ok

Specs

generate() :: binary()
Link to this callback

generate_challenge(options)

View Source

Specs

generate_challenge(options :: keyword()) :: {binary(), binary(), binary()}
Link to this callback

persist(code, client_id, redirect_uri, args, options)

View Source

Specs

persist(
  code :: binary(),
  client_id :: binary(),
  redirect_uri :: binary(),
  args :: map(),
  options :: keyword()
) :: :ok | {:error, any()}
Link to this callback

persist_challenge(code, challenge, method, options)

View Source

Specs

persist_challenge(
  code :: binary(),
  challenge :: binary(),
  method :: binary(),
  options :: keyword()
) :: :ok | {:error, any()}
Link to this callback

verify(code, client_id, redirect_uri, options)

View Source

Specs

verify(
  code :: binary(),
  client_id :: binary(),
  redirect_uri :: binary(),
  options :: keyword()
) :: {:ok, map()} | {:error, any()}
Link to this callback

verify_challenge(verifier, code, options)

View Source

Specs

verify_challenge(verifier :: binary(), code :: binary(), options :: keyword()) ::
  :ok | {:error, any()}