Class AuthnError.Builder

java.lang.Object
com.pingidentity.sdk.api.authn.model.AuthnError.Builder
Enclosing class:
AuthnError

public static class AuthnError.Builder extends Object
A fluent builder for AuthnError instances.
Since:
9.3
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • build

      public AuthnError build()
      Create the authn error.
    • httpStatus

      public AuthnError.Builder httpStatus(int httpStatus)
      Set the status code.
    • code

      public AuthnError.Builder code(String code)
      Set the error code.
    • message

      public AuthnError.Builder message(String message)
      Set the developer-facing error message.
    • userMessageKey

      public AuthnError.Builder userMessageKey(String messageKey)
      Set the user-facing error message key. In the JSON serialization this key will automatically be converted to a localized string if a corresponding message is defined in the authn-api-messages or the pingfederate-messages properties file for the user's locale.
    • userMessage

      public AuthnError.Builder userMessage(String userMessage)
      Directly set the localized user-facing error message.
    • detail

      public AuthnError.Builder detail(AuthnErrorDetail detail)
      Add an additional error detail object.