@wix/auto_sdk_ecom_cart-v-2 1.0.62 → 1.0.64

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.
Files changed (37) hide show
  1. package/build/cjs/index.d.ts +27 -4
  2. package/build/cjs/index.js +128 -0
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +181 -2
  5. package/build/cjs/index.typings.js +119 -0
  6. package/build/cjs/index.typings.js.map +1 -1
  7. package/build/cjs/meta.d.ts +125 -2
  8. package/build/cjs/meta.js +77 -0
  9. package/build/cjs/meta.js.map +1 -1
  10. package/build/es/index.d.mts +27 -4
  11. package/build/es/index.mjs +127 -0
  12. package/build/es/index.mjs.map +1 -1
  13. package/build/es/index.typings.d.mts +181 -2
  14. package/build/es/index.typings.mjs +118 -0
  15. package/build/es/index.typings.mjs.map +1 -1
  16. package/build/es/meta.d.mts +125 -2
  17. package/build/es/meta.mjs +76 -0
  18. package/build/es/meta.mjs.map +1 -1
  19. package/build/internal/cjs/index.d.ts +27 -4
  20. package/build/internal/cjs/index.js +128 -0
  21. package/build/internal/cjs/index.js.map +1 -1
  22. package/build/internal/cjs/index.typings.d.ts +191 -2
  23. package/build/internal/cjs/index.typings.js +119 -0
  24. package/build/internal/cjs/index.typings.js.map +1 -1
  25. package/build/internal/cjs/meta.d.ts +125 -2
  26. package/build/internal/cjs/meta.js +77 -0
  27. package/build/internal/cjs/meta.js.map +1 -1
  28. package/build/internal/es/index.d.mts +27 -4
  29. package/build/internal/es/index.mjs +127 -0
  30. package/build/internal/es/index.mjs.map +1 -1
  31. package/build/internal/es/index.typings.d.mts +191 -2
  32. package/build/internal/es/index.typings.mjs +118 -0
  33. package/build/internal/es/index.typings.mjs.map +1 -1
  34. package/build/internal/es/meta.d.mts +125 -2
  35. package/build/internal/es/meta.mjs +76 -0
  36. package/build/internal/es/meta.mjs.map +1 -1
  37. package/package.json +2 -2
@@ -2604,6 +2604,46 @@ interface CalculateCurrentCartResponse {
2604
2604
  /** The calculation summary. */
2605
2605
  summary?: CartSummary;
2606
2606
  }
2607
+ interface EstimateCurrentCartRequest {
2608
+ /**
2609
+ * Whether to retrieve the latest item prices, discounts, and inventory data from the catalogs before estimating the cart.
2610
+ *
2611
+ * Default: `false`
2612
+ */
2613
+ refreshCart?: boolean;
2614
+ /**
2615
+ * Specifies the level of **business validation** to perform during cart calculation,
2616
+ * by calling the [Validations service plugin](https://dev.wix.com/api/rest/wix-ecommerce/validations-integration-spi/introduction).
2617
+ */
2618
+ validationConfig?: ValidationsConfigWithLiterals;
2619
+ /**
2620
+ * Whether to calculate delivery costs.
2621
+ * Default: false
2622
+ */
2623
+ calculateDelivery?: boolean;
2624
+ /**
2625
+ * Whether to calculate any additional fees.
2626
+ * Default: false
2627
+ */
2628
+ calculateAdditionalFees?: boolean;
2629
+ /**
2630
+ * Whether to include tax calculation.
2631
+ * Default: false
2632
+ */
2633
+ calculateTax?: boolean;
2634
+ /**
2635
+ * Whether to calculate the effect of gift card balances on the cart total.
2636
+ * Gift cards are not redeemed - only reflected for estimation purposes.
2637
+ * Default: false
2638
+ */
2639
+ calculateGiftCards?: boolean;
2640
+ }
2641
+ interface EstimateCurrentCartResponse {
2642
+ /** The Cart that was calculated. */
2643
+ cart?: Cart;
2644
+ /** The calculation summary. */
2645
+ summary?: CartSummary;
2646
+ }
2607
2647
  interface AddLineItemsToCurrentCartRequest {
2608
2648
  /**
2609
2649
  * A list of catalog items to add to the cart.
@@ -3011,6 +3051,51 @@ interface RefreshCartResponse {
3011
3051
  /** Synchronized Cart. */
3012
3052
  cart?: Cart;
3013
3053
  }
3054
+ interface EstimateCartRequest {
3055
+ /**
3056
+ * ID of the Cart to calculate.
3057
+ * @format GUID
3058
+ */
3059
+ cartId: string;
3060
+ /**
3061
+ * Whether to retrieve the latest item prices, discounts, and inventory data from the catalogs before estimating the cart.
3062
+ *
3063
+ * Default: `false`
3064
+ */
3065
+ refreshCart?: boolean;
3066
+ /**
3067
+ * Specifies the level of **business validation** to perform during cart calculation,
3068
+ * by calling the [Validations service plugin](https://dev.wix.com/api/rest/wix-ecommerce/validations-integration-spi/introduction).
3069
+ */
3070
+ validationConfig?: ValidationsConfigWithLiterals;
3071
+ /**
3072
+ * Whether to calculate delivery costs.
3073
+ * Default: false
3074
+ */
3075
+ calculateDelivery?: boolean;
3076
+ /**
3077
+ * Whether to calculate any additional fees.
3078
+ * Default: false
3079
+ */
3080
+ calculateAdditionalFees?: boolean;
3081
+ /**
3082
+ * Whether to include tax calculation.
3083
+ * Default: false
3084
+ */
3085
+ calculateTax?: boolean;
3086
+ /**
3087
+ * Whether to calculate the effect of gift card balances on the cart total.
3088
+ * Gift cards are not redeemed - only reflected for estimation purposes.
3089
+ * Default: false
3090
+ */
3091
+ calculateGiftCards?: boolean;
3092
+ }
3093
+ interface EstimateCartResponse {
3094
+ /** The Cart that was calculated. */
3095
+ cart?: Cart;
3096
+ /** The calculation summary. */
3097
+ summary?: CartSummary;
3098
+ }
3014
3099
  interface CalculateCartRequest {
3015
3100
  /**
3016
3101
  * ID of the Cart to calculate.
@@ -3880,6 +3965,16 @@ interface DiscountRule {
3880
3965
  name?: DiscountRuleName;
3881
3966
  /** Discount value. */
3882
3967
  amount?: MultiCurrencyPrice;
3968
+ /**
3969
+ * A list of item combinations for this discount rule.
3970
+ * Each entry represents a unique combination of line items that triggered
3971
+ * or received this discount, along with how many times that combination was applied together.
3972
+ * Relevant ONLY for BXGY and Quantity-based promotions.
3973
+ * In BXGY the combination will contain the "X" items with discount amount of 0.
3974
+ * @internal
3975
+ * @maxSize 1000
3976
+ */
3977
+ itemCombinations?: ItemCombination[];
3883
3978
  }
