Whether or not the client containing this StitchAuth
object is currently
authenticated.
A StitchUser object representing the user that the client is
currently authenticated as. undefined
if the client is not currently
authenticated.
Registers a StitchAuthListener with the client.
The listener to be triggered when an authentication event occurs on this auth object.
Retrieves the authentication provider client for the authentication provider associated with the specified factory.
The factory that produces the desired client.
Retrieves the authentication provider client for the authentication provider associated with the specified factory and auth provider name.
The factory that produces the desired client.
Handles a redirect by completing the login response and authenticating the client. Should be called by the redirect handling page that {@link loginWithRedirect()} redirects to.
Checks whether or not the page was just redirected to from a login process initiated by {@link loginWithRedirect()}. Call this method before calling handleRedirectResult if you want to avoid errors.
Authenticates the client as a MongoDB Stitch user using the provided StitchCredential.
The credential to use when logging in.
Authenticates the client as a MongoDB Stitch user using the provided StitchRedirectCredential. This method will redirect the user to an OAuth2 login page where the login is handled externally. That external page will redirect the user back to the page specified in the redirect credential. To complete the login, that page will need to handle the redirect by calling {@link handleRedirectResult()}.
The credential to use when logging in.
Logs out the currently authenticated user, and clears any persisted authentication information.
Unregisters a listener.
Generated using TypeDoc
A set of methods for retrieving or modifying the authentication state of a StitchAppClient. An implementation can be instantiated with a StitchAppClient instance.