code: @Override
      public boolean setWebhook(String url, InputFile certificate) throws IOException {
          AnalyticsData data = new AnalyticsData("setWebhook");
          IOException ioException = null;
          boolean returned = false;
          data.setValue("url", url);
          data.setValue("certificate", certificate);
          try {
              returned = bot.setWebhook(url, certificate);
              data.setReturned(returned);
          } catch (IOException e) {
              ioException = e;
              data.setIoException(ioException);
          }
          analyticsWorker.putData(data);
          if (ioException != null) {
              throw ioException;
          }
          return returned;
      }
docs: Use this method to specify a url and receive incoming updates via an outgoing webhook.
  Whenever there is an update for the bot, an HTTPS POST request to the specified url will be sent, containing a JSON-serialized Update.
  In case of an unsuccessful request, it will give up after a reasonable amount of attempts.
  You will not be able to receive updates using getUpdates for as long as an outgoing webhook is set up.
  To use a self-signed certificate, you need to upload your public key certificate using certificate parameter.
  Please upload the certificate as InputFile, sending a String will not work.
  Ports currently supported for Webhooks: 443, 80, 88, 8443.
  
  @param url         HTTPS url to send updates to. Use an empty string to remove webhook integration
  @param certificate Upload your public key certificate so that the root certificate in use can be checked. See our self-signed guide for details.
  @return An array of Update objects is returned. Returns an empty array if there aren't any updates.
  @throws IOException an exception is thrown in case of any service call failures