Exceptions

All exceptions are current as of version 4.7.0.

Exceptions are delivered to the onException method of the UsedeskActionListener — that is, they belong to the chat.

The Knowledge Base does not throw exceptions: its methods return either Done or Error with an error code. See "Knowledge Base Methods".


UsedeskException : RuntimeException

The parent exception for all non-standard exceptions of the library. Abstract class.

Fields:

Name Type Description
message String? Error text message


UsedeskSocketException : UsedeskException

Socket error. The only exception the SDK throws itself, while the chat is running.

Fields:

Name Type Description
error UsedeskSocketException.Error Error type
message String? Error text message


UsedeskSocketException.Error values:

  • INTERNAL_SERVER_ERROR - internal server error
  • BAD_REQUEST_ERROR - bad request
  • FORBIDDEN_ERROR - access forbidden
  • DISCONNECTED - connection lost
  • SOCKET_INIT_ERROR - socket initialization error
  • JSON_ERROR - JSON parsing error
  • UNKNOWN_ERROR - unknown error


UsedeskDataNotFoundException : UsedeskException

The requested data was not found. The SDK does not throw this exception — it is available for use in your own code, for example when a downloaded file cannot be read.

Fields:

Name Type Description
message String? Error text message