/**
   * Updates the specified product with the parameters passed in the request. Any attribute not
   * provided will be left unchanged. For example, if you pass the name parameter we will update the
   * name of the product and leave everything else unchanged. This request can only update
   * attributes specific to products and cannot be used to update anything to do with the product
   * variations of a product.
   *
   * @param product Product
   * @param apiKey apiKey
   * @return JSONObject
   */
  public JSONObject updateProductVariationJSONObject(
      ProductVariation productVariation, String apiKey) {
    String url = PropertiesUtil.getUpdateProductVariation();
    // 发起POST请求
    JSONObject jsonObject =
        CommonUtil.httpsRequest(
            url, "POST", productVariation.updateProductVariationObject() + "key=" + apiKey);

    if (null != jsonObject) {
      return jsonObject;
    } else {
      return null;
    }
  }
  /**
   * Updates the specified product with the parameters passed in the request. Any attribute not
   * provided will be left unchanged. For example, if you pass the name parameter we will update the
   * name of the product and leave everything else unchanged. This request can only update
   * attributes specific to products and cannot be used to update anything to do with the product
   * variations of a product.
   *
   * @param product Product
   * @param apiKey apiKey
   * @return Boolean
   */
  public Boolean updateProductVariationBoolean(ProductVariation productVariation, String apiKey) {
    String url = PropertiesUtil.getUpdateProductVariation();
    // 发起POST请求
    JSONObject jsonObject =
        CommonUtil.httpsRequest(
            url, "POST", productVariation.updateProductVariationObject() + "key=" + apiKey);

    if (null != jsonObject) {
      int code = jsonObject.getInt("code");
      if (0 == code) {
        return true;
      } else {
        return false;
      }
    } else {
      return false;
    }
  }