Class ApiException

All Implemented Interfaces:
Serializable

public class ApiException extends RuntimeException
Thrown when the ID Analyzer API returns an error, or a transport error occurs.
See Also:
  • Constructor Details

    • ApiException

      public ApiException(String message, String code)
      Creates an exception with an error message and code.
      Parameters:
      message - the human-readable error message.
      code - the API error code, or a transport code such as "TRANSPORT".
    • ApiException

      public ApiException(String message, String code, Throwable cause)
      Creates an exception with an error message, code and underlying cause.
      Parameters:
      message - the human-readable error message.
      code - the API error code, or a transport code such as "TRANSPORT".
      cause - the underlying throwable that triggered this exception.
  • Method Details

    • getCode

      public String getCode()
      The API error code (or "TRANSPORT" for network/transport errors).
      Returns:
      the error code associated with this exception.