@wix/auto_sdk_ecom_current-cart 1.0.130 → 1.0.132
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 +1 -1
- package/build/cjs/index.js +9 -9
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +1 -1
- package/build/cjs/index.typings.js +6 -6
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.js +6 -6
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +1 -1
- package/build/es/index.mjs +9 -9
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +1 -1
- package/build/es/index.typings.mjs +6 -6
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.mjs +6 -6
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +1 -1
- package/build/internal/cjs/index.js +9 -9
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +1 -1
- package/build/internal/cjs/index.typings.js +6 -6
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.js +6 -6
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +1 -1
- package/build/internal/es/index.mjs +9 -9
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +1 -1
- package/build/internal/es/index.typings.mjs +6 -6
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.mjs +6 -6
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +2 -2
package/build/cjs/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpClient, NonNullablePaths, EventDefinition, MaybeContext, BuildRESTFunction, BuildEventDefinition } from '@wix/sdk-types';
|
|
2
2
|
import { Cart, UpdateCurrentCartOptions, AddToCurrentCartOptions, AddToCartResponse, RemoveLineItemsResponse, CreateCheckoutFromCurrentCartOptions, CreateCheckoutResponse, RemoveCouponResponse, LineItemQuantityUpdate, UpdateLineItemsQuantityResponse, EstimateCurrentCartTotalsOptions, EstimateTotalsResponse, CartDeletedEnvelope, CartUpdatedEnvelope, CartCreatedEnvelope } from './index.typings.js';
|
|
3
|
-
export { AccountInfo, 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.js';
|
|
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.js';
|
|
4
4
|
|
|
5
5
|
declare function getCurrentCart$1(httpClient: HttpClient): GetCurrentCartSignature;
|
|
6
6
|
interface GetCurrentCartSignature {
|
package/build/cjs/index.js
CHANGED
|
@@ -51,7 +51,7 @@ __export(index_exports, {
|
|
|
51
51
|
createCheckoutFromCurrentCart: () => createCheckoutFromCurrentCart4,
|
|
52
52
|
deleteCurrentCart: () => deleteCurrentCart4,
|
|
53
53
|
estimateCurrentCartTotals: () => estimateCurrentCartTotals4,
|
|
54
|
-
getCurrentCart: () =>
|
|
54
|
+
getCurrentCart: () => getCurrentCart4,
|
|
55
55
|
onCartCreated: () => onCartCreated2,
|
|
56
56
|
onCartDeleted: () => onCartDeleted2,
|
|
57
57
|
onCartUpdated: () => onCartUpdated2,
|
|
@@ -195,8 +195,8 @@ function resolveComWixEcomCartApiV1CurrentCartServiceUrl(opts) {
|
|
|
195
195
|
return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
|
|
196
196
|
}
|
|
197
197
|
var PACKAGE_NAME = "@wix/auto_sdk_ecom_current-cart";
|
|
198
|
-
function
|
|
199
|
-
function
|
|
198
|
+
function getCurrentCart(payload) {
|
|
199
|
+
function __getCurrentCart({ host }) {
|
|
200
200
|
const metadata = {
|
|
201
201
|
entityFqdn: "wix.ecom.v1.cart",
|
|
202
202
|
method: "GET",
|
|
@@ -242,7 +242,7 @@ function currentCartGetCurrentCart(payload) {
|
|
|
242
242
|
};
|
|
243
243
|
return metadata;
|
|
244
244
|
}
|
|
245
|
-
return
|
|
245
|
+
return __getCurrentCart;
|
|
246
246
|
}
|
|
247
247
|
function updateCurrentCart(payload) {
|
|
248
248
|
function __updateCurrentCart({ host }) {
|
|
@@ -921,10 +921,10 @@ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
|
921
921
|
WebhookIdentityType2["APP"] = "APP";
|
|
922
922
|
return WebhookIdentityType2;
|
|
923
923
|
})(WebhookIdentityType || {});
|
|
924
|
-
async function
|
|
924
|
+
async function getCurrentCart2() {
|
|
925
925
|
const { httpClient, sideEffects } = arguments[0];
|
|
926
926
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({});
|
|
927
|
-
const reqOpts =
|
|
927
|
+
const reqOpts = getCurrentCart(payload);
|
|
928
928
|
sideEffects?.onSiteCall?.();
|
|
929
929
|
try {
|
|
930
930
|
const result = await httpClient.request(reqOpts);
|
|
@@ -1373,8 +1373,8 @@ async function deleteCurrentCart2() {
|
|
|
1373
1373
|
}
|
|
1374
1374
|
|
|
1375
1375
|
// src/ecom-v1-cart-current-cart.public.ts
|
|
1376
|
-
function
|
|
1377
|
-
return () =>
|
|
1376
|
+
function getCurrentCart3(httpClient) {
|
|
1377
|
+
return () => getCurrentCart2(
|
|
1378
1378
|
// @ts-ignore
|
|
1379
1379
|
{ httpClient }
|
|
1380
1380
|
);
|
|
@@ -1593,7 +1593,7 @@ var onCartCreated = (0, import_sdk_types.EventDefinition)(
|
|
|
1593
1593
|
// src/ecom-v1-cart-current-cart.context.ts
|
|
1594
1594
|
var import_rest_modules3 = require("@wix/sdk-runtime/rest-modules");
|
|
1595
1595
|
var import_event_definition_modules = require("@wix/sdk-runtime/event-definition-modules");
|
|
1596
|
-
var
|
|
1596
|
+
var getCurrentCart4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getCurrentCart3);
|
|
1597
1597
|
var updateCurrentCart4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateCurrentCart3);
|
|
1598
1598
|
var addToCurrentCart4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(addToCurrentCart3);
|
|
1599
1599
|
var removeLineItemsFromCurrentCart4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(removeLineItemsFromCurrentCart3);
|