PortalAuth method. Idempotent and side-effect free, so it is safe to call on every sign-in screen and safe to retry.
Returns
AuthMethodsResult: Contains the following:allowedAuthMethods:[AuthMethod], the enabled methods:.emailMagicLink,.google,.apple. Values this SDK version does not recognize are dropped, never surfaced.autoCreateWallet:Bool, the environment’s Auto-create wallet setting. A hint for your app; Portal never creates the wallet itself.
PortalAuthError.malformedResponse(path:missing:): The response did not carry the documented fields.PortalRequestsError.unauthorized: The Auth Environment ID does not match an environment, or authentication is switched off for it.- Other transport errors unchanged.
- A two-factor requirement is not observable here. It only shows up as
.totpRequiredin the result ofhandleRedirectorsignInWith*. - A provider that is enabled but incompletely configured still appears in
allowedAuthMethods, and makesloginWith*/signInWith*fail for every provider. SeeloginWithGoogle. - Call it again after adopting a session to decide whether to create a wallet; see Create or reuse the wallet.
- Available starting from SDK version 8.0.0.