code: public void checkConnection() throws ConnectionException {
          IAPIConnector connector = populateHeaders(new V1APIConnector(getApplicationURL()
                  + MEMBER_CONNECT_PARAM, username, password, ApiClientInternals.getProxyProvider(proxySettings)));
  
          try {
              connector.getData().close();
          } catch (Exception ex) {
              throw new ConnectionException("Application not found at the URL: "
                      + getApplicationURL(), ex);
          }
      }
docs: Check server connection and authentication.
  
  @throws ConnectionException - if no connection.