SyntropyWeb.ApiAuth
(syntropy v0.1.0)
Copy Markdown
Runtime auth policy for Syntropy's external REST and channel surface.
Summary
Types
@type validation_error() :: :missing_token | :invalid_token
@type validation_result() :: :ok | {:error, validation_error()}
Functions
@spec error_message(validation_error()) :: String.t()
@spec required?() :: boolean()
@spec token() :: String.t() | nil
@spec validate_conn(Plug.Conn.t()) :: validation_result()
@spec validate_socket(map()) :: validation_result()