@wix/auto_sdk_ecom_cart-v-2 1.0.15 → 1.0.17
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 +68 -38
- package/build/cjs/index.js +53 -17
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +1 -1
- package/build/cjs/index.typings.js +53 -17
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +155 -33
- package/build/cjs/meta.js +51 -0
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +68 -38
- package/build/es/index.mjs +53 -15
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +1 -1
- package/build/es/index.typings.mjs +53 -15
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +155 -33
- package/build/es/meta.mjs +51 -0
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +2 -2
- package/build/internal/cjs/index.js +53 -17
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +69 -39
- package/build/internal/cjs/index.typings.js +53 -17
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +155 -33
- package/build/internal/cjs/meta.js +51 -0
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +2 -2
- package/build/internal/es/index.mjs +53 -15
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +69 -39
- package/build/internal/es/index.typings.mjs +53 -15
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +155 -33
- package/build/internal/es/meta.mjs +51 -0
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
export { ActionEvent, AddCouponRequest, AddCouponResponse, AddCouponToCurrentCartRequest, AddCouponToCurrentCartResponse, AddGiftCardRequest, AddGiftCardResponse, AddGiftCardToCurrentCartRequest, AddGiftCardToCurrentCartResponse, AddLineItemsOptions, AddLineItemsRequest, AddLineItemsResponse, AddLineItemsToCurrentCartRequest, AddLineItemsToCurrentCartResponse, AdditionalFee, AdditionalFeeTax, Address, AddressLocation, ApplicationError, BusinessInfo, CalculateCartOptions, CalculateCartRequest, CalculateCartResponse, CalculateCurrentCartRequest, CalculateCurrentCartResponse,
|
|
1
|
+
export { ActionEvent, AddCouponRequest, AddCouponResponse, AddCouponToCurrentCartRequest, AddCouponToCurrentCartResponse, AddGiftCardRequest, AddGiftCardResponse, AddGiftCardToCurrentCartRequest, AddGiftCardToCurrentCartResponse, AddLineItemsOptions, AddLineItemsRequest, AddLineItemsResponse, AddLineItemsToCurrentCartRequest, AddLineItemsToCurrentCartResponse, AdditionalFee, AdditionalFeeTax, Address, AddressLocation, ApplicationError, BusinessInfo, CalculateCartOptions, CalculateCartRequest, CalculateCartResponse, CalculateCurrentCartRequest, CalculateCurrentCartResponse, CalculationConfig, CalculationErrors, CalculationErrorsShippingCalculationErrorOneOf, CarrierError, CarrierErrors, Cart, CartSettings, CartSource, CartSummary, CatalogItemInput, CatalogOverrideFields, CatalogReference, ChannelType, ChannelTypeWithLiterals, Charge, Color, Coupon, CreateCartOptions, CreateCartRequest, CreateCartResponse, CreateCurrentCartRequest, CreateCurrentCartResponse, CreatedBy, CreatedByIdOneOf, CustomContentReference, CustomField, CustomItemAttributes, CustomItemDeliveryConfig, CustomItemInput, CustomItemPaymentConfig, CustomItemPricingInfo, CustomItemQuantityInfo, CustomItemSource, CustomItemTaxConfig, CustomerInfo, CustomerInfoIdOneOf, DeleteCartRequest, DeleteCartResponse, DeleteCurrentCartRequest, DeleteCurrentCartResponse, DeliveryInfo, DeliveryMethod, DeliverySummary, Description, DescriptionLine, DescriptionLineDescriptionLineValueOneOf, DescriptionLineName, DescriptionLineType, DescriptionLineTypeWithLiterals, DescriptionLineValueOneOf, Details, DetailsKindOneOf, Discount, DiscountBenefit, DiscountBenefitValueOneOf, DiscountScope, DiscountScopeWithLiterals, DiscountSource, DiscountSourceType, DiscountSourceTypeWithLiterals, DomainEvent, DomainEventBodyOneOf, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, ExtendedFields, ExternalReference, FieldViolation, FileType, FileTypeWithLiterals, FreeTrialPeriod, FullAddressContactDetails, GetCartRequest, GetCartResponse, GetCheckoutURLRequest, GetCheckoutURLResponse, GetCheckoutUrlOptions, GetCurrentCartRequest, GetCurrentCartResponse, GiftCard, GiftCardSummary, Group, HandleAsyncCheckoutCompletionRequest, HeadersEntry, IdentificationData, IdentificationDataIdOneOf, ItemAttributes, ItemDeliveryConfig, ItemDiscount, ItemModifier, ItemPaymentConfig, ItemPriceBreakdown, ItemPricingInfo, ItemQuantityInfo, ItemSource, ItemStatus, ItemStatusWithLiterals, ItemTaxConfig, ItemType, ItemTypeItemType, ItemTypeItemTypeDataOneOf, ItemTypeItemTypeWithLiterals, LegacyFields, LineItem, LineItemSummary, LineItemTax, LineItemUpdate, MarkCartAsCompletedOptions, MarkCartAsCompletedRequest, MarkCartAsCompletedResponse, Membership, MessageEnvelope, ModifierGroup, MultiCurrencyPrice, NameInLineItem, NameInLineItemWithLiterals, NameInOther, NameInOtherWithLiterals, Other, PaymentInfo, PaymentOption, PaymentOptionType, PaymentOptionTypeWithLiterals, PaymentSummary, PhysicalProperties, PlaceOrderOptions, PlaceOrderRequest, PlaceOrderResponse, PlainTextValue, Policy, PriceDescription, PriceSummary, QuantityUpdate, RawHttpResponse, RedirectUrls, RefreshCartRequest, RefreshCartResponse, RefreshCurrentCartRequest, RefreshCurrentCartResponse, RemoveCouponFromCurrentCartRequest, RemoveCouponFromCurrentCartResponse, RemoveCouponRequest, RemoveCouponResponse, RemoveGiftCardFromCurrentCartRequest, RemoveGiftCardFromCurrentCartResponse, RemoveGiftCardRequest, RemoveGiftCardResponse, RemoveLineItemsFromCurrentCartRequest, RemoveLineItemsFromCurrentCartResponse, RemoveLineItemsRequest, RemoveLineItemsResponse, RestoreInfo, RuleType, RuleTypeWithLiterals, Scope, SecuredMedia, SelectedMembership, SelectedMembershipUpdate, ServiceProperties, Severity, SeverityWithLiterals, StreetAddress, SubscriptionCharges, SubscriptionFrequency, SubscriptionFrequencyWithLiterals, SubscriptionOptionInfo, SubscriptionSettings, SuggestedFix, SuggestedFixWithLiterals, SystemError, Target, TargetTargetTypeOneOf, Tax, TaxDetails, TaxInfo, TaxSummary, TaxableAddress, TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, TaxableAddressTypeWithLiterals, Title, TranslatableString, UpdateCart, UpdateCartRequest, UpdateCartResponse, UpdateCurrentCartRequest, UpdateCurrentCartResponse, UpdateLineItemsInCurrentCartRequest, UpdateLineItemsInCurrentCartResponse, UpdateLineItemsOptions, UpdateLineItemsRequest, UpdateLineItemsResponse, V2AdditionalFee, V2LineItem, ValidationError, ValidationsConfig, ValidationsConfigWithLiterals, VatId, VatType, VatTypeWithLiterals, Violation, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WeightUnit, WeightUnitWithLiterals } from './index.js';
|
|
@@ -20,12 +20,10 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
20
20
|
// index.typings.ts
|
|
21
21
|
var index_typings_exports = {};
|
|
22
22
|
__export(index_typings_exports, {
|
|
23
|
-
CalculationComponent: () => CalculationComponent,
|
|
24
23
|
ChannelType: () => ChannelType,
|
|
25
24
|
DescriptionLineType: () => DescriptionLineType,
|
|
26
25
|
DiscountScope: () => DiscountScope,
|
|
27
26
|
DiscountSourceType: () => DiscountSourceType,
|
|
28
|
-
ErrorCode: () => ErrorCode,
|
|
29
27
|
FileType: () => FileType,
|
|
30
28
|
ItemStatus: () => ItemStatus,
|
|
31
29
|
ItemTypeItemType: () => ItemTypeItemType,
|
|
@@ -214,6 +212,9 @@ function createCart(payload) {
|
|
|
214
212
|
method: "POST",
|
|
215
213
|
methodFqn: "wix.ecom.cart.v2.CartService.CreateCart",
|
|
216
214
|
packageName: PACKAGE_NAME,
|
|
215
|
+
migrationOptions: {
|
|
216
|
+
optInTransformResponse: true
|
|
217
|
+
},
|
|
217
218
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
218
219
|
protoPath: "/v2/carts",
|
|
219
220
|
data: serializedData,
|
|
@@ -264,6 +265,9 @@ function getCart(payload) {
|
|
|
264
265
|
method: "GET",
|
|
265
266
|
methodFqn: "wix.ecom.cart.v2.CartService.GetCart",
|
|
266
267
|
packageName: PACKAGE_NAME,
|
|
268
|
+
migrationOptions: {
|
|
269
|
+
optInTransformResponse: true
|
|
270
|
+
},
|
|
267
271
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
268
272
|
protoPath: "/v2/carts/{cartId}",
|
|
269
273
|
data: payload,
|
|
@@ -348,6 +352,9 @@ function updateCart(payload) {
|
|
|
348
352
|
method: "PATCH",
|
|
349
353
|
methodFqn: "wix.ecom.cart.v2.CartService.UpdateCart",
|
|
350
354
|
packageName: PACKAGE_NAME,
|
|
355
|
+
migrationOptions: {
|
|
356
|
+
optInTransformResponse: true
|
|
357
|
+
},
|
|
351
358
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
352
359
|
protoPath: "/v2/carts/{cart.id}",
|
|
353
360
|
data: serializedData,
|
|
@@ -398,6 +405,9 @@ function deleteCart(payload) {
|
|
|
398
405
|
method: "DELETE",
|
|
399
406
|
methodFqn: "wix.ecom.cart.v2.CartService.DeleteCart",
|
|
400
407
|
packageName: PACKAGE_NAME,
|
|
408
|
+
migrationOptions: {
|
|
409
|
+
optInTransformResponse: true
|
|
410
|
+
},
|
|
401
411
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
402
412
|
protoPath: "/v2/carts/{cartId}",
|
|
403
413
|
data: payload,
|
|
@@ -416,6 +426,9 @@ function refreshCart(payload) {
|
|
|
416
426
|
method: "POST",
|
|
417
427
|
methodFqn: "wix.ecom.cart.v2.CartService.RefreshCart",
|
|
418
428
|
packageName: PACKAGE_NAME,
|
|
429
|
+
migrationOptions: {
|
|
430
|
+
optInTransformResponse: true
|
|
431
|
+
},
|
|
419
432
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
420
433
|
protoPath: "/v2/carts/{cartId}/refresh",
|
|
421
434
|
data: payload,
|
|
@@ -466,6 +479,9 @@ function calculateCart(payload) {
|
|
|
466
479
|
method: "POST",
|
|
467
480
|
methodFqn: "wix.ecom.cart.v2.CartService.CalculateCart",
|
|
468
481
|
packageName: PACKAGE_NAME,
|
|
482
|
+
migrationOptions: {
|
|
483
|
+
optInTransformResponse: true
|
|
484
|
+
},
|
|
469
485
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
470
486
|
protoPath: "/v2/carts/{cartId}/calculate",
|
|
471
487
|
data: payload,
|
|
@@ -519,6 +535,9 @@ function getCheckoutUrl(payload) {
|
|
|
519
535
|
method: "POST",
|
|
520
536
|
methodFqn: "wix.ecom.cart.v2.CartService.GetCheckoutURL",
|
|
521
537
|
packageName: PACKAGE_NAME,
|
|
538
|
+
migrationOptions: {
|
|
539
|
+
optInTransformResponse: true
|
|
540
|
+
},
|
|
522
541
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
523
542
|
protoPath: "/v2/carts/{cartId}/get-checkout-url",
|
|
524
543
|
data: payload,
|
|
@@ -537,6 +556,9 @@ function placeOrder(payload) {
|
|
|
537
556
|
method: "POST",
|
|
538
557
|
methodFqn: "wix.ecom.cart.v2.CartService.PlaceOrder",
|
|
539
558
|
packageName: PACKAGE_NAME,
|
|
559
|
+
migrationOptions: {
|
|
560
|
+
optInTransformResponse: true
|
|
561
|
+
},
|
|
540
562
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
541
563
|
protoPath: "/v2/carts/{cartId}/place-order",
|
|
542
564
|
data: payload,
|
|
@@ -579,6 +601,9 @@ function addLineItems(payload) {
|
|
|
579
601
|
method: "POST",
|
|
580
602
|
methodFqn: "wix.ecom.cart.v2.CartService.AddLineItems",
|
|
581
603
|
packageName: PACKAGE_NAME,
|
|
604
|
+
migrationOptions: {
|
|
605
|
+
optInTransformResponse: true
|
|
606
|
+
},
|
|
582
607
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
583
608
|
protoPath: "/v2/carts/{cartId}/add-line-items",
|
|
584
609
|
data: serializedData,
|
|
@@ -629,6 +654,9 @@ function removeLineItems(payload) {
|
|
|
629
654
|
method: "POST",
|
|
630
655
|
methodFqn: "wix.ecom.cart.v2.CartService.RemoveLineItems",
|
|
631
656
|
packageName: PACKAGE_NAME,
|
|
657
|
+
migrationOptions: {
|
|
658
|
+
optInTransformResponse: true
|
|
659
|
+
},
|
|
632
660
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
633
661
|
protoPath: "/v2/carts/{cartId}/remove-line-items",
|
|
634
662
|
data: payload,
|
|
@@ -679,6 +707,9 @@ function updateLineItems(payload) {
|
|
|
679
707
|
method: "POST",
|
|
680
708
|
methodFqn: "wix.ecom.cart.v2.CartService.UpdateLineItems",
|
|
681
709
|
packageName: PACKAGE_NAME,
|
|
710
|
+
migrationOptions: {
|
|
711
|
+
optInTransformResponse: true
|
|
712
|
+
},
|
|
682
713
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
683
714
|
protoPath: "/v2/carts/{cartId}/update-line-items",
|
|
684
715
|
data: payload,
|
|
@@ -729,6 +760,9 @@ function addCoupon(payload) {
|
|
|
729
760
|
method: "POST",
|
|
730
761
|
methodFqn: "wix.ecom.cart.v2.CartService.AddCoupon",
|
|
731
762
|
packageName: PACKAGE_NAME,
|
|
763
|
+
migrationOptions: {
|
|
764
|
+
optInTransformResponse: true
|
|
765
|
+
},
|
|
732
766
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
733
767
|
protoPath: "/v2/carts/{cartId}/add-coupon",
|
|
734
768
|
data: payload,
|
|
@@ -779,6 +813,9 @@ function removeCoupon(payload) {
|
|
|
779
813
|
method: "POST",
|
|
780
814
|
methodFqn: "wix.ecom.cart.v2.CartService.RemoveCoupon",
|
|
781
815
|
packageName: PACKAGE_NAME,
|
|
816
|
+
migrationOptions: {
|
|
817
|
+
optInTransformResponse: true
|
|
818
|
+
},
|
|
782
819
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
783
820
|
protoPath: "/v2/carts/{cartId}/remove-coupon",
|
|
784
821
|
data: payload,
|
|
@@ -829,6 +866,9 @@ function addGiftCard(payload) {
|
|
|
829
866
|
method: "POST",
|
|
830
867
|
methodFqn: "wix.ecom.cart.v2.CartService.AddGiftCard",
|
|
831
868
|
packageName: PACKAGE_NAME,
|
|
869
|
+
migrationOptions: {
|
|
870
|
+
optInTransformResponse: true
|
|
871
|
+
},
|
|
832
872
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
833
873
|
protoPath: "/v2/carts/{cartId}/add-gift-card",
|
|
834
874
|
data: payload,
|
|
@@ -879,6 +919,9 @@ function removeGiftCard(payload) {
|
|
|
879
919
|
method: "POST",
|
|
880
920
|
methodFqn: "wix.ecom.cart.v2.CartService.RemoveGiftCard",
|
|
881
921
|
packageName: PACKAGE_NAME,
|
|
922
|
+
migrationOptions: {
|
|
923
|
+
optInTransformResponse: true
|
|
924
|
+
},
|
|
882
925
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
883
926
|
protoPath: "/v2/carts/{cartId}/remove-gift-card",
|
|
884
927
|
data: payload,
|
|
@@ -929,6 +972,9 @@ function markCartAsCompleted(payload) {
|
|
|
929
972
|
method: "POST",
|
|
930
973
|
methodFqn: "wix.ecom.cart.v2.CartService.MarkCartAsCompleted",
|
|
931
974
|
packageName: PACKAGE_NAME,
|
|
975
|
+
migrationOptions: {
|
|
976
|
+
optInTransformResponse: true
|
|
977
|
+
},
|
|
932
978
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
933
979
|
protoPath: "/v2/carts/{cartId}/mark-cart-as-completed",
|
|
934
980
|
data: payload,
|
|
@@ -979,6 +1025,9 @@ function handleAsyncCheckoutCompletion(payload) {
|
|
|
979
1025
|
method: "POST",
|
|
980
1026
|
methodFqn: "wix.ecom.cart.v2.CartService.HandleAsyncCheckoutCompletion",
|
|
981
1027
|
packageName: PACKAGE_NAME,
|
|
1028
|
+
migrationOptions: {
|
|
1029
|
+
optInTransformResponse: true
|
|
1030
|
+
},
|
|
982
1031
|
url: resolveWixEcomCartV2CartServiceUrl({
|
|
983
1032
|
protoPath: "/v2/carts/handle-async-checkout-completion",
|
|
984
1033
|
data: payload,
|
|
@@ -1105,19 +1154,6 @@ var DiscountScope = /* @__PURE__ */ ((DiscountScope2) => {
|
|
|
1105
1154
|
DiscountScope2["DELIVERY"] = "DELIVERY";
|
|
1106
1155
|
return DiscountScope2;
|
|
1107
1156
|
})(DiscountScope || {});
|
|
1108
|
-
var CalculationComponent = /* @__PURE__ */ ((CalculationComponent2) => {
|
|
1109
|
-
CalculationComponent2["UNKNOWN_CALCULATION_COMPONENT"] = "UNKNOWN_CALCULATION_COMPONENT";
|
|
1110
|
-
CalculationComponent2["DISCOUNTS"] = "DISCOUNTS";
|
|
1111
|
-
CalculationComponent2["DELIVERY"] = "DELIVERY";
|
|
1112
|
-
CalculationComponent2["TAX"] = "TAX";
|
|
1113
|
-
CalculationComponent2["MEMBERSHIPS"] = "MEMBERSHIPS";
|
|
1114
|
-
CalculationComponent2["GIFT_CARDS"] = "GIFT_CARDS";
|
|
1115
|
-
return CalculationComponent2;
|
|
1116
|
-
})(CalculationComponent || {});
|
|
1117
|
-
var ErrorCode = /* @__PURE__ */ ((ErrorCode2) => {
|
|
1118
|
-
ErrorCode2["UNKNOWN_ERROR_CODE"] = "UNKNOWN_ERROR_CODE";
|
|
1119
|
-
return ErrorCode2;
|
|
1120
|
-
})(ErrorCode || {});
|
|
1121
1157
|
var RuleType = /* @__PURE__ */ ((RuleType2) => {
|
|
1122
1158
|
RuleType2["VALIDATION"] = "VALIDATION";
|
|
1123
1159
|
RuleType2["OTHER"] = "OTHER";
|
|
@@ -1520,6 +1556,7 @@ async function placeOrder2(cartId, options) {
|
|
|
1520
1556
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
1521
1557
|
cartId,
|
|
1522
1558
|
pricingToken: options?.pricingToken,
|
|
1559
|
+
paymentToken: options?.paymentToken,
|
|
1523
1560
|
redirectUrls: options?.redirectUrls,
|
|
1524
1561
|
savePaymentMethod: options?.savePaymentMethod,
|
|
1525
1562
|
delayCapture: options?.delayCapture
|
|
@@ -1538,6 +1575,7 @@ async function placeOrder2(cartId, options) {
|
|
|
1538
1575
|
explicitPathsToArguments: {
|
|
1539
1576
|
cartId: "$[0]",
|
|
1540
1577
|
pricingToken: "$[1].pricingToken",
|
|
1578
|
+
paymentToken: "$[1].paymentToken",
|
|
1541
1579
|
redirectUrls: "$[1].redirectUrls",
|
|
1542
1580
|
savePaymentMethod: "$[1].savePaymentMethod",
|
|
1543
1581
|
delayCapture: "$[1].delayCapture"
|
|
@@ -1974,12 +2012,10 @@ async function handleAsyncCheckoutCompletion2(token) {
|
|
|
1974
2012
|
}
|
|
1975
2013
|
// Annotate the CommonJS export names for ESM import in node:
|
|
1976
2014
|
0 && (module.exports = {
|
|
1977
|
-
CalculationComponent,
|
|
1978
2015
|
ChannelType,
|
|
1979
2016
|
DescriptionLineType,
|
|
1980
2017
|
DiscountScope,
|
|
1981
2018
|
DiscountSourceType,
|
|
1982
|
-
ErrorCode,
|
|
1983
2019
|
FileType,
|
|
1984
2020
|
ItemStatus,
|
|
1985
2021
|
ItemTypeItemType,
|