docs: protected void addFormParam(Form formData, String name, Object value, boolean required) throws IllegalArgumentException {
  
          if (value == null) {
  
              if (required) {
                  throw new IllegalArgumentException(name + " cannot be empty or null");
              }
  
              return;
          }
  
          String stringValue = value.toString();
          if (required && stringValue.trim().length() == 0) {
              throw new IllegalArgumentException(name + " cannot be empty or null");
          }
  
          formData.param(name, stringValue);
      }