@wix/auto_sdk_ecom_cart-v-2 1.0.39 → 1.0.41
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.
- package/build/cjs/index.d.ts +139 -4049
- package/build/cjs/index.js +16 -16
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +4374 -1
- package/build/cjs/index.typings.js +12 -12
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +32 -29
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +139 -4049
- package/build/es/index.mjs +16 -16
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +4374 -1
- package/build/es/index.typings.mjs +12 -12
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +32 -29
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +4 -40
- package/build/internal/cjs/index.js +16 -16
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +58 -58
- package/build/internal/cjs/index.typings.js +12 -12
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +30 -28
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +4 -40
- package/build/internal/es/index.mjs +16 -16
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +58 -58
- package/build/internal/es/index.typings.mjs +12 -12
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +30 -28
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +2 -2
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { HttpClient, NonNullablePaths, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
|
|
2
|
-
import { CreateCartOptions, Cart, GetCartApplicationErrors, UpdateCart, RefreshCartResponse, CalculateCartOptions, CalculateCartResponse, GetCheckoutUrlOptions, GetCheckoutURLResponse, PlaceOrderOptions, PlaceOrderResponse, AddLineItemsOptions, AddLineItemsResponse, RemoveLineItemsResponse, UpdateLineItemsOptions, UpdateLineItemsResponse, AddCouponResponse, RemoveCouponResponse, DeliveryMethodInput, SetDeliveryMethodResponse, AddGiftCardResponse, RemoveGiftCardResponse, MarkCartAsCompletedOptions, MarkCartAsCompletedResponse, RawHttpResponse } from './index.typings.js';
|
|
2
|
+
import { CreateCartOptions, Cart, GetCartApplicationErrors, UpdateCart, RefreshCartResponse, CalculateCartOptions, CalculateCartResponse, GetCheckoutUrlOptions, GetCheckoutURLResponse, PlaceOrderOptions, PlaceOrderResponse, AddLineItemsOptions, AddLineItemsResponse, RemoveLineItemsResponse, UpdateLineItemsOptions, UpdateLineItemsResponse, CouponInput, AddCouponResponse, RemoveCouponResponse, DeliveryMethodInput, SetDeliveryMethodResponse, GiftCardInput, AddGiftCardResponse, RemoveGiftCardResponse, MarkCartAsCompletedOptions, MarkCartAsCompletedResponse, RawHttpResponse } from './index.typings.js';
|
|
3
3
|
export { ActionEvent, AddCouponRequest, AddCouponToCurrentCartRequest, AddCouponToCurrentCartResponse, AddGiftCardRequest, AddGiftCardToCurrentCartRequest, AddGiftCardToCurrentCartResponse, AddLineItemsRequest, AddLineItemsToCurrentCartRequest, AddLineItemsToCurrentCartResponse, AdditionalFee, AdditionalFeeSource, AdditionalFeeSourceWithLiterals, AdditionalFeeTax, Address, AddressLocation, AggregatedTaxBreakdown, ApplicableLineItems, ApplicationError, AppliedDiscount, AppliedDiscountDiscountSourceOneOf, AutoTaxFallbackCalculationDetails, BusinessInfo, CalculateCartForV1Request, CalculateCartForV1Response, CalculateCartRequest, CalculateCurrentCartRequest, CalculateCurrentCartResponse, CalculateTotalsResponse, CalculatedItemModifier, CalculatedLineItem, CalculationConfig, CalculationErrors, CalculationErrorsShippingCalculationErrorOneOf, Carrier, CarrierError, CarrierErrors, CarrierServiceOption, CartSettings, CartSource, CartSummary, CatalogItemInput, CatalogOverrideFields, CatalogReference, ChannelType, ChannelTypeWithLiterals, Charge, ChargeType, ChargeTypeWithLiterals, CheckoutStage, CheckoutStageWithLiterals, Color, ConvertedMoney, Coupon, CreateCartRequest, CreateCartResponse, CreateCurrentCartRequest, CreateCurrentCartResponse, CreatedBy, CreatedByIdOneOf, CustomContentReference, CustomField, CustomItemAttributes, CustomItemDeliveryConfig, CustomItemInput, CustomItemPaymentConfig, CustomItemPricingInfo, CustomItemQuantityInfo, CustomItemSource, CustomItemTaxConfig, CustomerInfo, CustomerInfoIdOneOf, DeleteCartRequest, DeleteCartResponse, DeleteCurrentCartRequest, DeleteCurrentCartResponse, DeliveryAllocation, DeliveryInfo, DeliveryLogistics, DeliveryMethod, DeliverySummary, DeliveryTimeSlot, Description, DescriptionLine, DescriptionLineDescriptionLineValueOneOf, DescriptionLineName, DescriptionLineType, DescriptionLineTypeWithLiterals, DescriptionLineValueOneOf, Details, DetailsKindOneOf, Discount, DiscountBenefit, DiscountBenefitValueOneOf, DiscountRule, DiscountRuleName, DiscountScope, DiscountScopeWithLiterals, DiscountSource, DiscountSourceType, DiscountSourceTypeWithLiterals, DiscountType, DiscountTypeWithLiterals, DomainEvent, DomainEventBodyOneOf, DummyErrorDataMethodLevel, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, ExtendedFields, ExternalReference, FallbackReason, FallbackReasonWithLiterals, FieldViolation, FileType, FileTypeWithLiterals, FreeTrialPeriod, FullAddressContactDetails, GetCartRequest, GetCartResponse, GetCheckoutURLRequest, GetCurrentCartRequest, GetCurrentCartResponse, GiftCard, GiftCardSummary, Group, HandleAsyncCheckoutCompletionRequest, HeadersEntry, IdentificationData, IdentificationDataIdOneOf, InvalidMembership, ItemAttributes, ItemDeliveryConfig, ItemDiscount, ItemModifier, ItemPaymentConfig, ItemPriceBreakdown, ItemPricingInfo, ItemQuantityInfo, ItemSource, ItemStatus, ItemStatusWithLiterals, ItemTaxConfig, ItemTaxFullDetails, ItemType, ItemTypeItemTypeDataOneOf, ItemTypePreset, ItemTypePresetWithLiterals, JurisdictionType, JurisdictionTypeWithLiterals, LegacyFields, LineItem, LineItemDiscount, LineItemIdentifier, LineItemIdentifierIdOneOf, LineItemPricesData, LineItemSummary, LineItemTax, LineItemUpdate, ManualCalculationReason, ManualCalculationReasonWithLiterals, MarkCartAsCompletedRequest, Membership, MembershipName, MembershipOptions, MembershipPaymentCredits, MerchantDiscount, MessageEnvelope, ModifierGroup, MultiCurrencyPrice, NameInLineItem, NameInLineItemWithLiterals, NameInOther, NameInOtherWithLiterals, Other, OtherCharge, PaymentInfo, PaymentOption, PaymentOptionType, PaymentOptionTypeWithLiterals, PaymentSummary, PhysicalProperties, PickupDetails, PickupMethod, PickupMethodWithLiterals, PlaceOrderRequest, PlainTextValue, Policy, PriceDescription, PriceSummary, QuantityUpdate, RateType, RateTypeWithLiterals, RedirectUrls, RefreshCartRequest, RefreshCurrentCartRequest, RefreshCurrentCartResponse, Region, RemoveCouponFromCurrentCartRequest, RemoveCouponFromCurrentCartResponse, RemoveCouponRequest, RemoveGiftCardFromCurrentCartRequest, RemoveGiftCardFromCurrentCartResponse, RemoveGiftCardRequest, RemoveLineItemsFromCurrentCartRequest, RemoveLineItemsFromCurrentCartResponse, RemoveLineItemsRequest, RestoreInfo, RuleType, RuleTypeWithLiterals, Scope, SecuredMedia, SelectedCarrierServiceOption, SelectedCarrierServiceOptionOtherCharge, SelectedCarrierServiceOptionPrices, SelectedMembership, SelectedMembershipUpdate, ServiceProperties, SetDeliveryMethodForCurrentCartRequest, SetDeliveryMethodForCurrentCartResponse, SetDeliveryMethodRequest, Severity, SeverityWithLiterals, ShippingInformation, ShippingOption, ShippingPrice, ShippingRegion, Stage, StageStagesOneOf, StreetAddress, SubscriptionCharges, SubscriptionFrequency, SubscriptionFrequencyWithLiterals, SubscriptionOptionInfo, SubscriptionSettings, SuggestedFix, SuggestedFixWithLiterals, SystemError, Target, TargetTargetTypeOneOf, Tax, TaxBreakdown, TaxCalculationDetails, TaxCalculationDetailsCalculationDetailsOneOf, TaxDetails, TaxInfo, TaxRateBreakdown, TaxSummary, TaxableAddress, TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, TaxableAddressTypeWithLiterals, Title, TranslatableString, UnmarkAsCurrentCartRequest, UnmarkAsCurrentCartResponse, UpdateCartRequest, UpdateCartResponse, UpdateCurrentCartRequest, UpdateCurrentCartResponse, UpdateLineItemsInCurrentCartRequest, UpdateLineItemsInCurrentCartResponse, UpdateLineItemsRequest, V1AdditionalFee, V2AdditionalFee, V2CalculationErrors, V2CalculationErrorsShippingCalculationErrorOneOf, V2CarrierError, V2CarrierErrors, V2Coupon, V2GiftCard, V2LineItem, V2Membership, V2PriceSummary, V2SelectedMembership, V2TaxSummary, ValidationError, ValidationsConfig, ValidationsConfigWithLiterals, VatId, VatType, VatTypeWithLiterals, Violation, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WeightUnit, WeightUnitWithLiterals } from './index.typings.js';
|
|
4
4
|
|
|
5
|
-
/** @internal */
|
|
6
5
|
declare function createCart$1(httpClient: HttpClient): CreateCartSignature;
|
|
7
6
|
interface CreateCartSignature {
|
|
8
7
|
/**
|
|
@@ -11,7 +10,6 @@ interface CreateCartSignature {
|
|
|
11
10
|
*/
|
|
12
11
|
(options?: NonNullablePaths<CreateCartOptions, `catalogItems.${number}.catalogReference` | `catalogItems.${number}.quantity` | `catalogItems.${number}.selectedMembership._id` | `catalogItems.${number}.selectedMembership.appId` | `customItems.${number}.attributes.descriptionLines.${number}.name` | `customItems.${number}.attributes.itemType` | `customItems.${number}.name` | `customItems.${number}.pricing` | `customItems.${number}.pricing.price` | `customItems.${number}.quantityInfo` | `customItems.${number}.quantityInfo.requestedQuantity`, 7>): Promise<NonNullablePaths<Cart, `_id` | `revision` | `lineItems` | `lineItems.${number}._id` | `lineItems.${number}.name.original` | `lineItems.${number}.quantityInfo.confirmedQuantity` | `lineItems.${number}.quantityInfo.requestedQuantity` | `lineItems.${number}.quantityInfo.fixedQuantity` | `lineItems.${number}.pricing.unitPrice.amount` | `lineItems.${number}.pricing.unitPrice.convertedAmount` | `lineItems.${number}.pricing.priceDescription.original` | `lineItems.${number}.pricing.priceUndetermined` | `lineItems.${number}.source.catalogReference.catalogItemId` | `lineItems.${number}.source.catalogReference.appId` | `lineItems.${number}.attributes.itemType.preset` | `lineItems.${number}.attributes.itemType.custom` | `lineItems.${number}.attributes.physicalProperties.shippable` | `lineItems.${number}.attributes.membersOnly` | `lineItems.${number}.taxConfig.taxableAddress.addressType` | `lineItems.${number}.paymentConfig.savePaymentMethod` | `lineItems.${number}.paymentConfig.selectedMembership._id` | `lineItems.${number}.paymentConfig.selectedMembership.appId` | `lineItems.${number}.paymentConfig.paymentOption` | `lineItems.${number}.status` | `lineItems.${number}.customLineItem` | `coupons` | `coupons.${number}._id` | `coupons.${number}.code` | `source.channelType` | `source.externalReferences` | `source.externalReferences.${number}.appId` | `source.createdBy.visitorId` | `source.createdBy.memberId` | `source.createdBy.userId` | `source.createdBy.appId` | `source.customContentReference.appId` | `source.customContentReference.componentId` | `businessInfo.languageCode` | `businessInfo.currencyCode` | `customerInfo.visitorId` | `customerInfo.memberId` | `customerInfo.userId` | `customerInfo.vatId._id` | `customerInfo.vatId.type` | `customerInfo.languageCode` | `customerInfo.currencyCode` | `deliveryInfo.address.streetAddress.number` | `deliveryInfo.address.streetAddress.name` | `deliveryInfo.method.code` | `deliveryInfo.method.pickup` | `deliveryInfo.weightUnit` | `taxInfo.pricesIncludeTax` | `paymentInfo.giftCards` | `paymentInfo.giftCards.${number}._id` | `paymentInfo.giftCards.${number}.obfuscatedCode` | `paymentInfo.giftCards.${number}.appId` | `paymentInfo.currencyCode` | `orderPlaced` | `currentCart`, 6>>;
|
|
13
12
|
}
|
|
14
|
-
/** @internal */
|
|
15
13
|
declare function getCart$1(httpClient: HttpClient): GetCartSignature;
|
|
16
14
|
interface GetCartSignature {
|
|
17
15
|
/**
|
|
@@ -23,7 +21,6 @@ interface GetCartSignature {
|
|
|
23
21
|
__applicationErrorsType?: GetCartApplicationErrors;
|
|
24
22
|
}>;
|
|
25
23
|
}
|
|
26
|
-
/** @internal */
|
|
27
24
|
declare function updateCart$1(httpClient: HttpClient): UpdateCartSignature;
|
|
28
25
|
interface UpdateCartSignature {
|
|
29
26
|
/**
|
|
@@ -36,7 +33,6 @@ interface UpdateCartSignature {
|
|
|
36
33
|
*/
|
|
37
34
|
(_id: string, cart: UpdateCart): Promise<NonNullablePaths<Cart, `_id` | `revision` | `lineItems` | `lineItems.${number}._id` | `lineItems.${number}.name.original` | `lineItems.${number}.quantityInfo.confirmedQuantity` | `lineItems.${number}.quantityInfo.requestedQuantity` | `lineItems.${number}.quantityInfo.fixedQuantity` | `lineItems.${number}.pricing.unitPrice.amount` | `lineItems.${number}.pricing.unitPrice.convertedAmount` | `lineItems.${number}.pricing.priceDescription.original` | `lineItems.${number}.pricing.priceUndetermined` | `lineItems.${number}.source.catalogReference.catalogItemId` | `lineItems.${number}.source.catalogReference.appId` | `lineItems.${number}.attributes.itemType.preset` | `lineItems.${number}.attributes.itemType.custom` | `lineItems.${number}.attributes.physicalProperties.shippable` | `lineItems.${number}.attributes.membersOnly` | `lineItems.${number}.taxConfig.taxableAddress.addressType` | `lineItems.${number}.paymentConfig.savePaymentMethod` | `lineItems.${number}.paymentConfig.selectedMembership._id` | `lineItems.${number}.paymentConfig.selectedMembership.appId` | `lineItems.${number}.paymentConfig.paymentOption` | `lineItems.${number}.status` | `lineItems.${number}.customLineItem` | `coupons` | `coupons.${number}._id` | `coupons.${number}.code` | `source.channelType` | `source.externalReferences` | `source.externalReferences.${number}.appId` | `source.createdBy.visitorId` | `source.createdBy.memberId` | `source.createdBy.userId` | `source.createdBy.appId` | `source.customContentReference.appId` | `source.customContentReference.componentId` | `businessInfo.languageCode` | `businessInfo.currencyCode` | `customerInfo.visitorId` | `customerInfo.memberId` | `customerInfo.userId` | `customerInfo.vatId._id` | `customerInfo.vatId.type` | `customerInfo.languageCode` | `customerInfo.currencyCode` | `deliveryInfo.address.streetAddress.number` | `deliveryInfo.address.streetAddress.name` | `deliveryInfo.method.code` | `deliveryInfo.method.pickup` | `deliveryInfo.weightUnit` | `taxInfo.pricesIncludeTax` | `paymentInfo.giftCards` | `paymentInfo.giftCards.${number}._id` | `paymentInfo.giftCards.${number}.obfuscatedCode` | `paymentInfo.giftCards.${number}.appId` | `paymentInfo.currencyCode` | `orderPlaced` | `currentCart`, 6>>;
|
|
38
35
|
}
|
|
39
|
-
/** @internal */
|
|
40
36
|
declare function deleteCart$1(httpClient: HttpClient): DeleteCartSignature;
|
|
41
37
|
interface DeleteCartSignature {
|
|
42
38
|
/**
|
|
@@ -45,7 +41,6 @@ interface DeleteCartSignature {
|
|
|
45
41
|
*/
|
|
46
42
|
(cartId: string): Promise<void>;
|
|
47
43
|
}
|
|
48
|
-
/** @internal */
|
|
49
44
|
declare function refreshCart$1(httpClient: HttpClient): RefreshCartSignature;
|
|
50
45
|
interface RefreshCartSignature {
|
|
51
46
|
/**
|
|
@@ -54,7 +49,6 @@ interface RefreshCartSignature {
|
|
|
54
49
|
*/
|
|
55
50
|
(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>>;
|
|
56
51
|
}
|
|
57
|
-
/** @internal */
|
|
58
52
|
declare function calculateCart$1(httpClient: HttpClient): CalculateCartSignature;
|
|
59
53
|
interface CalculateCartSignature {
|
|
60
54
|
/**
|
|
@@ -65,7 +59,6 @@ interface CalculateCartSignature {
|
|
|
65
59
|
*/
|
|
66
60
|
(cartId: string, options?: CalculateCartOptions): Promise<NonNullablePaths<CalculateCartResponse, `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.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>>;
|
|
67
61
|
}
|
|
68
|
-
/** @internal */
|
|
69
62
|
declare function getCheckoutUrl$1(httpClient: HttpClient): GetCheckoutUrlSignature;
|
|
70
63
|
interface GetCheckoutUrlSignature {
|
|
71
64
|
/**
|
|
@@ -77,7 +70,6 @@ interface GetCheckoutUrlSignature {
|
|
|
77
70
|
*/
|
|
78
71
|
(cartId: string, options?: GetCheckoutUrlOptions): Promise<NonNullablePaths<GetCheckoutURLResponse, `checkoutUrl`, 2>>;
|
|
79
72
|
}
|
|
80
|
-
/** @internal */
|
|
81
73
|
declare function placeOrder$1(httpClient: HttpClient): PlaceOrderSignature;
|
|
82
74
|
interface PlaceOrderSignature {
|
|
83
75
|
/**
|
|
@@ -89,7 +81,6 @@ interface PlaceOrderSignature {
|
|
|
89
81
|
*/
|
|
90
82
|
(cartId: string, options?: PlaceOrderOptions): Promise<NonNullablePaths<PlaceOrderResponse, `orderId` | `completed`, 2>>;
|
|
91
83
|
}
|
|
92
|
-
/** @internal */
|
|
93
84
|
declare function addLineItems$1(httpClient: HttpClient): AddLineItemsSignature;
|
|
94
85
|
interface AddLineItemsSignature {
|
|
95
86
|
/**
|
|
@@ -98,7 +89,6 @@ interface AddLineItemsSignature {
|
|
|
98
89
|
*/
|
|
99
90
|
(cartId: string, options?: NonNullablePaths<AddLineItemsOptions, `catalogItems.${number}.catalogReference` | `catalogItems.${number}.quantity` | `catalogItems.${number}.selectedMembership._id` | `catalogItems.${number}.selectedMembership.appId` | `customItems.${number}.attributes.descriptionLines.${number}.name` | `customItems.${number}.attributes.itemType` | `customItems.${number}.name` | `customItems.${number}.pricing` | `customItems.${number}.pricing.price` | `customItems.${number}.quantityInfo` | `customItems.${number}.quantityInfo.requestedQuantity`, 7>): Promise<NonNullablePaths<AddLineItemsResponse, `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>>;
|
|
100
91
|
}
|
|
101
|
-
/** @internal */
|
|
102
92
|
declare function removeLineItems$1(httpClient: HttpClient): RemoveLineItemsSignature;
|
|
103
93
|
interface RemoveLineItemsSignature {
|
|
104
94
|
/**
|
|
@@ -108,7 +98,6 @@ interface RemoveLineItemsSignature {
|
|
|
108
98
|
*/
|
|
109
99
|
(cartId: string, lineItemIds: string[]): Promise<NonNullablePaths<RemoveLineItemsResponse, `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>>;
|
|
110
100
|
}
|
|
111
|
-
/** @internal */
|
|
112
101
|
declare function updateLineItems$1(httpClient: HttpClient): UpdateLineItemsSignature;
|
|
113
102
|
interface UpdateLineItemsSignature {
|
|
114
103
|
/**
|
|
@@ -118,7 +107,6 @@ interface UpdateLineItemsSignature {
|
|
|
118
107
|
*/
|
|
119
108
|
(cartId: string, options?: NonNullablePaths<UpdateLineItemsOptions, `lineItems.${number}.lineItemId` | `lineItems.${number}.quantity.newQuantity`, 5>): Promise<NonNullablePaths<UpdateLineItemsResponse, `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>>;
|
|
120
109
|
}
|
|
121
|
-
/** @internal */
|
|
122
110
|
declare function addCoupon$1(httpClient: HttpClient): AddCouponSignature;
|
|
123
111
|
interface AddCouponSignature {
|
|
124
112
|
/**
|
|
@@ -128,9 +116,8 @@ interface AddCouponSignature {
|
|
|
128
116
|
*
|
|
129
117
|
* Currently only one is supported.
|
|
130
118
|
*/
|
|
131
|
-
(cartId: string,
|
|
119
|
+
(cartId: string, coupon: NonNullablePaths<CouponInput, `code`, 2>): Promise<NonNullablePaths<AddCouponResponse, `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>>;
|
|
132
120
|
}
|
|
133
|
-
/** @internal */
|
|
134
121
|
declare function removeCoupon$1(httpClient: HttpClient): RemoveCouponSignature;
|
|
135
122
|
interface RemoveCouponSignature {
|
|
136
123
|
/**
|
|
@@ -140,7 +127,6 @@ interface RemoveCouponSignature {
|
|
|
140
127
|
*/
|
|
141
128
|
(cartId: string, couponId: string): Promise<NonNullablePaths<RemoveCouponResponse, `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>>;
|
|
142
129
|
}
|
|
143
|
-
/** @internal */
|
|
144
130
|
declare function setDeliveryMethod$1(httpClient: HttpClient): SetDeliveryMethodSignature;
|
|
145
131
|
interface SetDeliveryMethodSignature {
|
|
146
132
|
/**
|
|
@@ -150,7 +136,6 @@ interface SetDeliveryMethodSignature {
|
|
|
150
136
|
*/
|
|
151
137
|
(cartId: string, deliveryMethod: NonNullablePaths<DeliveryMethodInput, `code`, 2>): Promise<NonNullablePaths<SetDeliveryMethodResponse, `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>>;
|
|
152
138
|
}
|
|
153
|
-
/** @internal */
|
|
154
139
|
declare function addGiftCard$1(httpClient: HttpClient): AddGiftCardSignature;
|
|
155
140
|
interface AddGiftCardSignature {
|
|
156
141
|
/**
|
|
@@ -161,9 +146,8 @@ interface AddGiftCardSignature {
|
|
|
161
146
|
*
|
|
162
147
|
* Currently only one is supported.
|
|
163
148
|
*/
|
|
164
|
-
(cartId: string,
|
|
149
|
+
(cartId: string, giftCard: NonNullablePaths<GiftCardInput, `code`, 2>): Promise<NonNullablePaths<AddGiftCardResponse, `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>>;
|
|
165
150
|
}
|
|
166
|
-
/** @internal */
|
|
167
151
|
declare function removeGiftCard$1(httpClient: HttpClient): RemoveGiftCardSignature;
|
|
168
152
|
interface RemoveGiftCardSignature {
|
|
169
153
|
/**
|
|
@@ -173,7 +157,6 @@ interface RemoveGiftCardSignature {
|
|
|
173
157
|
*/
|
|
174
158
|
(cartId: string, giftCardId: string): Promise<NonNullablePaths<RemoveGiftCardResponse, `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>>;
|
|
175
159
|
}
|
|
176
|
-
/** @internal */
|
|
177
160
|
declare function markCartAsCompleted$1(httpClient: HttpClient): MarkCartAsCompletedSignature;
|
|
178
161
|
interface MarkCartAsCompletedSignature {
|
|
179
162
|
/**
|
|
@@ -184,7 +167,6 @@ interface MarkCartAsCompletedSignature {
|
|
|
184
167
|
*/
|
|
185
168
|
(cartId: string, options?: MarkCartAsCompletedOptions): Promise<NonNullablePaths<MarkCartAsCompletedResponse, `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>>;
|
|
186
169
|
}
|
|
187
|
-
/** @internal */
|
|
188
170
|
declare function handleAsyncCheckoutCompletion$1(httpClient: HttpClient): HandleAsyncCheckoutCompletionSignature;
|
|
189
171
|
interface HandleAsyncCheckoutCompletionSignature {
|
|
190
172
|
/**
|
|
@@ -197,41 +179,23 @@ interface HandleAsyncCheckoutCompletionSignature {
|
|
|
197
179
|
(token: string): Promise<NonNullablePaths<RawHttpResponse, `body` | `headers` | `headers.${number}.key` | `headers.${number}.value`, 4>>;
|
|
198
180
|
}
|
|
199
181
|
|
|
200
|
-
/** @internal */
|
|
201
182
|
declare const createCart: MaybeContext<BuildRESTFunction<typeof createCart$1> & typeof createCart$1>;
|
|
202
|
-
/** @internal */
|
|
203
183
|
declare const getCart: MaybeContext<BuildRESTFunction<typeof getCart$1> & typeof getCart$1>;
|
|
204
|
-
/** @internal */
|
|
205
184
|
declare const updateCart: MaybeContext<BuildRESTFunction<typeof updateCart$1> & typeof updateCart$1>;
|
|
206
|
-
/** @internal */
|
|
207
185
|
declare const deleteCart: MaybeContext<BuildRESTFunction<typeof deleteCart$1> & typeof deleteCart$1>;
|
|
208
|
-
/** @internal */
|
|
209
186
|
declare const refreshCart: MaybeContext<BuildRESTFunction<typeof refreshCart$1> & typeof refreshCart$1>;
|
|
210
|
-
/** @internal */
|
|
211
187
|
declare const calculateCart: MaybeContext<BuildRESTFunction<typeof calculateCart$1> & typeof calculateCart$1>;
|
|
212
|
-
/** @internal */
|
|
213
188
|
declare const getCheckoutUrl: MaybeContext<BuildRESTFunction<typeof getCheckoutUrl$1> & typeof getCheckoutUrl$1>;
|
|
214
|
-
/** @internal */
|
|
215
189
|
declare const placeOrder: MaybeContext<BuildRESTFunction<typeof placeOrder$1> & typeof placeOrder$1>;
|
|
216
|
-
/** @internal */
|
|
217
190
|
declare const addLineItems: MaybeContext<BuildRESTFunction<typeof addLineItems$1> & typeof addLineItems$1>;
|
|
218
|
-
/** @internal */
|
|
219
191
|
declare const removeLineItems: MaybeContext<BuildRESTFunction<typeof removeLineItems$1> & typeof removeLineItems$1>;
|
|
220
|
-
/** @internal */
|
|
221
192
|
declare const updateLineItems: MaybeContext<BuildRESTFunction<typeof updateLineItems$1> & typeof updateLineItems$1>;
|
|
222
|
-
/** @internal */
|
|
223
193
|
declare const addCoupon: MaybeContext<BuildRESTFunction<typeof addCoupon$1> & typeof addCoupon$1>;
|
|
224
|
-
/** @internal */
|
|
225
194
|
declare const removeCoupon: MaybeContext<BuildRESTFunction<typeof removeCoupon$1> & typeof removeCoupon$1>;
|
|
226
|
-
/** @internal */
|
|
227
195
|
declare const setDeliveryMethod: MaybeContext<BuildRESTFunction<typeof setDeliveryMethod$1> & typeof setDeliveryMethod$1>;
|
|
228
|
-
/** @internal */
|
|
229
196
|
declare const addGiftCard: MaybeContext<BuildRESTFunction<typeof addGiftCard$1> & typeof addGiftCard$1>;
|
|
230
|
-
/** @internal */
|
|
231
197
|
declare const removeGiftCard: MaybeContext<BuildRESTFunction<typeof removeGiftCard$1> & typeof removeGiftCard$1>;
|
|
232
|
-
/** @internal */
|
|
233
198
|
declare const markCartAsCompleted: MaybeContext<BuildRESTFunction<typeof markCartAsCompleted$1> & typeof markCartAsCompleted$1>;
|
|
234
|
-
/** @internal */
|
|
235
199
|
declare const handleAsyncCheckoutCompletion: MaybeContext<BuildRESTFunction<typeof handleAsyncCheckoutCompletion$1> & typeof handleAsyncCheckoutCompletion$1>;
|
|
236
200
|
|
|
237
|
-
export { AddCouponResponse, AddGiftCardResponse, AddLineItemsOptions, AddLineItemsResponse, CalculateCartOptions, CalculateCartResponse, Cart, CreateCartOptions, DeliveryMethodInput, GetCartApplicationErrors, GetCheckoutURLResponse, GetCheckoutUrlOptions, MarkCartAsCompletedOptions, MarkCartAsCompletedResponse, PlaceOrderOptions, PlaceOrderResponse, RawHttpResponse, RefreshCartResponse, RemoveCouponResponse, RemoveGiftCardResponse, RemoveLineItemsResponse, SetDeliveryMethodResponse, UpdateCart, UpdateLineItemsOptions, UpdateLineItemsResponse, addCoupon, addGiftCard, addLineItems, calculateCart, createCart, deleteCart, getCart, getCheckoutUrl, handleAsyncCheckoutCompletion, markCartAsCompleted, placeOrder, refreshCart, removeCoupon, removeGiftCard, removeLineItems, setDeliveryMethod, updateCart, updateLineItems };
|
|
201
|
+
export { AddCouponResponse, AddGiftCardResponse, AddLineItemsOptions, AddLineItemsResponse, CalculateCartOptions, CalculateCartResponse, Cart, CouponInput, CreateCartOptions, DeliveryMethodInput, GetCartApplicationErrors, GetCheckoutURLResponse, GetCheckoutUrlOptions, GiftCardInput, MarkCartAsCompletedOptions, MarkCartAsCompletedResponse, PlaceOrderOptions, PlaceOrderResponse, RawHttpResponse, RefreshCartResponse, RemoveCouponResponse, RemoveGiftCardResponse, RemoveLineItemsResponse, SetDeliveryMethodResponse, UpdateCart, UpdateLineItemsOptions, UpdateLineItemsResponse, addCoupon, addGiftCard, addLineItems, calculateCart, createCart, deleteCart, getCart, getCheckoutUrl, handleAsyncCheckoutCompletion, markCartAsCompleted, placeOrder, refreshCart, removeCoupon, removeGiftCard, removeLineItems, setDeliveryMethod, updateCart, updateLineItems };
|
|
@@ -1339,9 +1339,9 @@ async function createCart2(options) {
|
|
|
1339
1339
|
cart: options?.cart,
|
|
1340
1340
|
catalogItems: options?.catalogItems,
|
|
1341
1341
|
customItems: options?.customItems,
|
|
1342
|
-
|
|
1342
|
+
coupons: options?.coupons,
|
|
1343
1343
|
deliveryMethod: options?.deliveryMethod,
|
|
1344
|
-
|
|
1344
|
+
giftCards: options?.giftCards
|
|
1345
1345
|
}),
|
|
1346
1346
|
[
|
|
1347
1347
|
{
|
|
@@ -1405,9 +1405,9 @@ async function createCart2(options) {
|
|
|
1405
1405
|
cart: "$[0].cart",
|
|
1406
1406
|
catalogItems: "$[0].catalogItems",
|
|
1407
1407
|
customItems: "$[0].customItems",
|
|
1408
|
-
|
|
1408
|
+
coupons: "$[0].coupons",
|
|
1409
1409
|
deliveryMethod: "$[0].deliveryMethod",
|
|
1410
|
-
|
|
1410
|
+
giftCards: "$[0].giftCards"
|
|
1411
1411
|
},
|
|
1412
1412
|
singleArgumentUnchanged: false
|
|
1413
1413
|
},
|
|
@@ -1877,11 +1877,11 @@ async function updateLineItems2(cartId, options) {
|
|
|
1877
1877
|
throw transformedError;
|
|
1878
1878
|
}
|
|
1879
1879
|
}
|
|
1880
|
-
async function addCoupon2(cartId,
|
|
1880
|
+
async function addCoupon2(cartId, coupon) {
|
|
1881
1881
|
const { httpClient, sideEffects } = arguments[2];
|
|
1882
1882
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
1883
1883
|
cartId,
|
|
1884
|
-
|
|
1884
|
+
coupon
|
|
1885
1885
|
});
|
|
1886
1886
|
const reqOpts = addCoupon(payload);
|
|
1887
1887
|
sideEffects?.onSiteCall?.();
|
|
@@ -1915,10 +1915,10 @@ async function addCoupon2(cartId, couponCode) {
|
|
|
1915
1915
|
err,
|
|
1916
1916
|
{
|
|
1917
1917
|
spreadPathsToArguments: {},
|
|
1918
|
-
explicitPathsToArguments: { cartId: "$[0]",
|
|
1918
|
+
explicitPathsToArguments: { cartId: "$[0]", coupon: "$[1]" },
|
|
1919
1919
|
singleArgumentUnchanged: false
|
|
1920
1920
|
},
|
|
1921
|
-
["cartId", "
|
|
1921
|
+
["cartId", "coupon"]
|
|
1922
1922
|
);
|
|
1923
1923
|
sideEffects?.onError?.(err);
|
|
1924
1924
|
throw transformedError;
|
|
@@ -2018,11 +2018,11 @@ async function setDeliveryMethod2(cartId, deliveryMethod) {
|
|
|
2018
2018
|
throw transformedError;
|
|
2019
2019
|
}
|
|
2020
2020
|
}
|
|
2021
|
-
async function addGiftCard2(cartId,
|
|
2021
|
+
async function addGiftCard2(cartId, giftCard) {
|
|
2022
2022
|
const { httpClient, sideEffects } = arguments[2];
|
|
2023
2023
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2024
2024
|
cartId,
|
|
2025
|
-
|
|
2025
|
+
giftCard
|
|
2026
2026
|
});
|
|
2027
2027
|
const reqOpts = addGiftCard(payload);
|
|
2028
2028
|
sideEffects?.onSiteCall?.();
|
|
@@ -2056,10 +2056,10 @@ async function addGiftCard2(cartId, giftCardCode) {
|
|
|
2056
2056
|
err,
|
|
2057
2057
|
{
|
|
2058
2058
|
spreadPathsToArguments: {},
|
|
2059
|
-
explicitPathsToArguments: { cartId: "$[0]",
|
|
2059
|
+
explicitPathsToArguments: { cartId: "$[0]", giftCard: "$[1]" },
|
|
2060
2060
|
singleArgumentUnchanged: false
|
|
2061
2061
|
},
|
|
2062
|
-
["cartId", "
|
|
2062
|
+
["cartId", "giftCard"]
|
|
2063
2063
|
);
|
|
2064
2064
|
sideEffects?.onError?.(err);
|
|
2065
2065
|
throw transformedError;
|
|
@@ -2269,9 +2269,9 @@ function updateLineItems3(httpClient) {
|
|
|
2269
2269
|
);
|
|
2270
2270
|
}
|
|
2271
2271
|
function addCoupon3(httpClient) {
|
|
2272
|
-
return (cartId,
|
|
2272
|
+
return (cartId, coupon) => addCoupon2(
|
|
2273
2273
|
cartId,
|
|
2274
|
-
|
|
2274
|
+
coupon,
|
|
2275
2275
|
// @ts-ignore
|
|
2276
2276
|
{ httpClient }
|
|
2277
2277
|
);
|
|
@@ -2293,9 +2293,9 @@ function setDeliveryMethod3(httpClient) {
|
|
|
2293
2293
|
);
|
|
2294
2294
|
}
|
|
2295
2295
|
function addGiftCard3(httpClient) {
|
|
2296
|
-
return (cartId,
|
|
2296
|
+
return (cartId, giftCard) => addGiftCard2(
|
|
2297
2297
|
cartId,
|
|
2298
|
-
|
|
2298
|
+
giftCard,
|
|
2299
2299
|
// @ts-ignore
|
|
2300
2300
|
{ httpClient }
|
|
2301
2301
|
);
|