View Source AshAuthentication.Strategy.Password.Actions (ash_authentication v4.3.7)

Actions for the password strategy

Provides the code interface for working with resources via a password strategy.

Summary

Functions

Attempt to register a new user.

Attempt to change a user's password using a reset token.

Request a password reset.

Attempt to sign in a user.

Attempt to sign in a previously-authenticated user with a short-lived sign in token.

Functions

register(strategy, params, options)

@spec register(AshAuthentication.Strategy.Password.t(), map(), keyword()) ::
  {:ok, Ash.Resource.record()} | {:error, any()}

Attempt to register a new user.

reset(strategy, params, options)

@spec reset(AshAuthentication.Strategy.Password.t(), map(), keyword()) ::
  {:ok, Ash.Resource.record()} | {:error, any()}

Attempt to change a user's password using a reset token.

reset_request(strategy, params, options)

@spec reset_request(AshAuthentication.Strategy.Password.t(), map(), keyword()) ::
  :ok | {:error, any()}

Request a password reset.

sign_in(strategy, params, options)

Attempt to sign in a user.

sign_in_with_token(strategy, params, options)

@spec sign_in_with_token(AshAuthentication.Strategy.Password.t(), map(), keyword()) ::
  {:ok, Ash.Resource.record()} | {:error, any()}

Attempt to sign in a previously-authenticated user with a short-lived sign in token.