code: private void sendKeepAliveBridgeMessage(int appId, String bridgeId, String token,
        final CallStatsHttp2Client httpClient) {
      long apiTS = System.currentTimeMillis();
      BridgeKeepAliveMessage message = new BridgeKeepAliveMessage(bridgeId, apiTS);
      String requestMessageString = gson.toJson(message);
      httpClient.sendBridgeAlive(keepAliveEventUrl, token, requestMessageString,
          new CallStatsHttp2ResponseListener() {
            public void onResponse(Response response) {
              int responseStatus = response.code();
              BridgeKeepAliveResponse keepAliveResponse;
              try {
                String responseString = response.body().string();
                keepAliveResponse = gson.fromJson(responseString, BridgeKeepAliveResponse.class);
              } catch (IOException e) {
                e.printStackTrace();
                throw new RuntimeException(e);
              } catch (JsonSyntaxException e) {
                logger.error("Json Syntax Exception " + e.getMessage(), e);
                e.printStackTrace();
                throw new RuntimeException(e);
              }
              httpClient.setDisrupted(false);
              if (responseStatus == CallStatsResponseStatus.RESPONSE_STATUS_SUCCESS) {
                keepAliveStatusListener.onSuccess();
  
              } else if (responseStatus == CallStatsResponseStatus.INVALID_AUTHENTICATION_TOKEN) {
                stopKeepAliveSender();
                keepAliveStatusListener.onKeepAliveError(CallStatsErrors.AUTH_ERROR,
                    keepAliveResponse.getMsg());
              } else {
                httpClient.setDisrupted(true);
              }
            }
  
            public void onFailure(Exception e) {
              logger.info("Response exception " + e.toString());
              httpClient.setDisrupted(true);
            }
  
          });
    }
docs: Send keep alive bridge message.
  
  @param appId the app id
  @param bridgeId the bridge id
  @param token the token
  @param httpClient the http client