@wix/ecom 1.0.785 → 1.0.786
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/package.json +39 -39
- package/type-bundles/context.bundle.d.ts +14010 -1362
- package/type-bundles/index.bundle.d.ts +14010 -1362
- package/type-bundles/meta.bundle.d.ts +14 -90
- package/type-bundles/service-plugins-context.bundle.d.ts +204 -210
- package/type-bundles/service-plugins.bundle.d.ts +204 -210
|
@@ -258,26 +258,27 @@ declare class AlreadyVoidedWixError extends Error {
|
|
|
258
258
|
static readonly __type = "wix_spi_error";
|
|
259
259
|
}
|
|
260
260
|
|
|
261
|
-
type ServicePluginMethodInput$
|
|
261
|
+
type ServicePluginMethodInput$8 = {
|
|
262
262
|
request: any;
|
|
263
263
|
metadata: any;
|
|
264
264
|
};
|
|
265
|
-
type ServicePluginContract$
|
|
266
|
-
type ServicePluginMethodMetadata$
|
|
265
|
+
type ServicePluginContract$8 = Record<string, (payload: ServicePluginMethodInput$8) => unknown | Promise<unknown>>;
|
|
266
|
+
type ServicePluginMethodMetadata$8 = {
|
|
267
267
|
name: string;
|
|
268
268
|
primaryHttpMappingPath: string;
|
|
269
269
|
transformations: {
|
|
270
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput$
|
|
270
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput$8;
|
|
271
271
|
toREST: (...args: unknown[]) => unknown;
|
|
272
272
|
};
|
|
273
273
|
};
|
|
274
|
-
type ServicePluginDefinition$
|
|
274
|
+
type ServicePluginDefinition$8<Contract extends ServicePluginContract$8> = {
|
|
275
275
|
__type: 'service-plugin-definition';
|
|
276
276
|
componentType: string;
|
|
277
|
-
methods: ServicePluginMethodMetadata$
|
|
277
|
+
methods: ServicePluginMethodMetadata$8[];
|
|
278
278
|
__contract: Contract;
|
|
279
279
|
};
|
|
280
|
-
declare function ServicePluginDefinition$
|
|
280
|
+
declare function ServicePluginDefinition$8<Contract extends ServicePluginContract$8>(componentType: string, methods: ServicePluginMethodMetadata$8[]): ServicePluginDefinition$8<Contract>;
|
|
281
|
+
type BuildServicePluginDefinition$8<T extends ServicePluginDefinition$8<any>> = (implementation: T['__contract']) => void;
|
|
281
282
|
|
|
282
283
|
declare global {
|
|
283
284
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
@@ -303,7 +304,7 @@ interface _voidEnvelope {
|
|
|
303
304
|
request: VoidRequest;
|
|
304
305
|
metadata: Context$8;
|
|
305
306
|
}
|
|
306
|
-
declare const provideHandlers$h: ServicePluginDefinition$
|
|
307
|
+
declare const provideHandlers$h: ServicePluginDefinition$8<{
|
|
307
308
|
/**
|
|
308
309
|
*
|
|
309
310
|
* This method retrieves gift card data from your app.
|
|
@@ -321,35 +322,6 @@ declare const provideHandlers$h: ServicePluginDefinition$9<{
|
|
|
321
322
|
_void(payload: _voidEnvelope): VoidResponse | Promise<VoidResponse>;
|
|
322
323
|
}>;
|
|
323
324
|
|
|
324
|
-
type ServicePluginMethodInput$8 = {
|
|
325
|
-
request: any;
|
|
326
|
-
metadata: any;
|
|
327
|
-
};
|
|
328
|
-
type ServicePluginContract$8 = Record<string, (payload: ServicePluginMethodInput$8) => unknown | Promise<unknown>>;
|
|
329
|
-
type ServicePluginMethodMetadata$8 = {
|
|
330
|
-
name: string;
|
|
331
|
-
primaryHttpMappingPath: string;
|
|
332
|
-
transformations: {
|
|
333
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput$8;
|
|
334
|
-
toREST: (...args: unknown[]) => unknown;
|
|
335
|
-
};
|
|
336
|
-
};
|
|
337
|
-
type ServicePluginDefinition$8<Contract extends ServicePluginContract$8> = {
|
|
338
|
-
__type: 'service-plugin-definition';
|
|
339
|
-
componentType: string;
|
|
340
|
-
methods: ServicePluginMethodMetadata$8[];
|
|
341
|
-
__contract: Contract;
|
|
342
|
-
};
|
|
343
|
-
declare function ServicePluginDefinition$8<Contract extends ServicePluginContract$8>(componentType: string, methods: ServicePluginMethodMetadata$8[]): ServicePluginDefinition$8<Contract>;
|
|
344
|
-
type BuildServicePluginDefinition$8<T extends ServicePluginDefinition$8<any>> = (implementation: T['__contract']) => void;
|
|
345
|
-
|
|
346
|
-
declare global {
|
|
347
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
348
|
-
interface SymbolConstructor {
|
|
349
|
-
readonly observable: symbol;
|
|
350
|
-
}
|
|
351
|
-
}
|
|
352
|
-
|
|
353
325
|
declare function createServicePluginModule$8<T extends ServicePluginDefinition$8<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$8<T> & T;
|
|
354
326
|
|
|
355
327
|
type _publicProvideHandlersType$8 = typeof provideHandlers$h;
|
|
@@ -838,6 +810,40 @@ declare class TransactionAlreadyVoidedWixError extends Error {
|
|
|
838
810
|
static readonly __type = "wix_spi_error";
|
|
839
811
|
}
|
|
840
812
|
|
|
813
|
+
type ServicePluginMethodInput$7 = {
|
|
814
|
+
request: any;
|
|
815
|
+
metadata: any;
|
|
816
|
+
};
|
|
817
|
+
type ServicePluginContract$7 = Record<string, (payload: ServicePluginMethodInput$7) => unknown | Promise<unknown>>;
|
|
818
|
+
type ServicePluginMethodMetadata$7 = {
|
|
819
|
+
name: string;
|
|
820
|
+
primaryHttpMappingPath: string;
|
|
821
|
+
transformations: {
|
|
822
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput$7;
|
|
823
|
+
toREST: (...args: unknown[]) => unknown;
|
|
824
|
+
};
|
|
825
|
+
};
|
|
826
|
+
type ServicePluginDefinition$7<Contract extends ServicePluginContract$7> = {
|
|
827
|
+
__type: 'service-plugin-definition';
|
|
828
|
+
componentType: string;
|
|
829
|
+
methods: ServicePluginMethodMetadata$7[];
|
|
830
|
+
__contract: Contract;
|
|
831
|
+
};
|
|
832
|
+
declare function ServicePluginDefinition$7<Contract extends ServicePluginContract$7>(componentType: string, methods: ServicePluginMethodMetadata$7[]): ServicePluginDefinition$7<Contract>;
|
|
833
|
+
type BuildServicePluginDefinition$7<T extends ServicePluginDefinition$7<any>> = (implementation: T['__contract']) => void;
|
|
834
|
+
|
|
835
|
+
declare global {
|
|
836
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
837
|
+
interface SymbolConstructor {
|
|
838
|
+
readonly observable: symbol;
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
|
|
842
|
+
declare global {
|
|
843
|
+
interface ContextualClient {
|
|
844
|
+
}
|
|
845
|
+
}
|
|
846
|
+
|
|
841
847
|
interface ListEligibleMembershipsEnvelope {
|
|
842
848
|
request: ListEligibleMembershipsRequest;
|
|
843
849
|
metadata: Context$7;
|
|
@@ -854,7 +860,7 @@ interface VoidMembershipChargeEnvelope {
|
|
|
854
860
|
request: VoidMembershipChargeRequest;
|
|
855
861
|
metadata: Context$7;
|
|
856
862
|
}
|
|
857
|
-
declare const provideHandlers$f: ServicePluginDefinition$
|
|
863
|
+
declare const provideHandlers$f: ServicePluginDefinition$7<{
|
|
858
864
|
/**
|
|
859
865
|
*
|
|
860
866
|
* This method retrieves eligible memberships from your app. */
|
|
@@ -873,35 +879,6 @@ declare const provideHandlers$f: ServicePluginDefinition$9<{
|
|
|
873
879
|
voidMembershipCharge(payload: VoidMembershipChargeEnvelope): VoidMembershipChargeResponse | Promise<VoidMembershipChargeResponse>;
|
|
874
880
|
}>;
|
|
875
881
|
|
|
876
|
-
type ServicePluginMethodInput$7 = {
|
|
877
|
-
request: any;
|
|
878
|
-
metadata: any;
|
|
879
|
-
};
|
|
880
|
-
type ServicePluginContract$7 = Record<string, (payload: ServicePluginMethodInput$7) => unknown | Promise<unknown>>;
|
|
881
|
-
type ServicePluginMethodMetadata$7 = {
|
|
882
|
-
name: string;
|
|
883
|
-
primaryHttpMappingPath: string;
|
|
884
|
-
transformations: {
|
|
885
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput$7;
|
|
886
|
-
toREST: (...args: unknown[]) => unknown;
|
|
887
|
-
};
|
|
888
|
-
};
|
|
889
|
-
type ServicePluginDefinition$7<Contract extends ServicePluginContract$7> = {
|
|
890
|
-
__type: 'service-plugin-definition';
|
|
891
|
-
componentType: string;
|
|
892
|
-
methods: ServicePluginMethodMetadata$7[];
|
|
893
|
-
__contract: Contract;
|
|
894
|
-
};
|
|
895
|
-
declare function ServicePluginDefinition$7<Contract extends ServicePluginContract$7>(componentType: string, methods: ServicePluginMethodMetadata$7[]): ServicePluginDefinition$7<Contract>;
|
|
896
|
-
type BuildServicePluginDefinition$7<T extends ServicePluginDefinition$7<any>> = (implementation: T['__contract']) => void;
|
|
897
|
-
|
|
898
|
-
declare global {
|
|
899
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
900
|
-
interface SymbolConstructor {
|
|
901
|
-
readonly observable: symbol;
|
|
902
|
-
}
|
|
903
|
-
}
|
|
904
|
-
|
|
905
882
|
declare function createServicePluginModule$7<T extends ServicePluginDefinition$7<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$7<T> & T;
|
|
906
883
|
|
|
907
884
|
type _publicProvideHandlersType$7 = typeof provideHandlers$f;
|
|
@@ -1119,20 +1096,6 @@ declare class ItemAppIdNotSupportedWixError extends Error {
|
|
|
1119
1096
|
static readonly __type = "wix_spi_error";
|
|
1120
1097
|
}
|
|
1121
1098
|
|
|
1122
|
-
interface GetRecommendationsEnvelope {
|
|
1123
|
-
request: GetRecommendationsRequest;
|
|
1124
|
-
metadata: Context$6;
|
|
1125
|
-
}
|
|
1126
|
-
declare const provideHandlers$d: ServicePluginDefinition$9<{
|
|
1127
|
-
/**
|
|
1128
|
-
*
|
|
1129
|
-
* Returns lists of items recommended by each requested algorithm.
|
|
1130
|
-
*
|
|
1131
|
-
* If the algorithm's type is `RELATED_ITEMS` then the `items` field is required in the request, and the response will contain items related to those submitted.
|
|
1132
|
-
* How the related items are selected based on the requested items depends on the algorithm. Some examples include items related by category or those frequently bought or watched together. */
|
|
1133
|
-
getRecommendations(payload: GetRecommendationsEnvelope): GetRecommendationsResponse | Promise<GetRecommendationsResponse>;
|
|
1134
|
-
}>;
|
|
1135
|
-
|
|
1136
1099
|
type ServicePluginMethodInput$6 = {
|
|
1137
1100
|
request: any;
|
|
1138
1101
|
metadata: any;
|
|
@@ -1162,6 +1125,25 @@ declare global {
|
|
|
1162
1125
|
}
|
|
1163
1126
|
}
|
|
1164
1127
|
|
|
1128
|
+
declare global {
|
|
1129
|
+
interface ContextualClient {
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
|
|
1133
|
+
interface GetRecommendationsEnvelope {
|
|
1134
|
+
request: GetRecommendationsRequest;
|
|
1135
|
+
metadata: Context$6;
|
|
1136
|
+
}
|
|
1137
|
+
declare const provideHandlers$d: ServicePluginDefinition$6<{
|
|
1138
|
+
/**
|
|
1139
|
+
*
|
|
1140
|
+
* Returns lists of items recommended by each requested algorithm.
|
|
1141
|
+
*
|
|
1142
|
+
* If the algorithm's type is `RELATED_ITEMS` then the `items` field is required in the request, and the response will contain items related to those submitted.
|
|
1143
|
+
* How the related items are selected based on the requested items depends on the algorithm. Some examples include items related by category or those frequently bought or watched together. */
|
|
1144
|
+
getRecommendations(payload: GetRecommendationsEnvelope): GetRecommendationsResponse | Promise<GetRecommendationsResponse>;
|
|
1145
|
+
}>;
|
|
1146
|
+
|
|
1165
1147
|
declare function createServicePluginModule$6<T extends ServicePluginDefinition$6<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$6<T> & T;
|
|
1166
1148
|
|
|
1167
1149
|
type _publicProvideHandlersType$6 = typeof provideHandlers$d;
|
|
@@ -1725,21 +1707,6 @@ declare class GenericShippingRatesWixError extends Error {
|
|
|
1725
1707
|
static readonly __type = "wix_spi_error";
|
|
1726
1708
|
}
|
|
1727
1709
|
|
|
1728
|
-
interface GetShippingRatesEnvelope {
|
|
1729
|
-
request: GetShippingRatesRequest;
|
|
1730
|
-
metadata: Context$5;
|
|
1731
|
-
}
|
|
1732
|
-
declare const provideHandlers$b: ServicePluginDefinition$9<{
|
|
1733
|
-
/**
|
|
1734
|
-
*
|
|
1735
|
-
* This method retrieves applicable shipping rates for a delivery from your app.
|
|
1736
|
-
*
|
|
1737
|
-
* Wix calls this method when certain actions are performed on the cart and/or checkout. For example, when an item is added to the cart, or the shipping destination is changed.
|
|
1738
|
-
*
|
|
1739
|
-
* > __Note:__ Do not call the Estimate Cart Totals, Estimate Current Cart Totals or Get Checkout methods from your implementation code for Get Shipping Rates. Doing so will result in an error. */
|
|
1740
|
-
getShippingRates(payload: GetShippingRatesEnvelope): GetShippingRatesResponse | Promise<GetShippingRatesResponse>;
|
|
1741
|
-
}>;
|
|
1742
|
-
|
|
1743
1710
|
type ServicePluginMethodInput$5 = {
|
|
1744
1711
|
request: any;
|
|
1745
1712
|
metadata: any;
|
|
@@ -1769,6 +1736,26 @@ declare global {
|
|
|
1769
1736
|
}
|
|
1770
1737
|
}
|
|
1771
1738
|
|
|
1739
|
+
declare global {
|
|
1740
|
+
interface ContextualClient {
|
|
1741
|
+
}
|
|
1742
|
+
}
|
|
1743
|
+
|
|
1744
|
+
interface GetShippingRatesEnvelope {
|
|
1745
|
+
request: GetShippingRatesRequest;
|
|
1746
|
+
metadata: Context$5;
|
|
1747
|
+
}
|
|
1748
|
+
declare const provideHandlers$b: ServicePluginDefinition$5<{
|
|
1749
|
+
/**
|
|
1750
|
+
*
|
|
1751
|
+
* This method retrieves applicable shipping rates for a delivery from your app.
|
|
1752
|
+
*
|
|
1753
|
+
* Wix calls this method when certain actions are performed on the cart and/or checkout. For example, when an item is added to the cart, or the shipping destination is changed.
|
|
1754
|
+
*
|
|
1755
|
+
* > __Note:__ Do not call the Estimate Cart Totals, Estimate Current Cart Totals or Get Checkout methods from your implementation code for Get Shipping Rates. Doing so will result in an error. */
|
|
1756
|
+
getShippingRates(payload: GetShippingRatesEnvelope): GetShippingRatesResponse | Promise<GetShippingRatesResponse>;
|
|
1757
|
+
}>;
|
|
1758
|
+
|
|
1772
1759
|
declare function createServicePluginModule$5<T extends ServicePluginDefinition$5<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$5<T> & T;
|
|
1773
1760
|
|
|
1774
1761
|
type _publicProvideHandlersType$5 = typeof provideHandlers$b;
|
|
@@ -2186,24 +2173,6 @@ interface IdentificationDataIdOneOf$4 {
|
|
|
2186
2173
|
appId?: string;
|
|
2187
2174
|
}
|
|
2188
2175
|
|
|
2189
|
-
interface CalculateAdditionalFeesEnvelope {
|
|
2190
|
-
request: CalculateAdditionalFeesRequest;
|
|
2191
|
-
metadata: Context$4;
|
|
2192
|
-
}
|
|
2193
|
-
declare const provideHandlers$9: ServicePluginDefinition$9<{
|
|
2194
|
-
/**
|
|
2195
|
-
*
|
|
2196
|
-
* This method retrieves additional fees calculated by your app.
|
|
2197
|
-
*
|
|
2198
|
-
* Wix calls this method when certain actions are performed on the cart or checkout.
|
|
2199
|
-
* For example, when an item is added to the cart or the amount of an item is updated in the checkout.
|
|
2200
|
-
*
|
|
2201
|
-
* > __Notes:__
|
|
2202
|
-
* > + Do not call the Estimate Cart Totals, Estimate Current Cart Totals or Get Checkout methods from your implementation code for Calculate Additional Fees. Doing so will result in an error.
|
|
2203
|
-
* > + The currency returned in the response object must match the site's currency or those fees will be filtered out and not returned. */
|
|
2204
|
-
calculateAdditionalFees(payload: CalculateAdditionalFeesEnvelope): CalculateAdditionalFeesResponse | Promise<CalculateAdditionalFeesResponse>;
|
|
2205
|
-
}>;
|
|
2206
|
-
|
|
2207
2176
|
type ServicePluginMethodInput$4 = {
|
|
2208
2177
|
request: any;
|
|
2209
2178
|
metadata: any;
|
|
@@ -2233,6 +2202,29 @@ declare global {
|
|
|
2233
2202
|
}
|
|
2234
2203
|
}
|
|
2235
2204
|
|
|
2205
|
+
declare global {
|
|
2206
|
+
interface ContextualClient {
|
|
2207
|
+
}
|
|
2208
|
+
}
|
|
2209
|
+
|
|
2210
|
+
interface CalculateAdditionalFeesEnvelope {
|
|
2211
|
+
request: CalculateAdditionalFeesRequest;
|
|
2212
|
+
metadata: Context$4;
|
|
2213
|
+
}
|
|
2214
|
+
declare const provideHandlers$9: ServicePluginDefinition$4<{
|
|
2215
|
+
/**
|
|
2216
|
+
*
|
|
2217
|
+
* This method retrieves additional fees calculated by your app.
|
|
2218
|
+
*
|
|
2219
|
+
* Wix calls this method when certain actions are performed on the cart or checkout.
|
|
2220
|
+
* For example, when an item is added to the cart or the amount of an item is updated in the checkout.
|
|
2221
|
+
*
|
|
2222
|
+
* > __Notes:__
|
|
2223
|
+
* > + Do not call the Estimate Cart Totals, Estimate Current Cart Totals or Get Checkout methods from your implementation code for Calculate Additional Fees. Doing so will result in an error.
|
|
2224
|
+
* > + The currency returned in the response object must match the site's currency or those fees will be filtered out and not returned. */
|
|
2225
|
+
calculateAdditionalFees(payload: CalculateAdditionalFeesEnvelope): CalculateAdditionalFeesResponse | Promise<CalculateAdditionalFeesResponse>;
|
|
2226
|
+
}>;
|
|
2227
|
+
|
|
2236
2228
|
declare function createServicePluginModule$4<T extends ServicePluginDefinition$4<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$4<T> & T;
|
|
2237
2229
|
|
|
2238
2230
|
type _publicProvideHandlersType$4 = typeof provideHandlers$9;
|
|
@@ -2384,30 +2376,6 @@ interface IdentificationDataIdOneOf$3 {
|
|
|
2384
2376
|
appId?: string;
|
|
2385
2377
|
}
|
|
2386
2378
|
|
|
2387
|
-
interface ListTriggersEnvelope {
|
|
2388
|
-
request: ListTriggersRequest;
|
|
2389
|
-
metadata: Context$3;
|
|
2390
|
-
}
|
|
2391
|
-
interface GetEligibleTriggersEnvelope {
|
|
2392
|
-
request: GetEligibleTriggersRequest;
|
|
2393
|
-
metadata: Context$3;
|
|
2394
|
-
}
|
|
2395
|
-
declare const provideHandlers$7: ServicePluginDefinition$9<{
|
|
2396
|
-
/**
|
|
2397
|
-
*
|
|
2398
|
-
* Lists all custom triggers provided by your service plugin integration.
|
|
2399
|
-
*
|
|
2400
|
-
* This method is automatically called by Wix eCommerce to populate the custom [minimum requirements section of an automatic discount](https://support.wix.com/en/article/wix-stores-creating-automatic-discounts#:~:text=Create%20minimum%20requirements). */
|
|
2401
|
-
listTriggers(payload: ListTriggersEnvelope): ListTriggersResponse | Promise<ListTriggersResponse>;
|
|
2402
|
-
/**
|
|
2403
|
-
*
|
|
2404
|
-
* Retrieves eligible custom discount triggers based on the provided items.
|
|
2405
|
-
*
|
|
2406
|
-
* This method is automatically called by Wix eCommerce to retrieve the custom discount triggers provided by your extension.
|
|
2407
|
-
* This happens when actions are performed on the cart and checkout entities/pages. For example, when an item is added to the cart. */
|
|
2408
|
-
getEligibleTriggers(payload: GetEligibleTriggersEnvelope): GetEligibleTriggersResponse | Promise<GetEligibleTriggersResponse>;
|
|
2409
|
-
}>;
|
|
2410
|
-
|
|
2411
2379
|
type ServicePluginMethodInput$3 = {
|
|
2412
2380
|
request: any;
|
|
2413
2381
|
metadata: any;
|
|
@@ -2437,6 +2405,35 @@ declare global {
|
|
|
2437
2405
|
}
|
|
2438
2406
|
}
|
|
2439
2407
|
|
|
2408
|
+
declare global {
|
|
2409
|
+
interface ContextualClient {
|
|
2410
|
+
}
|
|
2411
|
+
}
|
|
2412
|
+
|
|
2413
|
+
interface ListTriggersEnvelope {
|
|
2414
|
+
request: ListTriggersRequest;
|
|
2415
|
+
metadata: Context$3;
|
|
2416
|
+
}
|
|
2417
|
+
interface GetEligibleTriggersEnvelope {
|
|
2418
|
+
request: GetEligibleTriggersRequest;
|
|
2419
|
+
metadata: Context$3;
|
|
2420
|
+
}
|
|
2421
|
+
declare const provideHandlers$7: ServicePluginDefinition$3<{
|
|
2422
|
+
/**
|
|
2423
|
+
*
|
|
2424
|
+
* Lists all custom triggers provided by your service plugin integration.
|
|
2425
|
+
*
|
|
2426
|
+
* This method is automatically called by Wix eCommerce to populate the custom [minimum requirements section of an automatic discount](https://support.wix.com/en/article/wix-stores-creating-automatic-discounts#:~:text=Create%20minimum%20requirements). */
|
|
2427
|
+
listTriggers(payload: ListTriggersEnvelope): ListTriggersResponse | Promise<ListTriggersResponse>;
|
|
2428
|
+
/**
|
|
2429
|
+
*
|
|
2430
|
+
* Retrieves eligible custom discount triggers based on the provided items.
|
|
2431
|
+
*
|
|
2432
|
+
* This method is automatically called by Wix eCommerce to retrieve the custom discount triggers provided by your extension.
|
|
2433
|
+
* This happens when actions are performed on the cart and checkout entities/pages. For example, when an item is added to the cart. */
|
|
2434
|
+
getEligibleTriggers(payload: GetEligibleTriggersEnvelope): GetEligibleTriggersResponse | Promise<GetEligibleTriggersResponse>;
|
|
2435
|
+
}>;
|
|
2436
|
+
|
|
2440
2437
|
declare function createServicePluginModule$3<T extends ServicePluginDefinition$3<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$3<T> & T;
|
|
2441
2438
|
|
|
2442
2439
|
type _publicProvideHandlersType$3 = typeof provideHandlers$7;
|
|
@@ -2736,18 +2733,6 @@ declare class CouponDoesNotExistWixError extends Error {
|
|
|
2736
2733
|
static readonly __type = "wix_spi_error";
|
|
2737
2734
|
}
|
|
2738
2735
|
|
|
2739
|
-
interface GetEligibleDiscountsEnvelope {
|
|
2740
|
-
request: GetEligibleDiscountsRequest;
|
|
2741
|
-
metadata: Context$2;
|
|
2742
|
-
}
|
|
2743
|
-
declare const provideHandlers$5: ServicePluginDefinition$9<{
|
|
2744
|
-
/**
|
|
2745
|
-
*
|
|
2746
|
-
* Wix calls this method when certain actions are performed on the cart or checkout.
|
|
2747
|
-
* For example, when an item is added to the cart or the amount of an item is updated in the checkout. */
|
|
2748
|
-
getEligibleDiscounts(payload: GetEligibleDiscountsEnvelope): GetEligibleDiscountsResponse | Promise<GetEligibleDiscountsResponse>;
|
|
2749
|
-
}>;
|
|
2750
|
-
|
|
2751
2736
|
type ServicePluginMethodInput$2 = {
|
|
2752
2737
|
request: any;
|
|
2753
2738
|
metadata: any;
|
|
@@ -2777,6 +2762,23 @@ declare global {
|
|
|
2777
2762
|
}
|
|
2778
2763
|
}
|
|
2779
2764
|
|
|
2765
|
+
declare global {
|
|
2766
|
+
interface ContextualClient {
|
|
2767
|
+
}
|
|
2768
|
+
}
|
|
2769
|
+
|
|
2770
|
+
interface GetEligibleDiscountsEnvelope {
|
|
2771
|
+
request: GetEligibleDiscountsRequest;
|
|
2772
|
+
metadata: Context$2;
|
|
2773
|
+
}
|
|
2774
|
+
declare const provideHandlers$5: ServicePluginDefinition$2<{
|
|
2775
|
+
/**
|
|
2776
|
+
*
|
|
2777
|
+
* Wix calls this method when certain actions are performed on the cart or checkout.
|
|
2778
|
+
* For example, when an item is added to the cart or the amount of an item is updated in the checkout. */
|
|
2779
|
+
getEligibleDiscounts(payload: GetEligibleDiscountsEnvelope): GetEligibleDiscountsResponse | Promise<GetEligibleDiscountsResponse>;
|
|
2780
|
+
}>;
|
|
2781
|
+
|
|
2780
2782
|
declare function createServicePluginModule$2<T extends ServicePluginDefinition$2<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$2<T> & T;
|
|
2781
2783
|
|
|
2782
2784
|
type _publicProvideHandlersType$2 = typeof provideHandlers$5;
|
|
@@ -3363,13 +3365,7 @@ declare enum PaymentStatus {
|
|
|
3363
3365
|
/** Payments received but not yet confirmed by the payment provider */
|
|
3364
3366
|
PENDING = "PENDING",
|
|
3365
3367
|
/** At least one payment was received and approved, covering less than total price amount */
|
|
3366
|
-
PARTIALLY_PAID = "PARTIALLY_PAID"
|
|
3367
|
-
/** Payment received but not yet confirmed by the payment provider and waits for some user action */
|
|
3368
|
-
PENDING_MERCHANT = "PENDING_MERCHANT",
|
|
3369
|
-
/** Payment was canceled by user on payment provider side */
|
|
3370
|
-
CANCELED = "CANCELED",
|
|
3371
|
-
/** Payment was declined by payment provider */
|
|
3372
|
-
DECLINED = "DECLINED"
|
|
3368
|
+
PARTIALLY_PAID = "PARTIALLY_PAID"
|
|
3373
3369
|
}
|
|
3374
3370
|
declare enum FulfillmentStatus {
|
|
3375
3371
|
/** none of the order items are fulfilled or order was manually marked as unfulfilled */
|
|
@@ -3576,9 +3572,7 @@ interface ShippingRegion {
|
|
|
3576
3572
|
declare enum OrderStatus {
|
|
3577
3573
|
INITIALIZED = "INITIALIZED",
|
|
3578
3574
|
APPROVED = "APPROVED",
|
|
3579
|
-
CANCELED = "CANCELED"
|
|
3580
|
-
PENDING = "PENDING",
|
|
3581
|
-
REJECTED = "REJECTED"
|
|
3575
|
+
CANCELED = "CANCELED"
|
|
3582
3576
|
}
|
|
3583
3577
|
interface TaxSummary {
|
|
3584
3578
|
/**
|
|
@@ -4060,17 +4054,7 @@ declare enum ActivityType {
|
|
|
4060
4054
|
NEW_EXCHANGE_ORDER_CREATED = "NEW_EXCHANGE_ORDER_CREATED",
|
|
4061
4055
|
ORDER_PARTIALLY_PAID = "ORDER_PARTIALLY_PAID",
|
|
4062
4056
|
DRAFT_ORDER_CHANGES_APPLIED = "DRAFT_ORDER_CHANGES_APPLIED",
|
|
4063
|
-
SAVED_PAYMENT_METHOD = "SAVED_PAYMENT_METHOD"
|
|
4064
|
-
AUTHORIZED_PAYMENT_CREATED = "AUTHORIZED_PAYMENT_CREATED",
|
|
4065
|
-
AUTHORIZED_PAYMENT_CAPTURED = "AUTHORIZED_PAYMENT_CAPTURED",
|
|
4066
|
-
AUTHORIZED_PAYMENT_VOIDED = "AUTHORIZED_PAYMENT_VOIDED",
|
|
4067
|
-
REFUND_INITIATED = "REFUND_INITIATED",
|
|
4068
|
-
PAYMENT_REFUNDED = "PAYMENT_REFUNDED",
|
|
4069
|
-
PAYMENT_REFUND_FAILED = "PAYMENT_REFUND_FAILED",
|
|
4070
|
-
REFUNDED_AS_STORE_CREDIT = "REFUNDED_AS_STORE_CREDIT",
|
|
4071
|
-
PAYMENT_PENDING = "PAYMENT_PENDING",
|
|
4072
|
-
PAYMENT_CANCELED = "PAYMENT_CANCELED",
|
|
4073
|
-
PAYMENT_DECLINED = "PAYMENT_DECLINED"
|
|
4057
|
+
SAVED_PAYMENT_METHOD = "SAVED_PAYMENT_METHOD"
|
|
4074
4058
|
}
|
|
4075
4059
|
declare enum AttributionSource {
|
|
4076
4060
|
UNSPECIFIED = "UNSPECIFIED",
|
|
@@ -5572,27 +5556,6 @@ interface IdentificationDataIdOneOf$1 {
|
|
|
5572
5556
|
appId?: string;
|
|
5573
5557
|
}
|
|
5574
5558
|
|
|
5575
|
-
interface GetPaymentSettingsEnvelope {
|
|
5576
|
-
request: GetPaymentSettingsRequest;
|
|
5577
|
-
metadata: Context$1;
|
|
5578
|
-
}
|
|
5579
|
-
interface GetPaymentSettingsForCheckoutEnvelope {
|
|
5580
|
-
request: GetPaymentSettingsForCheckoutRequest;
|
|
5581
|
-
metadata: Context$1;
|
|
5582
|
-
}
|
|
5583
|
-
declare const provideHandlers$3: ServicePluginDefinition$9<{
|
|
5584
|
-
/**
|
|
5585
|
-
*
|
|
5586
|
-
* This method retrieves payment settings from your app.
|
|
5587
|
-
*
|
|
5588
|
-
* Wix calls this method during the payment process. For example, when a customer inserts credit card details and places an order.
|
|
5589
|
-
* This method retrieves the payment settings to apply, and Wix passes on the settings to the payment provider. */
|
|
5590
|
-
getPaymentSettings(payload: GetPaymentSettingsEnvelope): GetPaymentSettingsResponse | Promise<GetPaymentSettingsResponse>;
|
|
5591
|
-
/**
|
|
5592
|
-
* Returns payment settings for provided Checkout entity. */
|
|
5593
|
-
getPaymentSettingsForCheckout(payload: GetPaymentSettingsForCheckoutEnvelope): GetPaymentSettingsForCheckoutResponse | Promise<GetPaymentSettingsForCheckoutResponse>;
|
|
5594
|
-
}>;
|
|
5595
|
-
|
|
5596
5559
|
type ServicePluginMethodInput$1 = {
|
|
5597
5560
|
request: any;
|
|
5598
5561
|
metadata: any;
|
|
@@ -5622,6 +5585,32 @@ declare global {
|
|
|
5622
5585
|
}
|
|
5623
5586
|
}
|
|
5624
5587
|
|
|
5588
|
+
declare global {
|
|
5589
|
+
interface ContextualClient {
|
|
5590
|
+
}
|
|
5591
|
+
}
|
|
5592
|
+
|
|
5593
|
+
interface GetPaymentSettingsEnvelope {
|
|
5594
|
+
request: GetPaymentSettingsRequest;
|
|
5595
|
+
metadata: Context$1;
|
|
5596
|
+
}
|
|
5597
|
+
interface GetPaymentSettingsForCheckoutEnvelope {
|
|
5598
|
+
request: GetPaymentSettingsForCheckoutRequest;
|
|
5599
|
+
metadata: Context$1;
|
|
5600
|
+
}
|
|
5601
|
+
declare const provideHandlers$3: ServicePluginDefinition$1<{
|
|
5602
|
+
/**
|
|
5603
|
+
*
|
|
5604
|
+
* This method retrieves payment settings from your app.
|
|
5605
|
+
*
|
|
5606
|
+
* Wix calls this method during the payment process. For example, when a customer inserts credit card details and places an order.
|
|
5607
|
+
* This method retrieves the payment settings to apply, and Wix passes on the settings to the payment provider. */
|
|
5608
|
+
getPaymentSettings(payload: GetPaymentSettingsEnvelope): GetPaymentSettingsResponse | Promise<GetPaymentSettingsResponse>;
|
|
5609
|
+
/**
|
|
5610
|
+
* Returns payment settings for provided Checkout entity. */
|
|
5611
|
+
getPaymentSettingsForCheckout(payload: GetPaymentSettingsForCheckoutEnvelope): GetPaymentSettingsForCheckoutResponse | Promise<GetPaymentSettingsForCheckoutResponse>;
|
|
5612
|
+
}>;
|
|
5613
|
+
|
|
5625
5614
|
declare function createServicePluginModule$1<T extends ServicePluginDefinition$1<any>>(servicePluginDefinition: T): BuildServicePluginDefinition$1<T> & T;
|
|
5626
5615
|
|
|
5627
5616
|
type _publicProvideHandlersType$1 = typeof provideHandlers$3;
|
|
@@ -6465,24 +6454,6 @@ interface IdentificationDataIdOneOf {
|
|
|
6465
6454
|
appId?: string;
|
|
6466
6455
|
}
|
|
6467
6456
|
|
|
6468
|
-
interface GetValidationViolationsEnvelope {
|
|
6469
|
-
request: GetValidationViolationsRequest;
|
|
6470
|
-
metadata: Context;
|
|
6471
|
-
}
|
|
6472
|
-
declare const provideHandlers$1: ServicePluginDefinition$9<{
|
|
6473
|
-
/**
|
|
6474
|
-
*
|
|
6475
|
-
* This method retrieves validation violations from your app.
|
|
6476
|
-
*
|
|
6477
|
-
* Wix calls this method when certain actions are performed on a visitor's cart and checkout. For example, when an item is added to the cart, or when a coupon is added to a checkout.
|
|
6478
|
-
* This method validates a visitor's cart and checkout, and returns any validation violations (using the structure provided by Wix eCommerce). Site visitors can see the validation violations in their cart and checkout pages. If there aren't any validation violations, the method returns an object containing an empty list.
|
|
6479
|
-
*
|
|
6480
|
-
* > __Notes:__
|
|
6481
|
-
* > + Do not call the Estimate Cart Totals, Estimate Current Cart Totals or Get Checkout methods from your implementation code for Get Validation Violations. Doing so will result in an error.
|
|
6482
|
-
* > + By default, this method only retrieves validation violations from a visitor's checkout. If you want to also retrieve validation violations from a visitor's cart, set the `validateInCart` parameter to `true` in the Ecom Validations Integration's config file. */
|
|
6483
|
-
getValidationViolations(payload: GetValidationViolationsEnvelope): GetValidationViolationsResponse | Promise<GetValidationViolationsResponse>;
|
|
6484
|
-
}>;
|
|
6485
|
-
|
|
6486
6457
|
type ServicePluginMethodInput = {
|
|
6487
6458
|
request: any;
|
|
6488
6459
|
metadata: any;
|
|
@@ -6512,6 +6483,29 @@ declare global {
|
|
|
6512
6483
|
}
|
|
6513
6484
|
}
|
|
6514
6485
|
|
|
6486
|
+
declare global {
|
|
6487
|
+
interface ContextualClient {
|
|
6488
|
+
}
|
|
6489
|
+
}
|
|
6490
|
+
|
|
6491
|
+
interface GetValidationViolationsEnvelope {
|
|
6492
|
+
request: GetValidationViolationsRequest;
|
|
6493
|
+
metadata: Context;
|
|
6494
|
+
}
|
|
6495
|
+
declare const provideHandlers$1: ServicePluginDefinition<{
|
|
6496
|
+
/**
|
|
6497
|
+
*
|
|
6498
|
+
* This method retrieves validation violations from your app.
|
|
6499
|
+
*
|
|
6500
|
+
* Wix calls this method when certain actions are performed on a visitor's cart and checkout. For example, when an item is added to the cart, or when a coupon is added to a checkout.
|
|
6501
|
+
* This method validates a visitor's cart and checkout, and returns any validation violations (using the structure provided by Wix eCommerce). Site visitors can see the validation violations in their cart and checkout pages. If there aren't any validation violations, the method returns an object containing an empty list.
|
|
6502
|
+
*
|
|
6503
|
+
* > __Notes:__
|
|
6504
|
+
* > + Do not call the Estimate Cart Totals, Estimate Current Cart Totals or Get Checkout methods from your implementation code for Get Validation Violations. Doing so will result in an error.
|
|
6505
|
+
* > + By default, this method only retrieves validation violations from a visitor's checkout. If you want to also retrieve validation violations from a visitor's cart, set the `validateInCart` parameter to `true` in the Ecom Validations Integration's config file. */
|
|
6506
|
+
getValidationViolations(payload: GetValidationViolationsEnvelope): GetValidationViolationsResponse | Promise<GetValidationViolationsResponse>;
|
|
6507
|
+
}>;
|
|
6508
|
+
|
|
6515
6509
|
declare function createServicePluginModule<T extends ServicePluginDefinition<any>>(servicePluginDefinition: T): BuildServicePluginDefinition<T> & T;
|
|
6516
6510
|
|
|
6517
6511
|
type _publicProvideHandlersType = typeof provideHandlers$1;
|