@wix/auto_sdk_ecom_current-cart 1.0.134 → 1.0.136
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 +10 -6
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +15 -5
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +7 -1
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +10 -6
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +15 -5
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +7 -1
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +10 -6
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +15 -5
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +7 -1
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +10 -6
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +15 -5
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +7 -1
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +2 -2
package/build/es/index.d.mts
CHANGED
|
@@ -1,17 +1,21 @@
|
|
|
1
1
|
import { HttpClient, NonNullablePaths, EventDefinition, MaybeContext, BuildRESTFunction, BuildEventDefinition } from '@wix/sdk-types';
|
|
2
|
-
import { Cart, UpdateCurrentCartOptions, AddToCurrentCartOptions, AddToCartResponse, RemoveLineItemsResponse, CreateCheckoutFromCurrentCartOptions, CreateCheckoutResponse, RemoveCouponResponse, LineItemQuantityUpdate, UpdateLineItemsQuantityResponse, EstimateCurrentCartTotalsOptions, EstimateTotalsResponse, CartDeletedEnvelope, CartUpdatedEnvelope, CartCreatedEnvelope } from './index.typings.mjs';
|
|
2
|
+
import { Cart, GetCurrentCartApplicationErrors, UpdateCurrentCartOptions, AddToCurrentCartOptions, AddToCartResponse, RemoveLineItemsResponse, CreateCheckoutFromCurrentCartOptions, CreateCheckoutResponse, RemoveCouponResponse, LineItemQuantityUpdate, UpdateLineItemsQuantityResponse, EstimateCurrentCartTotalsOptions, EstimateTotalsResponse, CartDeletedEnvelope, CartUpdatedEnvelope, CartCreatedEnvelope } from './index.typings.mjs';
|
|
3
3
|
export { AccountInfo, AccountInfoMetadata, ActionEvent, AddToCartRequest, AddToCurrentCartAndEstimateTotalsRequest, AddToCurrentCartRequest, AdditionalFee, AdditionalFeeSource, AdditionalFeeSourceWithLiterals, Address, AddressLocation, AddressWithContact, AggregatedTaxBreakdown, ApplicableLineItems, ApplicationError, AppliedDiscount, AppliedDiscountDiscountSourceOneOf, AppliedDiscountDiscountType, AppliedDiscountDiscountTypeWithLiterals, AutoTaxFallbackCalculationDetails, BalanceType, BalanceTypeWithLiterals, BaseEventMetadata, BuyerInfo, BuyerInfoIdOneOf, CalculatedItemModifier, CalculatedLineItem, CalculationErrors, CalculationErrorsShippingCalculationErrorOneOf, Carrier, CarrierError, CarrierErrors, CarrierServiceOption, CartDiscount, CartDiscountDiscountSourceOneOf, CatalogOverrideFields, CatalogReference, ChannelType, ChannelTypeWithLiterals, ChargeType, ChargeTypeWithLiterals, Color, Coupon, CreateCartRequest, CreateCartResponse, CreateCheckoutFromCurrentCartRequest, CreateCheckoutRequest, CustomLineItem, DeleteCartRequest, DeleteCartResponse, DeleteCurrentCartRequest, DeliveryAllocation, DeliveryLogistics, DeliveryTimeSlot, Description, DescriptionLine, DescriptionLineDescriptionLineValueOneOf, DescriptionLineName, DescriptionLineType, DescriptionLineTypeWithLiterals, DescriptionLineValueOneOf, Details, DetailsKindOneOf, DiscountRule, DiscountRuleName, DiscountType, DiscountTypeWithLiterals, DomainEvent, DomainEventBodyOneOf, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, EstimateCurrentCartTotalsRequest, EstimateTotalsRequest, EventMetadata, ExtendedFields, FallbackReason, FallbackReasonWithLiterals, FieldViolation, FileType, FileTypeWithLiterals, FocalPoint, FreeTrialPeriod, FullAddressContactDetails, GetCartByCheckoutIdRequest, GetCartByCheckoutIdResponse, GetCartRequest, GetCartResponse, GetCurrentCartRequest, GetCurrentCartResponse, GiftCard, Group, HostSelectedMembership, IdentificationData, IdentificationDataIdOneOf, InvalidMembership, ItemAvailabilityInfo, ItemAvailabilityStatus, ItemAvailabilityStatusWithLiterals, ItemCombination, ItemCombinationLineItem, ItemModifier, ItemTaxFullDetails, ItemType, ItemTypeItemTypeDataOneOf, ItemTypePreset, ItemTypePresetWithLiterals, JurisdictionType, JurisdictionTypeWithLiterals, LineItem, LineItemAdded, LineItemDiscount, LineItemPricesData, ManualCalculationReason, ManualCalculationReasonWithLiterals, Membership, MembershipName, MembershipOptions, MembershipPaymentCredits, MerchantDiscount, MerchantDiscountInput, MessageEnvelope, ModifierGroup, MultiCurrencyPrice, NameInLineItem, NameInLineItemWithLiterals, NameInOther, NameInOtherWithLiterals, Other, OtherCharge, PaymentOption, PaymentOptionType, PaymentOptionTypeWithLiterals, PhysicalProperties, PickupDetails, PickupMethod, PickupMethodWithLiterals, PlainTextValue, PlatformFee, PlatformFeeChargeType, PlatformFeeChargeTypeWithLiterals, Policy, PriceDescription, PriceSummary, ProductName, RateType, RateTypeWithLiterals, Region, RemoveBusinessLocationRequest, RemoveBusinessLocationResponse, RemoveCouponFromCurrentCartRequest, RemoveCouponRequest, RemoveLineItemsFromCurrentCartRequest, RemoveLineItemsRequest, RestoreInfo, RuleType, RuleTypeWithLiterals, Scope, SecuredMedia, SelectedCarrierServiceOption, SelectedCarrierServiceOptionOtherCharge, SelectedCarrierServiceOptionPrices, SelectedMembership, SelectedMemberships, SelectedShippingOption, ServiceProperties, Severity, SeverityWithLiterals, ShippingInformation, ShippingOption, ShippingPrice, ShippingRegion, StreetAddress, SubscriptionFrequency, SubscriptionFrequencyWithLiterals, SubscriptionOptionInfo, SubscriptionSettings, SuggestedFix, SuggestedFixWithLiterals, SystemError, Target, TargetLineItem, TargetTargetTypeOneOf, TaxBreakdown, TaxCalculationDetails, TaxCalculationDetailsCalculationDetailsOneOf, TaxRateBreakdown, TaxSummary, TaxableAddress, TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, TaxableAddressTypeWithLiterals, Title, TranslatableString, UpdateCartRequest, UpdateCartResponse, UpdateCurrentCartLineItemQuantityRequest, UpdateLineItemsQuantityRequest, V1Coupon, V1DiscountRule, V1DiscountRuleName, V1ItemModifier, V1MerchantDiscount, V1ModifierGroup, ValidationError, VatId, VatType, VatTypeWithLiterals, Violation, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WeightUnit, WeightUnitWithLiterals } from './index.typings.mjs';
|
|
4
4
|
|
|
5
5
|
declare function getCurrentCart$1(httpClient: HttpClient): GetCurrentCartSignature;
|
|
6
6
|
interface GetCurrentCartSignature {
|
|
7
7
|
/**
|
|
8
|
-
* Retrieves the current site visitor's cart.
|
|
8
|
+
* Retrieves the current site visitor/member's cart.
|
|
9
9
|
*
|
|
10
|
-
* >**
|
|
11
|
-
* >
|
|
10
|
+
* >**Notes:**
|
|
11
|
+
* > + A 'current cart' is automatically created when the site visitor/member adds an item to their cart, or when calling [Add To Current Cart](https://dev.wix.com/docs/api-reference/business-solutions/e-commerce/purchase-flow/cart/cart/add-to-current-cart).
|
|
12
|
+
* > + Calling this method before adding an item to the cart will return a 404 error.
|
|
13
|
+
* > + This method requires [visitor or member authentication](https://dev.wix.com/docs/api-reference/articles/authentication/about-identities).
|
|
12
14
|
* @returns Current session's active cart.
|
|
13
15
|
*/
|
|
14
|
-
(): Promise<NonNullablePaths<Cart, `lineItems` | `lineItems.${number}.quantity` | `lineItems.${number}.catalogReference.catalogItemId` | `lineItems.${number}.catalogReference.appId` | `lineItems.${number}.productName.original` | `lineItems.${number}.price.amount` | `lineItems.${number}.price.convertedAmount` | `lineItems.${number}.price.formattedAmount` | `lineItems.${number}.price.formattedConvertedAmount` | `lineItems.${number}.availability.status` | `lineItems.${number}.physicalProperties.shippable` | `lineItems.${number}.itemType.preset` | `lineItems.${number}.itemType.custom` | `lineItems.${number}.subscriptionOptionInfo.subscriptionSettings.frequency` | `lineItems.${number}.subscriptionOptionInfo.subscriptionSettings.autoRenewal` | `lineItems.${number}.subscriptionOptionInfo.subscriptionSettings.enableCustomerCancellation` | `lineItems.${number}.subscriptionOptionInfo.title.original` | `lineItems.${number}.subscriptionOptionInfo.description.original` | `lineItems.${number}.paymentOption` | `lineItems.${number}.priceDescription.original` | `lineItems.${number}.selectedMembership._id` | `lineItems.${number}.selectedMembership.appId` | `lineItems.${number}.customLineItem` | `lineItems.${number}.priceUndetermined` | `lineItems.${number}.fixedQuantity` | `lineItems.${number}.catalogOverrideFields.paymentOption.value` | `lineItems.${number}.savePaymentMethod` | `lineItems.${number}.taxableAddress.addressType` | `lineItems.${number}.membersOnly` | `buyerInfo.visitorId` | `buyerInfo.memberId` | `buyerInfo.userId` | `currency` | `conversionCurrency` | `weightUnit` | `appliedDiscounts` | `appliedDiscounts.${number}.coupon._id` | `appliedDiscounts.${number}.coupon.code` | `contactInfo.address.streetAddress.number` | `contactInfo.address.streetAddress.name` | `contactInfo.contactDetails.vatId._id` | `contactInfo.contactDetails.vatId.type` | `selectedShippingOption.code` | `paymentCurrency`, 6
|
|
16
|
+
(): Promise<NonNullablePaths<Cart, `lineItems` | `lineItems.${number}.quantity` | `lineItems.${number}.catalogReference.catalogItemId` | `lineItems.${number}.catalogReference.appId` | `lineItems.${number}.productName.original` | `lineItems.${number}.price.amount` | `lineItems.${number}.price.convertedAmount` | `lineItems.${number}.price.formattedAmount` | `lineItems.${number}.price.formattedConvertedAmount` | `lineItems.${number}.availability.status` | `lineItems.${number}.physicalProperties.shippable` | `lineItems.${number}.itemType.preset` | `lineItems.${number}.itemType.custom` | `lineItems.${number}.subscriptionOptionInfo.subscriptionSettings.frequency` | `lineItems.${number}.subscriptionOptionInfo.subscriptionSettings.autoRenewal` | `lineItems.${number}.subscriptionOptionInfo.subscriptionSettings.enableCustomerCancellation` | `lineItems.${number}.subscriptionOptionInfo.title.original` | `lineItems.${number}.subscriptionOptionInfo.description.original` | `lineItems.${number}.paymentOption` | `lineItems.${number}.priceDescription.original` | `lineItems.${number}.selectedMembership._id` | `lineItems.${number}.selectedMembership.appId` | `lineItems.${number}.customLineItem` | `lineItems.${number}.priceUndetermined` | `lineItems.${number}.fixedQuantity` | `lineItems.${number}.catalogOverrideFields.paymentOption.value` | `lineItems.${number}.savePaymentMethod` | `lineItems.${number}.taxableAddress.addressType` | `lineItems.${number}.membersOnly` | `buyerInfo.visitorId` | `buyerInfo.memberId` | `buyerInfo.userId` | `currency` | `conversionCurrency` | `weightUnit` | `appliedDiscounts` | `appliedDiscounts.${number}.coupon._id` | `appliedDiscounts.${number}.coupon.code` | `contactInfo.address.streetAddress.number` | `contactInfo.address.streetAddress.name` | `contactInfo.contactDetails.vatId._id` | `contactInfo.contactDetails.vatId.type` | `selectedShippingOption.code` | `paymentCurrency`, 6> & {
|
|
17
|
+
__applicationErrorsType?: GetCurrentCartApplicationErrors;
|
|
18
|
+
}>;
|
|
15
19
|
}
|
|
16
20
|
declare function updateCurrentCart$1(httpClient: HttpClient): UpdateCurrentCartSignature;
|
|
17
21
|
interface UpdateCurrentCartSignature {
|
|
@@ -145,4 +149,4 @@ declare const onCartUpdated: BuildEventDefinition<typeof onCartUpdated$1> & type
|
|
|
145
149
|
*/
|
|
146
150
|
declare const onCartCreated: BuildEventDefinition<typeof onCartCreated$1> & typeof onCartCreated$1;
|
|
147
151
|
|
|
148
|
-
export { AddToCartResponse, AddToCurrentCartOptions, Cart, CartCreatedEnvelope, CartDeletedEnvelope, CartUpdatedEnvelope, CreateCheckoutFromCurrentCartOptions, CreateCheckoutResponse, EstimateCurrentCartTotalsOptions, EstimateTotalsResponse, LineItemQuantityUpdate, RemoveCouponResponse, RemoveLineItemsResponse, UpdateCurrentCartOptions, UpdateLineItemsQuantityResponse, addToCurrentCart, createCheckoutFromCurrentCart, deleteCurrentCart, estimateCurrentCartTotals, getCurrentCart, onCartCreated, onCartDeleted, onCartUpdated, removeCouponFromCurrentCart, removeLineItemsFromCurrentCart, updateCurrentCart, updateCurrentCartLineItemQuantity };
|
|
152
|
+
export { AddToCartResponse, AddToCurrentCartOptions, Cart, CartCreatedEnvelope, CartDeletedEnvelope, CartUpdatedEnvelope, CreateCheckoutFromCurrentCartOptions, CreateCheckoutResponse, EstimateCurrentCartTotalsOptions, EstimateTotalsResponse, GetCurrentCartApplicationErrors, LineItemQuantityUpdate, RemoveCouponResponse, RemoveLineItemsResponse, UpdateCurrentCartOptions, UpdateLineItemsQuantityResponse, addToCurrentCart, createCheckoutFromCurrentCart, deleteCurrentCart, estimateCurrentCartTotals, getCurrentCart, onCartCreated, onCartDeleted, onCartUpdated, removeCouponFromCurrentCart, removeLineItemsFromCurrentCart, updateCurrentCart, updateCurrentCartLineItemQuantity };
|