| Auth.AuthProviderPluginException |
Throw this exception to indicate that an error occurred when using the auth
provider plug-in. Use to display a custom error message to the user. To get the
error message and write it to debug log, use the String getMessage(). |
| Auth.ConnectedAppPluginException |
Throw this exception to indicate that an error occurred while running the
custom behavior for a connected app. To get the error message and write it to debug
log, use the String getMessage(). |
| Auth.DiscoveryCustomErrorException |
Throw this exception to customize error messages that appear on Discovery
logins and Configurable Self-Registration pages. An error message can have up to 200
characters. Use custom error exceptions to localize error messages. Include this
exception in:
-
Auth.MyDomainLoginDiscoveryHandler
to show a custom error message on the My Domain login page
-
Auth.LoginDiscoveryHandler to show
an error message on the Experience Cloud site login page
-
Auth.ConfigurableSelfRegHandler to
show an error message on the Experience Cloud site self-registration Verify
page
The Verify page shows up if you configured self-registration with either an
Email or Text Message verification
method. If you didn’t set up sign-up with a verification method, the error message
appears on the self-registration page.
To get the error message and write it
to debug log, use the String
getMessage().
|
| Auth.JWTBearerTokenExchange.JWTBearerTokenExchangeException |
Throw this exception to indicate a problem with the response from the token
endpoint in the JWTBearerTokenExchange class. This exception occurs during the OAuth
2.0 JWT bearer token flow when the HTTP response:
- Fails to return an access token
- Isn’t in JSON format
- Returns a response code other than a 200 “OK” success code
To get the error message and write it to debug log, use the String getMessage().
|
| Auth.JWTValidationException |
Throws this exception to indicate failure to validate a JWT using methods in
the JWTUtil class. This exception occurs during
the OAuth 2.0 token exchange flow in these scenarios.
- Can’t parse the JWT
- Can’t validate the JWT using a certificate, a public key, or the remote keys
endpoint, depending on which method you use
|
| Auth.LoginDiscoveryException |
Throw this exception to indicate that an error occurred when executing the
Login Discovery handler. For an example, see LoginDiscoveryHandler Example
Implementation. To get the error message and write it to debug log, use the String getMessage(). |
| Auth.VerificationException |
Throw this exception to trigger verification based on the passed-in policy. You
can throw this exception in an Apex trigger or Visualforce controller. The system
automatically sends you to the verification endpoint, if possible.You can’t
catch this exception. The exception immediately triggers the
verification.
|