@wix/auto_sdk_ecom_orders 1.0.34 → 1.0.36
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 -0
- package/build/cjs/index.js +18 -0
- package/build/cjs/index.js.map +1 -0
- package/build/cjs/index.typings.d.ts +1 -0
- package/build/cjs/index.typings.js +18 -0
- package/build/cjs/index.typings.js.map +1 -0
- package/build/cjs/meta.d.ts +1 -0
- package/build/cjs/meta.js +18 -0
- package/build/cjs/meta.js.map +1 -0
- package/build/cjs/src/ecom-v1-order-orders.context.d.ts +34 -0
- package/build/cjs/src/ecom-v1-order-orders.context.js +117 -0
- package/build/cjs/src/ecom-v1-order-orders.context.js.map +1 -0
- package/build/cjs/src/ecom-v1-order-orders.http.d.ts +200 -0
- package/build/cjs/src/ecom-v1-order-orders.http.js +1610 -0
- package/build/cjs/src/ecom-v1-order-orders.http.js.map +1 -0
- package/build/cjs/src/ecom-v1-order-orders.meta.d.ts +78 -0
- package/build/cjs/src/ecom-v1-order-orders.meta.js +503 -0
- package/build/cjs/src/ecom-v1-order-orders.meta.js.map +1 -0
- package/build/cjs/src/ecom-v1-order-orders.public.d.ts +189 -0
- package/build/cjs/src/ecom-v1-order-orders.public.js +382 -0
- package/build/cjs/src/ecom-v1-order-orders.public.js.map +1 -0
- package/build/{ecom-v1-order-orders.universal-UflOyGzD.d.mts → cjs/src/ecom-v1-order-orders.types.d.ts} +637 -1109
- package/build/cjs/src/ecom-v1-order-orders.types.js +652 -0
- package/build/cjs/src/ecom-v1-order-orders.types.js.map +1 -0
- package/build/{internal/ecom-v1-order-orders.universal-DkzM7BQ-.d.ts → cjs/src/ecom-v1-order-orders.universal.d.ts} +985 -957
- package/build/cjs/src/ecom-v1-order-orders.universal.js +2294 -0
- package/build/cjs/src/ecom-v1-order-orders.universal.js.map +1 -0
- package/build/es/index.d.ts +1 -0
- package/build/es/index.js +2 -0
- package/build/es/index.js.map +1 -0
- package/build/es/index.typings.d.ts +1 -0
- package/build/es/index.typings.js +2 -0
- package/build/es/index.typings.js.map +1 -0
- package/build/es/meta.d.ts +1 -0
- package/build/es/meta.js +2 -0
- package/build/es/meta.js.map +1 -0
- package/build/es/package.json +3 -0
- package/build/es/src/ecom-v1-order-orders.context.d.ts +34 -0
- package/build/es/src/ecom-v1-order-orders.context.js +62 -0
- package/build/es/src/ecom-v1-order-orders.context.js.map +1 -0
- package/build/es/src/ecom-v1-order-orders.http.d.ts +200 -0
- package/build/es/src/ecom-v1-order-orders.http.js +1582 -0
- package/build/es/src/ecom-v1-order-orders.http.js.map +1 -0
- package/build/es/src/ecom-v1-order-orders.meta.d.ts +78 -0
- package/build/es/src/ecom-v1-order-orders.meta.js +452 -0
- package/build/es/src/ecom-v1-order-orders.meta.js.map +1 -0
- package/build/es/src/ecom-v1-order-orders.public.d.ts +189 -0
- package/build/es/src/ecom-v1-order-orders.public.js +302 -0
- package/build/es/src/ecom-v1-order-orders.public.js.map +1 -0
- package/build/{ecom-v1-order-orders.universal-UflOyGzD.d.ts → es/src/ecom-v1-order-orders.types.d.ts} +637 -1109
- package/build/es/src/ecom-v1-order-orders.types.js +648 -0
- package/build/es/src/ecom-v1-order-orders.types.js.map +1 -0
- package/build/{internal/ecom-v1-order-orders.universal-DkzM7BQ-.d.mts → es/src/ecom-v1-order-orders.universal.d.ts} +985 -957
- package/build/es/src/ecom-v1-order-orders.universal.js +2242 -0
- package/build/es/src/ecom-v1-order-orders.universal.js.map +1 -0
- package/build/internal/cjs/index.d.ts +1 -0
- package/build/internal/cjs/index.js +18 -0
- package/build/internal/cjs/index.js.map +1 -0
- package/build/internal/cjs/index.typings.d.ts +1 -0
- package/build/internal/cjs/index.typings.js +18 -0
- package/build/internal/cjs/index.typings.js.map +1 -0
- package/build/internal/cjs/meta.d.ts +1 -0
- package/build/internal/cjs/meta.js +18 -0
- package/build/internal/cjs/meta.js.map +1 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.context.d.ts +62 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.context.js +117 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.context.js.map +1 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.http.d.ts +200 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.http.js +1610 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.http.js.map +1 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.meta.d.ts +78 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.meta.js +503 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.meta.js.map +1 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.public.d.ts +340 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.public.js +382 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.public.js.map +1 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.types.d.ts +6096 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.types.js +652 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.types.js.map +1 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.universal.d.ts +7750 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.universal.js +2294 -0
- package/build/internal/cjs/src/ecom-v1-order-orders.universal.js.map +1 -0
- package/build/internal/es/index.d.ts +1 -0
- package/build/internal/es/index.js +2 -0
- package/build/internal/es/index.js.map +1 -0
- package/build/internal/es/index.typings.d.ts +1 -0
- package/build/internal/es/index.typings.js +2 -0
- package/build/internal/es/index.typings.js.map +1 -0
- package/build/internal/es/meta.d.ts +1 -0
- package/build/internal/es/meta.js +2 -0
- package/build/internal/es/meta.js.map +1 -0
- package/build/internal/es/src/ecom-v1-order-orders.context.d.ts +62 -0
- package/build/internal/es/src/ecom-v1-order-orders.context.js +62 -0
- package/build/internal/es/src/ecom-v1-order-orders.context.js.map +1 -0
- package/build/internal/es/src/ecom-v1-order-orders.http.d.ts +200 -0
- package/build/internal/es/src/ecom-v1-order-orders.http.js +1582 -0
- package/build/internal/es/src/ecom-v1-order-orders.http.js.map +1 -0
- package/build/internal/es/src/ecom-v1-order-orders.meta.d.ts +78 -0
- package/build/internal/es/src/ecom-v1-order-orders.meta.js +452 -0
- package/build/internal/es/src/ecom-v1-order-orders.meta.js.map +1 -0
- package/build/internal/es/src/ecom-v1-order-orders.public.d.ts +340 -0
- package/build/internal/es/src/ecom-v1-order-orders.public.js +302 -0
- package/build/internal/es/src/ecom-v1-order-orders.public.js.map +1 -0
- package/build/internal/es/src/ecom-v1-order-orders.types.d.ts +6096 -0
- package/build/internal/es/src/ecom-v1-order-orders.types.js +648 -0
- package/build/internal/es/src/ecom-v1-order-orders.types.js.map +1 -0
- package/build/internal/es/src/ecom-v1-order-orders.universal.d.ts +7750 -0
- package/build/internal/es/src/ecom-v1-order-orders.universal.js +2242 -0
- package/build/internal/es/src/ecom-v1-order-orders.universal.js.map +1 -0
- package/package.json +11 -12
- package/build/index.d.mts +0 -212
- package/build/index.d.ts +0 -212
- package/build/index.js +0 -3504
- package/build/index.js.map +0 -1
- package/build/index.mjs +0 -3401
- package/build/index.mjs.map +0 -1
- package/build/internal/index.d.mts +0 -391
- package/build/internal/index.d.ts +0 -391
- package/build/internal/index.js +0 -3504
- package/build/internal/index.js.map +0 -1
- package/build/internal/index.mjs +0 -3401
- package/build/internal/index.mjs.map +0 -1
- package/build/internal/meta.d.mts +0 -3192
- package/build/internal/meta.d.ts +0 -3192
- package/build/internal/meta.js +0 -1941
- package/build/internal/meta.js.map +0 -1
- package/build/internal/meta.mjs +0 -1890
- package/build/internal/meta.mjs.map +0 -1
- package/build/meta.d.mts +0 -3192
- package/build/meta.d.ts +0 -3192
- package/build/meta.js +0 -1941
- package/build/meta.js.map +0 -1
- package/build/meta.mjs +0 -1890
- package/build/meta.mjs.map +0 -1
package/build/internal/index.js
DELETED
|
@@ -1,3504 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
|
|
20
|
-
// index.ts
|
|
21
|
-
var index_exports = {};
|
|
22
|
-
__export(index_exports, {
|
|
23
|
-
ActionType: () => ActionType,
|
|
24
|
-
ActivityType: () => ActivityType,
|
|
25
|
-
AdjustmentType: () => AdjustmentType,
|
|
26
|
-
AnimationDetection: () => AnimationDetection,
|
|
27
|
-
AttributionSource: () => AttributionSource,
|
|
28
|
-
AuthorizationCaptureStatus: () => AuthorizationCaptureStatus,
|
|
29
|
-
AuthorizationVoidStatus: () => AuthorizationVoidStatus,
|
|
30
|
-
ChannelType: () => ChannelType,
|
|
31
|
-
CustomFieldGroup: () => CustomFieldGroup,
|
|
32
|
-
DeltaPaymentOptionType: () => DeltaPaymentOptionType,
|
|
33
|
-
DepositType: () => DepositType,
|
|
34
|
-
DescriptionLineType: () => DescriptionLineType,
|
|
35
|
-
DiscountReason: () => DiscountReason,
|
|
36
|
-
DiscountType: () => DiscountType,
|
|
37
|
-
DurationUnit: () => DurationUnit,
|
|
38
|
-
FulfillmentStatus: () => FulfillmentStatus,
|
|
39
|
-
InventoryAction: () => InventoryAction,
|
|
40
|
-
InvoiceStatus: () => InvoiceStatus,
|
|
41
|
-
ItemTypeItemType: () => ItemTypeItemType,
|
|
42
|
-
JurisdictionType: () => JurisdictionType,
|
|
43
|
-
LineItemQuantityChangeType: () => LineItemQuantityChangeType,
|
|
44
|
-
ManuallyRefundableReason: () => ManuallyRefundableReason,
|
|
45
|
-
MembershipPaymentStatus: () => MembershipPaymentStatus,
|
|
46
|
-
Namespace: () => Namespace,
|
|
47
|
-
NonRefundableReason: () => NonRefundableReason,
|
|
48
|
-
OrderApprovalStrategy: () => OrderApprovalStrategy,
|
|
49
|
-
OrderStatus: () => OrderStatus,
|
|
50
|
-
PaymentCollectabilityStatus: () => PaymentCollectabilityStatus,
|
|
51
|
-
PaymentOptionType: () => PaymentOptionType,
|
|
52
|
-
PaymentStatus: () => PaymentStatus,
|
|
53
|
-
PickupMethod: () => PickupMethod,
|
|
54
|
-
Placement: () => Placement,
|
|
55
|
-
PreviewEmailType: () => PreviewEmailType,
|
|
56
|
-
Reason: () => Reason,
|
|
57
|
-
RefundStatus: () => RefundStatus,
|
|
58
|
-
RefundableStatus: () => RefundableStatus,
|
|
59
|
-
RestockType: () => RestockType,
|
|
60
|
-
ScheduledAction: () => ScheduledAction,
|
|
61
|
-
SortOrder: () => SortOrder,
|
|
62
|
-
SourceType: () => SourceType,
|
|
63
|
-
State: () => State,
|
|
64
|
-
SubdivisionType: () => SubdivisionType,
|
|
65
|
-
SubscriptionFrequency: () => SubscriptionFrequency,
|
|
66
|
-
TaxableAddressType: () => TaxableAddressType,
|
|
67
|
-
TextDetection: () => TextDetection,
|
|
68
|
-
TransactionStatus: () => TransactionStatus,
|
|
69
|
-
ValueType: () => ValueType,
|
|
70
|
-
VatType: () => VatType,
|
|
71
|
-
VersioningMode: () => VersioningMode,
|
|
72
|
-
WebhookIdentityType: () => WebhookIdentityType,
|
|
73
|
-
WeightUnit: () => WeightUnit,
|
|
74
|
-
addActivity: () => addActivity4,
|
|
75
|
-
aggregateOrders: () => aggregateOrders4,
|
|
76
|
-
bulkUpdateOrderTags: () => bulkUpdateOrderTags4,
|
|
77
|
-
bulkUpdateOrders: () => bulkUpdateOrders4,
|
|
78
|
-
cancelOrder: () => cancelOrder4,
|
|
79
|
-
captureAuthorizedPayments: () => captureAuthorizedPayments4,
|
|
80
|
-
chargeMemberships: () => chargeMemberships4,
|
|
81
|
-
commitDeltas: () => commitDeltas4,
|
|
82
|
-
createOrder: () => createOrder4,
|
|
83
|
-
deleteActivity: () => deleteActivity4,
|
|
84
|
-
getOrder: () => getOrder4,
|
|
85
|
-
getPaymentCollectabilityStatus: () => getPaymentCollectabilityStatus4,
|
|
86
|
-
getRefundabilityStatus: () => getRefundabilityStatus4,
|
|
87
|
-
onOrderApproved: () => onOrderApproved2,
|
|
88
|
-
onOrderCanceled: () => onOrderCanceled2,
|
|
89
|
-
onOrderCreated: () => onOrderCreated2,
|
|
90
|
-
onOrderUpdated: () => onOrderUpdated2,
|
|
91
|
-
paymentCollectionBulkMarkOrdersAsPaid: () => paymentCollectionBulkMarkOrdersAsPaid4,
|
|
92
|
-
paymentCollectionCreatePaymentGatewayOrder: () => paymentCollectionCreatePaymentGatewayOrder4,
|
|
93
|
-
paymentCollectionMarkOrderAsPaid: () => paymentCollectionMarkOrderAsPaid4,
|
|
94
|
-
preparePaymentCollection: () => preparePaymentCollection4,
|
|
95
|
-
recordManuallyCollectedPayment: () => recordManuallyCollectedPayment4,
|
|
96
|
-
searchOrders: () => searchOrders4,
|
|
97
|
-
triggerRefund: () => triggerRefund4,
|
|
98
|
-
updateActivity: () => updateActivity4,
|
|
99
|
-
updateOrder: () => updateOrder4,
|
|
100
|
-
updateOrderLineItem: () => updateOrderLineItem4,
|
|
101
|
-
updateOrderStatus: () => updateOrderStatus4,
|
|
102
|
-
voidAuthorizedPayments: () => voidAuthorizedPayments4
|
|
103
|
-
});
|
|
104
|
-
module.exports = __toCommonJS(index_exports);
|
|
105
|
-
|
|
106
|
-
// src/ecom-v1-order-orders.public.ts
|
|
107
|
-
var import_rename_all_nested_keys2 = require("@wix/sdk-runtime/rename-all-nested-keys");
|
|
108
|
-
var import_address3 = require("@wix/sdk-runtime/transformations/address");
|
|
109
|
-
var import_float3 = require("@wix/sdk-runtime/transformations/float");
|
|
110
|
-
var import_image3 = require("@wix/sdk-runtime/transformations/image");
|
|
111
|
-
var import_timestamp3 = require("@wix/sdk-runtime/transformations/timestamp");
|
|
112
|
-
var import_transform_paths3 = require("@wix/sdk-runtime/transformations/transform-paths");
|
|
113
|
-
var import_sdk_types = require("@wix/sdk-types");
|
|
114
|
-
|
|
115
|
-
// src/ecom-v1-order-orders.universal.ts
|
|
116
|
-
var import_transform_error = require("@wix/sdk-runtime/transform-error");
|
|
117
|
-
var import_rename_all_nested_keys = require("@wix/sdk-runtime/rename-all-nested-keys");
|
|
118
|
-
|
|
119
|
-
// src/ecom-v1-order-orders.http.ts
|
|
120
|
-
var import_rest_modules = require("@wix/sdk-runtime/rest-modules");
|
|
121
|
-
var import_float = require("@wix/sdk-runtime/transformations/float");
|
|
122
|
-
var import_float2 = require("@wix/sdk-runtime/transformations/float");
|
|
123
|
-
var import_timestamp = require("@wix/sdk-runtime/transformations/timestamp");
|
|
124
|
-
var import_timestamp2 = require("@wix/sdk-runtime/transformations/timestamp");
|
|
125
|
-
var import_field_mask = require("@wix/sdk-runtime/transformations/field-mask");
|
|
126
|
-
var import_transform_paths = require("@wix/sdk-runtime/transformations/transform-paths");
|
|
127
|
-
var import_rest_modules2 = require("@wix/sdk-runtime/rest-modules");
|
|
128
|
-
function resolveComWixEcomOrdersV1OrdersUrl(opts) {
|
|
129
|
-
const domainToMappings = {
|
|
130
|
-
_: [
|
|
131
|
-
{
|
|
132
|
-
srcPath: "/_api/ecom-orders",
|
|
133
|
-
destPath: ""
|
|
134
|
-
},
|
|
135
|
-
{
|
|
136
|
-
srcPath: "/_api/orders",
|
|
137
|
-
destPath: ""
|
|
138
|
-
}
|
|
139
|
-
],
|
|
140
|
-
"manage._base_domain_": [
|
|
141
|
-
{
|
|
142
|
-
srcPath: "/_api/ecom-orders",
|
|
143
|
-
destPath: ""
|
|
144
|
-
}
|
|
145
|
-
],
|
|
146
|
-
"www.wixapis.com": [
|
|
147
|
-
{
|
|
148
|
-
srcPath: "/ecom/v1/bulk/orders",
|
|
149
|
-
destPath: "/v1/bulk/orders"
|
|
150
|
-
},
|
|
151
|
-
{
|
|
152
|
-
srcPath: "/ecom/v1/orders",
|
|
153
|
-
destPath: "/v1/orders"
|
|
154
|
-
}
|
|
155
|
-
]
|
|
156
|
-
};
|
|
157
|
-
return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
|
|
158
|
-
}
|
|
159
|
-
function resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl(opts) {
|
|
160
|
-
const domainToMappings = {
|
|
161
|
-
"api._api_base_domain_": [
|
|
162
|
-
{
|
|
163
|
-
srcPath: "/payments-collector",
|
|
164
|
-
destPath: ""
|
|
165
|
-
}
|
|
166
|
-
],
|
|
167
|
-
"www.wixapis.com": [
|
|
168
|
-
{
|
|
169
|
-
srcPath: "/ecom/v1/payments-collector",
|
|
170
|
-
destPath: "/v1/payments-collector"
|
|
171
|
-
}
|
|
172
|
-
],
|
|
173
|
-
"manage._base_domain_": [
|
|
174
|
-
{
|
|
175
|
-
srcPath: "/ecom/v1/payments-collector",
|
|
176
|
-
destPath: "/v1/payments-collector"
|
|
177
|
-
},
|
|
178
|
-
{
|
|
179
|
-
srcPath: "/_api/v1/payments-collector",
|
|
180
|
-
destPath: "/v1/payments-collector"
|
|
181
|
-
},
|
|
182
|
-
{
|
|
183
|
-
srcPath: "/v1/payments-collector",
|
|
184
|
-
destPath: "/v1/payments-collector"
|
|
185
|
-
},
|
|
186
|
-
{
|
|
187
|
-
srcPath: "/_api/payments-collector",
|
|
188
|
-
destPath: "/v1/payments-collector"
|
|
189
|
-
}
|
|
190
|
-
]
|
|
191
|
-
};
|
|
192
|
-
return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
|
|
193
|
-
}
|
|
194
|
-
var PACKAGE_NAME = "@wix/auto_sdk_ecom_orders";
|
|
195
|
-
function preparePaymentCollection(payload) {
|
|
196
|
-
function __preparePaymentCollection({ host }) {
|
|
197
|
-
const metadata = {
|
|
198
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
199
|
-
method: "POST",
|
|
200
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.PreparePaymentCollection",
|
|
201
|
-
packageName: PACKAGE_NAME,
|
|
202
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
203
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/prepare-payment-collection",
|
|
204
|
-
data: payload,
|
|
205
|
-
host
|
|
206
|
-
}),
|
|
207
|
-
data: payload
|
|
208
|
-
};
|
|
209
|
-
return metadata;
|
|
210
|
-
}
|
|
211
|
-
return __preparePaymentCollection;
|
|
212
|
-
}
|
|
213
|
-
function getPaymentCollectabilityStatus(payload) {
|
|
214
|
-
function __getPaymentCollectabilityStatus({ host }) {
|
|
215
|
-
const metadata = {
|
|
216
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
217
|
-
method: "GET",
|
|
218
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.GetPaymentCollectabilityStatus",
|
|
219
|
-
packageName: PACKAGE_NAME,
|
|
220
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
221
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/payment-collectability-status",
|
|
222
|
-
data: payload,
|
|
223
|
-
host
|
|
224
|
-
}),
|
|
225
|
-
params: (0, import_rest_modules.toURLSearchParams)(payload)
|
|
226
|
-
};
|
|
227
|
-
return metadata;
|
|
228
|
-
}
|
|
229
|
-
return __getPaymentCollectabilityStatus;
|
|
230
|
-
}
|
|
231
|
-
function recordManuallyCollectedPayment(payload) {
|
|
232
|
-
function __recordManuallyCollectedPayment({ host }) {
|
|
233
|
-
const metadata = {
|
|
234
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
235
|
-
method: "POST",
|
|
236
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.RecordManuallyCollectedPayment",
|
|
237
|
-
packageName: PACKAGE_NAME,
|
|
238
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
239
|
-
protoPath: "/v1/payments-collector/orders/{orderId}/manual-payment",
|
|
240
|
-
data: payload,
|
|
241
|
-
host
|
|
242
|
-
}),
|
|
243
|
-
data: payload
|
|
244
|
-
};
|
|
245
|
-
return metadata;
|
|
246
|
-
}
|
|
247
|
-
return __recordManuallyCollectedPayment;
|
|
248
|
-
}
|
|
249
|
-
function paymentCollectionMarkOrderAsPaid(payload) {
|
|
250
|
-
function __paymentCollectionMarkOrderAsPaid({ host }) {
|
|
251
|
-
const metadata = {
|
|
252
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
253
|
-
method: "POST",
|
|
254
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.MarkOrderAsPaid",
|
|
255
|
-
packageName: PACKAGE_NAME,
|
|
256
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
257
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/mark-as-paid",
|
|
258
|
-
data: payload,
|
|
259
|
-
host
|
|
260
|
-
}),
|
|
261
|
-
data: payload,
|
|
262
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
263
|
-
{
|
|
264
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
265
|
-
paths: [
|
|
266
|
-
{ path: "order.createdDate" },
|
|
267
|
-
{ path: "order.updatedDate" },
|
|
268
|
-
{ path: "order.purchasedDate" },
|
|
269
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
270
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
271
|
-
{
|
|
272
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
273
|
-
},
|
|
274
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
275
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
276
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
277
|
-
{ path: "order.activities.createdDate" }
|
|
278
|
-
]
|
|
279
|
-
},
|
|
280
|
-
{
|
|
281
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
282
|
-
paths: [
|
|
283
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
284
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
285
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
286
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
287
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
288
|
-
{
|
|
289
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
290
|
-
},
|
|
291
|
-
{
|
|
292
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
293
|
-
},
|
|
294
|
-
{
|
|
295
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
296
|
-
},
|
|
297
|
-
{
|
|
298
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
299
|
-
},
|
|
300
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
301
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
302
|
-
]
|
|
303
|
-
}
|
|
304
|
-
])
|
|
305
|
-
};
|
|
306
|
-
return metadata;
|
|
307
|
-
}
|
|
308
|
-
return __paymentCollectionMarkOrderAsPaid;
|
|
309
|
-
}
|
|
310
|
-
function paymentCollectionBulkMarkOrdersAsPaid(payload) {
|
|
311
|
-
function __paymentCollectionBulkMarkOrdersAsPaid({ host }) {
|
|
312
|
-
const metadata = {
|
|
313
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
314
|
-
method: "POST",
|
|
315
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.BulkMarkOrdersAsPaid",
|
|
316
|
-
packageName: PACKAGE_NAME,
|
|
317
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
318
|
-
protoPath: "/v1/bulk/payments-collector/mark-as-paid",
|
|
319
|
-
data: payload,
|
|
320
|
-
host
|
|
321
|
-
}),
|
|
322
|
-
data: payload,
|
|
323
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
324
|
-
{
|
|
325
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
326
|
-
paths: [
|
|
327
|
-
{ path: "results.item.createdDate" },
|
|
328
|
-
{ path: "results.item.updatedDate" },
|
|
329
|
-
{ path: "results.item.purchasedDate" },
|
|
330
|
-
{ path: "results.item.lineItems.image.urlExpirationDate" },
|
|
331
|
-
{ path: "results.item.lineItems.digitalFile.expirationDate" },
|
|
332
|
-
{
|
|
333
|
-
path: "results.item.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
334
|
-
},
|
|
335
|
-
{ path: "results.item.shippingInfo.logistics.deliverByDate" },
|
|
336
|
-
{
|
|
337
|
-
path: "results.item.shippingInfo.logistics.deliveryTimeSlot.from"
|
|
338
|
-
},
|
|
339
|
-
{
|
|
340
|
-
path: "results.item.shippingInfo.logistics.deliveryTimeSlot.to"
|
|
341
|
-
},
|
|
342
|
-
{ path: "results.item.activities.createdDate" }
|
|
343
|
-
]
|
|
344
|
-
},
|
|
345
|
-
{
|
|
346
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
347
|
-
paths: [
|
|
348
|
-
{ path: "results.item.lineItems.image.focalPoint.x" },
|
|
349
|
-
{ path: "results.item.lineItems.image.focalPoint.y" },
|
|
350
|
-
{ path: "results.item.lineItems.physicalProperties.weight" },
|
|
351
|
-
{ path: "results.item.billingInfo.address.geocode.latitude" },
|
|
352
|
-
{ path: "results.item.billingInfo.address.geocode.longitude" },
|
|
353
|
-
{
|
|
354
|
-
path: "results.item.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
355
|
-
},
|
|
356
|
-
{
|
|
357
|
-
path: "results.item.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
358
|
-
},
|
|
359
|
-
{
|
|
360
|
-
path: "results.item.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
361
|
-
},
|
|
362
|
-
{
|
|
363
|
-
path: "results.item.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
364
|
-
},
|
|
365
|
-
{ path: "results.item.recipientInfo.address.geocode.latitude" },
|
|
366
|
-
{ path: "results.item.recipientInfo.address.geocode.longitude" }
|
|
367
|
-
]
|
|
368
|
-
}
|
|
369
|
-
])
|
|
370
|
-
};
|
|
371
|
-
return metadata;
|
|
372
|
-
}
|
|
373
|
-
return __paymentCollectionBulkMarkOrdersAsPaid;
|
|
374
|
-
}
|
|
375
|
-
function getRefundabilityStatus(payload) {
|
|
376
|
-
function __getRefundabilityStatus({ host }) {
|
|
377
|
-
const metadata = {
|
|
378
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
379
|
-
method: "GET",
|
|
380
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.GetRefundabilityStatus",
|
|
381
|
-
packageName: PACKAGE_NAME,
|
|
382
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
383
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/refundability",
|
|
384
|
-
data: payload,
|
|
385
|
-
host
|
|
386
|
-
}),
|
|
387
|
-
params: (0, import_rest_modules.toURLSearchParams)(payload)
|
|
388
|
-
};
|
|
389
|
-
return metadata;
|
|
390
|
-
}
|
|
391
|
-
return __getRefundabilityStatus;
|
|
392
|
-
}
|
|
393
|
-
function paymentCollectionCreatePaymentGatewayOrder(payload) {
|
|
394
|
-
function __paymentCollectionCreatePaymentGatewayOrder({ host }) {
|
|
395
|
-
const metadata = {
|
|
396
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
397
|
-
method: "POST",
|
|
398
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.CreatePaymentGatewayOrder",
|
|
399
|
-
packageName: PACKAGE_NAME,
|
|
400
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
401
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/create-payment-gateway-order",
|
|
402
|
-
data: payload,
|
|
403
|
-
host
|
|
404
|
-
}),
|
|
405
|
-
data: payload
|
|
406
|
-
};
|
|
407
|
-
return metadata;
|
|
408
|
-
}
|
|
409
|
-
return __paymentCollectionCreatePaymentGatewayOrder;
|
|
410
|
-
}
|
|
411
|
-
function chargeMemberships(payload) {
|
|
412
|
-
function __chargeMemberships({ host }) {
|
|
413
|
-
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
414
|
-
{
|
|
415
|
-
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
|
416
|
-
paths: [{ path: "membershipCharges.serviceProperties.scheduledDate" }]
|
|
417
|
-
}
|
|
418
|
-
]);
|
|
419
|
-
const metadata = {
|
|
420
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
421
|
-
method: "POST",
|
|
422
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.ChargeMemberships",
|
|
423
|
-
packageName: PACKAGE_NAME,
|
|
424
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
425
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/charge-membership",
|
|
426
|
-
data: serializedData,
|
|
427
|
-
host
|
|
428
|
-
}),
|
|
429
|
-
data: serializedData
|
|
430
|
-
};
|
|
431
|
-
return metadata;
|
|
432
|
-
}
|
|
433
|
-
return __chargeMemberships;
|
|
434
|
-
}
|
|
435
|
-
function triggerRefund(payload) {
|
|
436
|
-
function __triggerRefund({ host }) {
|
|
437
|
-
const metadata = {
|
|
438
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
439
|
-
method: "POST",
|
|
440
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.TriggerRefund",
|
|
441
|
-
packageName: PACKAGE_NAME,
|
|
442
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
443
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/trigger-refund",
|
|
444
|
-
data: payload,
|
|
445
|
-
host
|
|
446
|
-
}),
|
|
447
|
-
data: payload,
|
|
448
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
449
|
-
{
|
|
450
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
451
|
-
paths: [
|
|
452
|
-
{ path: "orderTransactions.payments.createdDate" },
|
|
453
|
-
{ path: "orderTransactions.payments.updatedDate" },
|
|
454
|
-
{
|
|
455
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.authorizedDate"
|
|
456
|
-
},
|
|
457
|
-
{
|
|
458
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.captures.createdDate"
|
|
459
|
-
},
|
|
460
|
-
{
|
|
461
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.void.voidedDate"
|
|
462
|
-
},
|
|
463
|
-
{
|
|
464
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.scheduledAction.executionDate"
|
|
465
|
-
},
|
|
466
|
-
{ path: "orderTransactions.refunds.createdDate" }
|
|
467
|
-
]
|
|
468
|
-
}
|
|
469
|
-
])
|
|
470
|
-
};
|
|
471
|
-
return metadata;
|
|
472
|
-
}
|
|
473
|
-
return __triggerRefund;
|
|
474
|
-
}
|
|
475
|
-
function voidAuthorizedPayments(payload) {
|
|
476
|
-
function __voidAuthorizedPayments({ host }) {
|
|
477
|
-
const metadata = {
|
|
478
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
479
|
-
method: "POST",
|
|
480
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.VoidAuthorizedPayments",
|
|
481
|
-
packageName: PACKAGE_NAME,
|
|
482
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
483
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/void-authorized-payments",
|
|
484
|
-
data: payload,
|
|
485
|
-
host
|
|
486
|
-
}),
|
|
487
|
-
data: payload,
|
|
488
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
489
|
-
{
|
|
490
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
491
|
-
paths: [
|
|
492
|
-
{ path: "orderTransactions.payments.createdDate" },
|
|
493
|
-
{ path: "orderTransactions.payments.updatedDate" },
|
|
494
|
-
{
|
|
495
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.authorizedDate"
|
|
496
|
-
},
|
|
497
|
-
{
|
|
498
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.captures.createdDate"
|
|
499
|
-
},
|
|
500
|
-
{
|
|
501
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.void.voidedDate"
|
|
502
|
-
},
|
|
503
|
-
{
|
|
504
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.scheduledAction.executionDate"
|
|
505
|
-
},
|
|
506
|
-
{ path: "orderTransactions.refunds.createdDate" }
|
|
507
|
-
]
|
|
508
|
-
}
|
|
509
|
-
])
|
|
510
|
-
};
|
|
511
|
-
return metadata;
|
|
512
|
-
}
|
|
513
|
-
return __voidAuthorizedPayments;
|
|
514
|
-
}
|
|
515
|
-
function captureAuthorizedPayments(payload) {
|
|
516
|
-
function __captureAuthorizedPayments({ host }) {
|
|
517
|
-
const metadata = {
|
|
518
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
519
|
-
method: "POST",
|
|
520
|
-
methodFqn: "com.wix.ecom.orders.payments_collector.v1.PaymentsCollector.CaptureAuthorizedPayments",
|
|
521
|
-
packageName: PACKAGE_NAME,
|
|
522
|
-
url: resolveComWixEcomOrdersPaymentsCollectorV1PaymentsCollectorUrl({
|
|
523
|
-
protoPath: "/v1/payments-collector/orders/{ecomOrderId}/capture-authorized-payments",
|
|
524
|
-
data: payload,
|
|
525
|
-
host
|
|
526
|
-
}),
|
|
527
|
-
data: payload,
|
|
528
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
529
|
-
{
|
|
530
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
531
|
-
paths: [
|
|
532
|
-
{ path: "orderTransactions.payments.createdDate" },
|
|
533
|
-
{ path: "orderTransactions.payments.updatedDate" },
|
|
534
|
-
{
|
|
535
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.authorizedDate"
|
|
536
|
-
},
|
|
537
|
-
{
|
|
538
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.captures.createdDate"
|
|
539
|
-
},
|
|
540
|
-
{
|
|
541
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.void.voidedDate"
|
|
542
|
-
},
|
|
543
|
-
{
|
|
544
|
-
path: "orderTransactions.payments.regularPaymentDetails.authorizationDetails.scheduledAction.executionDate"
|
|
545
|
-
},
|
|
546
|
-
{ path: "orderTransactions.refunds.createdDate" }
|
|
547
|
-
]
|
|
548
|
-
}
|
|
549
|
-
])
|
|
550
|
-
};
|
|
551
|
-
return metadata;
|
|
552
|
-
}
|
|
553
|
-
return __captureAuthorizedPayments;
|
|
554
|
-
}
|
|
555
|
-
function getOrder(payload) {
|
|
556
|
-
function __getOrder({ host }) {
|
|
557
|
-
const metadata = {
|
|
558
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
559
|
-
method: "GET",
|
|
560
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.GetOrder",
|
|
561
|
-
packageName: PACKAGE_NAME,
|
|
562
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
563
|
-
protoPath: "/v1/orders/{id}",
|
|
564
|
-
data: payload,
|
|
565
|
-
host
|
|
566
|
-
}),
|
|
567
|
-
params: (0, import_rest_modules.toURLSearchParams)(payload),
|
|
568
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
569
|
-
{
|
|
570
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
571
|
-
paths: [
|
|
572
|
-
{ path: "order.createdDate" },
|
|
573
|
-
{ path: "order.updatedDate" },
|
|
574
|
-
{ path: "order.purchasedDate" },
|
|
575
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
576
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
577
|
-
{
|
|
578
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
579
|
-
},
|
|
580
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
581
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
582
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
583
|
-
{ path: "order.activities.createdDate" }
|
|
584
|
-
]
|
|
585
|
-
},
|
|
586
|
-
{
|
|
587
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
588
|
-
paths: [
|
|
589
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
590
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
591
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
592
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
593
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
594
|
-
{
|
|
595
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
596
|
-
},
|
|
597
|
-
{
|
|
598
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
599
|
-
},
|
|
600
|
-
{
|
|
601
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
602
|
-
},
|
|
603
|
-
{
|
|
604
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
605
|
-
},
|
|
606
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
607
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
608
|
-
]
|
|
609
|
-
}
|
|
610
|
-
])
|
|
611
|
-
};
|
|
612
|
-
return metadata;
|
|
613
|
-
}
|
|
614
|
-
return __getOrder;
|
|
615
|
-
}
|
|
616
|
-
function searchOrders(payload) {
|
|
617
|
-
function __searchOrders({ host }) {
|
|
618
|
-
const metadata = {
|
|
619
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
620
|
-
method: "POST",
|
|
621
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.SearchOrders",
|
|
622
|
-
packageName: PACKAGE_NAME,
|
|
623
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
624
|
-
protoPath: "/v1/orders/search",
|
|
625
|
-
data: payload,
|
|
626
|
-
host
|
|
627
|
-
}),
|
|
628
|
-
data: payload,
|
|
629
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
630
|
-
{
|
|
631
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
632
|
-
paths: [
|
|
633
|
-
{ path: "orders.createdDate" },
|
|
634
|
-
{ path: "orders.updatedDate" },
|
|
635
|
-
{ path: "orders.purchasedDate" },
|
|
636
|
-
{ path: "orders.lineItems.image.urlExpirationDate" },
|
|
637
|
-
{ path: "orders.lineItems.digitalFile.expirationDate" },
|
|
638
|
-
{
|
|
639
|
-
path: "orders.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
640
|
-
},
|
|
641
|
-
{ path: "orders.shippingInfo.logistics.deliverByDate" },
|
|
642
|
-
{ path: "orders.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
643
|
-
{ path: "orders.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
644
|
-
{ path: "orders.activities.createdDate" }
|
|
645
|
-
]
|
|
646
|
-
},
|
|
647
|
-
{
|
|
648
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
649
|
-
paths: [
|
|
650
|
-
{ path: "orders.lineItems.image.focalPoint.x" },
|
|
651
|
-
{ path: "orders.lineItems.image.focalPoint.y" },
|
|
652
|
-
{ path: "orders.lineItems.physicalProperties.weight" },
|
|
653
|
-
{ path: "orders.billingInfo.address.geocode.latitude" },
|
|
654
|
-
{ path: "orders.billingInfo.address.geocode.longitude" },
|
|
655
|
-
{
|
|
656
|
-
path: "orders.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
657
|
-
},
|
|
658
|
-
{
|
|
659
|
-
path: "orders.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
660
|
-
},
|
|
661
|
-
{
|
|
662
|
-
path: "orders.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
663
|
-
},
|
|
664
|
-
{
|
|
665
|
-
path: "orders.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
666
|
-
},
|
|
667
|
-
{ path: "orders.recipientInfo.address.geocode.latitude" },
|
|
668
|
-
{ path: "orders.recipientInfo.address.geocode.longitude" }
|
|
669
|
-
]
|
|
670
|
-
}
|
|
671
|
-
])
|
|
672
|
-
};
|
|
673
|
-
return metadata;
|
|
674
|
-
}
|
|
675
|
-
return __searchOrders;
|
|
676
|
-
}
|
|
677
|
-
function createOrder(payload) {
|
|
678
|
-
function __createOrder({ host }) {
|
|
679
|
-
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
680
|
-
{
|
|
681
|
-
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
|
682
|
-
paths: [
|
|
683
|
-
{ path: "order.createdDate" },
|
|
684
|
-
{ path: "order.updatedDate" },
|
|
685
|
-
{ path: "order.purchasedDate" },
|
|
686
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
687
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
688
|
-
{
|
|
689
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
690
|
-
},
|
|
691
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
692
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
693
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
694
|
-
{ path: "order.activities.createdDate" }
|
|
695
|
-
]
|
|
696
|
-
},
|
|
697
|
-
{
|
|
698
|
-
transformFn: import_float.transformSDKFloatToRESTFloat,
|
|
699
|
-
paths: [
|
|
700
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
701
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
702
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
703
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
704
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
705
|
-
{
|
|
706
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
707
|
-
},
|
|
708
|
-
{
|
|
709
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
710
|
-
},
|
|
711
|
-
{
|
|
712
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
713
|
-
},
|
|
714
|
-
{
|
|
715
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
716
|
-
},
|
|
717
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
718
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
719
|
-
]
|
|
720
|
-
}
|
|
721
|
-
]);
|
|
722
|
-
const metadata = {
|
|
723
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
724
|
-
method: "POST",
|
|
725
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.CreateOrder",
|
|
726
|
-
packageName: PACKAGE_NAME,
|
|
727
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
728
|
-
protoPath: "/v1/orders",
|
|
729
|
-
data: serializedData,
|
|
730
|
-
host
|
|
731
|
-
}),
|
|
732
|
-
data: serializedData,
|
|
733
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
734
|
-
{
|
|
735
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
736
|
-
paths: [
|
|
737
|
-
{ path: "order.createdDate" },
|
|
738
|
-
{ path: "order.updatedDate" },
|
|
739
|
-
{ path: "order.purchasedDate" },
|
|
740
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
741
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
742
|
-
{
|
|
743
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
744
|
-
},
|
|
745
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
746
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
747
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
748
|
-
{ path: "order.activities.createdDate" }
|
|
749
|
-
]
|
|
750
|
-
},
|
|
751
|
-
{
|
|
752
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
753
|
-
paths: [
|
|
754
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
755
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
756
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
757
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
758
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
759
|
-
{
|
|
760
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
761
|
-
},
|
|
762
|
-
{
|
|
763
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
764
|
-
},
|
|
765
|
-
{
|
|
766
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
767
|
-
},
|
|
768
|
-
{
|
|
769
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
770
|
-
},
|
|
771
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
772
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
773
|
-
]
|
|
774
|
-
}
|
|
775
|
-
])
|
|
776
|
-
};
|
|
777
|
-
return metadata;
|
|
778
|
-
}
|
|
779
|
-
return __createOrder;
|
|
780
|
-
}
|
|
781
|
-
function updateOrder(payload) {
|
|
782
|
-
function __updateOrder({ host }) {
|
|
783
|
-
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
784
|
-
{
|
|
785
|
-
transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
|
|
786
|
-
paths: [{ path: "fieldMask" }]
|
|
787
|
-
},
|
|
788
|
-
{
|
|
789
|
-
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
|
790
|
-
paths: [
|
|
791
|
-
{ path: "order.createdDate" },
|
|
792
|
-
{ path: "order.updatedDate" },
|
|
793
|
-
{ path: "order.purchasedDate" },
|
|
794
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
795
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
796
|
-
{
|
|
797
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
798
|
-
},
|
|
799
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
800
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
801
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
802
|
-
{ path: "order.activities.createdDate" }
|
|
803
|
-
]
|
|
804
|
-
},
|
|
805
|
-
{
|
|
806
|
-
transformFn: import_float.transformSDKFloatToRESTFloat,
|
|
807
|
-
paths: [
|
|
808
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
809
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
810
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
811
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
812
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
813
|
-
{
|
|
814
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
815
|
-
},
|
|
816
|
-
{
|
|
817
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
818
|
-
},
|
|
819
|
-
{
|
|
820
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
821
|
-
},
|
|
822
|
-
{
|
|
823
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
824
|
-
},
|
|
825
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
826
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
827
|
-
]
|
|
828
|
-
}
|
|
829
|
-
]);
|
|
830
|
-
const metadata = {
|
|
831
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
832
|
-
method: "PATCH",
|
|
833
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.UpdateOrder",
|
|
834
|
-
packageName: PACKAGE_NAME,
|
|
835
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
836
|
-
protoPath: "/v1/orders/{order.id}",
|
|
837
|
-
data: serializedData,
|
|
838
|
-
host
|
|
839
|
-
}),
|
|
840
|
-
data: serializedData,
|
|
841
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
842
|
-
{
|
|
843
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
844
|
-
paths: [
|
|
845
|
-
{ path: "order.createdDate" },
|
|
846
|
-
{ path: "order.updatedDate" },
|
|
847
|
-
{ path: "order.purchasedDate" },
|
|
848
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
849
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
850
|
-
{
|
|
851
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
852
|
-
},
|
|
853
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
854
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
855
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
856
|
-
{ path: "order.activities.createdDate" }
|
|
857
|
-
]
|
|
858
|
-
},
|
|
859
|
-
{
|
|
860
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
861
|
-
paths: [
|
|
862
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
863
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
864
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
865
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
866
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
867
|
-
{
|
|
868
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
869
|
-
},
|
|
870
|
-
{
|
|
871
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
872
|
-
},
|
|
873
|
-
{
|
|
874
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
875
|
-
},
|
|
876
|
-
{
|
|
877
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
878
|
-
},
|
|
879
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
880
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
881
|
-
]
|
|
882
|
-
}
|
|
883
|
-
])
|
|
884
|
-
};
|
|
885
|
-
return metadata;
|
|
886
|
-
}
|
|
887
|
-
return __updateOrder;
|
|
888
|
-
}
|
|
889
|
-
function bulkUpdateOrders(payload) {
|
|
890
|
-
function __bulkUpdateOrders({ host }) {
|
|
891
|
-
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
892
|
-
{
|
|
893
|
-
transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
|
|
894
|
-
paths: [{ path: "orders.fieldMask" }]
|
|
895
|
-
},
|
|
896
|
-
{
|
|
897
|
-
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
|
898
|
-
paths: [
|
|
899
|
-
{ path: "orders.order.createdDate" },
|
|
900
|
-
{ path: "orders.order.updatedDate" },
|
|
901
|
-
{ path: "orders.order.purchasedDate" },
|
|
902
|
-
{ path: "orders.order.lineItems.image.urlExpirationDate" },
|
|
903
|
-
{ path: "orders.order.lineItems.digitalFile.expirationDate" },
|
|
904
|
-
{
|
|
905
|
-
path: "orders.order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
906
|
-
},
|
|
907
|
-
{ path: "orders.order.shippingInfo.logistics.deliverByDate" },
|
|
908
|
-
{ path: "orders.order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
909
|
-
{ path: "orders.order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
910
|
-
{ path: "orders.order.activities.createdDate" }
|
|
911
|
-
]
|
|
912
|
-
},
|
|
913
|
-
{
|
|
914
|
-
transformFn: import_float.transformSDKFloatToRESTFloat,
|
|
915
|
-
paths: [
|
|
916
|
-
{ path: "orders.order.lineItems.image.focalPoint.x" },
|
|
917
|
-
{ path: "orders.order.lineItems.image.focalPoint.y" },
|
|
918
|
-
{ path: "orders.order.lineItems.physicalProperties.weight" },
|
|
919
|
-
{ path: "orders.order.billingInfo.address.geocode.latitude" },
|
|
920
|
-
{ path: "orders.order.billingInfo.address.geocode.longitude" },
|
|
921
|
-
{
|
|
922
|
-
path: "orders.order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
923
|
-
},
|
|
924
|
-
{
|
|
925
|
-
path: "orders.order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
926
|
-
},
|
|
927
|
-
{
|
|
928
|
-
path: "orders.order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
929
|
-
},
|
|
930
|
-
{
|
|
931
|
-
path: "orders.order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
932
|
-
},
|
|
933
|
-
{ path: "orders.order.recipientInfo.address.geocode.latitude" },
|
|
934
|
-
{ path: "orders.order.recipientInfo.address.geocode.longitude" }
|
|
935
|
-
]
|
|
936
|
-
}
|
|
937
|
-
]);
|
|
938
|
-
const metadata = {
|
|
939
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
940
|
-
method: "POST",
|
|
941
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.BulkUpdateOrders",
|
|
942
|
-
packageName: PACKAGE_NAME,
|
|
943
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
944
|
-
protoPath: "/v1/bulk/orders/update",
|
|
945
|
-
data: serializedData,
|
|
946
|
-
host
|
|
947
|
-
}),
|
|
948
|
-
data: serializedData,
|
|
949
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
950
|
-
{
|
|
951
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
952
|
-
paths: [
|
|
953
|
-
{ path: "results.item.createdDate" },
|
|
954
|
-
{ path: "results.item.updatedDate" },
|
|
955
|
-
{ path: "results.item.purchasedDate" },
|
|
956
|
-
{ path: "results.item.lineItems.image.urlExpirationDate" },
|
|
957
|
-
{ path: "results.item.lineItems.digitalFile.expirationDate" },
|
|
958
|
-
{
|
|
959
|
-
path: "results.item.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
960
|
-
},
|
|
961
|
-
{ path: "results.item.shippingInfo.logistics.deliverByDate" },
|
|
962
|
-
{
|
|
963
|
-
path: "results.item.shippingInfo.logistics.deliveryTimeSlot.from"
|
|
964
|
-
},
|
|
965
|
-
{
|
|
966
|
-
path: "results.item.shippingInfo.logistics.deliveryTimeSlot.to"
|
|
967
|
-
},
|
|
968
|
-
{ path: "results.item.activities.createdDate" }
|
|
969
|
-
]
|
|
970
|
-
},
|
|
971
|
-
{
|
|
972
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
973
|
-
paths: [
|
|
974
|
-
{ path: "results.item.lineItems.image.focalPoint.x" },
|
|
975
|
-
{ path: "results.item.lineItems.image.focalPoint.y" },
|
|
976
|
-
{ path: "results.item.lineItems.physicalProperties.weight" },
|
|
977
|
-
{ path: "results.item.billingInfo.address.geocode.latitude" },
|
|
978
|
-
{ path: "results.item.billingInfo.address.geocode.longitude" },
|
|
979
|
-
{
|
|
980
|
-
path: "results.item.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
981
|
-
},
|
|
982
|
-
{
|
|
983
|
-
path: "results.item.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
984
|
-
},
|
|
985
|
-
{
|
|
986
|
-
path: "results.item.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
987
|
-
},
|
|
988
|
-
{
|
|
989
|
-
path: "results.item.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
990
|
-
},
|
|
991
|
-
{ path: "results.item.recipientInfo.address.geocode.latitude" },
|
|
992
|
-
{ path: "results.item.recipientInfo.address.geocode.longitude" }
|
|
993
|
-
]
|
|
994
|
-
}
|
|
995
|
-
])
|
|
996
|
-
};
|
|
997
|
-
return metadata;
|
|
998
|
-
}
|
|
999
|
-
return __bulkUpdateOrders;
|
|
1000
|
-
}
|
|
1001
|
-
function commitDeltas(payload) {
|
|
1002
|
-
function __commitDeltas({ host }) {
|
|
1003
|
-
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
1004
|
-
{
|
|
1005
|
-
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
|
1006
|
-
paths: [
|
|
1007
|
-
{ path: "changes.changedShippingInfo.logistics.deliverByDate" },
|
|
1008
|
-
{
|
|
1009
|
-
path: "changes.changedShippingInfo.logistics.deliveryTimeSlot.from"
|
|
1010
|
-
},
|
|
1011
|
-
{ path: "changes.changedShippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1012
|
-
{ path: "changes.lineItems.lineItem.image.urlExpirationDate" },
|
|
1013
|
-
{ path: "changes.lineItems.lineItem.digitalFile.expirationDate" },
|
|
1014
|
-
{
|
|
1015
|
-
path: "changes.lineItems.lineItem.subscriptionInfo.subscriptionSettings.startDate"
|
|
1016
|
-
}
|
|
1017
|
-
]
|
|
1018
|
-
},
|
|
1019
|
-
{
|
|
1020
|
-
transformFn: import_float.transformSDKFloatToRESTFloat,
|
|
1021
|
-
paths: [
|
|
1022
|
-
{
|
|
1023
|
-
path: "changes.changedShippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1024
|
-
},
|
|
1025
|
-
{
|
|
1026
|
-
path: "changes.changedShippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1027
|
-
},
|
|
1028
|
-
{
|
|
1029
|
-
path: "changes.changedShippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1030
|
-
},
|
|
1031
|
-
{
|
|
1032
|
-
path: "changes.changedShippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1033
|
-
},
|
|
1034
|
-
{ path: "changes.changedBillingInfo.address.geocode.latitude" },
|
|
1035
|
-
{ path: "changes.changedBillingInfo.address.geocode.longitude" },
|
|
1036
|
-
{ path: "changes.changedRecipientInfo.address.geocode.latitude" },
|
|
1037
|
-
{ path: "changes.changedRecipientInfo.address.geocode.longitude" },
|
|
1038
|
-
{ path: "changes.lineItems.lineItem.physicalProperties.weight" },
|
|
1039
|
-
{ path: "changes.lineItems.lineItem.image.focalPoint.x" },
|
|
1040
|
-
{ path: "changes.lineItems.lineItem.image.focalPoint.y" }
|
|
1041
|
-
]
|
|
1042
|
-
}
|
|
1043
|
-
]);
|
|
1044
|
-
const metadata = {
|
|
1045
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1046
|
-
method: "POST",
|
|
1047
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.CommitDeltas",
|
|
1048
|
-
packageName: PACKAGE_NAME,
|
|
1049
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1050
|
-
protoPath: "/v1/orders/{id}/commit-deltas",
|
|
1051
|
-
data: serializedData,
|
|
1052
|
-
host
|
|
1053
|
-
}),
|
|
1054
|
-
data: serializedData,
|
|
1055
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
1056
|
-
{
|
|
1057
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
1058
|
-
paths: [
|
|
1059
|
-
{ path: "order.createdDate" },
|
|
1060
|
-
{ path: "order.updatedDate" },
|
|
1061
|
-
{ path: "order.purchasedDate" },
|
|
1062
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
1063
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
1064
|
-
{
|
|
1065
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
1066
|
-
},
|
|
1067
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
1068
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
1069
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1070
|
-
{ path: "order.activities.createdDate" }
|
|
1071
|
-
]
|
|
1072
|
-
},
|
|
1073
|
-
{
|
|
1074
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
1075
|
-
paths: [
|
|
1076
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
1077
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
1078
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
1079
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
1080
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
1081
|
-
{
|
|
1082
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1083
|
-
},
|
|
1084
|
-
{
|
|
1085
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1086
|
-
},
|
|
1087
|
-
{
|
|
1088
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1089
|
-
},
|
|
1090
|
-
{
|
|
1091
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1092
|
-
},
|
|
1093
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
1094
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
1095
|
-
]
|
|
1096
|
-
}
|
|
1097
|
-
])
|
|
1098
|
-
};
|
|
1099
|
-
return metadata;
|
|
1100
|
-
}
|
|
1101
|
-
return __commitDeltas;
|
|
1102
|
-
}
|
|
1103
|
-
function updateOrderLineItem(payload) {
|
|
1104
|
-
function __updateOrderLineItem({ host }) {
|
|
1105
|
-
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
1106
|
-
{
|
|
1107
|
-
transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
|
|
1108
|
-
paths: [{ path: "fieldMask" }]
|
|
1109
|
-
},
|
|
1110
|
-
{
|
|
1111
|
-
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
|
1112
|
-
paths: [
|
|
1113
|
-
{ path: "lineItem.image.urlExpirationDate" },
|
|
1114
|
-
{ path: "lineItem.digitalFile.expirationDate" },
|
|
1115
|
-
{ path: "lineItem.subscriptionInfo.subscriptionSettings.startDate" }
|
|
1116
|
-
]
|
|
1117
|
-
},
|
|
1118
|
-
{
|
|
1119
|
-
transformFn: import_float.transformSDKFloatToRESTFloat,
|
|
1120
|
-
paths: [
|
|
1121
|
-
{ path: "lineItem.image.focalPoint.x" },
|
|
1122
|
-
{ path: "lineItem.image.focalPoint.y" },
|
|
1123
|
-
{ path: "lineItem.physicalProperties.weight" }
|
|
1124
|
-
]
|
|
1125
|
-
}
|
|
1126
|
-
]);
|
|
1127
|
-
const metadata = {
|
|
1128
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1129
|
-
method: "PATCH",
|
|
1130
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.UpdateOrderLineItem",
|
|
1131
|
-
packageName: PACKAGE_NAME,
|
|
1132
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1133
|
-
protoPath: "/v1/orders/{id}/line-item/{lineItem.id}",
|
|
1134
|
-
data: serializedData,
|
|
1135
|
-
host
|
|
1136
|
-
}),
|
|
1137
|
-
data: serializedData,
|
|
1138
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
1139
|
-
{
|
|
1140
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
1141
|
-
paths: [
|
|
1142
|
-
{ path: "order.createdDate" },
|
|
1143
|
-
{ path: "order.updatedDate" },
|
|
1144
|
-
{ path: "order.purchasedDate" },
|
|
1145
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
1146
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
1147
|
-
{
|
|
1148
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
1149
|
-
},
|
|
1150
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
1151
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
1152
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1153
|
-
{ path: "order.activities.createdDate" }
|
|
1154
|
-
]
|
|
1155
|
-
},
|
|
1156
|
-
{
|
|
1157
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
1158
|
-
paths: [
|
|
1159
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
1160
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
1161
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
1162
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
1163
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
1164
|
-
{
|
|
1165
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1166
|
-
},
|
|
1167
|
-
{
|
|
1168
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1169
|
-
},
|
|
1170
|
-
{
|
|
1171
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1172
|
-
},
|
|
1173
|
-
{
|
|
1174
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1175
|
-
},
|
|
1176
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
1177
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
1178
|
-
]
|
|
1179
|
-
}
|
|
1180
|
-
])
|
|
1181
|
-
};
|
|
1182
|
-
return metadata;
|
|
1183
|
-
}
|
|
1184
|
-
return __updateOrderLineItem;
|
|
1185
|
-
}
|
|
1186
|
-
function addActivity(payload) {
|
|
1187
|
-
function __addActivity({ host }) {
|
|
1188
|
-
const metadata = {
|
|
1189
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1190
|
-
method: "POST",
|
|
1191
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.AddActivity",
|
|
1192
|
-
packageName: PACKAGE_NAME,
|
|
1193
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1194
|
-
protoPath: "/v1/orders/{id}/activities",
|
|
1195
|
-
data: payload,
|
|
1196
|
-
host
|
|
1197
|
-
}),
|
|
1198
|
-
data: payload,
|
|
1199
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
1200
|
-
{
|
|
1201
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
1202
|
-
paths: [
|
|
1203
|
-
{ path: "order.createdDate" },
|
|
1204
|
-
{ path: "order.updatedDate" },
|
|
1205
|
-
{ path: "order.purchasedDate" },
|
|
1206
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
1207
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
1208
|
-
{
|
|
1209
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
1210
|
-
},
|
|
1211
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
1212
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
1213
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1214
|
-
{ path: "order.activities.createdDate" }
|
|
1215
|
-
]
|
|
1216
|
-
},
|
|
1217
|
-
{
|
|
1218
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
1219
|
-
paths: [
|
|
1220
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
1221
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
1222
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
1223
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
1224
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
1225
|
-
{
|
|
1226
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1227
|
-
},
|
|
1228
|
-
{
|
|
1229
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1230
|
-
},
|
|
1231
|
-
{
|
|
1232
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1233
|
-
},
|
|
1234
|
-
{
|
|
1235
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1236
|
-
},
|
|
1237
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
1238
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
1239
|
-
]
|
|
1240
|
-
}
|
|
1241
|
-
])
|
|
1242
|
-
};
|
|
1243
|
-
return metadata;
|
|
1244
|
-
}
|
|
1245
|
-
return __addActivity;
|
|
1246
|
-
}
|
|
1247
|
-
function updateActivity(payload) {
|
|
1248
|
-
function __updateActivity({ host }) {
|
|
1249
|
-
const metadata = {
|
|
1250
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1251
|
-
method: "PATCH",
|
|
1252
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.UpdateActivity",
|
|
1253
|
-
packageName: PACKAGE_NAME,
|
|
1254
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1255
|
-
protoPath: "/v1/orders/{id}/activities/{activityId}",
|
|
1256
|
-
data: payload,
|
|
1257
|
-
host
|
|
1258
|
-
}),
|
|
1259
|
-
data: payload,
|
|
1260
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
1261
|
-
{
|
|
1262
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
1263
|
-
paths: [
|
|
1264
|
-
{ path: "order.createdDate" },
|
|
1265
|
-
{ path: "order.updatedDate" },
|
|
1266
|
-
{ path: "order.purchasedDate" },
|
|
1267
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
1268
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
1269
|
-
{
|
|
1270
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
1271
|
-
},
|
|
1272
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
1273
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
1274
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1275
|
-
{ path: "order.activities.createdDate" }
|
|
1276
|
-
]
|
|
1277
|
-
},
|
|
1278
|
-
{
|
|
1279
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
1280
|
-
paths: [
|
|
1281
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
1282
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
1283
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
1284
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
1285
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
1286
|
-
{
|
|
1287
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1288
|
-
},
|
|
1289
|
-
{
|
|
1290
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1291
|
-
},
|
|
1292
|
-
{
|
|
1293
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1294
|
-
},
|
|
1295
|
-
{
|
|
1296
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1297
|
-
},
|
|
1298
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
1299
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
1300
|
-
]
|
|
1301
|
-
}
|
|
1302
|
-
])
|
|
1303
|
-
};
|
|
1304
|
-
return metadata;
|
|
1305
|
-
}
|
|
1306
|
-
return __updateActivity;
|
|
1307
|
-
}
|
|
1308
|
-
function deleteActivity(payload) {
|
|
1309
|
-
function __deleteActivity({ host }) {
|
|
1310
|
-
const metadata = {
|
|
1311
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1312
|
-
method: "DELETE",
|
|
1313
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.DeleteActivity",
|
|
1314
|
-
packageName: PACKAGE_NAME,
|
|
1315
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1316
|
-
protoPath: "/v1/orders/{id}/activities/{activityId}",
|
|
1317
|
-
data: payload,
|
|
1318
|
-
host
|
|
1319
|
-
}),
|
|
1320
|
-
params: (0, import_rest_modules.toURLSearchParams)(payload),
|
|
1321
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
1322
|
-
{
|
|
1323
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
1324
|
-
paths: [
|
|
1325
|
-
{ path: "order.createdDate" },
|
|
1326
|
-
{ path: "order.updatedDate" },
|
|
1327
|
-
{ path: "order.purchasedDate" },
|
|
1328
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
1329
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
1330
|
-
{
|
|
1331
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
1332
|
-
},
|
|
1333
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
1334
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
1335
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1336
|
-
{ path: "order.activities.createdDate" }
|
|
1337
|
-
]
|
|
1338
|
-
},
|
|
1339
|
-
{
|
|
1340
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
1341
|
-
paths: [
|
|
1342
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
1343
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
1344
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
1345
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
1346
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
1347
|
-
{
|
|
1348
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1349
|
-
},
|
|
1350
|
-
{
|
|
1351
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1352
|
-
},
|
|
1353
|
-
{
|
|
1354
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1355
|
-
},
|
|
1356
|
-
{
|
|
1357
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1358
|
-
},
|
|
1359
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
1360
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
1361
|
-
]
|
|
1362
|
-
}
|
|
1363
|
-
])
|
|
1364
|
-
};
|
|
1365
|
-
return metadata;
|
|
1366
|
-
}
|
|
1367
|
-
return __deleteActivity;
|
|
1368
|
-
}
|
|
1369
|
-
function cancelOrder(payload) {
|
|
1370
|
-
function __cancelOrder({ host }) {
|
|
1371
|
-
const metadata = {
|
|
1372
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1373
|
-
method: "POST",
|
|
1374
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.CancelOrder",
|
|
1375
|
-
packageName: PACKAGE_NAME,
|
|
1376
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1377
|
-
protoPath: "/v1/orders/{id}/cancel",
|
|
1378
|
-
data: payload,
|
|
1379
|
-
host
|
|
1380
|
-
}),
|
|
1381
|
-
data: payload,
|
|
1382
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
1383
|
-
{
|
|
1384
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
1385
|
-
paths: [
|
|
1386
|
-
{ path: "order.createdDate" },
|
|
1387
|
-
{ path: "order.updatedDate" },
|
|
1388
|
-
{ path: "order.purchasedDate" },
|
|
1389
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
1390
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
1391
|
-
{
|
|
1392
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
1393
|
-
},
|
|
1394
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
1395
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
1396
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1397
|
-
{ path: "order.activities.createdDate" }
|
|
1398
|
-
]
|
|
1399
|
-
},
|
|
1400
|
-
{
|
|
1401
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
1402
|
-
paths: [
|
|
1403
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
1404
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
1405
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
1406
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
1407
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
1408
|
-
{
|
|
1409
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1410
|
-
},
|
|
1411
|
-
{
|
|
1412
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1413
|
-
},
|
|
1414
|
-
{
|
|
1415
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1416
|
-
},
|
|
1417
|
-
{
|
|
1418
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1419
|
-
},
|
|
1420
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
1421
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
1422
|
-
]
|
|
1423
|
-
}
|
|
1424
|
-
])
|
|
1425
|
-
};
|
|
1426
|
-
return metadata;
|
|
1427
|
-
}
|
|
1428
|
-
return __cancelOrder;
|
|
1429
|
-
}
|
|
1430
|
-
function updateOrderStatus(payload) {
|
|
1431
|
-
function __updateOrderStatus({ host }) {
|
|
1432
|
-
const metadata = {
|
|
1433
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1434
|
-
method: "POST",
|
|
1435
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.UpdateOrderStatus",
|
|
1436
|
-
packageName: PACKAGE_NAME,
|
|
1437
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1438
|
-
protoPath: "/v1/orders/{orderId}/update-status",
|
|
1439
|
-
data: payload,
|
|
1440
|
-
host
|
|
1441
|
-
}),
|
|
1442
|
-
data: payload,
|
|
1443
|
-
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
1444
|
-
{
|
|
1445
|
-
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
1446
|
-
paths: [
|
|
1447
|
-
{ path: "order.createdDate" },
|
|
1448
|
-
{ path: "order.updatedDate" },
|
|
1449
|
-
{ path: "order.purchasedDate" },
|
|
1450
|
-
{ path: "order.lineItems.image.urlExpirationDate" },
|
|
1451
|
-
{ path: "order.lineItems.digitalFile.expirationDate" },
|
|
1452
|
-
{
|
|
1453
|
-
path: "order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
1454
|
-
},
|
|
1455
|
-
{ path: "order.shippingInfo.logistics.deliverByDate" },
|
|
1456
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
1457
|
-
{ path: "order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
1458
|
-
{ path: "order.activities.createdDate" }
|
|
1459
|
-
]
|
|
1460
|
-
},
|
|
1461
|
-
{
|
|
1462
|
-
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
|
1463
|
-
paths: [
|
|
1464
|
-
{ path: "order.lineItems.image.focalPoint.x" },
|
|
1465
|
-
{ path: "order.lineItems.image.focalPoint.y" },
|
|
1466
|
-
{ path: "order.lineItems.physicalProperties.weight" },
|
|
1467
|
-
{ path: "order.billingInfo.address.geocode.latitude" },
|
|
1468
|
-
{ path: "order.billingInfo.address.geocode.longitude" },
|
|
1469
|
-
{
|
|
1470
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.latitude"
|
|
1471
|
-
},
|
|
1472
|
-
{
|
|
1473
|
-
path: "order.shippingInfo.logistics.shippingDestination.address.geocode.longitude"
|
|
1474
|
-
},
|
|
1475
|
-
{
|
|
1476
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.latitude"
|
|
1477
|
-
},
|
|
1478
|
-
{
|
|
1479
|
-
path: "order.shippingInfo.logistics.pickupDetails.address.geocode.longitude"
|
|
1480
|
-
},
|
|
1481
|
-
{ path: "order.recipientInfo.address.geocode.latitude" },
|
|
1482
|
-
{ path: "order.recipientInfo.address.geocode.longitude" }
|
|
1483
|
-
]
|
|
1484
|
-
}
|
|
1485
|
-
])
|
|
1486
|
-
};
|
|
1487
|
-
return metadata;
|
|
1488
|
-
}
|
|
1489
|
-
return __updateOrderStatus;
|
|
1490
|
-
}
|
|
1491
|
-
function aggregateOrders(payload) {
|
|
1492
|
-
function __aggregateOrders({ host }) {
|
|
1493
|
-
const metadata = {
|
|
1494
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1495
|
-
method: "POST",
|
|
1496
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.AggregateOrders",
|
|
1497
|
-
packageName: PACKAGE_NAME,
|
|
1498
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1499
|
-
protoPath: "/v1/orders/aggregate",
|
|
1500
|
-
data: payload,
|
|
1501
|
-
host
|
|
1502
|
-
}),
|
|
1503
|
-
data: payload
|
|
1504
|
-
};
|
|
1505
|
-
return metadata;
|
|
1506
|
-
}
|
|
1507
|
-
return __aggregateOrders;
|
|
1508
|
-
}
|
|
1509
|
-
function bulkUpdateOrderTags(payload) {
|
|
1510
|
-
function __bulkUpdateOrderTags({ host }) {
|
|
1511
|
-
const metadata = {
|
|
1512
|
-
entityFqdn: "wix.ecom.v1.order",
|
|
1513
|
-
method: "POST",
|
|
1514
|
-
methodFqn: "com.wix.ecom.orders.v1.Orders.BulkUpdateOrderTags",
|
|
1515
|
-
packageName: PACKAGE_NAME,
|
|
1516
|
-
url: resolveComWixEcomOrdersV1OrdersUrl({
|
|
1517
|
-
protoPath: "/v1/bulk/orders/update-tags",
|
|
1518
|
-
data: payload,
|
|
1519
|
-
host
|
|
1520
|
-
}),
|
|
1521
|
-
data: payload
|
|
1522
|
-
};
|
|
1523
|
-
return metadata;
|
|
1524
|
-
}
|
|
1525
|
-
return __bulkUpdateOrderTags;
|
|
1526
|
-
}
|
|
1527
|
-
|
|
1528
|
-
// src/ecom-v1-order-orders.universal.ts
|
|
1529
|
-
var import_address = require("@wix/sdk-runtime/transformations/address");
|
|
1530
|
-
var import_address2 = require("@wix/sdk-runtime/transformations/address");
|
|
1531
|
-
var import_image = require("@wix/sdk-runtime/transformations/image");
|
|
1532
|
-
var import_image2 = require("@wix/sdk-runtime/transformations/image");
|
|
1533
|
-
var import_transform_paths2 = require("@wix/sdk-runtime/transformations/transform-paths");
|
|
1534
|
-
var DescriptionLineType = /* @__PURE__ */ ((DescriptionLineType2) => {
|
|
1535
|
-
DescriptionLineType2["UNRECOGNISED"] = "UNRECOGNISED";
|
|
1536
|
-
DescriptionLineType2["PLAIN_TEXT"] = "PLAIN_TEXT";
|
|
1537
|
-
DescriptionLineType2["COLOR"] = "COLOR";
|
|
1538
|
-
return DescriptionLineType2;
|
|
1539
|
-
})(DescriptionLineType || {});
|
|
1540
|
-
var ItemTypeItemType = /* @__PURE__ */ ((ItemTypeItemType2) => {
|
|
1541
|
-
ItemTypeItemType2["UNRECOGNISED"] = "UNRECOGNISED";
|
|
1542
|
-
ItemTypeItemType2["PHYSICAL"] = "PHYSICAL";
|
|
1543
|
-
ItemTypeItemType2["DIGITAL"] = "DIGITAL";
|
|
1544
|
-
ItemTypeItemType2["GIFT_CARD"] = "GIFT_CARD";
|
|
1545
|
-
ItemTypeItemType2["SERVICE"] = "SERVICE";
|
|
1546
|
-
return ItemTypeItemType2;
|
|
1547
|
-
})(ItemTypeItemType || {});
|
|
1548
|
-
var PaymentOptionType = /* @__PURE__ */ ((PaymentOptionType2) => {
|
|
1549
|
-
PaymentOptionType2["FULL_PAYMENT_ONLINE"] = "FULL_PAYMENT_ONLINE";
|
|
1550
|
-
PaymentOptionType2["FULL_PAYMENT_OFFLINE"] = "FULL_PAYMENT_OFFLINE";
|
|
1551
|
-
PaymentOptionType2["MEMBERSHIP"] = "MEMBERSHIP";
|
|
1552
|
-
PaymentOptionType2["DEPOSIT_ONLINE"] = "DEPOSIT_ONLINE";
|
|
1553
|
-
PaymentOptionType2["MEMBERSHIP_OFFLINE"] = "MEMBERSHIP_OFFLINE";
|
|
1554
|
-
return PaymentOptionType2;
|
|
1555
|
-
})(PaymentOptionType || {});
|
|
1556
|
-
var JurisdictionType = /* @__PURE__ */ ((JurisdictionType2) => {
|
|
1557
|
-
JurisdictionType2["UNDEFINED"] = "UNDEFINED";
|
|
1558
|
-
JurisdictionType2["COUNTRY"] = "COUNTRY";
|
|
1559
|
-
JurisdictionType2["STATE"] = "STATE";
|
|
1560
|
-
JurisdictionType2["COUNTY"] = "COUNTY";
|
|
1561
|
-
JurisdictionType2["CITY"] = "CITY";
|
|
1562
|
-
JurisdictionType2["SPECIAL"] = "SPECIAL";
|
|
1563
|
-
return JurisdictionType2;
|
|
1564
|
-
})(JurisdictionType || {});
|
|
1565
|
-
var SubscriptionFrequency = /* @__PURE__ */ ((SubscriptionFrequency2) => {
|
|
1566
|
-
SubscriptionFrequency2["UNDEFINED"] = "UNDEFINED";
|
|
1567
|
-
SubscriptionFrequency2["DAY"] = "DAY";
|
|
1568
|
-
SubscriptionFrequency2["WEEK"] = "WEEK";
|
|
1569
|
-
SubscriptionFrequency2["MONTH"] = "MONTH";
|
|
1570
|
-
SubscriptionFrequency2["YEAR"] = "YEAR";
|
|
1571
|
-
return SubscriptionFrequency2;
|
|
1572
|
-
})(SubscriptionFrequency || {});
|
|
1573
|
-
var AdjustmentType = /* @__PURE__ */ ((AdjustmentType2) => {
|
|
1574
|
-
AdjustmentType2["UNKNOWN_ADJUSTMENT_TYPE"] = "UNKNOWN_ADJUSTMENT_TYPE";
|
|
1575
|
-
AdjustmentType2["EXTRA_CHARGE"] = "EXTRA_CHARGE";
|
|
1576
|
-
AdjustmentType2["CREDIT"] = "CREDIT";
|
|
1577
|
-
return AdjustmentType2;
|
|
1578
|
-
})(AdjustmentType || {});
|
|
1579
|
-
var TaxableAddressType = /* @__PURE__ */ ((TaxableAddressType2) => {
|
|
1580
|
-
TaxableAddressType2["UNKNOWN_TAXABLE_ADDRESS"] = "UNKNOWN_TAXABLE_ADDRESS";
|
|
1581
|
-
TaxableAddressType2["BUSINESS"] = "BUSINESS";
|
|
1582
|
-
TaxableAddressType2["BILLING"] = "BILLING";
|
|
1583
|
-
TaxableAddressType2["SHIPPING"] = "SHIPPING";
|
|
1584
|
-
return TaxableAddressType2;
|
|
1585
|
-
})(TaxableAddressType || {});
|
|
1586
|
-
var PaymentStatus = /* @__PURE__ */ ((PaymentStatus2) => {
|
|
1587
|
-
PaymentStatus2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
1588
|
-
PaymentStatus2["NOT_PAID"] = "NOT_PAID";
|
|
1589
|
-
PaymentStatus2["PAID"] = "PAID";
|
|
1590
|
-
PaymentStatus2["PARTIALLY_REFUNDED"] = "PARTIALLY_REFUNDED";
|
|
1591
|
-
PaymentStatus2["FULLY_REFUNDED"] = "FULLY_REFUNDED";
|
|
1592
|
-
PaymentStatus2["PENDING"] = "PENDING";
|
|
1593
|
-
PaymentStatus2["PARTIALLY_PAID"] = "PARTIALLY_PAID";
|
|
1594
|
-
PaymentStatus2["PENDING_MERCHANT"] = "PENDING_MERCHANT";
|
|
1595
|
-
PaymentStatus2["CANCELED"] = "CANCELED";
|
|
1596
|
-
PaymentStatus2["DECLINED"] = "DECLINED";
|
|
1597
|
-
return PaymentStatus2;
|
|
1598
|
-
})(PaymentStatus || {});
|
|
1599
|
-
var FulfillmentStatus = /* @__PURE__ */ ((FulfillmentStatus2) => {
|
|
1600
|
-
FulfillmentStatus2["NOT_FULFILLED"] = "NOT_FULFILLED";
|
|
1601
|
-
FulfillmentStatus2["FULFILLED"] = "FULFILLED";
|
|
1602
|
-
FulfillmentStatus2["PARTIALLY_FULFILLED"] = "PARTIALLY_FULFILLED";
|
|
1603
|
-
return FulfillmentStatus2;
|
|
1604
|
-
})(FulfillmentStatus || {});
|
|
1605
|
-
var WeightUnit = /* @__PURE__ */ ((WeightUnit2) => {
|
|
1606
|
-
WeightUnit2["UNSPECIFIED_WEIGHT_UNIT"] = "UNSPECIFIED_WEIGHT_UNIT";
|
|
1607
|
-
WeightUnit2["KG"] = "KG";
|
|
1608
|
-
WeightUnit2["LB"] = "LB";
|
|
1609
|
-
return WeightUnit2;
|
|
1610
|
-
})(WeightUnit || {});
|
|
1611
|
-
var VatType = /* @__PURE__ */ ((VatType2) => {
|
|
1612
|
-
VatType2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
1613
|
-
VatType2["CPF"] = "CPF";
|
|
1614
|
-
VatType2["CNPJ"] = "CNPJ";
|
|
1615
|
-
return VatType2;
|
|
1616
|
-
})(VatType || {});
|
|
1617
|
-
var PickupMethod = /* @__PURE__ */ ((PickupMethod2) => {
|
|
1618
|
-
PickupMethod2["UNKNOWN_METHOD"] = "UNKNOWN_METHOD";
|
|
1619
|
-
PickupMethod2["STORE_PICKUP"] = "STORE_PICKUP";
|
|
1620
|
-
PickupMethod2["PICKUP_POINT"] = "PICKUP_POINT";
|
|
1621
|
-
return PickupMethod2;
|
|
1622
|
-
})(PickupMethod || {});
|
|
1623
|
-
var OrderStatus = /* @__PURE__ */ ((OrderStatus3) => {
|
|
1624
|
-
OrderStatus3["INITIALIZED"] = "INITIALIZED";
|
|
1625
|
-
OrderStatus3["APPROVED"] = "APPROVED";
|
|
1626
|
-
OrderStatus3["CANCELED"] = "CANCELED";
|
|
1627
|
-
OrderStatus3["PENDING"] = "PENDING";
|
|
1628
|
-
OrderStatus3["REJECTED"] = "REJECTED";
|
|
1629
|
-
return OrderStatus3;
|
|
1630
|
-
})(OrderStatus || {});
|
|
1631
|
-
var DiscountType = /* @__PURE__ */ ((DiscountType2) => {
|
|
1632
|
-
DiscountType2["GLOBAL"] = "GLOBAL";
|
|
1633
|
-
DiscountType2["SPECIFIC_ITEMS"] = "SPECIFIC_ITEMS";
|
|
1634
|
-
DiscountType2["SHIPPING"] = "SHIPPING";
|
|
1635
|
-
return DiscountType2;
|
|
1636
|
-
})(DiscountType || {});
|
|
1637
|
-
var DiscountReason = /* @__PURE__ */ ((DiscountReason2) => {
|
|
1638
|
-
DiscountReason2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
1639
|
-
DiscountReason2["EXCHANGED_ITEMS"] = "EXCHANGED_ITEMS";
|
|
1640
|
-
DiscountReason2["BILLING_ADJUSTMENT"] = "BILLING_ADJUSTMENT";
|
|
1641
|
-
return DiscountReason2;
|
|
1642
|
-
})(DiscountReason || {});
|
|
1643
|
-
var LineItemQuantityChangeType = /* @__PURE__ */ ((LineItemQuantityChangeType2) => {
|
|
1644
|
-
LineItemQuantityChangeType2["QUANTITY_INCREASED"] = "QUANTITY_INCREASED";
|
|
1645
|
-
LineItemQuantityChangeType2["QUANTITY_DECREASED"] = "QUANTITY_DECREASED";
|
|
1646
|
-
return LineItemQuantityChangeType2;
|
|
1647
|
-
})(LineItemQuantityChangeType || {});
|
|
1648
|
-
var ActivityType = /* @__PURE__ */ ((ActivityType2) => {
|
|
1649
|
-
ActivityType2["ORDER_REFUNDED"] = "ORDER_REFUNDED";
|
|
1650
|
-
ActivityType2["ORDER_PLACED"] = "ORDER_PLACED";
|
|
1651
|
-
ActivityType2["ORDER_PAID"] = "ORDER_PAID";
|
|
1652
|
-
ActivityType2["ORDER_FULFILLED"] = "ORDER_FULFILLED";
|
|
1653
|
-
ActivityType2["ORDER_NOT_FULFILLED"] = "ORDER_NOT_FULFILLED";
|
|
1654
|
-
ActivityType2["ORDER_CANCELED"] = "ORDER_CANCELED";
|
|
1655
|
-
ActivityType2["DOWNLOAD_LINK_SENT"] = "DOWNLOAD_LINK_SENT";
|
|
1656
|
-
ActivityType2["TRACKING_NUMBER_ADDED"] = "TRACKING_NUMBER_ADDED";
|
|
1657
|
-
ActivityType2["TRACKING_NUMBER_EDITED"] = "TRACKING_NUMBER_EDITED";
|
|
1658
|
-
ActivityType2["TRACKING_LINK_ADDED"] = "TRACKING_LINK_ADDED";
|
|
1659
|
-
ActivityType2["SHIPPING_CONFIRMATION_EMAIL_SENT"] = "SHIPPING_CONFIRMATION_EMAIL_SENT";
|
|
1660
|
-
ActivityType2["INVOICE_ADDED"] = "INVOICE_ADDED";
|
|
1661
|
-
ActivityType2["INVOICE_REMOVED"] = "INVOICE_REMOVED";
|
|
1662
|
-
ActivityType2["INVOICE_SENT"] = "INVOICE_SENT";
|
|
1663
|
-
ActivityType2["FULFILLER_EMAIL_SENT"] = "FULFILLER_EMAIL_SENT";
|
|
1664
|
-
ActivityType2["SHIPPING_ADDRESS_EDITED"] = "SHIPPING_ADDRESS_EDITED";
|
|
1665
|
-
ActivityType2["EMAIL_EDITED"] = "EMAIL_EDITED";
|
|
1666
|
-
ActivityType2["PICKUP_READY_EMAIL_SENT"] = "PICKUP_READY_EMAIL_SENT";
|
|
1667
|
-
ActivityType2["CUSTOM_ACTIVITY"] = "CUSTOM_ACTIVITY";
|
|
1668
|
-
ActivityType2["MERCHANT_COMMENT"] = "MERCHANT_COMMENT";
|
|
1669
|
-
ActivityType2["ORDER_CREATED_FROM_EXCHANGE"] = "ORDER_CREATED_FROM_EXCHANGE";
|
|
1670
|
-
ActivityType2["NEW_EXCHANGE_ORDER_CREATED"] = "NEW_EXCHANGE_ORDER_CREATED";
|
|
1671
|
-
ActivityType2["ORDER_PARTIALLY_PAID"] = "ORDER_PARTIALLY_PAID";
|
|
1672
|
-
ActivityType2["DRAFT_ORDER_CHANGES_APPLIED"] = "DRAFT_ORDER_CHANGES_APPLIED";
|
|
1673
|
-
ActivityType2["SAVED_PAYMENT_METHOD"] = "SAVED_PAYMENT_METHOD";
|
|
1674
|
-
ActivityType2["PAYMENT_PENDING"] = "PAYMENT_PENDING";
|
|
1675
|
-
ActivityType2["PAYMENT_CANCELED"] = "PAYMENT_CANCELED";
|
|
1676
|
-
ActivityType2["PAYMENT_DECLINED"] = "PAYMENT_DECLINED";
|
|
1677
|
-
ActivityType2["ORDER_PENDING"] = "ORDER_PENDING";
|
|
1678
|
-
ActivityType2["ORDER_REJECTED"] = "ORDER_REJECTED";
|
|
1679
|
-
return ActivityType2;
|
|
1680
|
-
})(ActivityType || {});
|
|
1681
|
-
var AttributionSource = /* @__PURE__ */ ((AttributionSource2) => {
|
|
1682
|
-
AttributionSource2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
1683
|
-
AttributionSource2["FACEBOOK_ADS"] = "FACEBOOK_ADS";
|
|
1684
|
-
return AttributionSource2;
|
|
1685
|
-
})(AttributionSource || {});
|
|
1686
|
-
var ChannelType = /* @__PURE__ */ ((ChannelType2) => {
|
|
1687
|
-
ChannelType2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
1688
|
-
ChannelType2["WEB"] = "WEB";
|
|
1689
|
-
ChannelType2["POS"] = "POS";
|
|
1690
|
-
ChannelType2["EBAY"] = "EBAY";
|
|
1691
|
-
ChannelType2["AMAZON"] = "AMAZON";
|
|
1692
|
-
ChannelType2["OTHER_PLATFORM"] = "OTHER_PLATFORM";
|
|
1693
|
-
ChannelType2["WIX_APP_STORE"] = "WIX_APP_STORE";
|
|
1694
|
-
ChannelType2["WIX_INVOICES"] = "WIX_INVOICES";
|
|
1695
|
-
ChannelType2["BACKOFFICE_MERCHANT"] = "BACKOFFICE_MERCHANT";
|
|
1696
|
-
ChannelType2["WISH"] = "WISH";
|
|
1697
|
-
ChannelType2["CLASS_PASS"] = "CLASS_PASS";
|
|
1698
|
-
ChannelType2["GLOBAL_E"] = "GLOBAL_E";
|
|
1699
|
-
ChannelType2["FACEBOOK"] = "FACEBOOK";
|
|
1700
|
-
ChannelType2["ETSY"] = "ETSY";
|
|
1701
|
-
ChannelType2["TIKTOK"] = "TIKTOK";
|
|
1702
|
-
ChannelType2["FAIRE_COM"] = "FAIRE_COM";
|
|
1703
|
-
return ChannelType2;
|
|
1704
|
-
})(ChannelType || {});
|
|
1705
|
-
var ScheduledAction = /* @__PURE__ */ ((ScheduledAction2) => {
|
|
1706
|
-
ScheduledAction2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
1707
|
-
ScheduledAction2["VOID"] = "VOID";
|
|
1708
|
-
ScheduledAction2["CAPTURE"] = "CAPTURE";
|
|
1709
|
-
return ScheduledAction2;
|
|
1710
|
-
})(ScheduledAction || {});
|
|
1711
|
-
var DurationUnit = /* @__PURE__ */ ((DurationUnit2) => {
|
|
1712
|
-
DurationUnit2["UNKNOWN_DURATION_UNIT"] = "UNKNOWN_DURATION_UNIT";
|
|
1713
|
-
DurationUnit2["MINUTES"] = "MINUTES";
|
|
1714
|
-
DurationUnit2["HOURS"] = "HOURS";
|
|
1715
|
-
DurationUnit2["DAYS"] = "DAYS";
|
|
1716
|
-
return DurationUnit2;
|
|
1717
|
-
})(DurationUnit || {});
|
|
1718
|
-
var PaymentCollectabilityStatus = /* @__PURE__ */ ((PaymentCollectabilityStatus2) => {
|
|
1719
|
-
PaymentCollectabilityStatus2["UNKNOWN"] = "UNKNOWN";
|
|
1720
|
-
PaymentCollectabilityStatus2["COLLECTABLE"] = "COLLECTABLE";
|
|
1721
|
-
PaymentCollectabilityStatus2["NONCOLLECTABLE_ORDER_IS_CANCELLED"] = "NONCOLLECTABLE_ORDER_IS_CANCELLED";
|
|
1722
|
-
PaymentCollectabilityStatus2["NONCOLLECTABLE_ORDER_IS_PAID"] = "NONCOLLECTABLE_ORDER_IS_PAID";
|
|
1723
|
-
PaymentCollectabilityStatus2["NONCOLLECTABLE_MISSING_PAYMENT_METHOD"] = "NONCOLLECTABLE_MISSING_PAYMENT_METHOD";
|
|
1724
|
-
PaymentCollectabilityStatus2["NONCOLLECTABLE_ORDER_IS_PENDING"] = "NONCOLLECTABLE_ORDER_IS_PENDING";
|
|
1725
|
-
PaymentCollectabilityStatus2["NONCOLLECTABLE_ORDER_IS_REJECTED"] = "NONCOLLECTABLE_ORDER_IS_REJECTED";
|
|
1726
|
-
PaymentCollectabilityStatus2["NONCOLLECTABLE_ORDER_HAS_SUBSCRIPTIONS"] = "NONCOLLECTABLE_ORDER_HAS_SUBSCRIPTIONS";
|
|
1727
|
-
return PaymentCollectabilityStatus2;
|
|
1728
|
-
})(PaymentCollectabilityStatus || {});
|
|
1729
|
-
var RefundableStatus = /* @__PURE__ */ ((RefundableStatus2) => {
|
|
1730
|
-
RefundableStatus2["NOT_REFUNDABLE"] = "NOT_REFUNDABLE";
|
|
1731
|
-
RefundableStatus2["MANUAL"] = "MANUAL";
|
|
1732
|
-
RefundableStatus2["REFUNDABLE"] = "REFUNDABLE";
|
|
1733
|
-
return RefundableStatus2;
|
|
1734
|
-
})(RefundableStatus || {});
|
|
1735
|
-
var NonRefundableReason = /* @__PURE__ */ ((NonRefundableReason2) => {
|
|
1736
|
-
NonRefundableReason2["NONE"] = "NONE";
|
|
1737
|
-
NonRefundableReason2["ALREADY_REFUNDED"] = "ALREADY_REFUNDED";
|
|
1738
|
-
NonRefundableReason2["PROVIDER_IS_DOWN"] = "PROVIDER_IS_DOWN";
|
|
1739
|
-
NonRefundableReason2["INTERNAL_ERROR"] = "INTERNAL_ERROR";
|
|
1740
|
-
NonRefundableReason2["NOT_PAID"] = "NOT_PAID";
|
|
1741
|
-
NonRefundableReason2["ACCESS_DENIED"] = "ACCESS_DENIED";
|
|
1742
|
-
NonRefundableReason2["ZERO_PRICE"] = "ZERO_PRICE";
|
|
1743
|
-
NonRefundableReason2["DISABLED_BY_PROVIDER"] = "DISABLED_BY_PROVIDER";
|
|
1744
|
-
NonRefundableReason2["PENDING_REFUND"] = "PENDING_REFUND";
|
|
1745
|
-
NonRefundableReason2["FORBIDDEN"] = "FORBIDDEN";
|
|
1746
|
-
NonRefundableReason2["TRANSACTION_NOT_FOUND"] = "TRANSACTION_NOT_FOUND";
|
|
1747
|
-
NonRefundableReason2["ORDER_IS_PENDING"] = "ORDER_IS_PENDING";
|
|
1748
|
-
NonRefundableReason2["ORDER_IS_REJECTED"] = "ORDER_IS_REJECTED";
|
|
1749
|
-
return NonRefundableReason2;
|
|
1750
|
-
})(NonRefundableReason || {});
|
|
1751
|
-
var ManuallyRefundableReason = /* @__PURE__ */ ((ManuallyRefundableReason2) => {
|
|
1752
|
-
ManuallyRefundableReason2["EXPIRED"] = "EXPIRED";
|
|
1753
|
-
ManuallyRefundableReason2["NOT_SUPPORTED"] = "NOT_SUPPORTED";
|
|
1754
|
-
ManuallyRefundableReason2["OFFLINE"] = "OFFLINE";
|
|
1755
|
-
ManuallyRefundableReason2["REQUIRES_CARD_READER"] = "REQUIRES_CARD_READER";
|
|
1756
|
-
return ManuallyRefundableReason2;
|
|
1757
|
-
})(ManuallyRefundableReason || {});
|
|
1758
|
-
var RestockType = /* @__PURE__ */ ((RestockType2) => {
|
|
1759
|
-
RestockType2["NO_ITEMS"] = "NO_ITEMS";
|
|
1760
|
-
RestockType2["ALL_ITEMS"] = "ALL_ITEMS";
|
|
1761
|
-
RestockType2["SOME_ITEMS"] = "SOME_ITEMS";
|
|
1762
|
-
return RestockType2;
|
|
1763
|
-
})(RestockType || {});
|
|
1764
|
-
var TransactionStatus = /* @__PURE__ */ ((TransactionStatus2) => {
|
|
1765
|
-
TransactionStatus2["UNDEFINED"] = "UNDEFINED";
|
|
1766
|
-
TransactionStatus2["APPROVED"] = "APPROVED";
|
|
1767
|
-
TransactionStatus2["PENDING"] = "PENDING";
|
|
1768
|
-
TransactionStatus2["PENDING_MERCHANT"] = "PENDING_MERCHANT";
|
|
1769
|
-
TransactionStatus2["CANCELED"] = "CANCELED";
|
|
1770
|
-
TransactionStatus2["DECLINED"] = "DECLINED";
|
|
1771
|
-
TransactionStatus2["REFUNDED"] = "REFUNDED";
|
|
1772
|
-
TransactionStatus2["PARTIALLY_REFUNDED"] = "PARTIALLY_REFUNDED";
|
|
1773
|
-
TransactionStatus2["AUTHORIZED"] = "AUTHORIZED";
|
|
1774
|
-
TransactionStatus2["VOIDED"] = "VOIDED";
|
|
1775
|
-
return TransactionStatus2;
|
|
1776
|
-
})(TransactionStatus || {});
|
|
1777
|
-
var AuthorizationCaptureStatus = /* @__PURE__ */ ((AuthorizationCaptureStatus2) => {
|
|
1778
|
-
AuthorizationCaptureStatus2["UNKNOWN_STATUS"] = "UNKNOWN_STATUS";
|
|
1779
|
-
AuthorizationCaptureStatus2["PENDING"] = "PENDING";
|
|
1780
|
-
AuthorizationCaptureStatus2["SUCCEEDED"] = "SUCCEEDED";
|
|
1781
|
-
AuthorizationCaptureStatus2["FAILED"] = "FAILED";
|
|
1782
|
-
return AuthorizationCaptureStatus2;
|
|
1783
|
-
})(AuthorizationCaptureStatus || {});
|
|
1784
|
-
var AuthorizationVoidStatus = /* @__PURE__ */ ((AuthorizationVoidStatus2) => {
|
|
1785
|
-
AuthorizationVoidStatus2["UNKNOWN_STATUS"] = "UNKNOWN_STATUS";
|
|
1786
|
-
AuthorizationVoidStatus2["PENDING"] = "PENDING";
|
|
1787
|
-
AuthorizationVoidStatus2["SUCCEEDED"] = "SUCCEEDED";
|
|
1788
|
-
AuthorizationVoidStatus2["FAILED"] = "FAILED";
|
|
1789
|
-
return AuthorizationVoidStatus2;
|
|
1790
|
-
})(AuthorizationVoidStatus || {});
|
|
1791
|
-
var Reason = /* @__PURE__ */ ((Reason2) => {
|
|
1792
|
-
Reason2["UNKNOWN_REASON"] = "UNKNOWN_REASON";
|
|
1793
|
-
Reason2["MANUAL"] = "MANUAL";
|
|
1794
|
-
Reason2["SCHEDULED"] = "SCHEDULED";
|
|
1795
|
-
return Reason2;
|
|
1796
|
-
})(Reason || {});
|
|
1797
|
-
var ActionType = /* @__PURE__ */ ((ActionType2) => {
|
|
1798
|
-
ActionType2["UNKNOWN_ACTION_TYPE"] = "UNKNOWN_ACTION_TYPE";
|
|
1799
|
-
ActionType2["VOID"] = "VOID";
|
|
1800
|
-
ActionType2["CAPTURE"] = "CAPTURE";
|
|
1801
|
-
return ActionType2;
|
|
1802
|
-
})(ActionType || {});
|
|
1803
|
-
var MembershipPaymentStatus = /* @__PURE__ */ ((MembershipPaymentStatus2) => {
|
|
1804
|
-
MembershipPaymentStatus2["CHARGED"] = "CHARGED";
|
|
1805
|
-
MembershipPaymentStatus2["CHARGE_FAILED"] = "CHARGE_FAILED";
|
|
1806
|
-
return MembershipPaymentStatus2;
|
|
1807
|
-
})(MembershipPaymentStatus || {});
|
|
1808
|
-
var RefundStatus = /* @__PURE__ */ ((RefundStatus2) => {
|
|
1809
|
-
RefundStatus2["PENDING"] = "PENDING";
|
|
1810
|
-
RefundStatus2["SUCCEEDED"] = "SUCCEEDED";
|
|
1811
|
-
RefundStatus2["FAILED"] = "FAILED";
|
|
1812
|
-
RefundStatus2["SCHEDULED"] = "SCHEDULED";
|
|
1813
|
-
RefundStatus2["STARTED"] = "STARTED";
|
|
1814
|
-
return RefundStatus2;
|
|
1815
|
-
})(RefundStatus || {});
|
|
1816
|
-
var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
1817
|
-
WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
|
|
1818
|
-
WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
|
|
1819
|
-
WebhookIdentityType2["MEMBER"] = "MEMBER";
|
|
1820
|
-
WebhookIdentityType2["WIX_USER"] = "WIX_USER";
|
|
1821
|
-
WebhookIdentityType2["APP"] = "APP";
|
|
1822
|
-
return WebhookIdentityType2;
|
|
1823
|
-
})(WebhookIdentityType || {});
|
|
1824
|
-
var TextDetection = /* @__PURE__ */ ((TextDetection2) => {
|
|
1825
|
-
TextDetection2["UNKNOWN_TEXT_DETECTION"] = "UNKNOWN_TEXT_DETECTION";
|
|
1826
|
-
TextDetection2["CONTAINS_TEXT"] = "CONTAINS_TEXT";
|
|
1827
|
-
TextDetection2["NO_TEXT"] = "NO_TEXT";
|
|
1828
|
-
return TextDetection2;
|
|
1829
|
-
})(TextDetection || {});
|
|
1830
|
-
var AnimationDetection = /* @__PURE__ */ ((AnimationDetection2) => {
|
|
1831
|
-
AnimationDetection2["UNKNOWN_ANIMATION_DETECTION"] = "UNKNOWN_ANIMATION_DETECTION";
|
|
1832
|
-
AnimationDetection2["CONTAINS_ANIMATION"] = "CONTAINS_ANIMATION";
|
|
1833
|
-
AnimationDetection2["NO_ANIMATION"] = "NO_ANIMATION";
|
|
1834
|
-
return AnimationDetection2;
|
|
1835
|
-
})(AnimationDetection || {});
|
|
1836
|
-
var PreviewEmailType = /* @__PURE__ */ ((PreviewEmailType2) => {
|
|
1837
|
-
PreviewEmailType2["ORDER_PLACED"] = "ORDER_PLACED";
|
|
1838
|
-
PreviewEmailType2["DOWNLOAD_LINKS"] = "DOWNLOAD_LINKS";
|
|
1839
|
-
PreviewEmailType2["ORDER_SHIPPED"] = "ORDER_SHIPPED";
|
|
1840
|
-
PreviewEmailType2["ORDER_READY_FOR_PICKUP"] = "ORDER_READY_FOR_PICKUP";
|
|
1841
|
-
return PreviewEmailType2;
|
|
1842
|
-
})(PreviewEmailType || {});
|
|
1843
|
-
var State = /* @__PURE__ */ ((State2) => {
|
|
1844
|
-
State2["UNKNOWN"] = "UNKNOWN";
|
|
1845
|
-
State2["ENABLED"] = "ENABLED";
|
|
1846
|
-
State2["DISABLED"] = "DISABLED";
|
|
1847
|
-
State2["TEMPLATE"] = "TEMPLATE";
|
|
1848
|
-
State2["PENDING"] = "PENDING";
|
|
1849
|
-
return State2;
|
|
1850
|
-
})(State || {});
|
|
1851
|
-
var Namespace = /* @__PURE__ */ ((Namespace2) => {
|
|
1852
|
-
Namespace2["UNKNOWN_NAMESPACE"] = "UNKNOWN_NAMESPACE";
|
|
1853
|
-
Namespace2["WIX"] = "WIX";
|
|
1854
|
-
Namespace2["SHOUT_OUT"] = "SHOUT_OUT";
|
|
1855
|
-
Namespace2["ALBUMS"] = "ALBUMS";
|
|
1856
|
-
Namespace2["WIX_STORES_TEST_DRIVE"] = "WIX_STORES_TEST_DRIVE";
|
|
1857
|
-
Namespace2["HOTELS"] = "HOTELS";
|
|
1858
|
-
Namespace2["CLUBS"] = "CLUBS";
|
|
1859
|
-
Namespace2["ONBOARDING_DRAFT"] = "ONBOARDING_DRAFT";
|
|
1860
|
-
Namespace2["DEV_SITE"] = "DEV_SITE";
|
|
1861
|
-
Namespace2["LOGOS"] = "LOGOS";
|
|
1862
|
-
Namespace2["VIDEO_MAKER"] = "VIDEO_MAKER";
|
|
1863
|
-
Namespace2["PARTNER_DASHBOARD"] = "PARTNER_DASHBOARD";
|
|
1864
|
-
Namespace2["DEV_CENTER_COMPANY"] = "DEV_CENTER_COMPANY";
|
|
1865
|
-
Namespace2["HTML_DRAFT"] = "HTML_DRAFT";
|
|
1866
|
-
Namespace2["SITELESS_BUSINESS"] = "SITELESS_BUSINESS";
|
|
1867
|
-
Namespace2["CREATOR_ECONOMY"] = "CREATOR_ECONOMY";
|
|
1868
|
-
Namespace2["DASHBOARD_FIRST"] = "DASHBOARD_FIRST";
|
|
1869
|
-
Namespace2["ANYWHERE"] = "ANYWHERE";
|
|
1870
|
-
Namespace2["HEADLESS"] = "HEADLESS";
|
|
1871
|
-
Namespace2["ACCOUNT_MASTER_CMS"] = "ACCOUNT_MASTER_CMS";
|
|
1872
|
-
Namespace2["RISE"] = "RISE";
|
|
1873
|
-
Namespace2["BRANDED_FIRST"] = "BRANDED_FIRST";
|
|
1874
|
-
Namespace2["NOWNIA"] = "NOWNIA";
|
|
1875
|
-
Namespace2["UGC_TEMPLATE"] = "UGC_TEMPLATE";
|
|
1876
|
-
Namespace2["CODUX"] = "CODUX";
|
|
1877
|
-
Namespace2["MEDIA_DESIGN_CREATOR"] = "MEDIA_DESIGN_CREATOR";
|
|
1878
|
-
Namespace2["SHARED_BLOG_ENTERPRISE"] = "SHARED_BLOG_ENTERPRISE";
|
|
1879
|
-
Namespace2["STANDALONE_FORMS"] = "STANDALONE_FORMS";
|
|
1880
|
-
Namespace2["STANDALONE_EVENTS"] = "STANDALONE_EVENTS";
|
|
1881
|
-
Namespace2["MIMIR"] = "MIMIR";
|
|
1882
|
-
return Namespace2;
|
|
1883
|
-
})(Namespace || {});
|
|
1884
|
-
var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
|
|
1885
|
-
SortOrder2["ASC"] = "ASC";
|
|
1886
|
-
SortOrder2["DESC"] = "DESC";
|
|
1887
|
-
return SortOrder2;
|
|
1888
|
-
})(SortOrder || {});
|
|
1889
|
-
var VersioningMode = /* @__PURE__ */ ((VersioningMode2) => {
|
|
1890
|
-
VersioningMode2["DEFAULT"] = "DEFAULT";
|
|
1891
|
-
VersioningMode2["GREATER_THAN"] = "GREATER_THAN";
|
|
1892
|
-
VersioningMode2["GREATER_OR_EQUAL"] = "GREATER_OR_EQUAL";
|
|
1893
|
-
return VersioningMode2;
|
|
1894
|
-
})(VersioningMode || {});
|
|
1895
|
-
var OrderApprovalStrategy = /* @__PURE__ */ ((OrderApprovalStrategy2) => {
|
|
1896
|
-
OrderApprovalStrategy2["DEFAULT"] = "DEFAULT";
|
|
1897
|
-
OrderApprovalStrategy2["PAYMENT_RECEIVED"] = "PAYMENT_RECEIVED";
|
|
1898
|
-
OrderApprovalStrategy2["PAYMENT_METHOD_SAVED"] = "PAYMENT_METHOD_SAVED";
|
|
1899
|
-
return OrderApprovalStrategy2;
|
|
1900
|
-
})(OrderApprovalStrategy || {});
|
|
1901
|
-
var DeltaPaymentOptionType = /* @__PURE__ */ ((DeltaPaymentOptionType2) => {
|
|
1902
|
-
DeltaPaymentOptionType2["UNKNOWN_PAYMENT_OPTION"] = "UNKNOWN_PAYMENT_OPTION";
|
|
1903
|
-
DeltaPaymentOptionType2["FULL_PAYMENT_OFFLINE"] = "FULL_PAYMENT_OFFLINE";
|
|
1904
|
-
DeltaPaymentOptionType2["MEMBERSHIP_OFFLINE"] = "MEMBERSHIP_OFFLINE";
|
|
1905
|
-
return DeltaPaymentOptionType2;
|
|
1906
|
-
})(DeltaPaymentOptionType || {});
|
|
1907
|
-
var InventoryAction = /* @__PURE__ */ ((InventoryAction2) => {
|
|
1908
|
-
InventoryAction2["RESTOCK"] = "RESTOCK";
|
|
1909
|
-
InventoryAction2["DECREASE"] = "DECREASE";
|
|
1910
|
-
return InventoryAction2;
|
|
1911
|
-
})(InventoryAction || {});
|
|
1912
|
-
var Placement = /* @__PURE__ */ ((Placement2) => {
|
|
1913
|
-
Placement2["Unknown"] = "Unknown";
|
|
1914
|
-
Placement2["Replace"] = "Replace";
|
|
1915
|
-
Placement2["Before"] = "Before";
|
|
1916
|
-
Placement2["After"] = "After";
|
|
1917
|
-
return Placement2;
|
|
1918
|
-
})(Placement || {});
|
|
1919
|
-
var SubdivisionType = /* @__PURE__ */ ((SubdivisionType2) => {
|
|
1920
|
-
SubdivisionType2["UNKNOWN_SUBDIVISION_TYPE"] = "UNKNOWN_SUBDIVISION_TYPE";
|
|
1921
|
-
SubdivisionType2["ADMINISTRATIVE_AREA_LEVEL_1"] = "ADMINISTRATIVE_AREA_LEVEL_1";
|
|
1922
|
-
SubdivisionType2["ADMINISTRATIVE_AREA_LEVEL_2"] = "ADMINISTRATIVE_AREA_LEVEL_2";
|
|
1923
|
-
SubdivisionType2["ADMINISTRATIVE_AREA_LEVEL_3"] = "ADMINISTRATIVE_AREA_LEVEL_3";
|
|
1924
|
-
SubdivisionType2["ADMINISTRATIVE_AREA_LEVEL_4"] = "ADMINISTRATIVE_AREA_LEVEL_4";
|
|
1925
|
-
SubdivisionType2["ADMINISTRATIVE_AREA_LEVEL_5"] = "ADMINISTRATIVE_AREA_LEVEL_5";
|
|
1926
|
-
SubdivisionType2["COUNTRY"] = "COUNTRY";
|
|
1927
|
-
return SubdivisionType2;
|
|
1928
|
-
})(SubdivisionType || {});
|
|
1929
|
-
var SourceType = /* @__PURE__ */ ((SourceType2) => {
|
|
1930
|
-
SourceType2["UNKNOWN_SOURCE_TYPE"] = "UNKNOWN_SOURCE_TYPE";
|
|
1931
|
-
SourceType2["WIX_APP"] = "WIX_APP";
|
|
1932
|
-
SourceType2["EXTERNAL"] = "EXTERNAL";
|
|
1933
|
-
SourceType2["ADMIN"] = "ADMIN";
|
|
1934
|
-
SourceType2["OTHER"] = "OTHER";
|
|
1935
|
-
return SourceType2;
|
|
1936
|
-
})(SourceType || {});
|
|
1937
|
-
var CustomFieldGroup = /* @__PURE__ */ ((CustomFieldGroup2) => {
|
|
1938
|
-
CustomFieldGroup2["UNKNOWN_CUSTOM_FIELD_GROUP"] = "UNKNOWN_CUSTOM_FIELD_GROUP";
|
|
1939
|
-
CustomFieldGroup2["BUSINESS_DETAILS"] = "BUSINESS_DETAILS";
|
|
1940
|
-
CustomFieldGroup2["CUSTOMER_DETAILS"] = "CUSTOMER_DETAILS";
|
|
1941
|
-
CustomFieldGroup2["DOCUMENT"] = "DOCUMENT";
|
|
1942
|
-
CustomFieldGroup2["FOOTER"] = "FOOTER";
|
|
1943
|
-
CustomFieldGroup2["OTHER"] = "OTHER";
|
|
1944
|
-
return CustomFieldGroup2;
|
|
1945
|
-
})(CustomFieldGroup || {});
|
|
1946
|
-
var ValueType = /* @__PURE__ */ ((ValueType2) => {
|
|
1947
|
-
ValueType2["UNKNOWN_VALUE_TYPE"] = "UNKNOWN_VALUE_TYPE";
|
|
1948
|
-
ValueType2["STRING"] = "STRING";
|
|
1949
|
-
ValueType2["DATE"] = "DATE";
|
|
1950
|
-
ValueType2["BOOLEAN"] = "BOOLEAN";
|
|
1951
|
-
ValueType2["NUMBER"] = "NUMBER";
|
|
1952
|
-
return ValueType2;
|
|
1953
|
-
})(ValueType || {});
|
|
1954
|
-
var DepositType = /* @__PURE__ */ ((DepositType2) => {
|
|
1955
|
-
DepositType2["UNKNOWN"] = "UNKNOWN";
|
|
1956
|
-
DepositType2["FLAT"] = "FLAT";
|
|
1957
|
-
DepositType2["PERCENTAGE"] = "PERCENTAGE";
|
|
1958
|
-
return DepositType2;
|
|
1959
|
-
})(DepositType || {});
|
|
1960
|
-
var InvoiceStatus = /* @__PURE__ */ ((InvoiceStatus2) => {
|
|
1961
|
-
InvoiceStatus2["Draft"] = "Draft";
|
|
1962
|
-
InvoiceStatus2["Sent"] = "Sent";
|
|
1963
|
-
InvoiceStatus2["Processing"] = "Processing";
|
|
1964
|
-
InvoiceStatus2["Paid"] = "Paid";
|
|
1965
|
-
InvoiceStatus2["Overdue"] = "Overdue";
|
|
1966
|
-
InvoiceStatus2["Void"] = "Void";
|
|
1967
|
-
InvoiceStatus2["Deleted"] = "Deleted";
|
|
1968
|
-
InvoiceStatus2["PartiallyPaid"] = "PartiallyPaid";
|
|
1969
|
-
InvoiceStatus2["PartialAndOverdue"] = "PartialAndOverdue";
|
|
1970
|
-
return InvoiceStatus2;
|
|
1971
|
-
})(InvoiceStatus || {});
|
|
1972
|
-
async function preparePaymentCollection2(ecomOrderId, amount, options) {
|
|
1973
|
-
const { httpClient, sideEffects } = arguments[3];
|
|
1974
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
1975
|
-
ecomOrderId,
|
|
1976
|
-
amount,
|
|
1977
|
-
paymentGatewayOrderId: options?.paymentGatewayOrderId,
|
|
1978
|
-
delayedCapture: options?.delayedCapture,
|
|
1979
|
-
delayedCaptureSettings: options?.delayedCaptureSettings
|
|
1980
|
-
});
|
|
1981
|
-
const reqOpts = preparePaymentCollection(payload);
|
|
1982
|
-
sideEffects?.onSiteCall?.();
|
|
1983
|
-
try {
|
|
1984
|
-
const result = await httpClient.request(reqOpts);
|
|
1985
|
-
sideEffects?.onSuccess?.(result);
|
|
1986
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
1987
|
-
} catch (err) {
|
|
1988
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
1989
|
-
err,
|
|
1990
|
-
{
|
|
1991
|
-
spreadPathsToArguments: {},
|
|
1992
|
-
explicitPathsToArguments: {
|
|
1993
|
-
ecomOrderId: "$[0]",
|
|
1994
|
-
amount: "$[1]",
|
|
1995
|
-
paymentGatewayOrderId: "$[2].paymentGatewayOrderId",
|
|
1996
|
-
delayedCapture: "$[2].delayedCapture",
|
|
1997
|
-
delayedCaptureSettings: "$[2].delayedCaptureSettings"
|
|
1998
|
-
},
|
|
1999
|
-
singleArgumentUnchanged: false
|
|
2000
|
-
},
|
|
2001
|
-
["ecomOrderId", "amount", "options"]
|
|
2002
|
-
);
|
|
2003
|
-
sideEffects?.onError?.(err);
|
|
2004
|
-
throw transformedError;
|
|
2005
|
-
}
|
|
2006
|
-
}
|
|
2007
|
-
async function getPaymentCollectabilityStatus2(ecomOrderId) {
|
|
2008
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2009
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2010
|
-
ecomOrderId
|
|
2011
|
-
});
|
|
2012
|
-
const reqOpts = getPaymentCollectabilityStatus(payload);
|
|
2013
|
-
sideEffects?.onSiteCall?.();
|
|
2014
|
-
try {
|
|
2015
|
-
const result = await httpClient.request(reqOpts);
|
|
2016
|
-
sideEffects?.onSuccess?.(result);
|
|
2017
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2018
|
-
} catch (err) {
|
|
2019
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2020
|
-
err,
|
|
2021
|
-
{
|
|
2022
|
-
spreadPathsToArguments: {},
|
|
2023
|
-
explicitPathsToArguments: { ecomOrderId: "$[0]" },
|
|
2024
|
-
singleArgumentUnchanged: false
|
|
2025
|
-
},
|
|
2026
|
-
["ecomOrderId"]
|
|
2027
|
-
);
|
|
2028
|
-
sideEffects?.onError?.(err);
|
|
2029
|
-
throw transformedError;
|
|
2030
|
-
}
|
|
2031
|
-
}
|
|
2032
|
-
async function recordManuallyCollectedPayment2(orderId, amount) {
|
|
2033
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2034
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2035
|
-
orderId,
|
|
2036
|
-
amount
|
|
2037
|
-
});
|
|
2038
|
-
const reqOpts = recordManuallyCollectedPayment(payload);
|
|
2039
|
-
sideEffects?.onSiteCall?.();
|
|
2040
|
-
try {
|
|
2041
|
-
const result = await httpClient.request(reqOpts);
|
|
2042
|
-
sideEffects?.onSuccess?.(result);
|
|
2043
|
-
} catch (err) {
|
|
2044
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2045
|
-
err,
|
|
2046
|
-
{
|
|
2047
|
-
spreadPathsToArguments: {},
|
|
2048
|
-
explicitPathsToArguments: { orderId: "$[0]", amount: "$[1]" },
|
|
2049
|
-
singleArgumentUnchanged: false
|
|
2050
|
-
},
|
|
2051
|
-
["orderId", "amount"]
|
|
2052
|
-
);
|
|
2053
|
-
sideEffects?.onError?.(err);
|
|
2054
|
-
throw transformedError;
|
|
2055
|
-
}
|
|
2056
|
-
}
|
|
2057
|
-
async function paymentCollectionMarkOrderAsPaid2(ecomOrderId) {
|
|
2058
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2059
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2060
|
-
ecomOrderId
|
|
2061
|
-
});
|
|
2062
|
-
const reqOpts = paymentCollectionMarkOrderAsPaid(payload);
|
|
2063
|
-
sideEffects?.onSiteCall?.();
|
|
2064
|
-
try {
|
|
2065
|
-
const result = await httpClient.request(reqOpts);
|
|
2066
|
-
sideEffects?.onSuccess?.(result);
|
|
2067
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2068
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2069
|
-
{
|
|
2070
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2071
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2072
|
-
},
|
|
2073
|
-
{
|
|
2074
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2075
|
-
paths: [
|
|
2076
|
-
{ path: "order.billingInfo.address" },
|
|
2077
|
-
{
|
|
2078
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2079
|
-
},
|
|
2080
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2081
|
-
{ path: "order.recipientInfo.address" }
|
|
2082
|
-
]
|
|
2083
|
-
}
|
|
2084
|
-
])
|
|
2085
|
-
);
|
|
2086
|
-
} catch (err) {
|
|
2087
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2088
|
-
err,
|
|
2089
|
-
{
|
|
2090
|
-
spreadPathsToArguments: {},
|
|
2091
|
-
explicitPathsToArguments: { ecomOrderId: "$[0]" },
|
|
2092
|
-
singleArgumentUnchanged: false
|
|
2093
|
-
},
|
|
2094
|
-
["ecomOrderId"]
|
|
2095
|
-
);
|
|
2096
|
-
sideEffects?.onError?.(err);
|
|
2097
|
-
throw transformedError;
|
|
2098
|
-
}
|
|
2099
|
-
}
|
|
2100
|
-
async function paymentCollectionBulkMarkOrdersAsPaid2(ecomOrderIds) {
|
|
2101
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2102
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2103
|
-
ecomOrderIds
|
|
2104
|
-
});
|
|
2105
|
-
const reqOpts = paymentCollectionBulkMarkOrdersAsPaid(payload);
|
|
2106
|
-
sideEffects?.onSiteCall?.();
|
|
2107
|
-
try {
|
|
2108
|
-
const result = await httpClient.request(reqOpts);
|
|
2109
|
-
sideEffects?.onSuccess?.(result);
|
|
2110
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2111
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2112
|
-
{
|
|
2113
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2114
|
-
paths: [{ path: "results.item.lineItems.image" }]
|
|
2115
|
-
},
|
|
2116
|
-
{
|
|
2117
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2118
|
-
paths: [
|
|
2119
|
-
{ path: "results.item.billingInfo.address" },
|
|
2120
|
-
{
|
|
2121
|
-
path: "results.item.shippingInfo.logistics.shippingDestination.address"
|
|
2122
|
-
},
|
|
2123
|
-
{
|
|
2124
|
-
path: "results.item.shippingInfo.logistics.pickupDetails.address"
|
|
2125
|
-
},
|
|
2126
|
-
{ path: "results.item.recipientInfo.address" }
|
|
2127
|
-
]
|
|
2128
|
-
}
|
|
2129
|
-
])
|
|
2130
|
-
);
|
|
2131
|
-
} catch (err) {
|
|
2132
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2133
|
-
err,
|
|
2134
|
-
{
|
|
2135
|
-
spreadPathsToArguments: {},
|
|
2136
|
-
explicitPathsToArguments: { ecomOrderIds: "$[0]" },
|
|
2137
|
-
singleArgumentUnchanged: false
|
|
2138
|
-
},
|
|
2139
|
-
["ecomOrderIds"]
|
|
2140
|
-
);
|
|
2141
|
-
sideEffects?.onError?.(err);
|
|
2142
|
-
throw transformedError;
|
|
2143
|
-
}
|
|
2144
|
-
}
|
|
2145
|
-
async function getRefundabilityStatus2(ecomOrderId) {
|
|
2146
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2147
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2148
|
-
ecomOrderId
|
|
2149
|
-
});
|
|
2150
|
-
const reqOpts = getRefundabilityStatus(payload);
|
|
2151
|
-
sideEffects?.onSiteCall?.();
|
|
2152
|
-
try {
|
|
2153
|
-
const result = await httpClient.request(reqOpts);
|
|
2154
|
-
sideEffects?.onSuccess?.(result);
|
|
2155
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2156
|
-
} catch (err) {
|
|
2157
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2158
|
-
err,
|
|
2159
|
-
{
|
|
2160
|
-
spreadPathsToArguments: {},
|
|
2161
|
-
explicitPathsToArguments: { ecomOrderId: "$[0]" },
|
|
2162
|
-
singleArgumentUnchanged: false
|
|
2163
|
-
},
|
|
2164
|
-
["ecomOrderId"]
|
|
2165
|
-
);
|
|
2166
|
-
sideEffects?.onError?.(err);
|
|
2167
|
-
throw transformedError;
|
|
2168
|
-
}
|
|
2169
|
-
}
|
|
2170
|
-
async function paymentCollectionCreatePaymentGatewayOrder2(ecomOrderId, options) {
|
|
2171
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2172
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2173
|
-
ecomOrderId,
|
|
2174
|
-
chargedBy: options?.chargedBy
|
|
2175
|
-
});
|
|
2176
|
-
const reqOpts = paymentCollectionCreatePaymentGatewayOrder(
|
|
2177
|
-
payload
|
|
2178
|
-
);
|
|
2179
|
-
sideEffects?.onSiteCall?.();
|
|
2180
|
-
try {
|
|
2181
|
-
const result = await httpClient.request(reqOpts);
|
|
2182
|
-
sideEffects?.onSuccess?.(result);
|
|
2183
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2184
|
-
} catch (err) {
|
|
2185
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2186
|
-
err,
|
|
2187
|
-
{
|
|
2188
|
-
spreadPathsToArguments: {},
|
|
2189
|
-
explicitPathsToArguments: {
|
|
2190
|
-
ecomOrderId: "$[0]",
|
|
2191
|
-
chargedBy: "$[1].chargedBy"
|
|
2192
|
-
},
|
|
2193
|
-
singleArgumentUnchanged: false
|
|
2194
|
-
},
|
|
2195
|
-
["ecomOrderId", "options"]
|
|
2196
|
-
);
|
|
2197
|
-
sideEffects?.onError?.(err);
|
|
2198
|
-
throw transformedError;
|
|
2199
|
-
}
|
|
2200
|
-
}
|
|
2201
|
-
async function chargeMemberships2(ecomOrderId, memberId, options) {
|
|
2202
|
-
const { httpClient, sideEffects } = arguments[3];
|
|
2203
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2204
|
-
ecomOrderId,
|
|
2205
|
-
memberId,
|
|
2206
|
-
membershipCharges: options?.membershipCharges
|
|
2207
|
-
});
|
|
2208
|
-
const reqOpts = chargeMemberships(payload);
|
|
2209
|
-
sideEffects?.onSiteCall?.();
|
|
2210
|
-
try {
|
|
2211
|
-
const result = await httpClient.request(reqOpts);
|
|
2212
|
-
sideEffects?.onSuccess?.(result);
|
|
2213
|
-
} catch (err) {
|
|
2214
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2215
|
-
err,
|
|
2216
|
-
{
|
|
2217
|
-
spreadPathsToArguments: {},
|
|
2218
|
-
explicitPathsToArguments: {
|
|
2219
|
-
ecomOrderId: "$[0]",
|
|
2220
|
-
memberId: "$[1]",
|
|
2221
|
-
membershipCharges: "$[2].membershipCharges"
|
|
2222
|
-
},
|
|
2223
|
-
singleArgumentUnchanged: false
|
|
2224
|
-
},
|
|
2225
|
-
["ecomOrderId", "memberId", "options"]
|
|
2226
|
-
);
|
|
2227
|
-
sideEffects?.onError?.(err);
|
|
2228
|
-
throw transformedError;
|
|
2229
|
-
}
|
|
2230
|
-
}
|
|
2231
|
-
async function triggerRefund2(ecomOrderId, payments, options) {
|
|
2232
|
-
const { httpClient, sideEffects } = arguments[3];
|
|
2233
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2234
|
-
ecomOrderId,
|
|
2235
|
-
payments,
|
|
2236
|
-
details: options?.details,
|
|
2237
|
-
sideEffects: options?.sideEffects
|
|
2238
|
-
});
|
|
2239
|
-
const reqOpts = triggerRefund(payload);
|
|
2240
|
-
sideEffects?.onSiteCall?.();
|
|
2241
|
-
try {
|
|
2242
|
-
const result = await httpClient.request(reqOpts);
|
|
2243
|
-
sideEffects?.onSuccess?.(result);
|
|
2244
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2245
|
-
} catch (err) {
|
|
2246
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2247
|
-
err,
|
|
2248
|
-
{
|
|
2249
|
-
spreadPathsToArguments: {},
|
|
2250
|
-
explicitPathsToArguments: {
|
|
2251
|
-
ecomOrderId: "$[0]",
|
|
2252
|
-
payments: "$[1]",
|
|
2253
|
-
details: "$[2].details",
|
|
2254
|
-
sideEffects: "$[2].sideEffects"
|
|
2255
|
-
},
|
|
2256
|
-
singleArgumentUnchanged: false
|
|
2257
|
-
},
|
|
2258
|
-
["ecomOrderId", "payments", "options"]
|
|
2259
|
-
);
|
|
2260
|
-
sideEffects?.onError?.(err);
|
|
2261
|
-
throw transformedError;
|
|
2262
|
-
}
|
|
2263
|
-
}
|
|
2264
|
-
async function voidAuthorizedPayments2(ecomOrderId, paymentIds) {
|
|
2265
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2266
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2267
|
-
ecomOrderId,
|
|
2268
|
-
paymentIds
|
|
2269
|
-
});
|
|
2270
|
-
const reqOpts = voidAuthorizedPayments(payload);
|
|
2271
|
-
sideEffects?.onSiteCall?.();
|
|
2272
|
-
try {
|
|
2273
|
-
const result = await httpClient.request(reqOpts);
|
|
2274
|
-
sideEffects?.onSuccess?.(result);
|
|
2275
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2276
|
-
} catch (err) {
|
|
2277
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2278
|
-
err,
|
|
2279
|
-
{
|
|
2280
|
-
spreadPathsToArguments: {},
|
|
2281
|
-
explicitPathsToArguments: { ecomOrderId: "$[0]", paymentIds: "$[1]" },
|
|
2282
|
-
singleArgumentUnchanged: false
|
|
2283
|
-
},
|
|
2284
|
-
["ecomOrderId", "paymentIds"]
|
|
2285
|
-
);
|
|
2286
|
-
sideEffects?.onError?.(err);
|
|
2287
|
-
throw transformedError;
|
|
2288
|
-
}
|
|
2289
|
-
}
|
|
2290
|
-
async function captureAuthorizedPayments2(ecomOrderId, payments) {
|
|
2291
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2292
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2293
|
-
ecomOrderId,
|
|
2294
|
-
payments
|
|
2295
|
-
});
|
|
2296
|
-
const reqOpts = captureAuthorizedPayments(payload);
|
|
2297
|
-
sideEffects?.onSiteCall?.();
|
|
2298
|
-
try {
|
|
2299
|
-
const result = await httpClient.request(reqOpts);
|
|
2300
|
-
sideEffects?.onSuccess?.(result);
|
|
2301
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2302
|
-
} catch (err) {
|
|
2303
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2304
|
-
err,
|
|
2305
|
-
{
|
|
2306
|
-
spreadPathsToArguments: {},
|
|
2307
|
-
explicitPathsToArguments: { ecomOrderId: "$[0]", payments: "$[1]" },
|
|
2308
|
-
singleArgumentUnchanged: false
|
|
2309
|
-
},
|
|
2310
|
-
["ecomOrderId", "payments"]
|
|
2311
|
-
);
|
|
2312
|
-
sideEffects?.onError?.(err);
|
|
2313
|
-
throw transformedError;
|
|
2314
|
-
}
|
|
2315
|
-
}
|
|
2316
|
-
async function getOrder2(_id) {
|
|
2317
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2318
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ id: _id });
|
|
2319
|
-
const reqOpts = getOrder(payload);
|
|
2320
|
-
sideEffects?.onSiteCall?.();
|
|
2321
|
-
try {
|
|
2322
|
-
const result = await httpClient.request(reqOpts);
|
|
2323
|
-
sideEffects?.onSuccess?.(result);
|
|
2324
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2325
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2326
|
-
{
|
|
2327
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2328
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2329
|
-
},
|
|
2330
|
-
{
|
|
2331
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2332
|
-
paths: [
|
|
2333
|
-
{ path: "order.billingInfo.address" },
|
|
2334
|
-
{
|
|
2335
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2336
|
-
},
|
|
2337
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2338
|
-
{ path: "order.recipientInfo.address" }
|
|
2339
|
-
]
|
|
2340
|
-
}
|
|
2341
|
-
])
|
|
2342
|
-
)?.order;
|
|
2343
|
-
} catch (err) {
|
|
2344
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2345
|
-
err,
|
|
2346
|
-
{
|
|
2347
|
-
spreadPathsToArguments: {},
|
|
2348
|
-
explicitPathsToArguments: { id: "$[0]" },
|
|
2349
|
-
singleArgumentUnchanged: false
|
|
2350
|
-
},
|
|
2351
|
-
["_id"]
|
|
2352
|
-
);
|
|
2353
|
-
sideEffects?.onError?.(err);
|
|
2354
|
-
throw transformedError;
|
|
2355
|
-
}
|
|
2356
|
-
}
|
|
2357
|
-
async function searchOrders2(options) {
|
|
2358
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2359
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2360
|
-
search: options?.search
|
|
2361
|
-
});
|
|
2362
|
-
const reqOpts = searchOrders(payload);
|
|
2363
|
-
sideEffects?.onSiteCall?.();
|
|
2364
|
-
try {
|
|
2365
|
-
const result = await httpClient.request(reqOpts);
|
|
2366
|
-
sideEffects?.onSuccess?.(result);
|
|
2367
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2368
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2369
|
-
{
|
|
2370
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2371
|
-
paths: [{ path: "orders.lineItems.image" }]
|
|
2372
|
-
},
|
|
2373
|
-
{
|
|
2374
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2375
|
-
paths: [
|
|
2376
|
-
{ path: "orders.billingInfo.address" },
|
|
2377
|
-
{
|
|
2378
|
-
path: "orders.shippingInfo.logistics.shippingDestination.address"
|
|
2379
|
-
},
|
|
2380
|
-
{ path: "orders.shippingInfo.logistics.pickupDetails.address" },
|
|
2381
|
-
{ path: "orders.recipientInfo.address" }
|
|
2382
|
-
]
|
|
2383
|
-
}
|
|
2384
|
-
])
|
|
2385
|
-
);
|
|
2386
|
-
} catch (err) {
|
|
2387
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2388
|
-
err,
|
|
2389
|
-
{
|
|
2390
|
-
spreadPathsToArguments: {},
|
|
2391
|
-
explicitPathsToArguments: { search: "$[0].search" },
|
|
2392
|
-
singleArgumentUnchanged: false
|
|
2393
|
-
},
|
|
2394
|
-
["options"]
|
|
2395
|
-
);
|
|
2396
|
-
sideEffects?.onError?.(err);
|
|
2397
|
-
throw transformedError;
|
|
2398
|
-
}
|
|
2399
|
-
}
|
|
2400
|
-
async function createOrder2(order, options) {
|
|
2401
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2402
|
-
const payload = (0, import_transform_paths2.transformPaths)(
|
|
2403
|
-
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2404
|
-
order,
|
|
2405
|
-
settings: options?.settings
|
|
2406
|
-
}),
|
|
2407
|
-
[
|
|
2408
|
-
{
|
|
2409
|
-
transformFn: import_image.transformSDKImageToRESTImage,
|
|
2410
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2411
|
-
},
|
|
2412
|
-
{
|
|
2413
|
-
transformFn: import_address.transformSDKAddressToRESTAddress,
|
|
2414
|
-
paths: [
|
|
2415
|
-
{ path: "order.billingInfo.address" },
|
|
2416
|
-
{ path: "order.shippingInfo.logistics.shippingDestination.address" },
|
|
2417
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2418
|
-
{ path: "order.recipientInfo.address" }
|
|
2419
|
-
]
|
|
2420
|
-
}
|
|
2421
|
-
]
|
|
2422
|
-
);
|
|
2423
|
-
const reqOpts = createOrder(payload);
|
|
2424
|
-
sideEffects?.onSiteCall?.();
|
|
2425
|
-
try {
|
|
2426
|
-
const result = await httpClient.request(reqOpts);
|
|
2427
|
-
sideEffects?.onSuccess?.(result);
|
|
2428
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2429
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2430
|
-
{
|
|
2431
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2432
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2433
|
-
},
|
|
2434
|
-
{
|
|
2435
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2436
|
-
paths: [
|
|
2437
|
-
{ path: "order.billingInfo.address" },
|
|
2438
|
-
{
|
|
2439
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2440
|
-
},
|
|
2441
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2442
|
-
{ path: "order.recipientInfo.address" }
|
|
2443
|
-
]
|
|
2444
|
-
}
|
|
2445
|
-
])
|
|
2446
|
-
)?.order;
|
|
2447
|
-
} catch (err) {
|
|
2448
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2449
|
-
err,
|
|
2450
|
-
{
|
|
2451
|
-
spreadPathsToArguments: {},
|
|
2452
|
-
explicitPathsToArguments: { order: "$[0]", settings: "$[1].settings" },
|
|
2453
|
-
singleArgumentUnchanged: false
|
|
2454
|
-
},
|
|
2455
|
-
["order", "options"]
|
|
2456
|
-
);
|
|
2457
|
-
sideEffects?.onError?.(err);
|
|
2458
|
-
throw transformedError;
|
|
2459
|
-
}
|
|
2460
|
-
}
|
|
2461
|
-
async function updateOrder2(_id, order) {
|
|
2462
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2463
|
-
const payload = (0, import_transform_paths2.transformPaths)(
|
|
2464
|
-
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ order: { ...order, id: _id } }),
|
|
2465
|
-
[
|
|
2466
|
-
{
|
|
2467
|
-
transformFn: import_image.transformSDKImageToRESTImage,
|
|
2468
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2469
|
-
},
|
|
2470
|
-
{
|
|
2471
|
-
transformFn: import_address.transformSDKAddressToRESTAddress,
|
|
2472
|
-
paths: [
|
|
2473
|
-
{ path: "order.billingInfo.address" },
|
|
2474
|
-
{ path: "order.shippingInfo.logistics.shippingDestination.address" },
|
|
2475
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2476
|
-
{ path: "order.recipientInfo.address" }
|
|
2477
|
-
]
|
|
2478
|
-
}
|
|
2479
|
-
]
|
|
2480
|
-
);
|
|
2481
|
-
const reqOpts = updateOrder(payload);
|
|
2482
|
-
sideEffects?.onSiteCall?.();
|
|
2483
|
-
try {
|
|
2484
|
-
const result = await httpClient.request(reqOpts);
|
|
2485
|
-
sideEffects?.onSuccess?.(result);
|
|
2486
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2487
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2488
|
-
{
|
|
2489
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2490
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2491
|
-
},
|
|
2492
|
-
{
|
|
2493
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2494
|
-
paths: [
|
|
2495
|
-
{ path: "order.billingInfo.address" },
|
|
2496
|
-
{
|
|
2497
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2498
|
-
},
|
|
2499
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2500
|
-
{ path: "order.recipientInfo.address" }
|
|
2501
|
-
]
|
|
2502
|
-
}
|
|
2503
|
-
])
|
|
2504
|
-
)?.order;
|
|
2505
|
-
} catch (err) {
|
|
2506
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2507
|
-
err,
|
|
2508
|
-
{
|
|
2509
|
-
spreadPathsToArguments: { order: "$[1]" },
|
|
2510
|
-
explicitPathsToArguments: { "order.id": "$[0]" },
|
|
2511
|
-
singleArgumentUnchanged: false
|
|
2512
|
-
},
|
|
2513
|
-
["_id", "order"]
|
|
2514
|
-
);
|
|
2515
|
-
sideEffects?.onError?.(err);
|
|
2516
|
-
throw transformedError;
|
|
2517
|
-
}
|
|
2518
|
-
}
|
|
2519
|
-
async function bulkUpdateOrders2(orders, options) {
|
|
2520
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2521
|
-
const payload = (0, import_transform_paths2.transformPaths)(
|
|
2522
|
-
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2523
|
-
orders,
|
|
2524
|
-
returnEntity: options?.returnEntity
|
|
2525
|
-
}),
|
|
2526
|
-
[
|
|
2527
|
-
{
|
|
2528
|
-
transformFn: import_image.transformSDKImageToRESTImage,
|
|
2529
|
-
paths: [{ path: "orders.order.lineItems.image" }]
|
|
2530
|
-
},
|
|
2531
|
-
{
|
|
2532
|
-
transformFn: import_address.transformSDKAddressToRESTAddress,
|
|
2533
|
-
paths: [
|
|
2534
|
-
{ path: "orders.order.billingInfo.address" },
|
|
2535
|
-
{
|
|
2536
|
-
path: "orders.order.shippingInfo.logistics.shippingDestination.address"
|
|
2537
|
-
},
|
|
2538
|
-
{ path: "orders.order.shippingInfo.logistics.pickupDetails.address" },
|
|
2539
|
-
{ path: "orders.order.recipientInfo.address" }
|
|
2540
|
-
]
|
|
2541
|
-
}
|
|
2542
|
-
]
|
|
2543
|
-
);
|
|
2544
|
-
const reqOpts = bulkUpdateOrders(payload);
|
|
2545
|
-
sideEffects?.onSiteCall?.();
|
|
2546
|
-
try {
|
|
2547
|
-
const result = await httpClient.request(reqOpts);
|
|
2548
|
-
sideEffects?.onSuccess?.(result);
|
|
2549
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2550
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2551
|
-
{
|
|
2552
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2553
|
-
paths: [{ path: "results.item.lineItems.image" }]
|
|
2554
|
-
},
|
|
2555
|
-
{
|
|
2556
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2557
|
-
paths: [
|
|
2558
|
-
{ path: "results.item.billingInfo.address" },
|
|
2559
|
-
{
|
|
2560
|
-
path: "results.item.shippingInfo.logistics.shippingDestination.address"
|
|
2561
|
-
},
|
|
2562
|
-
{
|
|
2563
|
-
path: "results.item.shippingInfo.logistics.pickupDetails.address"
|
|
2564
|
-
},
|
|
2565
|
-
{ path: "results.item.recipientInfo.address" }
|
|
2566
|
-
]
|
|
2567
|
-
}
|
|
2568
|
-
])
|
|
2569
|
-
);
|
|
2570
|
-
} catch (err) {
|
|
2571
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2572
|
-
err,
|
|
2573
|
-
{
|
|
2574
|
-
spreadPathsToArguments: {},
|
|
2575
|
-
explicitPathsToArguments: {
|
|
2576
|
-
orders: "$[0]",
|
|
2577
|
-
returnEntity: "$[1].returnEntity"
|
|
2578
|
-
},
|
|
2579
|
-
singleArgumentUnchanged: false
|
|
2580
|
-
},
|
|
2581
|
-
["orders", "options"]
|
|
2582
|
-
);
|
|
2583
|
-
sideEffects?.onError?.(err);
|
|
2584
|
-
throw transformedError;
|
|
2585
|
-
}
|
|
2586
|
-
}
|
|
2587
|
-
async function commitDeltas2(_id, options) {
|
|
2588
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2589
|
-
const payload = (0, import_transform_paths2.transformPaths)(
|
|
2590
|
-
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2591
|
-
id: _id,
|
|
2592
|
-
draftOrderId: options?.draftOrderId,
|
|
2593
|
-
changes: options?.changes,
|
|
2594
|
-
commitSettings: options?.commitSettings,
|
|
2595
|
-
reason: options?.reason
|
|
2596
|
-
}),
|
|
2597
|
-
[
|
|
2598
|
-
{
|
|
2599
|
-
transformFn: import_address.transformSDKAddressToRESTAddress,
|
|
2600
|
-
paths: [
|
|
2601
|
-
{
|
|
2602
|
-
path: "changes.changedShippingInfo.logistics.shippingDestination.address"
|
|
2603
|
-
},
|
|
2604
|
-
{
|
|
2605
|
-
path: "changes.changedShippingInfo.logistics.pickupDetails.address"
|
|
2606
|
-
},
|
|
2607
|
-
{ path: "changes.changedBillingInfo.address" },
|
|
2608
|
-
{ path: "changes.changedRecipientInfo.address" }
|
|
2609
|
-
]
|
|
2610
|
-
},
|
|
2611
|
-
{
|
|
2612
|
-
transformFn: import_image.transformSDKImageToRESTImage,
|
|
2613
|
-
paths: [{ path: "changes.lineItems.lineItem.image" }]
|
|
2614
|
-
}
|
|
2615
|
-
]
|
|
2616
|
-
);
|
|
2617
|
-
const reqOpts = commitDeltas(payload);
|
|
2618
|
-
sideEffects?.onSiteCall?.();
|
|
2619
|
-
try {
|
|
2620
|
-
const result = await httpClient.request(reqOpts);
|
|
2621
|
-
sideEffects?.onSuccess?.(result);
|
|
2622
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2623
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2624
|
-
{
|
|
2625
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2626
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2627
|
-
},
|
|
2628
|
-
{
|
|
2629
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2630
|
-
paths: [
|
|
2631
|
-
{ path: "order.billingInfo.address" },
|
|
2632
|
-
{
|
|
2633
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2634
|
-
},
|
|
2635
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2636
|
-
{ path: "order.recipientInfo.address" }
|
|
2637
|
-
]
|
|
2638
|
-
}
|
|
2639
|
-
])
|
|
2640
|
-
);
|
|
2641
|
-
} catch (err) {
|
|
2642
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2643
|
-
err,
|
|
2644
|
-
{
|
|
2645
|
-
spreadPathsToArguments: {},
|
|
2646
|
-
explicitPathsToArguments: {
|
|
2647
|
-
id: "$[0]",
|
|
2648
|
-
draftOrderId: "$[1].draftOrderId",
|
|
2649
|
-
changes: "$[1].changes",
|
|
2650
|
-
commitSettings: "$[1].commitSettings",
|
|
2651
|
-
reason: "$[1].reason"
|
|
2652
|
-
},
|
|
2653
|
-
singleArgumentUnchanged: false
|
|
2654
|
-
},
|
|
2655
|
-
["_id", "options"]
|
|
2656
|
-
);
|
|
2657
|
-
sideEffects?.onError?.(err);
|
|
2658
|
-
throw transformedError;
|
|
2659
|
-
}
|
|
2660
|
-
}
|
|
2661
|
-
async function updateOrderLineItem2(identifiers, lineItem) {
|
|
2662
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2663
|
-
const payload = (0, import_transform_paths2.transformPaths)(
|
|
2664
|
-
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2665
|
-
id: identifiers?._id,
|
|
2666
|
-
lineItem: { ...lineItem, id: identifiers?.lineItemId }
|
|
2667
|
-
}),
|
|
2668
|
-
[
|
|
2669
|
-
{
|
|
2670
|
-
transformFn: import_image.transformSDKImageToRESTImage,
|
|
2671
|
-
paths: [{ path: "lineItem.image" }]
|
|
2672
|
-
}
|
|
2673
|
-
]
|
|
2674
|
-
);
|
|
2675
|
-
const reqOpts = updateOrderLineItem(payload);
|
|
2676
|
-
sideEffects?.onSiteCall?.();
|
|
2677
|
-
try {
|
|
2678
|
-
const result = await httpClient.request(reqOpts);
|
|
2679
|
-
sideEffects?.onSuccess?.(result);
|
|
2680
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2681
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2682
|
-
{
|
|
2683
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2684
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2685
|
-
},
|
|
2686
|
-
{
|
|
2687
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2688
|
-
paths: [
|
|
2689
|
-
{ path: "order.billingInfo.address" },
|
|
2690
|
-
{
|
|
2691
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2692
|
-
},
|
|
2693
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2694
|
-
{ path: "order.recipientInfo.address" }
|
|
2695
|
-
]
|
|
2696
|
-
}
|
|
2697
|
-
])
|
|
2698
|
-
);
|
|
2699
|
-
} catch (err) {
|
|
2700
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2701
|
-
err,
|
|
2702
|
-
{
|
|
2703
|
-
spreadPathsToArguments: { lineItem: "$[1]" },
|
|
2704
|
-
explicitPathsToArguments: {
|
|
2705
|
-
id: "$[0]._id",
|
|
2706
|
-
"lineItem.id": "$[0].lineItemId"
|
|
2707
|
-
},
|
|
2708
|
-
singleArgumentUnchanged: false
|
|
2709
|
-
},
|
|
2710
|
-
["identifiers", "lineItem"]
|
|
2711
|
-
);
|
|
2712
|
-
sideEffects?.onError?.(err);
|
|
2713
|
-
throw transformedError;
|
|
2714
|
-
}
|
|
2715
|
-
}
|
|
2716
|
-
async function addActivity2(_id, activity) {
|
|
2717
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2718
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2719
|
-
id: _id,
|
|
2720
|
-
activity
|
|
2721
|
-
});
|
|
2722
|
-
const reqOpts = addActivity(payload);
|
|
2723
|
-
sideEffects?.onSiteCall?.();
|
|
2724
|
-
try {
|
|
2725
|
-
const result = await httpClient.request(reqOpts);
|
|
2726
|
-
sideEffects?.onSuccess?.(result);
|
|
2727
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2728
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2729
|
-
{
|
|
2730
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2731
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2732
|
-
},
|
|
2733
|
-
{
|
|
2734
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2735
|
-
paths: [
|
|
2736
|
-
{ path: "order.billingInfo.address" },
|
|
2737
|
-
{
|
|
2738
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2739
|
-
},
|
|
2740
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2741
|
-
{ path: "order.recipientInfo.address" }
|
|
2742
|
-
]
|
|
2743
|
-
}
|
|
2744
|
-
])
|
|
2745
|
-
);
|
|
2746
|
-
} catch (err) {
|
|
2747
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2748
|
-
err,
|
|
2749
|
-
{
|
|
2750
|
-
spreadPathsToArguments: {},
|
|
2751
|
-
explicitPathsToArguments: { id: "$[0]", activity: "$[1]" },
|
|
2752
|
-
singleArgumentUnchanged: false
|
|
2753
|
-
},
|
|
2754
|
-
["_id", "activity"]
|
|
2755
|
-
);
|
|
2756
|
-
sideEffects?.onError?.(err);
|
|
2757
|
-
throw transformedError;
|
|
2758
|
-
}
|
|
2759
|
-
}
|
|
2760
|
-
async function updateActivity2(identifiers, activity) {
|
|
2761
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2762
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2763
|
-
id: identifiers?._id,
|
|
2764
|
-
activityId: identifiers?.activityId,
|
|
2765
|
-
activity
|
|
2766
|
-
});
|
|
2767
|
-
const reqOpts = updateActivity(payload);
|
|
2768
|
-
sideEffects?.onSiteCall?.();
|
|
2769
|
-
try {
|
|
2770
|
-
const result = await httpClient.request(reqOpts);
|
|
2771
|
-
sideEffects?.onSuccess?.(result);
|
|
2772
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2773
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2774
|
-
{
|
|
2775
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2776
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2777
|
-
},
|
|
2778
|
-
{
|
|
2779
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2780
|
-
paths: [
|
|
2781
|
-
{ path: "order.billingInfo.address" },
|
|
2782
|
-
{
|
|
2783
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2784
|
-
},
|
|
2785
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2786
|
-
{ path: "order.recipientInfo.address" }
|
|
2787
|
-
]
|
|
2788
|
-
}
|
|
2789
|
-
])
|
|
2790
|
-
);
|
|
2791
|
-
} catch (err) {
|
|
2792
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2793
|
-
err,
|
|
2794
|
-
{
|
|
2795
|
-
spreadPathsToArguments: {},
|
|
2796
|
-
explicitPathsToArguments: {
|
|
2797
|
-
id: "$[0]._id",
|
|
2798
|
-
activityId: "$[0].activityId",
|
|
2799
|
-
activity: "$[1]"
|
|
2800
|
-
},
|
|
2801
|
-
singleArgumentUnchanged: false
|
|
2802
|
-
},
|
|
2803
|
-
["identifiers", "activity"]
|
|
2804
|
-
);
|
|
2805
|
-
sideEffects?.onError?.(err);
|
|
2806
|
-
throw transformedError;
|
|
2807
|
-
}
|
|
2808
|
-
}
|
|
2809
|
-
async function deleteActivity2(identifiers) {
|
|
2810
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2811
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2812
|
-
id: identifiers?._id,
|
|
2813
|
-
activityId: identifiers?.activityId
|
|
2814
|
-
});
|
|
2815
|
-
const reqOpts = deleteActivity(payload);
|
|
2816
|
-
sideEffects?.onSiteCall?.();
|
|
2817
|
-
try {
|
|
2818
|
-
const result = await httpClient.request(reqOpts);
|
|
2819
|
-
sideEffects?.onSuccess?.(result);
|
|
2820
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2821
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2822
|
-
{
|
|
2823
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2824
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2825
|
-
},
|
|
2826
|
-
{
|
|
2827
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2828
|
-
paths: [
|
|
2829
|
-
{ path: "order.billingInfo.address" },
|
|
2830
|
-
{
|
|
2831
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2832
|
-
},
|
|
2833
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2834
|
-
{ path: "order.recipientInfo.address" }
|
|
2835
|
-
]
|
|
2836
|
-
}
|
|
2837
|
-
])
|
|
2838
|
-
);
|
|
2839
|
-
} catch (err) {
|
|
2840
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2841
|
-
err,
|
|
2842
|
-
{
|
|
2843
|
-
spreadPathsToArguments: {},
|
|
2844
|
-
explicitPathsToArguments: {
|
|
2845
|
-
id: "$[0]._id",
|
|
2846
|
-
activityId: "$[0].activityId"
|
|
2847
|
-
},
|
|
2848
|
-
singleArgumentUnchanged: false
|
|
2849
|
-
},
|
|
2850
|
-
["identifiers"]
|
|
2851
|
-
);
|
|
2852
|
-
sideEffects?.onError?.(err);
|
|
2853
|
-
throw transformedError;
|
|
2854
|
-
}
|
|
2855
|
-
}
|
|
2856
|
-
async function cancelOrder2(_id, options) {
|
|
2857
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2858
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2859
|
-
id: _id,
|
|
2860
|
-
sendOrderCanceledEmail: options?.sendOrderCanceledEmail,
|
|
2861
|
-
customMessage: options?.customMessage,
|
|
2862
|
-
restockAllItems: options?.restockAllItems
|
|
2863
|
-
});
|
|
2864
|
-
const reqOpts = cancelOrder(payload);
|
|
2865
|
-
sideEffects?.onSiteCall?.();
|
|
2866
|
-
try {
|
|
2867
|
-
const result = await httpClient.request(reqOpts);
|
|
2868
|
-
sideEffects?.onSuccess?.(result);
|
|
2869
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2870
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2871
|
-
{
|
|
2872
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2873
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2874
|
-
},
|
|
2875
|
-
{
|
|
2876
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2877
|
-
paths: [
|
|
2878
|
-
{ path: "order.billingInfo.address" },
|
|
2879
|
-
{
|
|
2880
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2881
|
-
},
|
|
2882
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2883
|
-
{ path: "order.recipientInfo.address" }
|
|
2884
|
-
]
|
|
2885
|
-
}
|
|
2886
|
-
])
|
|
2887
|
-
);
|
|
2888
|
-
} catch (err) {
|
|
2889
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2890
|
-
err,
|
|
2891
|
-
{
|
|
2892
|
-
spreadPathsToArguments: {},
|
|
2893
|
-
explicitPathsToArguments: {
|
|
2894
|
-
id: "$[0]",
|
|
2895
|
-
sendOrderCanceledEmail: "$[1].sendOrderCanceledEmail",
|
|
2896
|
-
customMessage: "$[1].customMessage",
|
|
2897
|
-
restockAllItems: "$[1].restockAllItems"
|
|
2898
|
-
},
|
|
2899
|
-
singleArgumentUnchanged: false
|
|
2900
|
-
},
|
|
2901
|
-
["_id", "options"]
|
|
2902
|
-
);
|
|
2903
|
-
sideEffects?.onError?.(err);
|
|
2904
|
-
throw transformedError;
|
|
2905
|
-
}
|
|
2906
|
-
}
|
|
2907
|
-
async function updateOrderStatus2(orderId, status) {
|
|
2908
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2909
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2910
|
-
orderId,
|
|
2911
|
-
status
|
|
2912
|
-
});
|
|
2913
|
-
const reqOpts = updateOrderStatus(payload);
|
|
2914
|
-
sideEffects?.onSiteCall?.();
|
|
2915
|
-
try {
|
|
2916
|
-
const result = await httpClient.request(reqOpts);
|
|
2917
|
-
sideEffects?.onSuccess?.(result);
|
|
2918
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
|
2919
|
-
(0, import_transform_paths2.transformPaths)(result.data, [
|
|
2920
|
-
{
|
|
2921
|
-
transformFn: import_image2.transformRESTImageToSDKImage,
|
|
2922
|
-
paths: [{ path: "order.lineItems.image" }]
|
|
2923
|
-
},
|
|
2924
|
-
{
|
|
2925
|
-
transformFn: import_address2.transformRESTAddressToSDKAddress,
|
|
2926
|
-
paths: [
|
|
2927
|
-
{ path: "order.billingInfo.address" },
|
|
2928
|
-
{
|
|
2929
|
-
path: "order.shippingInfo.logistics.shippingDestination.address"
|
|
2930
|
-
},
|
|
2931
|
-
{ path: "order.shippingInfo.logistics.pickupDetails.address" },
|
|
2932
|
-
{ path: "order.recipientInfo.address" }
|
|
2933
|
-
]
|
|
2934
|
-
}
|
|
2935
|
-
])
|
|
2936
|
-
);
|
|
2937
|
-
} catch (err) {
|
|
2938
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2939
|
-
err,
|
|
2940
|
-
{
|
|
2941
|
-
spreadPathsToArguments: {},
|
|
2942
|
-
explicitPathsToArguments: { orderId: "$[0]", status: "$[1]" },
|
|
2943
|
-
singleArgumentUnchanged: false
|
|
2944
|
-
},
|
|
2945
|
-
["orderId", "status"]
|
|
2946
|
-
);
|
|
2947
|
-
sideEffects?.onError?.(err);
|
|
2948
|
-
throw transformedError;
|
|
2949
|
-
}
|
|
2950
|
-
}
|
|
2951
|
-
async function aggregateOrders2(options) {
|
|
2952
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
2953
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2954
|
-
filter: options?.filter,
|
|
2955
|
-
aggregation: options?.aggregation,
|
|
2956
|
-
hierarchySeparatorOverride: options?.hierarchySeparatorOverride
|
|
2957
|
-
});
|
|
2958
|
-
const reqOpts = aggregateOrders(payload);
|
|
2959
|
-
sideEffects?.onSiteCall?.();
|
|
2960
|
-
try {
|
|
2961
|
-
const result = await httpClient.request(reqOpts);
|
|
2962
|
-
sideEffects?.onSuccess?.(result);
|
|
2963
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2964
|
-
} catch (err) {
|
|
2965
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2966
|
-
err,
|
|
2967
|
-
{
|
|
2968
|
-
spreadPathsToArguments: {},
|
|
2969
|
-
explicitPathsToArguments: {
|
|
2970
|
-
filter: "$[0].filter",
|
|
2971
|
-
aggregation: "$[0].aggregation",
|
|
2972
|
-
hierarchySeparatorOverride: "$[0].hierarchySeparatorOverride"
|
|
2973
|
-
},
|
|
2974
|
-
singleArgumentUnchanged: false
|
|
2975
|
-
},
|
|
2976
|
-
["options"]
|
|
2977
|
-
);
|
|
2978
|
-
sideEffects?.onError?.(err);
|
|
2979
|
-
throw transformedError;
|
|
2980
|
-
}
|
|
2981
|
-
}
|
|
2982
|
-
async function bulkUpdateOrderTags2(orderIds, options) {
|
|
2983
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
2984
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
2985
|
-
orderIds,
|
|
2986
|
-
assignTags: options?.assignTags,
|
|
2987
|
-
unassignTags: options?.unassignTags
|
|
2988
|
-
});
|
|
2989
|
-
const reqOpts = bulkUpdateOrderTags(payload);
|
|
2990
|
-
sideEffects?.onSiteCall?.();
|
|
2991
|
-
try {
|
|
2992
|
-
const result = await httpClient.request(reqOpts);
|
|
2993
|
-
sideEffects?.onSuccess?.(result);
|
|
2994
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
2995
|
-
} catch (err) {
|
|
2996
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
2997
|
-
err,
|
|
2998
|
-
{
|
|
2999
|
-
spreadPathsToArguments: {},
|
|
3000
|
-
explicitPathsToArguments: {
|
|
3001
|
-
orderIds: "$[0]",
|
|
3002
|
-
assignTags: "$[1].assignTags",
|
|
3003
|
-
unassignTags: "$[1].unassignTags"
|
|
3004
|
-
},
|
|
3005
|
-
singleArgumentUnchanged: false
|
|
3006
|
-
},
|
|
3007
|
-
["orderIds", "options"]
|
|
3008
|
-
);
|
|
3009
|
-
sideEffects?.onError?.(err);
|
|
3010
|
-
throw transformedError;
|
|
3011
|
-
}
|
|
3012
|
-
}
|
|
3013
|
-
|
|
3014
|
-
// src/ecom-v1-order-orders.public.ts
|
|
3015
|
-
function preparePaymentCollection3(httpClient) {
|
|
3016
|
-
return (ecomOrderId, amount, options) => preparePaymentCollection2(
|
|
3017
|
-
ecomOrderId,
|
|
3018
|
-
amount,
|
|
3019
|
-
options,
|
|
3020
|
-
// @ts-ignore
|
|
3021
|
-
{ httpClient }
|
|
3022
|
-
);
|
|
3023
|
-
}
|
|
3024
|
-
function getPaymentCollectabilityStatus3(httpClient) {
|
|
3025
|
-
return (ecomOrderId) => getPaymentCollectabilityStatus2(
|
|
3026
|
-
ecomOrderId,
|
|
3027
|
-
// @ts-ignore
|
|
3028
|
-
{ httpClient }
|
|
3029
|
-
);
|
|
3030
|
-
}
|
|
3031
|
-
function recordManuallyCollectedPayment3(httpClient) {
|
|
3032
|
-
return (orderId, amount) => recordManuallyCollectedPayment2(
|
|
3033
|
-
orderId,
|
|
3034
|
-
amount,
|
|
3035
|
-
// @ts-ignore
|
|
3036
|
-
{ httpClient }
|
|
3037
|
-
);
|
|
3038
|
-
}
|
|
3039
|
-
function paymentCollectionMarkOrderAsPaid3(httpClient) {
|
|
3040
|
-
return (ecomOrderId) => paymentCollectionMarkOrderAsPaid2(
|
|
3041
|
-
ecomOrderId,
|
|
3042
|
-
// @ts-ignore
|
|
3043
|
-
{ httpClient }
|
|
3044
|
-
);
|
|
3045
|
-
}
|
|
3046
|
-
function paymentCollectionBulkMarkOrdersAsPaid3(httpClient) {
|
|
3047
|
-
return (ecomOrderIds) => paymentCollectionBulkMarkOrdersAsPaid2(
|
|
3048
|
-
ecomOrderIds,
|
|
3049
|
-
// @ts-ignore
|
|
3050
|
-
{ httpClient }
|
|
3051
|
-
);
|
|
3052
|
-
}
|
|
3053
|
-
function getRefundabilityStatus3(httpClient) {
|
|
3054
|
-
return (ecomOrderId) => getRefundabilityStatus2(
|
|
3055
|
-
ecomOrderId,
|
|
3056
|
-
// @ts-ignore
|
|
3057
|
-
{ httpClient }
|
|
3058
|
-
);
|
|
3059
|
-
}
|
|
3060
|
-
function paymentCollectionCreatePaymentGatewayOrder3(httpClient) {
|
|
3061
|
-
return (ecomOrderId, options) => paymentCollectionCreatePaymentGatewayOrder2(
|
|
3062
|
-
ecomOrderId,
|
|
3063
|
-
options,
|
|
3064
|
-
// @ts-ignore
|
|
3065
|
-
{ httpClient }
|
|
3066
|
-
);
|
|
3067
|
-
}
|
|
3068
|
-
function chargeMemberships3(httpClient) {
|
|
3069
|
-
return (ecomOrderId, memberId, options) => chargeMemberships2(
|
|
3070
|
-
ecomOrderId,
|
|
3071
|
-
memberId,
|
|
3072
|
-
options,
|
|
3073
|
-
// @ts-ignore
|
|
3074
|
-
{ httpClient }
|
|
3075
|
-
);
|
|
3076
|
-
}
|
|
3077
|
-
function triggerRefund3(httpClient) {
|
|
3078
|
-
return (ecomOrderId, payments, options) => triggerRefund2(
|
|
3079
|
-
ecomOrderId,
|
|
3080
|
-
payments,
|
|
3081
|
-
options,
|
|
3082
|
-
// @ts-ignore
|
|
3083
|
-
{ httpClient }
|
|
3084
|
-
);
|
|
3085
|
-
}
|
|
3086
|
-
function voidAuthorizedPayments3(httpClient) {
|
|
3087
|
-
return (ecomOrderId, paymentIds) => voidAuthorizedPayments2(
|
|
3088
|
-
ecomOrderId,
|
|
3089
|
-
paymentIds,
|
|
3090
|
-
// @ts-ignore
|
|
3091
|
-
{ httpClient }
|
|
3092
|
-
);
|
|
3093
|
-
}
|
|
3094
|
-
function captureAuthorizedPayments3(httpClient) {
|
|
3095
|
-
return (ecomOrderId, payments) => captureAuthorizedPayments2(
|
|
3096
|
-
ecomOrderId,
|
|
3097
|
-
payments,
|
|
3098
|
-
// @ts-ignore
|
|
3099
|
-
{ httpClient }
|
|
3100
|
-
);
|
|
3101
|
-
}
|
|
3102
|
-
function getOrder3(httpClient) {
|
|
3103
|
-
return (_id) => getOrder2(
|
|
3104
|
-
_id,
|
|
3105
|
-
// @ts-ignore
|
|
3106
|
-
{ httpClient }
|
|
3107
|
-
);
|
|
3108
|
-
}
|
|
3109
|
-
function searchOrders3(httpClient) {
|
|
3110
|
-
return (options) => searchOrders2(
|
|
3111
|
-
options,
|
|
3112
|
-
// @ts-ignore
|
|
3113
|
-
{ httpClient }
|
|
3114
|
-
);
|
|
3115
|
-
}
|
|
3116
|
-
function createOrder3(httpClient) {
|
|
3117
|
-
return (order, options) => createOrder2(
|
|
3118
|
-
order,
|
|
3119
|
-
options,
|
|
3120
|
-
// @ts-ignore
|
|
3121
|
-
{ httpClient }
|
|
3122
|
-
);
|
|
3123
|
-
}
|
|
3124
|
-
function updateOrder3(httpClient) {
|
|
3125
|
-
return (_id, order) => updateOrder2(
|
|
3126
|
-
_id,
|
|
3127
|
-
order,
|
|
3128
|
-
// @ts-ignore
|
|
3129
|
-
{ httpClient }
|
|
3130
|
-
);
|
|
3131
|
-
}
|
|
3132
|
-
function bulkUpdateOrders3(httpClient) {
|
|
3133
|
-
return (orders, options) => bulkUpdateOrders2(
|
|
3134
|
-
orders,
|
|
3135
|
-
options,
|
|
3136
|
-
// @ts-ignore
|
|
3137
|
-
{ httpClient }
|
|
3138
|
-
);
|
|
3139
|
-
}
|
|
3140
|
-
function commitDeltas3(httpClient) {
|
|
3141
|
-
return (_id, options) => commitDeltas2(
|
|
3142
|
-
_id,
|
|
3143
|
-
options,
|
|
3144
|
-
// @ts-ignore
|
|
3145
|
-
{ httpClient }
|
|
3146
|
-
);
|
|
3147
|
-
}
|
|
3148
|
-
function updateOrderLineItem3(httpClient) {
|
|
3149
|
-
return (identifiers, lineItem) => updateOrderLineItem2(
|
|
3150
|
-
identifiers,
|
|
3151
|
-
lineItem,
|
|
3152
|
-
// @ts-ignore
|
|
3153
|
-
{ httpClient }
|
|
3154
|
-
);
|
|
3155
|
-
}
|
|
3156
|
-
function addActivity3(httpClient) {
|
|
3157
|
-
return (_id, activity) => addActivity2(
|
|
3158
|
-
_id,
|
|
3159
|
-
activity,
|
|
3160
|
-
// @ts-ignore
|
|
3161
|
-
{ httpClient }
|
|
3162
|
-
);
|
|
3163
|
-
}
|
|
3164
|
-
function updateActivity3(httpClient) {
|
|
3165
|
-
return (identifiers, activity) => updateActivity2(
|
|
3166
|
-
identifiers,
|
|
3167
|
-
activity,
|
|
3168
|
-
// @ts-ignore
|
|
3169
|
-
{ httpClient }
|
|
3170
|
-
);
|
|
3171
|
-
}
|
|
3172
|
-
function deleteActivity3(httpClient) {
|
|
3173
|
-
return (identifiers) => deleteActivity2(
|
|
3174
|
-
identifiers,
|
|
3175
|
-
// @ts-ignore
|
|
3176
|
-
{ httpClient }
|
|
3177
|
-
);
|
|
3178
|
-
}
|
|
3179
|
-
function cancelOrder3(httpClient) {
|
|
3180
|
-
return (_id, options) => cancelOrder2(
|
|
3181
|
-
_id,
|
|
3182
|
-
options,
|
|
3183
|
-
// @ts-ignore
|
|
3184
|
-
{ httpClient }
|
|
3185
|
-
);
|
|
3186
|
-
}
|
|
3187
|
-
function updateOrderStatus3(httpClient) {
|
|
3188
|
-
return (orderId, status) => updateOrderStatus2(
|
|
3189
|
-
orderId,
|
|
3190
|
-
status,
|
|
3191
|
-
// @ts-ignore
|
|
3192
|
-
{ httpClient }
|
|
3193
|
-
);
|
|
3194
|
-
}
|
|
3195
|
-
function aggregateOrders3(httpClient) {
|
|
3196
|
-
return (options) => aggregateOrders2(
|
|
3197
|
-
options,
|
|
3198
|
-
// @ts-ignore
|
|
3199
|
-
{ httpClient }
|
|
3200
|
-
);
|
|
3201
|
-
}
|
|
3202
|
-
function bulkUpdateOrderTags3(httpClient) {
|
|
3203
|
-
return (orderIds, options) => bulkUpdateOrderTags2(
|
|
3204
|
-
orderIds,
|
|
3205
|
-
options,
|
|
3206
|
-
// @ts-ignore
|
|
3207
|
-
{ httpClient }
|
|
3208
|
-
);
|
|
3209
|
-
}
|
|
3210
|
-
var onOrderApproved = (0, import_sdk_types.EventDefinition)(
|
|
3211
|
-
"wix.ecom.v1.order_approved",
|
|
3212
|
-
true,
|
|
3213
|
-
(event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
|
|
3214
|
-
(0, import_transform_paths3.transformPaths)(event, [
|
|
3215
|
-
{
|
|
3216
|
-
transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
|
|
3217
|
-
paths: [
|
|
3218
|
-
{ path: "data.order.createdDate" },
|
|
3219
|
-
{ path: "data.order.updatedDate" },
|
|
3220
|
-
{ path: "data.order.purchasedDate" },
|
|
3221
|
-
{ path: "data.order.lineItems.digitalFile.expirationDate" },
|
|
3222
|
-
{
|
|
3223
|
-
path: "data.order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
3224
|
-
},
|
|
3225
|
-
{ path: "data.order.shippingInfo.logistics.deliverByDate" },
|
|
3226
|
-
{ path: "data.order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
3227
|
-
{ path: "data.order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
3228
|
-
{ path: "data.order.activities.createdDate" },
|
|
3229
|
-
{ path: "metadata.eventTime" }
|
|
3230
|
-
]
|
|
3231
|
-
},
|
|
3232
|
-
{
|
|
3233
|
-
transformFn: import_image3.transformRESTImageToSDKImage,
|
|
3234
|
-
paths: [{ path: "data.order.lineItems.image" }]
|
|
3235
|
-
},
|
|
3236
|
-
{
|
|
3237
|
-
transformFn: import_float3.transformRESTFloatToSDKFloat,
|
|
3238
|
-
paths: [{ path: "data.order.lineItems.physicalProperties.weight" }]
|
|
3239
|
-
},
|
|
3240
|
-
{
|
|
3241
|
-
transformFn: import_address3.transformRESTAddressToSDKAddress,
|
|
3242
|
-
paths: [
|
|
3243
|
-
{ path: "data.order.billingInfo.address" },
|
|
3244
|
-
{
|
|
3245
|
-
path: "data.order.shippingInfo.logistics.shippingDestination.address"
|
|
3246
|
-
},
|
|
3247
|
-
{ path: "data.order.shippingInfo.logistics.pickupDetails.address" },
|
|
3248
|
-
{ path: "data.order.recipientInfo.address" }
|
|
3249
|
-
]
|
|
3250
|
-
}
|
|
3251
|
-
])
|
|
3252
|
-
)
|
|
3253
|
-
)();
|
|
3254
|
-
var onOrderUpdated = (0, import_sdk_types.EventDefinition)(
|
|
3255
|
-
"wix.ecom.v1.order_updated",
|
|
3256
|
-
true,
|
|
3257
|
-
(event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
|
|
3258
|
-
(0, import_transform_paths3.transformPaths)(event, [
|
|
3259
|
-
{
|
|
3260
|
-
transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
|
|
3261
|
-
paths: [
|
|
3262
|
-
{ path: "entity.createdDate" },
|
|
3263
|
-
{ path: "entity.updatedDate" },
|
|
3264
|
-
{ path: "entity.purchasedDate" },
|
|
3265
|
-
{ path: "entity.lineItems.digitalFile.expirationDate" },
|
|
3266
|
-
{
|
|
3267
|
-
path: "entity.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
3268
|
-
},
|
|
3269
|
-
{ path: "entity.shippingInfo.logistics.deliverByDate" },
|
|
3270
|
-
{ path: "entity.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
3271
|
-
{ path: "entity.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
3272
|
-
{ path: "entity.activities.createdDate" },
|
|
3273
|
-
{ path: "metadata.eventTime" }
|
|
3274
|
-
]
|
|
3275
|
-
},
|
|
3276
|
-
{
|
|
3277
|
-
transformFn: import_image3.transformRESTImageToSDKImage,
|
|
3278
|
-
paths: [{ path: "entity.lineItems.image" }]
|
|
3279
|
-
},
|
|
3280
|
-
{
|
|
3281
|
-
transformFn: import_float3.transformRESTFloatToSDKFloat,
|
|
3282
|
-
paths: [{ path: "entity.lineItems.physicalProperties.weight" }]
|
|
3283
|
-
},
|
|
3284
|
-
{
|
|
3285
|
-
transformFn: import_address3.transformRESTAddressToSDKAddress,
|
|
3286
|
-
paths: [
|
|
3287
|
-
{ path: "entity.billingInfo.address" },
|
|
3288
|
-
{
|
|
3289
|
-
path: "entity.shippingInfo.logistics.shippingDestination.address"
|
|
3290
|
-
},
|
|
3291
|
-
{ path: "entity.shippingInfo.logistics.pickupDetails.address" },
|
|
3292
|
-
{ path: "entity.recipientInfo.address" }
|
|
3293
|
-
]
|
|
3294
|
-
}
|
|
3295
|
-
])
|
|
3296
|
-
)
|
|
3297
|
-
)();
|
|
3298
|
-
var onOrderCanceled = (0, import_sdk_types.EventDefinition)(
|
|
3299
|
-
"wix.ecom.v1.order_canceled",
|
|
3300
|
-
true,
|
|
3301
|
-
(event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
|
|
3302
|
-
(0, import_transform_paths3.transformPaths)(event, [
|
|
3303
|
-
{
|
|
3304
|
-
transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
|
|
3305
|
-
paths: [
|
|
3306
|
-
{ path: "data.order.createdDate" },
|
|
3307
|
-
{ path: "data.order.updatedDate" },
|
|
3308
|
-
{ path: "data.order.purchasedDate" },
|
|
3309
|
-
{ path: "data.order.lineItems.digitalFile.expirationDate" },
|
|
3310
|
-
{
|
|
3311
|
-
path: "data.order.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
3312
|
-
},
|
|
3313
|
-
{ path: "data.order.shippingInfo.logistics.deliverByDate" },
|
|
3314
|
-
{ path: "data.order.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
3315
|
-
{ path: "data.order.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
3316
|
-
{ path: "data.order.activities.createdDate" },
|
|
3317
|
-
{ path: "metadata.eventTime" }
|
|
3318
|
-
]
|
|
3319
|
-
},
|
|
3320
|
-
{
|
|
3321
|
-
transformFn: import_image3.transformRESTImageToSDKImage,
|
|
3322
|
-
paths: [{ path: "data.order.lineItems.image" }]
|
|
3323
|
-
},
|
|
3324
|
-
{
|
|
3325
|
-
transformFn: import_float3.transformRESTFloatToSDKFloat,
|
|
3326
|
-
paths: [{ path: "data.order.lineItems.physicalProperties.weight" }]
|
|
3327
|
-
},
|
|
3328
|
-
{
|
|
3329
|
-
transformFn: import_address3.transformRESTAddressToSDKAddress,
|
|
3330
|
-
paths: [
|
|
3331
|
-
{ path: "data.order.billingInfo.address" },
|
|
3332
|
-
{
|
|
3333
|
-
path: "data.order.shippingInfo.logistics.shippingDestination.address"
|
|
3334
|
-
},
|
|
3335
|
-
{ path: "data.order.shippingInfo.logistics.pickupDetails.address" },
|
|
3336
|
-
{ path: "data.order.recipientInfo.address" }
|
|
3337
|
-
]
|
|
3338
|
-
}
|
|
3339
|
-
])
|
|
3340
|
-
)
|
|
3341
|
-
)();
|
|
3342
|
-
var onOrderCreated = (0, import_sdk_types.EventDefinition)(
|
|
3343
|
-
"wix.ecom.v1.order_created",
|
|
3344
|
-
true,
|
|
3345
|
-
(event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
|
|
3346
|
-
(0, import_transform_paths3.transformPaths)(event, [
|
|
3347
|
-
{
|
|
3348
|
-
transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
|
|
3349
|
-
paths: [
|
|
3350
|
-
{ path: "entity.createdDate" },
|
|
3351
|
-
{ path: "entity.updatedDate" },
|
|
3352
|
-
{ path: "entity.purchasedDate" },
|
|
3353
|
-
{ path: "entity.lineItems.digitalFile.expirationDate" },
|
|
3354
|
-
{
|
|
3355
|
-
path: "entity.lineItems.subscriptionInfo.subscriptionSettings.startDate"
|
|
3356
|
-
},
|
|
3357
|
-
{ path: "entity.shippingInfo.logistics.deliverByDate" },
|
|
3358
|
-
{ path: "entity.shippingInfo.logistics.deliveryTimeSlot.from" },
|
|
3359
|
-
{ path: "entity.shippingInfo.logistics.deliveryTimeSlot.to" },
|
|
3360
|
-
{ path: "entity.activities.createdDate" },
|
|
3361
|
-
{ path: "metadata.eventTime" }
|
|
3362
|
-
]
|
|
3363
|
-
},
|
|
3364
|
-
{
|
|
3365
|
-
transformFn: import_image3.transformRESTImageToSDKImage,
|
|
3366
|
-
paths: [{ path: "entity.lineItems.image" }]
|
|
3367
|
-
},
|
|
3368
|
-
{
|
|
3369
|
-
transformFn: import_float3.transformRESTFloatToSDKFloat,
|
|
3370
|
-
paths: [{ path: "entity.lineItems.physicalProperties.weight" }]
|
|
3371
|
-
},
|
|
3372
|
-
{
|
|
3373
|
-
transformFn: import_address3.transformRESTAddressToSDKAddress,
|
|
3374
|
-
paths: [
|
|
3375
|
-
{ path: "entity.billingInfo.address" },
|
|
3376
|
-
{
|
|
3377
|
-
path: "entity.shippingInfo.logistics.shippingDestination.address"
|
|
3378
|
-
},
|
|
3379
|
-
{ path: "entity.shippingInfo.logistics.pickupDetails.address" },
|
|
3380
|
-
{ path: "entity.recipientInfo.address" }
|
|
3381
|
-
]
|
|
3382
|
-
}
|
|
3383
|
-
])
|
|
3384
|
-
)
|
|
3385
|
-
)();
|
|
3386
|
-
|
|
3387
|
-
// src/ecom-v1-order-orders.context.ts
|
|
3388
|
-
var import_rest_modules3 = require("@wix/sdk-runtime/rest-modules");
|
|
3389
|
-
var import_event_definition_modules = require("@wix/sdk-runtime/event-definition-modules");
|
|
3390
|
-
var preparePaymentCollection4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(preparePaymentCollection3);
|
|
3391
|
-
var getPaymentCollectabilityStatus4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getPaymentCollectabilityStatus3);
|
|
3392
|
-
var recordManuallyCollectedPayment4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(recordManuallyCollectedPayment3);
|
|
3393
|
-
var paymentCollectionMarkOrderAsPaid4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(paymentCollectionMarkOrderAsPaid3);
|
|
3394
|
-
var paymentCollectionBulkMarkOrdersAsPaid4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(paymentCollectionBulkMarkOrdersAsPaid3);
|
|
3395
|
-
var getRefundabilityStatus4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getRefundabilityStatus3);
|
|
3396
|
-
var paymentCollectionCreatePaymentGatewayOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(
|
|
3397
|
-
paymentCollectionCreatePaymentGatewayOrder3
|
|
3398
|
-
);
|
|
3399
|
-
var chargeMemberships4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(chargeMemberships3);
|
|
3400
|
-
var triggerRefund4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(triggerRefund3);
|
|
3401
|
-
var voidAuthorizedPayments4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(voidAuthorizedPayments3);
|
|
3402
|
-
var captureAuthorizedPayments4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(captureAuthorizedPayments3);
|
|
3403
|
-
var getOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getOrder3);
|
|
3404
|
-
var searchOrders4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(searchOrders3);
|
|
3405
|
-
var createOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createOrder3);
|
|
3406
|
-
var updateOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateOrder3);
|
|
3407
|
-
var bulkUpdateOrders4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(bulkUpdateOrders3);
|
|
3408
|
-
var commitDeltas4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(commitDeltas3);
|
|
3409
|
-
var updateOrderLineItem4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateOrderLineItem3);
|
|
3410
|
-
var addActivity4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(addActivity3);
|
|
3411
|
-
var updateActivity4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateActivity3);
|
|
3412
|
-
var deleteActivity4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(deleteActivity3);
|
|
3413
|
-
var cancelOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(cancelOrder3);
|
|
3414
|
-
var updateOrderStatus4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateOrderStatus3);
|
|
3415
|
-
var aggregateOrders4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(aggregateOrders3);
|
|
3416
|
-
var bulkUpdateOrderTags4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(bulkUpdateOrderTags3);
|
|
3417
|
-
var onOrderApproved2 = (0, import_event_definition_modules.createEventModule)(onOrderApproved);
|
|
3418
|
-
var onOrderUpdated2 = (0, import_event_definition_modules.createEventModule)(onOrderUpdated);
|
|
3419
|
-
var onOrderCanceled2 = (0, import_event_definition_modules.createEventModule)(onOrderCanceled);
|
|
3420
|
-
var onOrderCreated2 = (0, import_event_definition_modules.createEventModule)(onOrderCreated);
|
|
3421
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
3422
|
-
0 && (module.exports = {
|
|
3423
|
-
ActionType,
|
|
3424
|
-
ActivityType,
|
|
3425
|
-
AdjustmentType,
|
|
3426
|
-
AnimationDetection,
|
|
3427
|
-
AttributionSource,
|
|
3428
|
-
AuthorizationCaptureStatus,
|
|
3429
|
-
AuthorizationVoidStatus,
|
|
3430
|
-
ChannelType,
|
|
3431
|
-
CustomFieldGroup,
|
|
3432
|
-
DeltaPaymentOptionType,
|
|
3433
|
-
DepositType,
|
|
3434
|
-
DescriptionLineType,
|
|
3435
|
-
DiscountReason,
|
|
3436
|
-
DiscountType,
|
|
3437
|
-
DurationUnit,
|
|
3438
|
-
FulfillmentStatus,
|
|
3439
|
-
InventoryAction,
|
|
3440
|
-
InvoiceStatus,
|
|
3441
|
-
ItemTypeItemType,
|
|
3442
|
-
JurisdictionType,
|
|
3443
|
-
LineItemQuantityChangeType,
|
|
3444
|
-
ManuallyRefundableReason,
|
|
3445
|
-
MembershipPaymentStatus,
|
|
3446
|
-
Namespace,
|
|
3447
|
-
NonRefundableReason,
|
|
3448
|
-
OrderApprovalStrategy,
|
|
3449
|
-
OrderStatus,
|
|
3450
|
-
PaymentCollectabilityStatus,
|
|
3451
|
-
PaymentOptionType,
|
|
3452
|
-
PaymentStatus,
|
|
3453
|
-
PickupMethod,
|
|
3454
|
-
Placement,
|
|
3455
|
-
PreviewEmailType,
|
|
3456
|
-
Reason,
|
|
3457
|
-
RefundStatus,
|
|
3458
|
-
RefundableStatus,
|
|
3459
|
-
RestockType,
|
|
3460
|
-
ScheduledAction,
|
|
3461
|
-
SortOrder,
|
|
3462
|
-
SourceType,
|
|
3463
|
-
State,
|
|
3464
|
-
SubdivisionType,
|
|
3465
|
-
SubscriptionFrequency,
|
|
3466
|
-
TaxableAddressType,
|
|
3467
|
-
TextDetection,
|
|
3468
|
-
TransactionStatus,
|
|
3469
|
-
ValueType,
|
|
3470
|
-
VatType,
|
|
3471
|
-
VersioningMode,
|
|
3472
|
-
WebhookIdentityType,
|
|
3473
|
-
WeightUnit,
|
|
3474
|
-
addActivity,
|
|
3475
|
-
aggregateOrders,
|
|
3476
|
-
bulkUpdateOrderTags,
|
|
3477
|
-
bulkUpdateOrders,
|
|
3478
|
-
cancelOrder,
|
|
3479
|
-
captureAuthorizedPayments,
|
|
3480
|
-
chargeMemberships,
|
|
3481
|
-
commitDeltas,
|
|
3482
|
-
createOrder,
|
|
3483
|
-
deleteActivity,
|
|
3484
|
-
getOrder,
|
|
3485
|
-
getPaymentCollectabilityStatus,
|
|
3486
|
-
getRefundabilityStatus,
|
|
3487
|
-
onOrderApproved,
|
|
3488
|
-
onOrderCanceled,
|
|
3489
|
-
onOrderCreated,
|
|
3490
|
-
onOrderUpdated,
|
|
3491
|
-
paymentCollectionBulkMarkOrdersAsPaid,
|
|
3492
|
-
paymentCollectionCreatePaymentGatewayOrder,
|
|
3493
|
-
paymentCollectionMarkOrderAsPaid,
|
|
3494
|
-
preparePaymentCollection,
|
|
3495
|
-
recordManuallyCollectedPayment,
|
|
3496
|
-
searchOrders,
|
|
3497
|
-
triggerRefund,
|
|
3498
|
-
updateActivity,
|
|
3499
|
-
updateOrder,
|
|
3500
|
-
updateOrderLineItem,
|
|
3501
|
-
updateOrderStatus,
|
|
3502
|
-
voidAuthorizedPayments
|
|
3503
|
-
});
|
|
3504
|
-
//# sourceMappingURL=index.js.map
|