@wix/ecom 1.0.727 → 1.0.728
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/service-plugins-context.d.ts +1 -0
- package/build/cjs/service-plugins-context.js +2 -1
- package/build/cjs/service-plugins-context.js.map +1 -1
- package/build/cjs/service-plugins.d.ts +1 -0
- package/build/cjs/service-plugins.js +2 -1
- package/build/cjs/service-plugins.js.map +1 -1
- package/build/es/service-plugins-context.d.ts +1 -0
- package/build/es/service-plugins-context.js +1 -0
- package/build/es/service-plugins-context.js.map +1 -1
- package/build/es/service-plugins.d.ts +1 -0
- package/build/es/service-plugins.js +1 -0
- package/build/es/service-plugins.js.map +1 -1
- package/package.json +33 -32
- package/type-bundles/context.bundle.d.ts +133 -100
- package/type-bundles/index.bundle.d.ts +133 -100
- package/type-bundles/meta.bundle.d.ts +77 -123
- package/type-bundles/service-plugins-context.bundle.d.ts +362 -41
- package/type-bundles/service-plugins.bundle.d.ts +362 -41
|
@@ -1,3 +1,352 @@
|
|
|
1
|
+
interface GiftCardProviderEntity {
|
|
2
|
+
/** Dummy id for docs generation. */
|
|
3
|
+
_id?: string | null;
|
|
4
|
+
}
|
|
5
|
+
interface GetBalanceRequest {
|
|
6
|
+
/** Gift card code. */
|
|
7
|
+
code?: string;
|
|
8
|
+
/**
|
|
9
|
+
* App instance ID of the Gift Card provider.
|
|
10
|
+
* @deprecated App instance ID of the Gift Card provider.
|
|
11
|
+
* @targetRemovalDate 2025-07-01
|
|
12
|
+
*/
|
|
13
|
+
appInstanceId?: string;
|
|
14
|
+
/** The physical location ID. */
|
|
15
|
+
locationId?: string | null;
|
|
16
|
+
}
|
|
17
|
+
interface GetBalanceResponse {
|
|
18
|
+
/** Current balance. */
|
|
19
|
+
balance?: number;
|
|
20
|
+
/** Currency code. */
|
|
21
|
+
currencyCode?: string;
|
|
22
|
+
/** Used for integration and tracking across different platforms. */
|
|
23
|
+
externalId?: string | null;
|
|
24
|
+
}
|
|
25
|
+
interface RedeemRequest {
|
|
26
|
+
/** Gift card code. */
|
|
27
|
+
code?: string;
|
|
28
|
+
/**
|
|
29
|
+
* App instance ID of the Gift Card provider.
|
|
30
|
+
* @deprecated App instance ID of the Gift Card provider.
|
|
31
|
+
* @targetRemovalDate 2025-07-01
|
|
32
|
+
*/
|
|
33
|
+
appInstanceId?: string;
|
|
34
|
+
/** Amount to redeem from the gift card. */
|
|
35
|
+
amount?: number;
|
|
36
|
+
/** Order ID the gift card transaction is applied to. */
|
|
37
|
+
orderId?: string;
|
|
38
|
+
/** Currency code. */
|
|
39
|
+
currencyCode?: string;
|
|
40
|
+
/** Physical location ID. */
|
|
41
|
+
locationId?: string | null;
|
|
42
|
+
}
|
|
43
|
+
interface RedeemResponse {
|
|
44
|
+
/** Remaining balance on the Gift Card after the redemption. */
|
|
45
|
+
remainingBalance?: number;
|
|
46
|
+
/** Currency code. */
|
|
47
|
+
currencyCode?: string;
|
|
48
|
+
/** Transaction ID. */
|
|
49
|
+
transactionId?: string;
|
|
50
|
+
}
|
|
51
|
+
interface VoidRequest {
|
|
52
|
+
/**
|
|
53
|
+
* App instance ID of the Gift Card provider.
|
|
54
|
+
* @deprecated App instance ID of the Gift Card provider.
|
|
55
|
+
* @targetRemovalDate 2025-07-01
|
|
56
|
+
*/
|
|
57
|
+
appInstanceId?: string;
|
|
58
|
+
/** Transaction ID to void. */
|
|
59
|
+
transactionId?: string;
|
|
60
|
+
/** Physical location ID. */
|
|
61
|
+
locationId?: string | null;
|
|
62
|
+
}
|
|
63
|
+
interface VoidResponse {
|
|
64
|
+
/** Remaining balance on the Gift Card after voiding the transaction. */
|
|
65
|
+
remainingBalance?: number;
|
|
66
|
+
/** Currency code. */
|
|
67
|
+
currencyCode?: string;
|
|
68
|
+
}
|
|
69
|
+
interface GiftCardProviderConfig {
|
|
70
|
+
/** Base URI of the SPI implementation. */
|
|
71
|
+
deploymentUri?: string;
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* this message is not directly used by any service,
|
|
75
|
+
* it exists to describe the expected parameters that SHOULD be provided to invoked Velo methods as part of open-platform.
|
|
76
|
+
* e.g. SPIs, event-handlers, etc..
|
|
77
|
+
* NOTE: this context object MUST be provided as the last argument in each Velo method signature.
|
|
78
|
+
*
|
|
79
|
+
* Example:
|
|
80
|
+
* ```typescript
|
|
81
|
+
* export function wixStores_onOrderCanceled({ event, metadata }: OrderCanceledEvent) {
|
|
82
|
+
* ...
|
|
83
|
+
* }
|
|
84
|
+
* ```
|
|
85
|
+
*/
|
|
86
|
+
interface Context$6 {
|
|
87
|
+
/** A unique identifier of the request. You may print this ID to your logs to help with future debugging and easier correlation with Wix's logs. */
|
|
88
|
+
requestId?: string | null;
|
|
89
|
+
/** [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) 3-letter currency code. */
|
|
90
|
+
currency?: string | null;
|
|
91
|
+
/** An object that describes the identity that triggered this request. */
|
|
92
|
+
identity?: IdentificationData$6;
|
|
93
|
+
/** A string representing a language and region in the format of `"xx-XX"`. First 2 letters represent the language code according to ISO 639-1. This is followed by a dash "-", and then a by 2 capital letters representing the region according to ISO 3166-2. For example, `"en-US"`. */
|
|
94
|
+
languages?: string[];
|
|
95
|
+
/** The service provider app's instance ID. */
|
|
96
|
+
instanceId?: string | null;
|
|
97
|
+
}
|
|
98
|
+
declare enum IdentityType$6 {
|
|
99
|
+
UNKNOWN = "UNKNOWN",
|
|
100
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
101
|
+
MEMBER = "MEMBER",
|
|
102
|
+
WIX_USER = "WIX_USER",
|
|
103
|
+
APP = "APP"
|
|
104
|
+
}
|
|
105
|
+
interface IdentificationData$6 extends IdentificationDataIdOneOf$6 {
|
|
106
|
+
/** ID of a site visitor that has not logged in to the site. */
|
|
107
|
+
anonymousVisitorId?: string;
|
|
108
|
+
/** ID of a site visitor that has logged in to the site. */
|
|
109
|
+
memberId?: string;
|
|
110
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
|
111
|
+
wixUserId?: string;
|
|
112
|
+
/** ID of an app. */
|
|
113
|
+
appId?: string;
|
|
114
|
+
/** @readonly */
|
|
115
|
+
identityType?: IdentityType$6;
|
|
116
|
+
}
|
|
117
|
+
/** @oneof */
|
|
118
|
+
interface IdentificationDataIdOneOf$6 {
|
|
119
|
+
/** ID of a site visitor that has not logged in to the site. */
|
|
120
|
+
anonymousVisitorId?: string;
|
|
121
|
+
/** ID of a site visitor that has logged in to the site. */
|
|
122
|
+
memberId?: string;
|
|
123
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
|
124
|
+
wixUserId?: string;
|
|
125
|
+
/** ID of an app. */
|
|
126
|
+
appId?: string;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
type ServicePluginMethodInput = {
|
|
130
|
+
request: any;
|
|
131
|
+
metadata: any;
|
|
132
|
+
};
|
|
133
|
+
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
134
|
+
type ServicePluginMethodMetadata = {
|
|
135
|
+
name: string;
|
|
136
|
+
primaryHttpMappingPath: string;
|
|
137
|
+
transformations: {
|
|
138
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
139
|
+
toREST: (...args: unknown[]) => unknown;
|
|
140
|
+
};
|
|
141
|
+
};
|
|
142
|
+
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
143
|
+
__type: 'service-plugin-definition';
|
|
144
|
+
componentType: string;
|
|
145
|
+
methods: ServicePluginMethodMetadata[];
|
|
146
|
+
__contract: Contract;
|
|
147
|
+
};
|
|
148
|
+
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
149
|
+
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
150
|
+
|
|
151
|
+
declare global {
|
|
152
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
153
|
+
interface SymbolConstructor {
|
|
154
|
+
readonly observable: symbol;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
interface GetBalanceEnvelope {
|
|
159
|
+
request: GetBalanceRequest;
|
|
160
|
+
metadata: Context$6;
|
|
161
|
+
}
|
|
162
|
+
interface RedeemEnvelope {
|
|
163
|
+
request: RedeemRequest;
|
|
164
|
+
metadata: Context$6;
|
|
165
|
+
}
|
|
166
|
+
interface _voidEnvelope {
|
|
167
|
+
request: VoidRequest;
|
|
168
|
+
metadata: Context$6;
|
|
169
|
+
}
|
|
170
|
+
declare const provideHandlers$d: ServicePluginDefinition<{
|
|
171
|
+
/**
|
|
172
|
+
*
|
|
173
|
+
* This method retrieves gift card data from your app.
|
|
174
|
+
* Wix calls this method when a customer applies a gift card as a payment method at checkout. */
|
|
175
|
+
getBalance(payload: GetBalanceEnvelope): GetBalanceResponse | Promise<GetBalanceResponse>;
|
|
176
|
+
/**
|
|
177
|
+
*
|
|
178
|
+
* This method requests that a transaction be created by your app.
|
|
179
|
+
* Wix calls this method when a customer completes a purchase that includes a gift card as a payment method at checkout. */
|
|
180
|
+
redeem(payload: RedeemEnvelope): RedeemResponse | Promise<RedeemResponse>;
|
|
181
|
+
/**
|
|
182
|
+
*
|
|
183
|
+
* This method requests that a gift card transaction be voided by your app.
|
|
184
|
+
* Wix calls this method when a purchase fails after gift card redemption. */
|
|
185
|
+
_void(payload: _voidEnvelope): VoidResponse | Promise<VoidResponse>;
|
|
186
|
+
}>;
|
|
187
|
+
|
|
188
|
+
declare function createServicePluginModule$6<T extends ServicePluginDefinition<any>>(servicePluginDefinition: T): BuildServicePluginDefinition<T> & T;
|
|
189
|
+
|
|
190
|
+
type _publicProvideHandlersType$6 = typeof provideHandlers$d;
|
|
191
|
+
declare const provideHandlers$c: ReturnType<typeof createServicePluginModule$6<_publicProvideHandlersType>>;
|
|
192
|
+
|
|
193
|
+
/**
|
|
194
|
+
* Gift card not found
|
|
195
|
+
*/
|
|
196
|
+
declare class GiftCardNotFoundWixError extends Error {
|
|
197
|
+
/** @hidden */
|
|
198
|
+
httpCode: number;
|
|
199
|
+
/** @hidden */
|
|
200
|
+
statusCode: string;
|
|
201
|
+
/** @hidden */
|
|
202
|
+
applicationCode: string;
|
|
203
|
+
/** @hidden */
|
|
204
|
+
name: string;
|
|
205
|
+
constructor();
|
|
206
|
+
/** @hidden */
|
|
207
|
+
static readonly __type = "wix_spi_error";
|
|
208
|
+
}
|
|
209
|
+
/**
|
|
210
|
+
* Gift card is disabled
|
|
211
|
+
*/
|
|
212
|
+
declare class GiftCardDisabledWixError extends Error {
|
|
213
|
+
/** @hidden */
|
|
214
|
+
httpCode: number;
|
|
215
|
+
/** @hidden */
|
|
216
|
+
statusCode: string;
|
|
217
|
+
/** @hidden */
|
|
218
|
+
applicationCode: string;
|
|
219
|
+
/** @hidden */
|
|
220
|
+
name: string;
|
|
221
|
+
constructor();
|
|
222
|
+
/** @hidden */
|
|
223
|
+
static readonly __type = "wix_spi_error";
|
|
224
|
+
}
|
|
225
|
+
/**
|
|
226
|
+
* Gift card was expired
|
|
227
|
+
*/
|
|
228
|
+
declare class GiftCardExpiredWixError extends Error {
|
|
229
|
+
/** @hidden */
|
|
230
|
+
httpCode: number;
|
|
231
|
+
/** @hidden */
|
|
232
|
+
statusCode: string;
|
|
233
|
+
/** @hidden */
|
|
234
|
+
applicationCode: string;
|
|
235
|
+
/** @hidden */
|
|
236
|
+
name: string;
|
|
237
|
+
constructor();
|
|
238
|
+
/** @hidden */
|
|
239
|
+
static readonly __type = "wix_spi_error";
|
|
240
|
+
}
|
|
241
|
+
/**
|
|
242
|
+
* Insufficient funds for redeem
|
|
243
|
+
*/
|
|
244
|
+
declare class InsufficientFundsWixError extends Error {
|
|
245
|
+
/** @hidden */
|
|
246
|
+
httpCode: number;
|
|
247
|
+
/** @hidden */
|
|
248
|
+
statusCode: string;
|
|
249
|
+
/** @hidden */
|
|
250
|
+
applicationCode: string;
|
|
251
|
+
/** @hidden */
|
|
252
|
+
name: string;
|
|
253
|
+
constructor();
|
|
254
|
+
/** @hidden */
|
|
255
|
+
static readonly __type = "wix_spi_error";
|
|
256
|
+
}
|
|
257
|
+
/**
|
|
258
|
+
* Gift card already redeemed for the given order
|
|
259
|
+
*/
|
|
260
|
+
declare class AlreadyRedeemedWixError extends Error {
|
|
261
|
+
/** @hidden */
|
|
262
|
+
httpCode: number;
|
|
263
|
+
/** @hidden */
|
|
264
|
+
statusCode: string;
|
|
265
|
+
/** @hidden */
|
|
266
|
+
applicationCode: string;
|
|
267
|
+
/** @hidden */
|
|
268
|
+
name: string;
|
|
269
|
+
constructor();
|
|
270
|
+
/** @hidden */
|
|
271
|
+
static readonly __type = "wix_spi_error";
|
|
272
|
+
}
|
|
273
|
+
/**
|
|
274
|
+
* Currency code not supported
|
|
275
|
+
*/
|
|
276
|
+
declare class CurrencyNotSupportedWixError extends Error {
|
|
277
|
+
/** @hidden */
|
|
278
|
+
httpCode: number;
|
|
279
|
+
/** @hidden */
|
|
280
|
+
statusCode: string;
|
|
281
|
+
/** @hidden */
|
|
282
|
+
applicationCode: string;
|
|
283
|
+
/** @hidden */
|
|
284
|
+
name: string;
|
|
285
|
+
constructor();
|
|
286
|
+
/** @hidden */
|
|
287
|
+
static readonly __type = "wix_spi_error";
|
|
288
|
+
}
|
|
289
|
+
/**
|
|
290
|
+
* Transaction not found.
|
|
291
|
+
*/
|
|
292
|
+
declare class TransactionNotFoundWixError extends Error {
|
|
293
|
+
/** @hidden */
|
|
294
|
+
httpCode: number;
|
|
295
|
+
/** @hidden */
|
|
296
|
+
statusCode: string;
|
|
297
|
+
/** @hidden */
|
|
298
|
+
applicationCode: string;
|
|
299
|
+
/** @hidden */
|
|
300
|
+
name: string;
|
|
301
|
+
constructor();
|
|
302
|
+
/** @hidden */
|
|
303
|
+
static readonly __type = "wix_spi_error";
|
|
304
|
+
}
|
|
305
|
+
/**
|
|
306
|
+
* Transaction already voided
|
|
307
|
+
*/
|
|
308
|
+
declare class AlreadyVoidedWixError extends Error {
|
|
309
|
+
/** @hidden */
|
|
310
|
+
httpCode: number;
|
|
311
|
+
/** @hidden */
|
|
312
|
+
statusCode: string;
|
|
313
|
+
/** @hidden */
|
|
314
|
+
applicationCode: string;
|
|
315
|
+
/** @hidden */
|
|
316
|
+
name: string;
|
|
317
|
+
constructor();
|
|
318
|
+
/** @hidden */
|
|
319
|
+
static readonly __type = "wix_spi_error";
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
type index_d$6_AlreadyRedeemedWixError = AlreadyRedeemedWixError;
|
|
323
|
+
declare const index_d$6_AlreadyRedeemedWixError: typeof AlreadyRedeemedWixError;
|
|
324
|
+
type index_d$6_AlreadyVoidedWixError = AlreadyVoidedWixError;
|
|
325
|
+
declare const index_d$6_AlreadyVoidedWixError: typeof AlreadyVoidedWixError;
|
|
326
|
+
type index_d$6_CurrencyNotSupportedWixError = CurrencyNotSupportedWixError;
|
|
327
|
+
declare const index_d$6_CurrencyNotSupportedWixError: typeof CurrencyNotSupportedWixError;
|
|
328
|
+
type index_d$6_GetBalanceRequest = GetBalanceRequest;
|
|
329
|
+
type index_d$6_GetBalanceResponse = GetBalanceResponse;
|
|
330
|
+
type index_d$6_GiftCardDisabledWixError = GiftCardDisabledWixError;
|
|
331
|
+
declare const index_d$6_GiftCardDisabledWixError: typeof GiftCardDisabledWixError;
|
|
332
|
+
type index_d$6_GiftCardExpiredWixError = GiftCardExpiredWixError;
|
|
333
|
+
declare const index_d$6_GiftCardExpiredWixError: typeof GiftCardExpiredWixError;
|
|
334
|
+
type index_d$6_GiftCardNotFoundWixError = GiftCardNotFoundWixError;
|
|
335
|
+
declare const index_d$6_GiftCardNotFoundWixError: typeof GiftCardNotFoundWixError;
|
|
336
|
+
type index_d$6_GiftCardProviderConfig = GiftCardProviderConfig;
|
|
337
|
+
type index_d$6_GiftCardProviderEntity = GiftCardProviderEntity;
|
|
338
|
+
type index_d$6_InsufficientFundsWixError = InsufficientFundsWixError;
|
|
339
|
+
declare const index_d$6_InsufficientFundsWixError: typeof InsufficientFundsWixError;
|
|
340
|
+
type index_d$6_RedeemRequest = RedeemRequest;
|
|
341
|
+
type index_d$6_RedeemResponse = RedeemResponse;
|
|
342
|
+
type index_d$6_TransactionNotFoundWixError = TransactionNotFoundWixError;
|
|
343
|
+
declare const index_d$6_TransactionNotFoundWixError: typeof TransactionNotFoundWixError;
|
|
344
|
+
type index_d$6_VoidRequest = VoidRequest;
|
|
345
|
+
type index_d$6_VoidResponse = VoidResponse;
|
|
346
|
+
declare namespace index_d$6 {
|
|
347
|
+
export { index_d$6_AlreadyRedeemedWixError as AlreadyRedeemedWixError, index_d$6_AlreadyVoidedWixError as AlreadyVoidedWixError, type Context$6 as Context, index_d$6_CurrencyNotSupportedWixError as CurrencyNotSupportedWixError, type index_d$6_GetBalanceRequest as GetBalanceRequest, type index_d$6_GetBalanceResponse as GetBalanceResponse, index_d$6_GiftCardDisabledWixError as GiftCardDisabledWixError, index_d$6_GiftCardExpiredWixError as GiftCardExpiredWixError, index_d$6_GiftCardNotFoundWixError as GiftCardNotFoundWixError, type index_d$6_GiftCardProviderConfig as GiftCardProviderConfig, type index_d$6_GiftCardProviderEntity as GiftCardProviderEntity, type IdentificationData$6 as IdentificationData, type IdentificationDataIdOneOf$6 as IdentificationDataIdOneOf, IdentityType$6 as IdentityType, index_d$6_InsufficientFundsWixError as InsufficientFundsWixError, type index_d$6_RedeemRequest as RedeemRequest, type index_d$6_RedeemResponse as RedeemResponse, index_d$6_TransactionNotFoundWixError as TransactionNotFoundWixError, type index_d$6_VoidRequest as VoidRequest, type index_d$6_VoidResponse as VoidResponse, type _publicProvideHandlersType$6 as _publicProvideHandlersType, provideHandlers$c as provideHandlers, provideHandlers$d as publicProvideHandlers };
|
|
348
|
+
}
|
|
349
|
+
|
|
1
350
|
interface GetShippingRatesRequest {
|
|
2
351
|
/** The line items to be shipped. */
|
|
3
352
|
lineItems?: ProductItem[];
|
|
@@ -423,35 +772,6 @@ interface IdentificationDataIdOneOf$5 {
|
|
|
423
772
|
appId?: string;
|
|
424
773
|
}
|
|
425
774
|
|
|
426
|
-
type ServicePluginMethodInput = {
|
|
427
|
-
request: any;
|
|
428
|
-
metadata: any;
|
|
429
|
-
};
|
|
430
|
-
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
431
|
-
type ServicePluginMethodMetadata = {
|
|
432
|
-
name: string;
|
|
433
|
-
primaryHttpMappingPath: string;
|
|
434
|
-
transformations: {
|
|
435
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
436
|
-
toREST: (...args: unknown[]) => unknown;
|
|
437
|
-
};
|
|
438
|
-
};
|
|
439
|
-
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
440
|
-
__type: 'service-plugin-definition';
|
|
441
|
-
componentType: string;
|
|
442
|
-
methods: ServicePluginMethodMetadata[];
|
|
443
|
-
__contract: Contract;
|
|
444
|
-
};
|
|
445
|
-
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
446
|
-
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
447
|
-
|
|
448
|
-
declare global {
|
|
449
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
450
|
-
interface SymbolConstructor {
|
|
451
|
-
readonly observable: symbol;
|
|
452
|
-
}
|
|
453
|
-
}
|
|
454
|
-
|
|
455
775
|
interface GetShippingRatesEnvelope {
|
|
456
776
|
request: GetShippingRatesRequest;
|
|
457
777
|
metadata: Context$5;
|
|
@@ -636,7 +956,7 @@ interface LineItem$3 {
|
|
|
636
956
|
* Max: `100000`
|
|
637
957
|
*/
|
|
638
958
|
quantity?: number | null;
|
|
639
|
-
/** Catalog and item reference. Includes IDs for the item and the catalog it came from, as well as further optional info. */
|
|
959
|
+
/** Catalog and item reference. Includes IDs for the item and the catalog it came from, as well as further optional info. Optional for custom line items, which don't trigger the Catalog service plugin. */
|
|
640
960
|
catalogReference?: CatalogReference$4;
|
|
641
961
|
/** Item name. */
|
|
642
962
|
productName?: string | null;
|
|
@@ -1049,7 +1369,7 @@ interface LineItem$2 {
|
|
|
1049
1369
|
quantity?: number | null;
|
|
1050
1370
|
/**
|
|
1051
1371
|
* Catalog and item reference. Holds IDs for the item and the catalog it came from, as well as further optional info.
|
|
1052
|
-
* This field
|
|
1372
|
+
* This field may be empty in the case of a custom line item.
|
|
1053
1373
|
*/
|
|
1054
1374
|
catalogReference?: CatalogReference$3;
|
|
1055
1375
|
/** Price of a single item. */
|
|
@@ -1593,7 +1913,7 @@ interface OrderLineItem {
|
|
|
1593
1913
|
productName?: ProductName$1;
|
|
1594
1914
|
/**
|
|
1595
1915
|
* References to the line item's origin catalog.
|
|
1596
|
-
* This field
|
|
1916
|
+
* This field may be empty in the case of a custom line item.
|
|
1597
1917
|
*/
|
|
1598
1918
|
catalogReference?: CatalogReference$1;
|
|
1599
1919
|
/** Line item quantity. */
|
|
@@ -3070,11 +3390,6 @@ interface ValidationInfo {
|
|
|
3070
3390
|
customFields?: CustomFields;
|
|
3071
3391
|
/** Applied discounts. */
|
|
3072
3392
|
appliedDiscounts?: AppliedDiscount[];
|
|
3073
|
-
/**
|
|
3074
|
-
* Used for integration and tracking across different platforms.
|
|
3075
|
-
* Contains external system IDs (e.g., app ID, external ID) to link the purchase flow with other systems.
|
|
3076
|
-
*/
|
|
3077
|
-
externalReference?: ExternalReference;
|
|
3078
3393
|
}
|
|
3079
3394
|
interface BuyerDetails {
|
|
3080
3395
|
/** Buyer's email address. */
|
|
@@ -3497,9 +3812,15 @@ interface DiscountRuleName {
|
|
|
3497
3812
|
translated?: string | null;
|
|
3498
3813
|
}
|
|
3499
3814
|
interface ExternalReference {
|
|
3500
|
-
/**
|
|
3815
|
+
/**
|
|
3816
|
+
* ID of the app associated with the purchase flow.
|
|
3817
|
+
* For example, the Wix Pay Links app ID.
|
|
3818
|
+
*/
|
|
3501
3819
|
appId?: string;
|
|
3502
|
-
/**
|
|
3820
|
+
/**
|
|
3821
|
+
* Reference to an external resource ID. Used to link the purchase flow to a specific entity in an external system.
|
|
3822
|
+
* For example, a Wix Pay Link ID.
|
|
3823
|
+
*/
|
|
3503
3824
|
resourceId?: string | null;
|
|
3504
3825
|
}
|
|
3505
3826
|
interface ExtendedFields {
|
|
@@ -3574,7 +3895,7 @@ interface ValidationsSPIConfig {
|
|
|
3574
3895
|
validateInCart?: boolean;
|
|
3575
3896
|
/**
|
|
3576
3897
|
* Required. Base URI where the endpoints are called. Wix appends the endpoint path to the base URI.
|
|
3577
|
-
* For example, to call the Get
|
|
3898
|
+
* For example, to call the Get Validation Violations endpoint at `https://my-validations.com/v1/get-violations`, the base URI you provide here is `https://my-validations.com`.
|
|
3578
3899
|
*/
|
|
3579
3900
|
deploymentUri?: string;
|
|
3580
3901
|
}
|
|
@@ -3736,4 +4057,4 @@ declare namespace index_d {
|
|
|
3736
4057
|
export { type index_d_Address as Address, type index_d_AddressLocation as AddressLocation, type index_d_AddressWithContact as AddressWithContact, type index_d_AppliedDiscount as AppliedDiscount, type index_d_AppliedDiscountDiscountSourceOneOf as AppliedDiscountDiscountSourceOneOf, type index_d_BuyerDetails as BuyerDetails, type index_d_CatalogReference as CatalogReference, index_d_CheckoutStage as CheckoutStage, type index_d_Context as Context, type index_d_Coupon as Coupon, type index_d_CustomField as CustomField, type index_d_CustomFields as CustomFields, type index_d_Description as Description, type index_d_DiscountRule as DiscountRule, type index_d_DiscountRuleName as DiscountRuleName, index_d_DiscountType as DiscountType, type index_d_ExtendedFields as ExtendedFields, type index_d_ExternalReference as ExternalReference, type index_d_FullAddressContactDetails as FullAddressContactDetails, type index_d_GetValidationViolationsRequest as GetValidationViolationsRequest, type index_d_GetValidationViolationsResponse as GetValidationViolationsResponse, type index_d_GiftCard as GiftCard, type index_d_IdentificationData as IdentificationData, type index_d_IdentificationDataIdOneOf as IdentificationDataIdOneOf, index_d_IdentityType as IdentityType, type index_d_ItemTaxFullDetails as ItemTaxFullDetails, type index_d_ItemType as ItemType, index_d_ItemTypeItemType as ItemTypeItemType, type index_d_ItemTypeItemTypeDataOneOf as ItemTypeItemTypeDataOneOf, index_d_JurisdictionType as JurisdictionType, type index_d_LineItem as LineItem, type index_d_LineItemPricesData as LineItemPricesData, type index_d_MerchantDiscount as MerchantDiscount, type index_d_MultiCurrencyPrice as MultiCurrencyPrice, index_d_NameInLineItem as NameInLineItem, index_d_NameInOther as NameInOther, type index_d_Other as Other, type index_d_PhysicalProperties as PhysicalProperties, type index_d_PriceSummary as PriceSummary, type index_d_ProductName as ProductName, type index_d_SelectedCarrierServiceOption as SelectedCarrierServiceOption, type index_d_SelectedCarrierServiceOptionPrices as SelectedCarrierServiceOptionPrices, index_d_Severity as Severity, type index_d_ShippingInfo as ShippingInfo, index_d_Source as Source, type index_d_SourceInfo as SourceInfo, type index_d_Stage as Stage, type index_d_StageStagesOneOf as StageStagesOneOf, type index_d_StreetAddress as StreetAddress, index_d_SubscriptionFrequency as SubscriptionFrequency, type index_d_SubscriptionOptionInfo as SubscriptionOptionInfo, type index_d_SubscriptionSettings as SubscriptionSettings, type index_d_Target as Target, type index_d_TargetLineItem as TargetLineItem, type index_d_TargetTargetTypeOneOf as TargetTargetTypeOneOf, type index_d_TaxBreakdown as TaxBreakdown, type index_d_Title as Title, type index_d_ValidationInfo as ValidationInfo, type index_d_ValidationsSPIConfig as ValidationsSPIConfig, type index_d_VatId as VatId, index_d_VatType as VatType, type index_d_Violation as Violation, index_d_WeightUnit as WeightUnit, type index_d__publicProvideHandlersType as _publicProvideHandlersType, index_d_provideHandlers as provideHandlers, provideHandlers$1 as publicProvideHandlers };
|
|
3737
4058
|
}
|
|
3738
4059
|
|
|
3739
|
-
export { index_d$4 as additionalFees, index_d$3 as customTriggers, index_d$2 as discounts, index_d$1 as paymentSettings, index_d$5 as shippingRates, index_d as validations };
|
|
4060
|
+
export { index_d$4 as additionalFees, index_d$3 as customTriggers, index_d$2 as discounts, index_d$6 as giftVouchersProvider, index_d$1 as paymentSettings, index_d$5 as shippingRates, index_d as validations };
|