3884
3979
  interface DiscountRuleName {
3885
3980
  /**
@@ -3895,6 +3990,35 @@ interface DiscountRuleName {
3895
3990
  */
3896
3991
  translated?: string | null;
3897
3992
  }
3993
+ interface ItemCombination {
3994
+ /**
3995
+ * The number of times this exact combination of items (with the specified quantities) was applied together in the order.
3996
+ * @min 1
3997
+ * @max 100000
3998
+ */
3999
+ count?: number;
4000
+ /**
4001
+ * Line items that participated together in this combination.
4002
+ * @minSize 1
4003
+ * @maxSize 100
4004
+ */
4005
+ lineItems?: ItemCombinationLineItem[];
4006
+ }
4007
+ interface ItemCombinationLineItem {
4008
+ /**
4009
+ * The unique ID of the line item to which this discount applies.
4010
+ * @format GUID
4011
+ */
4012
+ lineItemId?: string;
4013
+ /** Total discount amount for all units (quantity) of this line item in this combination. */
4014
+ discountAmount?: MultiCurrencyPrice;
4015
+ /**
4016
+ * Number of units from this line item that participated in a single combination.
4017
+ * @min 1
4018
+ * @max 100000
4019
+ */
4020
+ quantity?: number;
4021
+ }
3898
4022
  interface LineItemDiscount {
3899
4023
  /**
3900
4024
  * ID of line item the discount applies to.
@@ -4601,6 +4725,12 @@ type RefreshCartApplicationErrors = {
4601
4725
  data?: CartAlreadyOrderedErrorData;
4602
4726
  };
4603
4727
  /** @docsIgnore */
4728
+ type EstimateCartApplicationErrors = {
4729
+ code?: 'CART_ALREADY_ORDERED';
4730
+ description?: string;
4731
+ data?: CartAlreadyOrderedErrorData;
4732
+ };
4733
+ /** @docsIgnore */
4604
4734
  type CalculateCartApplicationErrors = {
4605
4735
  code?: 'CART_ALREADY_ORDERED';
4606
4736
  description?: string;
@@ -5131,10 +5261,69 @@ declare function deleteCart(cartId: string): Promise<void>;
5131
5261
  declare function refreshCart(cartId: string): Promise<NonNullablePaths<RefreshCartResponse, `cart._id` | `cart.revision` | `cart.lineItems` | `cart.lineItems.${number}._id` | `cart.lineItems.${number}.name.original` | `cart.lineItems.${number}.quantityInfo.confirmedQuantity` | `cart.lineItems.${number}.quantityInfo.requestedQuantity` | `cart.lineItems.${number}.quantityInfo.fixedQuantity` | `cart.lineItems.${number}.pricing.unitPrice.amount` | `cart.lineItems.${number}.pricing.unitPrice.convertedAmount` | `cart.lineItems.${number}.pricing.priceDescription.original` | `cart.lineItems.${number}.pricing.priceUndetermined` | `cart.lineItems.${number}.source.catalogReference.catalogItemId` | `cart.lineItems.${number}.source.catalogReference.appId` | `cart.lineItems.${number}.attributes.itemType.preset` | `cart.lineItems.${number}.attributes.itemType.custom` | `cart.lineItems.${number}.attributes.physicalProperties.shippable` | `cart.lineItems.${number}.attributes.membersOnly` | `cart.lineItems.${number}.taxConfig.taxableAddress.addressType` | `cart.lineItems.${number}.paymentConfig.savePaymentMethod` | `cart.lineItems.${number}.paymentConfig.selectedMembership._id` | `cart.lineItems.${number}.paymentConfig.selectedMembership.appId` | `cart.lineItems.${number}.paymentConfig.paymentOption` | `cart.lineItems.${number}.status` | `cart.lineItems.${number}.customLineItem` | `cart.coupons` | `cart.coupons.${number}._id` | `cart.coupons.${number}.code` | `cart.source.channelType` | `cart.source.externalReferences` | `cart.source.externalReferences.${number}.appId` | `cart.source.createdBy.visitorId` | `cart.source.createdBy.memberId` | `cart.source.createdBy.userId` | `cart.source.createdBy.appId` | `cart.source.customContentReference.appId` | `cart.source.customContentReference.componentId` | `cart.businessInfo.languageCode` | `cart.businessInfo.currencyCode` | `cart.customerInfo.visitorId` | `cart.customerInfo.memberId` | `cart.customerInfo.userId` | `cart.customerInfo.vatId._id` | `cart.customerInfo.vatId.type` | `cart.customerInfo.languageCode` | `cart.customerInfo.currencyCode` | `cart.deliveryInfo.address.streetAddress.number` | `cart.deliveryInfo.address.streetAddress.name` | `cart.deliveryInfo.method.code` | `cart.deliveryInfo.method.pickup` | `cart.deliveryInfo.weightUnit` | `cart.taxInfo.pricesIncludeTax` | `cart.paymentInfo.giftCards` | `cart.paymentInfo.giftCards.${number}._id` | `cart.paymentInfo.giftCards.${number}.obfuscatedCode` | `cart.paymentInfo.giftCards.${number}.appId` | `cart.paymentInfo.currencyCode` | `cart.orderPlaced` | `cart.currentCart`, 7> & {
5132
5262
  __applicationErrorsType?: RefreshCartApplicationErrors;
5133
5263
  }>;
5264
+ /**
5265
+ * Estimates the cart totals based on its current state and the selected
5266
+ * calculation components.
5267
+ *
5268
+ * This API provides a partial, component-based estimation of the cart and is
5269
+ * intended for preview purposes (e.g. showing partial estimated totals).
5270
+ *
5271
+ * The estimation is controlled by boolean flags that indicate which components
5272
+ * should be included (delivery costs, additional fees, taxes, gift cards).
5273
+ * Components that are not explicitly enabled are excluded from the calculation.
5274
+ *
5275
+ * This is NOT a full cart calculation.
5276
+ *
5277
+ * Note that line items discounts are already pre-computed and applied to the Cart.
5278
+ * @param cartId - ID of the Cart to calculate.
5279
+ * @public
5280
+ * @documentationMaturity preview
5281
+ * @requiredField cartId
5282
+ * @permissionId ecom:v2:cart:estimate_cart
5283
+ * @applicableIdentity APP
5284
+ * @fqn wix.ecom.cart.v2.CartService.EstimateCart
5285
+ */
5286
+ declare function estimateCart(cartId: string, options?: EstimateCartOptions): Promise<NonNullablePaths<EstimateCartResponse, `cart._id` | `cart.revision` | `cart.lineItems` | `cart.lineItems.${number}._id` | `cart.lineItems.${number}.name.original` | `cart.lineItems.${number}.quantityInfo.confirmedQuantity` | `cart.lineItems.${number}.quantityInfo.requestedQuantity` | `cart.lineItems.${number}.quantityInfo.fixedQuantity` | `cart.lineItems.${number}.pricing.unitPrice.amount` | `cart.lineItems.${number}.pricing.unitPrice.convertedAmount` | `cart.lineItems.${number}.pricing.priceDescription.original` | `cart.lineItems.${number}.pricing.priceUndetermined` | `cart.lineItems.${number}.source.catalogReference.catalogItemId` | `cart.lineItems.${number}.source.catalogReference.appId` | `cart.lineItems.${number}.attributes.itemType.preset` | `cart.lineItems.${number}.attributes.itemType.custom` | `cart.lineItems.${number}.attributes.physicalProperties.shippable` | `cart.lineItems.${number}.attributes.membersOnly` | `cart.lineItems.${number}.taxConfig.taxableAddress.addressType` | `cart.lineItems.${number}.paymentConfig.savePaymentMethod` | `cart.lineItems.${number}.paymentConfig.selectedMembership._id` | `cart.lineItems.${number}.paymentConfig.selectedMembership.appId` | `cart.lineItems.${number}.paymentConfig.paymentOption` | `cart.lineItems.${number}.status` | `cart.lineItems.${number}.customLineItem` | `cart.coupons` | `cart.coupons.${number}._id` | `cart.coupons.${number}.code` | `cart.source.channelType` | `cart.source.externalReferences` | `cart.source.externalReferences.${number}.appId` | `cart.source.createdBy.visitorId` | `cart.source.createdBy.memberId` | `cart.source.createdBy.userId` | `cart.source.createdBy.appId` | `cart.source.customContentReference.appId` | `cart.source.customContentReference.componentId` | `cart.businessInfo.languageCode` | `cart.businessInfo.currencyCode` | `cart.customerInfo.visitorId` | `cart.customerInfo.memberId` | `cart.customerInfo.userId` | `cart.customerInfo.vatId._id` | `cart.customerInfo.vatId.type` | `cart.customerInfo.languageCode` | `cart.customerInfo.currencyCode` | `cart.deliveryInfo.address.streetAddress.number` | `cart.deliveryInfo.address.streetAddress.name` | `cart.deliveryInfo.method.code` | `cart.deliveryInfo.method.pickup` | `cart.deliveryInfo.weightUnit` | `cart.taxInfo.pricesIncludeTax` | `cart.paymentInfo.giftCards` | `cart.paymentInfo.giftCards.${number}._id` | `cart.paymentInfo.giftCards.${number}.obfuscatedCode` | `cart.paymentInfo.giftCards.${number}.appId` | `cart.paymentInfo.currencyCode` | `cart.orderPlaced` | `cart.currentCart` | `summary.cartId` | `summary.cartRevision` | `summary.calculationId` | `summary.lineItems` | `summary.lineItems.${number}.lineItemId` | `summary.lineItems.${number}.quantity` | `summary.lineItems.${number}.unitPrice.amount` | `summary.lineItems.${number}.unitPrice.convertedAmount` | `summary.discounts` | `summary.discounts.${number}.name.original` | `summary.discounts.${number}.source.sourceType` | `summary.discounts.${number}.scope` | `summary.deliverySummary.method.code` | `summary.deliverySummary.method.pickup` | `summary.additionalFees` | `summary.taxSummary.taxes` | `summary.taxSummary.pricesIncludeTax` | `summary.taxSummary.lineItemTaxes` | `summary.taxSummary.lineItemTaxes.${number}.lineItemId` | `summary.taxSummary.additionalFeeTaxes` | `summary.taxSummary.additionalFeeTaxes.${number}.additionalFeeCode` | `summary.paymentSummary.giftCards` | `summary.paymentSummary.giftCards.${number}.giftCardId` | `summary.paymentSummary.memberships` | `summary.paymentSummary.memberships.${number}._id` | `summary.paymentSummary.memberships.${number}.appId` | `summary.paymentSummary.subscriptionCharges` | `summary.paymentSummary.requiresPaymentAfterGiftCard` | `summary.calculationErrors.generalShippingCalculationError.applicationError.code` | `summary.calculationErrors.generalShippingCalculationError.applicationError.description` | `summary.calculationErrors.generalShippingCalculationError.validationError.fieldViolations` | `summary.calculationErrors.generalShippingCalculationError.validationError.fieldViolations.${number}.field` | `summary.calculationErrors.generalShippingCalculationError.validationError.fieldViolations.${number}.description` | `summary.calculationErrors.generalShippingCalculationError.validationError.fieldViolations.${number}.violatedRule` | `summary.calculationErrors.carrierErrors.errors` | `summary.calculationErrors.carrierErrors.errors.${number}.carrierId` | `summary.calculationErrors.orderValidationErrors` | `summary.spiViolations` | `summary.spiViolations.${number}.severity` | `summary.spiViolations.${number}.target.other.name` | `summary.spiViolations.${number}.target.lineItem.name`, 8> & {
5287
+ __applicationErrorsType?: EstimateCartApplicationErrors;
5288
+ }>;
5289
+ interface EstimateCartOptions {
5290
+ /**
5291
+ * Whether to retrieve the latest item prices, discounts, and inventory data from the catalogs before estimating the cart.
5292
+ *
5293
+ * Default: `false`
5294
+ */
5295
+ refreshCart?: boolean;
5296
+ /**
5297
+ * Specifies the level of **business validation** to perform during cart calculation,
5298
+ * by calling the [Validations service plugin](https://dev.wix.com/api/rest/wix-ecommerce/validations-integration-spi/introduction).
5299
+ */
5300
+ validationConfig?: ValidationsConfigWithLiterals;
5301
+ /**
5302
+ * Whether to calculate delivery costs.
5303
+ * Default: false
5304
+ */
5305
+ calculateDelivery?: boolean;
5306
+ /**
5307
+ * Whether to calculate any additional fees.
5308
+ * Default: false
5309
+ */
5310
+ calculateAdditionalFees?: boolean;
5311
+ /**
5312
+ * Whether to include tax calculation.
5313
+ * Default: false
5314
+ */
5315
+ calculateTax?: boolean;
5316
+ /**
5317
+ * Whether to calculate the effect of gift card balances on the cart total.
5318
+ * Gift cards are not redeemed - only reflected for estimation purposes.
5319
+ * Default: false
5320
+ */
5321
+ calculateGiftCards?: boolean;
5322
+ }
5134
5323
  /**
5135
5324
  * Calculates the cart based on its current state (line items, discounts, delivery method, etc.)
5136
5325
  * and returns a detailed summary including subtotal, delivery costs, taxes, fees and the total price.
5137
- * Note that discounts are already pre-computed and applied to the Cart.
5326
+ * Note that line items discounts are already pre-computed and applied to the Cart.
5138
5327
  * @param cartId - ID of the Cart to calculate.
5139
5328
  * @public
5140
5329
  * @documentationMaturity preview
@@ -5432,4 +5621,4 @@ interface UpdateFormSubmissionsOptions {
5432
5621
  formSubmissions?: FormSubmission[];
5433
5622
  }
5434
5623
 
5435
- export { type ActionEvent, type AddCouponApplicationErrors, type AddCouponRequest, type AddCouponResponse, type AddCouponToCurrentCartRequest, type AddCouponToCurrentCartResponse, type AddGiftCardApplicationErrors, type AddGiftCardRequest, type AddGiftCardResponse, type AddGiftCardToCurrentCartRequest, type AddGiftCardToCurrentCartResponse, type AddLineItemsApplicationErrors, type AddLineItemsOptions, type AddLineItemsRequest, type AddLineItemsResponse, type AddLineItemsToCurrentCartRequest, type AddLineItemsToCurrentCartResponse, type AdditionalFee, AdditionalFeeSource, type AdditionalFeeSourceWithLiterals, type AdditionalFeeTax, type Address, type AddressLocation, type AggregatedTaxBreakdown, type AllLineItemsOutOfStockErrorData, type ApplicableLineItems, type ApplicationError, type AppliedDiscount, type AppliedDiscountDiscountSourceOneOf, type AutoTaxFallbackCalculationDetails, BalanceType, type BalanceTypeWithLiterals, type BusinessInfo, type CalculateCartApplicationErrors, type CalculateCartForV1Request, type CalculateCartForV1Response, type CalculateCartOptions, type CalculateCartRequest, type CalculateCartResponse, type CalculateCurrentCartRequest, type CalculateCurrentCartResponse, type CalculateTotalsResponse, type CalculatedItemModifier, type CalculatedLineItem, type CalculatedPlatformFee, type CalculationConfig, type CalculationErrors, type CalculationErrorsShippingCalculationErrorOneOf, type CalculationOverrides, type Carrier, type CarrierError, type CarrierErrors, type CarrierServiceOption, type Cart, type CartAlreadyOrderedErrorData, type CartSettings, type CartSource, type CartSummary, type CatalogItemInput, type CatalogOverrideFields, type CatalogReference, ChannelType, type ChannelTypeWithLiterals, type Charge, ChargeType, type ChargeTypeWithLiterals, CheckoutStage, type CheckoutStageWithLiterals, type Color, type ConvertedMoney, type Coupon, type CouponAdded, type CouponAlreadyExistsErrorData, type CouponInput, type CouponNotFoundInCartErrorData, type CouponRemoved, type CreateCartApplicationErrors, type CreateCartOptions, type CreateCartRequest, type CreateCartResponse, type CreateCurrentCartRequest, type CreateCurrentCartResponse, type CreatedBy, type CreatedByIdOneOf, type CustomContentReference, type CustomField, type CustomItemAttributes, type CustomItemDeliveryConfig, type CustomItemInput, type CustomItemPaymentConfig, type CustomItemPricingInfo, type CustomItemQuantityInfo, type CustomItemSource, type CustomItemTaxConfig, type CustomerInfo, type CustomerInfoIdOneOf, type DeleteCartRequest, type DeleteCartResponse, type DeleteCurrentCartRequest, type DeleteCurrentCartResponse, type DeliveryAllocation, type DeliveryInfo, type DeliveryLogistics, type DeliveryMethod, type DeliveryMethodInput, type DeliveryMethodNotFoundErrorData, type DeliverySummary, type DeliveryTimeSlot, type Description, type DescriptionLine, type DescriptionLineDescriptionLineValueOneOf, type DescriptionLineName, DescriptionLineType, type DescriptionLineTypeWithLiterals, type DescriptionLineValueOneOf, type Details, type DetailsKindOneOf, type Discount, type DiscountBenefit, type DiscountBenefitValueOneOf, type DiscountRule, type DiscountRuleName, DiscountScope, type DiscountScopeWithLiterals, type DiscountSource, DiscountSourceType, type DiscountSourceTypeWithLiterals, DiscountType, type DiscountTypeWithLiterals, type DomainEvent, type DomainEventBodyOneOf, type DuplicateItemModifierIdsErrorData, type DuplicateLineItemUpdatesErrorData, type DuplicateModifierGroupIdsErrorData, type Empty, type EmptyLineItemUpdatesErrorData, type EmptyPaymentTokenErrorData, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type ExtendedFields, type ExternalReference, FallbackReason, type FallbackReasonWithLiterals, type FieldViolation, FileType, type FileTypeWithLiterals, type FixedQuantityItemErrorData, type FormIdentifier, type FormInfo, type FormSubmission, type FreeTrialPeriod, type FullAddressContactDetails, type GetCartRequest, type GetCartResponse, type GetCheckoutURLRequest, type GetCheckoutURLResponse, type GetCheckoutUrlApplicationErrors, type GetCheckoutUrlOptions, type GetCurrentCartRequest, type GetCurrentCartResponse, type GiftCard, type GiftCardAdded, type GiftCardAlreadyExistsErrorData, type GiftCardInput, type GiftCardNotFoundInCartErrorData, type GiftCardRedeemErrorData, type GiftCardRemoved, type GiftCardSummary, type Group, type HandleAsyncCheckoutCompletionRequest, type HeadersEntry, type IdentificationData, type IdentificationDataIdOneOf, type InsufficientInventoryEntry, type InsufficientInventoryErrorData, type InvalidCouponCodeErrorData, InvalidCouponReason, type InvalidCouponReasonWithLiterals, type InvalidCouponStatusErrorData, type InvalidCouponStatusErrorDataDetailsOneOf, type InvalidGiftCardCodeErrorData, InvalidGiftCardReason, type InvalidGiftCardReasonWithLiterals, type InvalidGiftCardStatusErrorData, type InvalidMembership, type InvalidMembershipEntry, type InvalidMembershipErrorData, type InvalidMembershipPaymentOptionErrorData, type InvalidPaymentStatusErrorData, type InvalidPriceVerificationTokenErrorData, type InvalidThirdPartyCheckoutTokenErrorData, type ItemAttributes, type ItemDeliveryConfig, type ItemDiscount, type ItemModifier, type ItemNotFoundInCatalogErrorData, type ItemPaymentConfig, type ItemPriceBreakdown, type ItemPricingInfo, type ItemQuantityInfo, type ItemSource, ItemStatus, type ItemStatusWithLiterals, type ItemTaxConfig, type ItemTaxFullDetails, type ItemType, type ItemTypeItemTypeDataOneOf, ItemTypePreset, type ItemTypePresetWithLiterals, JurisdictionType, type JurisdictionTypeWithLiterals, type LegacyFields, type LineItem, type LineItemAdded, type LineItemDiscount, type LineItemIdentifier, type LineItemIdentifierIdOneOf, type LineItemNotFoundInCartErrorData, type LineItemPriceConflictErrorData, type LineItemPricesData, type LineItemSummary, type LineItemTax, type LineItemUpdate, ManualCalculationReason, type ManualCalculationReasonWithLiterals, type MarkCartAsCompletedOptions, type MarkCartAsCompletedRequest, type MarkCartAsCompletedResponse, type MaxItemModifiersExceededErrorData, type MaxLineItemsExceededErrorData, type MembersOnlyItemErrorData, type Membership, type MembershipName, type MembershipOptions, type MembershipPaymentCredits, type MerchantDiscount, type MessageEnvelope, type MinLineItemQuantityNotReachedDetails, type MinSubtotalNotReachedDetails, type ModifierGroup, type MultiCurrencyPrice, NameInLineItem, type NameInLineItemWithLiterals, NameInOther, type NameInOtherWithLiterals, type Other, type OtherCharge, type PaymentInfo, type PaymentOption, PaymentOptionType, type PaymentOptionTypeWithLiterals, type PaymentSummary, type PhysicalProperties, type PickupDetails, PickupMethod, type PickupMethodWithLiterals, type PlaceOrderApplicationErrors, type PlaceOrderOptions, type PlaceOrderRequest, type PlaceOrderResponse, type PlainTextValue, PlatformFeeChargeType, type PlatformFeeChargeTypeWithLiterals, type PlatformFeeSummary, type Policy, type PriceDescription, type PriceSummary, type QuantityUpdate, RateType, type RateTypeWithLiterals, type RawHttpResponse, type RedirectUrls, type RefreshCartApplicationErrors, type RefreshCartRequest, type RefreshCartResponse, type RefreshCurrentCartRequest, type RefreshCurrentCartResponse, type Region, type RemoveCouponApplicationErrors, type RemoveCouponFromCurrentCartRequest, type RemoveCouponFromCurrentCartResponse, type RemoveCouponRequest, type RemoveCouponResponse, type RemoveGiftCardApplicationErrors, type RemoveGiftCardFromCurrentCartRequest, type RemoveGiftCardFromCurrentCartResponse, type RemoveGiftCardRequest, type RemoveGiftCardResponse, type RemoveLineItemsApplicationErrors, type RemoveLineItemsFromCurrentCartRequest, type RemoveLineItemsFromCurrentCartResponse, type RemoveLineItemsRequest, type RemoveLineItemsResponse, type RestoreInfo, RuleType, type RuleTypeWithLiterals, type Scope, type SecuredMedia, type SelectedCarrierServiceOption, type SelectedCarrierServiceOptionOtherCharge, type SelectedCarrierServiceOptionPrices, type SelectedMembership, type SelectedMembershipUpdate, type SelectedMemberships, type ServiceProperties, type SetDeliveryMethodApplicationErrors, type SetDeliveryMethodForCurrentCartRequest, type SetDeliveryMethodForCurrentCartResponse, type SetDeliveryMethodRequest, type SetDeliveryMethodResponse, Severity, type SeverityWithLiterals, type ShippingInformation, type ShippingOption, type ShippingPrice, type ShippingRegion, type SomeLineItemsOutOfStockErrorData, type Stage, type StageStagesOneOf, type StreetAddress, type SubscriptionCharges, SubscriptionFrequency, type SubscriptionFrequencyWithLiterals, type SubscriptionOptionInfo, type SubscriptionSettings, SuggestedFix, type SuggestedFixWithLiterals, type SystemError, type Target, type TargetTargetTypeOneOf, type Tax, type TaxBreakdown, type TaxCalculationDetails, type TaxCalculationDetailsCalculationDetailsOneOf, type TaxDetails, type TaxInfo, type TaxRateBreakdown, type TaxSummary, type TaxableAddress, type TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, type TaxableAddressTypeWithLiterals, type Title, type TranslatableString, type UnmarkAsCurrentCartRequest, type UnmarkAsCurrentCartResponse, type UpdateCart, type UpdateCartApplicationErrors, type UpdateCartRequest, type UpdateCartResponse, type UpdateCurrentCartRequest, type UpdateCurrentCartResponse, type UpdateFormSubmissionsInCurrentCartRequest, type UpdateFormSubmissionsInCurrentCartResponse, type UpdateFormSubmissionsOptions, type UpdateFormSubmissionsRequest, type UpdateFormSubmissionsResponse, type UpdateLineItemsApplicationErrors, type UpdateLineItemsInCurrentCartRequest, type UpdateLineItemsInCurrentCartResponse, type UpdateLineItemsOptions, type UpdateLineItemsRequest, type UpdateLineItemsResponse, type V1AdditionalFee, type V2AdditionalFee, type V2CalculationErrors, type V2CalculationErrorsShippingCalculationErrorOneOf, type V2CarrierError, type V2CarrierErrors, type V2Coupon, type V2GiftCard, type V2LineItem, type V2Membership, type V2PriceSummary, type V2SelectedMembership, type V2TaxSummary, type ValidationError, ValidationsConfig, type ValidationsConfigWithLiterals, type VatId, VatType, type VatTypeWithLiterals, type Violation, type ViolationWithErrorSeverityErrorData, type ViolationsList, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, WeightUnit, type WeightUnitWithLiterals, addCoupon, addGiftCard, addLineItems, calculateCart, createCart, deleteCart, getCart, getCheckoutUrl, handleAsyncCheckoutCompletion, markCartAsCompleted, placeOrder, refreshCart, removeCoupon, removeGiftCard, removeLineItems, setDeliveryMethod, updateCart, updateFormSubmissions, updateLineItems };
5624
+ export { type ActionEvent, type AddCouponApplicationErrors, type AddCouponRequest, type AddCouponResponse, type AddCouponToCurrentCartRequest, type AddCouponToCurrentCartResponse, type AddGiftCardApplicationErrors, type AddGiftCardRequest, type AddGiftCardResponse, type AddGiftCardToCurrentCartRequest, type AddGiftCardToCurrentCartResponse, type AddLineItemsApplicationErrors, type AddLineItemsOptions, type AddLineItemsRequest, type AddLineItemsResponse, type AddLineItemsToCurrentCartRequest, type AddLineItemsToCurrentCartResponse, type AdditionalFee, AdditionalFeeSource, type AdditionalFeeSourceWithLiterals, type AdditionalFeeTax, type Address, type AddressLocation, type AggregatedTaxBreakdown, type AllLineItemsOutOfStockErrorData, type ApplicableLineItems, type ApplicationError, type AppliedDiscount, type AppliedDiscountDiscountSourceOneOf, type AutoTaxFallbackCalculationDetails, BalanceType, type BalanceTypeWithLiterals, type BusinessInfo, type CalculateCartApplicationErrors, type CalculateCartForV1Request, type CalculateCartForV1Response, type CalculateCartOptions, type CalculateCartRequest, type CalculateCartResponse, type CalculateCurrentCartRequest, type CalculateCurrentCartResponse, type CalculateTotalsResponse, type CalculatedItemModifier, type CalculatedLineItem, type CalculatedPlatformFee, type CalculationConfig, type CalculationErrors, type CalculationErrorsShippingCalculationErrorOneOf, type CalculationOverrides, type Carrier, type CarrierError, type CarrierErrors, type CarrierServiceOption, type Cart, type CartAlreadyOrderedErrorData, type CartSettings, type CartSource, type CartSummary, type CatalogItemInput, type CatalogOverrideFields, type CatalogReference, ChannelType, type ChannelTypeWithLiterals, type Charge, ChargeType, type ChargeTypeWithLiterals, CheckoutStage, type CheckoutStageWithLiterals, type Color, type ConvertedMoney, type Coupon, type CouponAdded, type CouponAlreadyExistsErrorData, type CouponInput, type CouponNotFoundInCartErrorData, type CouponRemoved, type CreateCartApplicationErrors, type CreateCartOptions, type CreateCartRequest, type CreateCartResponse, type CreateCurrentCartRequest, type CreateCurrentCartResponse, type CreatedBy, type CreatedByIdOneOf, type CustomContentReference, type CustomField, type CustomItemAttributes, type CustomItemDeliveryConfig, type CustomItemInput, type CustomItemPaymentConfig, type CustomItemPricingInfo, type CustomItemQuantityInfo, type CustomItemSource, type CustomItemTaxConfig, type CustomerInfo, type CustomerInfoIdOneOf, type DeleteCartRequest, type DeleteCartResponse, type DeleteCurrentCartRequest, type DeleteCurrentCartResponse, type DeliveryAllocation, type DeliveryInfo, type DeliveryLogistics, type DeliveryMethod, type DeliveryMethodInput, type DeliveryMethodNotFoundErrorData, type DeliverySummary, type DeliveryTimeSlot, type Description, type DescriptionLine, type DescriptionLineDescriptionLineValueOneOf, type DescriptionLineName, DescriptionLineType, type DescriptionLineTypeWithLiterals, type DescriptionLineValueOneOf, type Details, type DetailsKindOneOf, type Discount, type DiscountBenefit, type DiscountBenefitValueOneOf, type DiscountRule, type DiscountRuleName, DiscountScope, type DiscountScopeWithLiterals, type DiscountSource, DiscountSourceType, type DiscountSourceTypeWithLiterals, DiscountType, type DiscountTypeWithLiterals, type DomainEvent, type DomainEventBodyOneOf, type DuplicateItemModifierIdsErrorData, type DuplicateLineItemUpdatesErrorData, type DuplicateModifierGroupIdsErrorData, type Empty, type EmptyLineItemUpdatesErrorData, type EmptyPaymentTokenErrorData, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type EstimateCartApplicationErrors, type EstimateCartOptions, type EstimateCartRequest, type EstimateCartResponse, type EstimateCurrentCartRequest, type EstimateCurrentCartResponse, type ExtendedFields, type ExternalReference, FallbackReason, type FallbackReasonWithLiterals, type FieldViolation, FileType, type FileTypeWithLiterals, type FixedQuantityItemErrorData, type FormIdentifier, type FormInfo, type FormSubmission, type FreeTrialPeriod, type FullAddressContactDetails, type GetCartRequest, type GetCartResponse, type GetCheckoutURLRequest, type GetCheckoutURLResponse, type GetCheckoutUrlApplicationErrors, type GetCheckoutUrlOptions, type GetCurrentCartRequest, type GetCurrentCartResponse, type GiftCard, type GiftCardAdded, type GiftCardAlreadyExistsErrorData, type GiftCardInput, type GiftCardNotFoundInCartErrorData, type GiftCardRedeemErrorData, type GiftCardRemoved, type GiftCardSummary, type Group, type HandleAsyncCheckoutCompletionRequest, type HeadersEntry, type IdentificationData, type IdentificationDataIdOneOf, type InsufficientInventoryEntry, type InsufficientInventoryErrorData, type InvalidCouponCodeErrorData, InvalidCouponReason, type InvalidCouponReasonWithLiterals, type InvalidCouponStatusErrorData, type InvalidCouponStatusErrorDataDetailsOneOf, type InvalidGiftCardCodeErrorData, InvalidGiftCardReason, type InvalidGiftCardReasonWithLiterals, type InvalidGiftCardStatusErrorData, type InvalidMembership, type InvalidMembershipEntry, type InvalidMembershipErrorData, type InvalidMembershipPaymentOptionErrorData, type InvalidPaymentStatusErrorData, type InvalidPriceVerificationTokenErrorData, type InvalidThirdPartyCheckoutTokenErrorData, type ItemAttributes, type ItemCombination, type ItemCombinationLineItem, type ItemDeliveryConfig, type ItemDiscount, type ItemModifier, type ItemNotFoundInCatalogErrorData, type ItemPaymentConfig, type ItemPriceBreakdown, type ItemPricingInfo, type ItemQuantityInfo, type ItemSource, ItemStatus, type ItemStatusWithLiterals, type ItemTaxConfig, type ItemTaxFullDetails, type ItemType, type ItemTypeItemTypeDataOneOf, ItemTypePreset, type ItemTypePresetWithLiterals, JurisdictionType, type JurisdictionTypeWithLiterals, type LegacyFields, type LineItem, type LineItemAdded, type LineItemDiscount, type LineItemIdentifier, type LineItemIdentifierIdOneOf, type LineItemNotFoundInCartErrorData, type LineItemPriceConflictErrorData, type LineItemPricesData, type LineItemSummary, type LineItemTax, type LineItemUpdate, ManualCalculationReason, type ManualCalculationReasonWithLiterals, type MarkCartAsCompletedOptions, type MarkCartAsCompletedRequest, type MarkCartAsCompletedResponse, type MaxItemModifiersExceededErrorData, type MaxLineItemsExceededErrorData, type MembersOnlyItemErrorData, type Membership, type MembershipName, type MembershipOptions, type MembershipPaymentCredits, type MerchantDiscount, type MessageEnvelope, type MinLineItemQuantityNotReachedDetails, type MinSubtotalNotReachedDetails, type ModifierGroup, type MultiCurrencyPrice, NameInLineItem, type NameInLineItemWithLiterals, NameInOther, type NameInOtherWithLiterals, type Other, type OtherCharge, type PaymentInfo, type PaymentOption, PaymentOptionType, type PaymentOptionTypeWithLiterals, type PaymentSummary, type PhysicalProperties, type PickupDetails, PickupMethod, type PickupMethodWithLiterals, type PlaceOrderApplicationErrors, type PlaceOrderOptions, type PlaceOrderRequest, type PlaceOrderResponse, type PlainTextValue, PlatformFeeChargeType, type PlatformFeeChargeTypeWithLiterals, type PlatformFeeSummary, type Policy, type PriceDescription, type PriceSummary, type QuantityUpdate, RateType, type RateTypeWithLiterals, type RawHttpResponse, type RedirectUrls, type RefreshCartApplicationErrors, type RefreshCartRequest, type RefreshCartResponse, type RefreshCurrentCartRequest, type RefreshCurrentCartResponse, type Region, type RemoveCouponApplicationErrors, type RemoveCouponFromCurrentCartRequest, type RemoveCouponFromCurrentCartResponse, type RemoveCouponRequest, type RemoveCouponResponse, type RemoveGiftCardApplicationErrors, type RemoveGiftCardFromCurrentCartRequest, type RemoveGiftCardFromCurrentCartResponse, type RemoveGiftCardRequest, type RemoveGiftCardResponse, type RemoveLineItemsApplicationErrors, type RemoveLineItemsFromCurrentCartRequest, type RemoveLineItemsFromCurrentCartResponse, type RemoveLineItemsRequest, type RemoveLineItemsResponse, type RestoreInfo, RuleType, type RuleTypeWithLiterals, type Scope, type SecuredMedia, type SelectedCarrierServiceOption, type SelectedCarrierServiceOptionOtherCharge, type SelectedCarrierServiceOptionPrices, type SelectedMembership, type SelectedMembershipUpdate, type SelectedMemberships, type ServiceProperties, type SetDeliveryMethodApplicationErrors, type SetDeliveryMethodForCurrentCartRequest, type SetDeliveryMethodForCurrentCartResponse, type SetDeliveryMethodRequest, type SetDeliveryMethodResponse, Severity, type SeverityWithLiterals, type ShippingInformation, type ShippingOption, type ShippingPrice, type ShippingRegion, type SomeLineItemsOutOfStockErrorData, type Stage, type StageStagesOneOf, type StreetAddress, type SubscriptionCharges, SubscriptionFrequency, type SubscriptionFrequencyWithLiterals, type SubscriptionOptionInfo, type SubscriptionSettings, SuggestedFix, type SuggestedFixWithLiterals, type SystemError, type Target, type TargetTargetTypeOneOf, type Tax, type TaxBreakdown, type TaxCalculationDetails, type TaxCalculationDetailsCalculationDetailsOneOf, type TaxDetails, type TaxInfo, type TaxRateBreakdown, type TaxSummary, type TaxableAddress, type TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, type TaxableAddressTypeWithLiterals, type Title, type TranslatableString, type UnmarkAsCurrentCartRequest, type UnmarkAsCurrentCartResponse, type UpdateCart, type UpdateCartApplicationErrors, type UpdateCartRequest, type UpdateCartResponse, type UpdateCurrentCartRequest, type UpdateCurrentCartResponse, type UpdateFormSubmissionsInCurrentCartRequest, type UpdateFormSubmissionsInCurrentCartResponse, type UpdateFormSubmissionsOptions, type UpdateFormSubmissionsRequest, type UpdateFormSubmissionsResponse, type UpdateLineItemsApplicationErrors, type UpdateLineItemsInCurrentCartRequest, type UpdateLineItemsInCurrentCartResponse, type UpdateLineItemsOptions, type UpdateLineItemsRequest, type UpdateLineItemsResponse, type V1AdditionalFee, type V2AdditionalFee, type V2CalculationErrors, type V2CalculationErrorsShippingCalculationErrorOneOf, type V2CarrierError, type V2CarrierErrors, type V2Coupon, type V2GiftCard, type V2LineItem, type V2Membership, type V2PriceSummary, type V2SelectedMembership, type V2TaxSummary, type ValidationError, ValidationsConfig, type ValidationsConfigWithLiterals, type VatId, VatType, type VatTypeWithLiterals, type Violation, type ViolationWithErrorSeverityErrorData, type ViolationsList, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, WeightUnit, type WeightUnitWithLiterals, addCoupon, addGiftCard, addLineItems, calculateCart, createCart, deleteCart, estimateCart, getCart, getCheckoutUrl, handleAsyncCheckoutCompletion, markCartAsCompleted, placeOrder, refreshCart, removeCoupon, removeGiftCard, removeLineItems, setDeliveryMethod, updateCart, updateFormSubmissions, updateLineItems };
@@ -421,6 +421,63 @@ function refreshCart(payload) {
421
421
  }
422
422
  return __refreshCart;
423
423
  }
424
+ function estimateCart(payload) {
425
+ function __estimateCart({ host }) {
426
+ const metadata = {
427
+ entityFqdn: "wix.ecom.v2.cart",
428
+ method: "POST",
429
+ methodFqn: "wix.ecom.cart.v2.CartService.EstimateCart",
430
+ packageName: PACKAGE_NAME,
431
+ migrationOptions: {
432
+ optInTransformResponse: true
433
+ },
434
+ url: resolveWixEcomCartV2CartServiceUrl({
435
+ protoPath: "/v2/carts/{cartId}/estimate",
436
+ data: payload,
437
+ host
438
+ }),
439
+ data: payload,
440
+ transformResponse: (payload2) => transformPaths(payload2, [
441
+ {
442
+ transformFn: transformRESTTimestampToSDKTimestamp,
443
+ paths: [
444
+ { path: "cart.createdDate" },
445
+ { path: "cart.updatedDate" },
446
+ {
447
+ path: "cart.lineItems.source.catalogOverrideFields.image.urlExpirationDate"
448
+ },
449
+ { path: "cart.lineItems.attributes.image.urlExpirationDate" },
450
+ {
451
+ path: "cart.lineItems.attributes.subscriptionInfo.subscriptionSettings.startDate"
452
+ },
453
+ {
454
+ path: "cart.lineItems.attributes.serviceProperties.scheduledDate"
455
+ },
456
+ { path: "cart.lineItems.attributes.serviceProperties.endDate" },
457
+ {
458
+ path: "summary.paymentSummary.subscriptionCharges.charges.cycleBillingDate"
459
+ }
460
+ ]
461
+ },
462
+ {
463
+ transformFn: transformRESTFloatToSDKFloat,
464
+ paths: [
465
+ {
466
+ path: "cart.lineItems.source.catalogOverrideFields.physicalProperties.weight"
467
+ },
468
+ { path: "cart.lineItems.attributes.physicalProperties.weight" },
469
+ { path: "cart.deliveryInfo.address.geocode.latitude" },
470
+ { path: "cart.deliveryInfo.address.geocode.longitude" },
471
+ { path: "cart.paymentInfo.billingAddress.geocode.latitude" },
472
+ { path: "cart.paymentInfo.billingAddress.geocode.longitude" }
473
+ ]
474
+ }
475
+ ])
476
+ };
477
+ return metadata;
478
+ }
479
+ return __estimateCart;
480
+ }
424
481
  function calculateCart(payload) {
425
482
  function __calculateCart({ host }) {
426
483
  const metadata = {
@@ -1629,6 +1686,66 @@ async function refreshCart2(cartId) {
1629
1686
  throw transformedError;
1630
1687
  }
1631
1688
  }
1689
+ async function estimateCart2(cartId, options) {
1690
+ const { httpClient, sideEffects } = arguments[2];
1691
+ const payload = renameKeysFromSDKRequestToRESTRequest({
1692
+ cartId,
1693
+ refreshCart: options?.refreshCart,
1694
+ validationConfig: options?.validationConfig,
1695
+ calculateDelivery: options?.calculateDelivery,
1696
+ calculateAdditionalFees: options?.calculateAdditionalFees,
1697
+ calculateTax: options?.calculateTax,
1698
+ calculateGiftCards: options?.calculateGiftCards
1699
+ });
1700
+ const reqOpts = estimateCart(payload);
1701
+ sideEffects?.onSiteCall?.();
1702
+ try {
1703
+ const result = await httpClient.request(reqOpts);
1704
+ sideEffects?.onSuccess?.(result);
1705
+ return renameKeysFromRESTResponseToSDKResponse(
1706
+ transformPaths2(result.data, [
1707
+ {
1708
+ transformFn: transformRESTImageToSDKImage,
1709
+ paths: [
1710
+ { path: "cart.lineItems.source.catalogOverrideFields.image" },
1711
+ { path: "cart.lineItems.attributes.image" }
1712
+ ]
1713
+ },
1714
+ {
1715
+ transformFn: transformRESTPageURLV2ToSDKPageURLV2,
1716
+ paths: [{ path: "cart.lineItems.attributes.url" }]
1717
+ },
1718
+ {
1719
+ transformFn: transformRESTAddressToSDKAddress,
1720
+ paths: [
1721
+ { path: "cart.deliveryInfo.address" },
1722
+ { path: "cart.paymentInfo.billingAddress" }
1723
+ ]
1724
+ }
1725
+ ])
1726
+ );
1727
+ } catch (err) {
1728
+ const transformedError = sdkTransformError(
1729
+ err,
1730
+ {
1731
+ spreadPathsToArguments: {},
1732
+ explicitPathsToArguments: {
1733
+ cartId: "$[0]",
1734
+ refreshCart: "$[1].refreshCart",
1735
+ validationConfig: "$[1].validationConfig",
1736
+ calculateDelivery: "$[1].calculateDelivery",
1737
+ calculateAdditionalFees: "$[1].calculateAdditionalFees",
1738
+ calculateTax: "$[1].calculateTax",
1739
+ calculateGiftCards: "$[1].calculateGiftCards"
1740
+ },
1741
+ singleArgumentUnchanged: false
1742
+ },
1743
+ ["cartId", "options"]
1744
+ );
1745
+ sideEffects?.onError?.(err);
1746
+ throw transformedError;
1747
+ }
1748
+ }
1632
1749
  async function calculateCart2(cartId, options) {
1633
1750
  const { httpClient, sideEffects } = arguments[2];
1634
1751
  const payload = renameKeysFromSDKRequestToRESTRequest({
@@ -2307,6 +2424,7 @@ export {
2307
2424
  calculateCart2 as calculateCart,
2308
2425
  createCart2 as createCart,
2309
2426
  deleteCart2 as deleteCart,
2427
+ estimateCart2 as estimateCart,
2310
2428
  getCart2 as getCart,
2311
2429
  getCheckoutUrl2 as getCheckoutUrl,
2312
2430
  handleAsyncCheckoutCompletion2 as handleAsyncCheckoutCompletion,