@wix/auto_sdk_ecom_current-cart-v-2 1.0.66 → 1.0.67

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2037,9 +2037,15 @@ interface LineItemAdded {
2037
2037
  * @minLength 1
2038
2038
  * @maxLength 36
2039
2039
  */
2040
- appId?: string | null;
2040
+ catalogAppId?: string | null;
2041
2041
  /** Whether the line item is a custom line item. */
2042
2042
  customLineItem?: boolean;
2043
+ /**
2044
+ * ID of the app that added the line item to the cart (from the identity context).
2045
+ * @minLength 1
2046
+ * @maxLength 36
2047
+ */
2048
+ appDefId?: string | null;
2043
2049
  }
2044
2050
  interface CouponAdded {
2045
2051
  /**
@@ -2573,6 +2579,11 @@ interface CalculationConfig {
2573
2579
  * Default: false
2574
2580
  */
2575
2581
  calculateGiftCards?: boolean;
2582
+ /**
2583
+ * Whether to calculate order-level discounts.
2584
+ * TODO: Currently i's ignored and always treated as true.
2585
+ */
2586
+ calculateOrderDiscounts?: boolean;
2576
2587
  }
2577
2588
  interface CalculateCurrentCartResponse {
2578
2589
  /** The Cart that was calculated. */
@@ -2592,6 +2603,11 @@ interface EstimateCurrentCartRequest {
2592
2603
  * by calling the [Validations service plugin](https://dev.wix.com/api/rest/wix-ecommerce/validations-integration-spi/introduction).
2593
2604
  */
2594
2605
  validationConfig?: ValidationsConfigWithLiterals;
2606
+ /**
2607
+ * Whether to calculate order-level discounts.
2608
+ * TODO: Currently i's ignored and always treated as true.
2609
+ */
2610
+ calculateOrderDiscounts?: boolean;
2595
2611
  /**
2596
2612
  * Whether to calculate delivery costs.
2597
2613
  * Default: false
@@ -3035,7 +3051,6 @@ interface EstimateCartRequest {
3035
3051
  cartId?: string;
3036
3052
  /**
3037
3053
  * Whether to retrieve the latest item prices, discounts, and inventory data from the catalogs before estimating the cart.
3038
- *
3039
3054
  * Default: `false`
3040
3055
  */
3041
3056
  refreshCart?: boolean;
@@ -3044,6 +3059,11 @@ interface EstimateCartRequest {
3044
3059
  * by calling the [Validations service plugin](https://dev.wix.com/api/rest/wix-ecommerce/validations-integration-spi/introduction).
3045
3060
  */
3046
3061
  validationConfig?: ValidationsConfigWithLiterals;
3062
+ /**
3063
+ * Whether to calculate order-level discounts.
3064
+ * TODO: Currently i's ignored and always treated as true.
3065
+ */
3066
+ calculateOrderDiscounts?: boolean;
3047
3067
  /**
3048
3068
  * Whether to calculate delivery costs.
3049
3069
  * Default: false
@@ -4999,6 +5019,11 @@ interface EstimateCurrentCartOptions {
4999
5019
  * by calling the [Validations service plugin](https://dev.wix.com/api/rest/wix-ecommerce/validations-integration-spi/introduction).
5000
5020
  */
5001
5021
  validationConfig?: ValidationsConfigWithLiterals;
5022
+ /**
5023
+ * Whether to calculate order-level discounts.
5024
+ * TODO: Currently i's ignored and always treated as true.
5025
+ */
5026
+ calculateOrderDiscounts?: boolean;
5002
5027
  /**
5003
5028
  * Whether to calculate delivery costs.
5004
5029
  * Default: false
@@ -1698,6 +1698,7 @@ async function estimateCurrentCart2(options) {
1698
1698
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1699
1699
  refreshCart: options?.refreshCart,
1700
1700
  validationConfig: options?.validationConfig,
1701
+ calculateOrderDiscounts: options?.calculateOrderDiscounts,
1701
1702
  calculateDelivery: options?.calculateDelivery,
1702
1703
  calculateAdditionalFees: options?.calculateAdditionalFees,
1703
1704
  calculateTax: options?.calculateTax,
@@ -1738,6 +1739,7 @@ async function estimateCurrentCart2(options) {
1738
1739
  explicitPathsToArguments: {
1739
1740
  refreshCart: "$[0].refreshCart",
1740
1741
  validationConfig: "$[0].validationConfig",
1742
+ calculateOrderDiscounts: "$[0].calculateOrderDiscounts",
1741
1743
  calculateDelivery: "$[0].calculateDelivery",
1742
1744
  calculateAdditionalFees: "$[0].calculateAdditionalFees",
1743
1745
  calculateTax: "$[0].calculateTax",