@wix/auto_sdk_ecom_catalog 1.0.58 → 1.0.60
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 +2 -2
- package/build/cjs/index.js +7 -0
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +2 -2
- package/build/cjs/index.typings.js +7 -0
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/{interfaces-ecommerce-v1-catalog-provider.public-C21kEkEU.d.ts → interfaces-ecommerce-v1-catalog-provider.public-FiyC3NMD.d.ts} +7 -1
- package/build/es/index.d.mts +2 -2
- package/build/es/index.mjs +6 -0
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +2 -2
- package/build/es/index.typings.mjs +6 -0
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/{interfaces-ecommerce-v1-catalog-provider.public-C21kEkEU.d.mts → interfaces-ecommerce-v1-catalog-provider.public-FiyC3NMD.d.mts} +7 -1
- package/build/internal/cjs/index.d.ts +2 -2
- package/build/internal/cjs/index.js +7 -0
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +2 -2
- package/build/internal/cjs/index.typings.js +7 -0
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/{interfaces-ecommerce-v1-catalog-provider.public-C21kEkEU.d.ts → interfaces-ecommerce-v1-catalog-provider.public-CQVNMtC3.d.ts} +193 -1
- package/build/internal/es/index.d.mts +2 -2
- package/build/internal/es/index.mjs +6 -0
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +2 -2
- package/build/internal/es/index.typings.mjs +6 -0
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/{interfaces-ecommerce-v1-catalog-provider.public-C21kEkEU.d.mts → interfaces-ecommerce-v1-catalog-provider.public-CQVNMtC3.d.mts} +193 -1
- package/package.json +4 -4
|
@@ -20,6 +20,18 @@ interface GetCatalogItemsRequest {
|
|
|
20
20
|
* @format CURRENCY
|
|
21
21
|
*/
|
|
22
22
|
currency?: string;
|
|
23
|
+
/**
|
|
24
|
+
* The business location ID associated with the requested items.
|
|
25
|
+
* Learn more about the [Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).
|
|
26
|
+
* @internal
|
|
27
|
+
* @format GUID
|
|
28
|
+
*/
|
|
29
|
+
businessLocationId?: string | null;
|
|
30
|
+
/**
|
|
31
|
+
* Buyer information.
|
|
32
|
+
* @internal
|
|
33
|
+
*/
|
|
34
|
+
buyerInfo?: BuyerInfo;
|
|
23
35
|
}
|
|
24
36
|
interface CatalogReferenceAndQuantity {
|
|
25
37
|
/** Catalog and item reference info. Holds IDs for the item and the catalog it belongs to, as well as further optional details. This is identical in the request and response. */
|
|
@@ -180,8 +192,36 @@ interface ItemData {
|
|
|
180
192
|
quantityAvailable?: number | null;
|
|
181
193
|
/** Physical properties of the item. Only return for physical items. When applicable, contains information such as SKU and item weight. */
|
|
182
194
|
physicalProperties?: PhysicalProperties;
|
|
195
|
+
/**
|
|
196
|
+
* Coupon scopes. These specify which app and items a coupon applies to.
|
|
197
|
+
* Should be used by Bookings, Stores, and Events in line with the current [Coupons API](https://bo.wix.com/wix-docs/rest/stores/coupons/valid-scope-values).
|
|
198
|
+
* @internal
|
|
199
|
+
*/
|
|
200
|
+
couponScopes?: Scope[];
|
|
183
201
|
/** Subscription option info. */
|
|
184
202
|
subscriptionOptionInfo?: SubscriptionOptionInfo;
|
|
203
|
+
/**
|
|
204
|
+
* ID of the fulfiller for this item. This field is internal and only used by Stores.
|
|
205
|
+
* @internal
|
|
206
|
+
* @format GUID
|
|
207
|
+
*/
|
|
208
|
+
fulfillerId?: string | null;
|
|
209
|
+
/**
|
|
210
|
+
* Digital file details. Required if `itemType.preset` is `DIGITAL`.
|
|
211
|
+
* @internal
|
|
212
|
+
*/
|
|
213
|
+
digitalFile?: SecuredMedia;
|
|
214
|
+
/**
|
|
215
|
+
* Deprecated. Use the `deliveryProfileId` instead.
|
|
216
|
+
* Shipping group ID. This field is internal and only used by Stores.
|
|
217
|
+
* @internal
|
|
218
|
+
* @format GUID
|
|
219
|
+
* @readonly
|
|
220
|
+
* @deprecated Deprecated. Use the `deliveryProfileId` instead.
|
|
221
|
+
* Shipping group ID. This field is internal and only used by Stores.
|
|
222
|
+
* @targetRemovalDate 2025-02-13
|
|
223
|
+
*/
|
|
224
|
+
shippingGroupId?: string | null;
|
|
185
225
|
/**
|
|
186
226
|
* Type of selected payment option for current item.
|
|
187
227
|
*
|
|
@@ -244,6 +284,12 @@ interface ItemData {
|
|
|
244
284
|
savePaymentMethod?: boolean;
|
|
245
285
|
/** Address to use for tax calculation purposes. */
|
|
246
286
|
taxableAddress?: TaxableAddress;
|
|
287
|
+
/**
|
|
288
|
+
* ID of the app managing the inventory.
|
|
289
|
+
* @internal
|
|
290
|
+
* @format GUID
|
|
291
|
+
*/
|
|
292
|
+
inventoryAppId?: string | null;
|
|
247
293
|
/**
|
|
248
294
|
* Policies to be displayed to the customer on the checkout page.
|
|
249
295
|
* @maxSize 5
|
|
@@ -265,6 +311,17 @@ interface ItemData {
|
|
|
265
311
|
* @maxSize 25
|
|
266
312
|
*/
|
|
267
313
|
modifierGroups?: ModifierGroup[];
|
|
314
|
+
/**
|
|
315
|
+
* Platform fee to be added to this item calculation. This field is internal for Wix verticals.
|
|
316
|
+
* @internal
|
|
317
|
+
*/
|
|
318
|
+
platformFee?: PlatformFee;
|
|
319
|
+
/**
|
|
320
|
+
* ID of the app providing upsells for this item.
|
|
321
|
+
* @internal
|
|
322
|
+
* @format GUID
|
|
323
|
+
*/
|
|
324
|
+
upsellOptionsAppId?: string | null;
|
|
268
325
|
}
|
|
269
326
|
interface ProductName {
|
|
270
327
|
/**
|
|
@@ -312,8 +369,26 @@ interface DescriptionLine extends DescriptionLineValueOneOf, DescriptionLineDesc
|
|
|
312
369
|
plainText?: PlainTextValue;
|
|
313
370
|
/** Description line color value. */
|
|
314
371
|
colorInfo?: Color;
|
|
372
|
+
/**
|
|
373
|
+
* Description line plain text value.
|
|
374
|
+
* @internal
|
|
375
|
+
* @deprecated
|
|
376
|
+
*/
|
|
377
|
+
plainTextValue?: PlainTextValue;
|
|
378
|
+
/**
|
|
379
|
+
* Description line color.
|
|
380
|
+
* @internal
|
|
381
|
+
* @deprecated
|
|
382
|
+
*/
|
|
383
|
+
color?: string;
|
|
315
384
|
/** Description line name. */
|
|
316
385
|
name?: DescriptionLineName;
|
|
386
|
+
/**
|
|
387
|
+
* Description line type.
|
|
388
|
+
* @internal
|
|
389
|
+
* @deprecated
|
|
390
|
+
*/
|
|
391
|
+
lineType?: DescriptionLineType;
|
|
317
392
|
}
|
|
318
393
|
/** @oneof */
|
|
319
394
|
interface DescriptionLineValueOneOf {
|
|
@@ -324,6 +399,18 @@ interface DescriptionLineValueOneOf {
|
|
|
324
399
|
}
|
|
325
400
|
/** @oneof */
|
|
326
401
|
interface DescriptionLineDescriptionLineValueOneOf {
|
|
402
|
+
/**
|
|
403
|
+
* Description line plain text value.
|
|
404
|
+
* @internal
|
|
405
|
+
* @deprecated
|
|
406
|
+
*/
|
|
407
|
+
plainTextValue?: PlainTextValue;
|
|
408
|
+
/**
|
|
409
|
+
* Description line color.
|
|
410
|
+
* @internal
|
|
411
|
+
* @deprecated
|
|
412
|
+
*/
|
|
413
|
+
color?: string;
|
|
327
414
|
}
|
|
328
415
|
interface DescriptionLineName {
|
|
329
416
|
/**
|
|
@@ -387,6 +474,16 @@ interface PhysicalProperties {
|
|
|
387
474
|
sku?: string | null;
|
|
388
475
|
/** Whether this line item is shippable. */
|
|
389
476
|
shippable?: boolean;
|
|
477
|
+
/**
|
|
478
|
+
* Product dimensions (length, width, height of the physical product).
|
|
479
|
+
* @internal
|
|
480
|
+
*/
|
|
481
|
+
productDimensions?: Dimensions;
|
|
482
|
+
/**
|
|
483
|
+
* Package dimensions (length, width, height of the shipping package).
|
|
484
|
+
* @internal
|
|
485
|
+
*/
|
|
486
|
+
packageDimensions?: Dimensions;
|
|
390
487
|
}
|
|
391
488
|
interface Dimensions {
|
|
392
489
|
/**
|
|
@@ -468,6 +565,21 @@ interface SubscriptionSettings {
|
|
|
468
565
|
* If None => no free trial
|
|
469
566
|
*/
|
|
470
567
|
freeTrialPeriod?: FreeTrialPeriod;
|
|
568
|
+
/**
|
|
569
|
+
* The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.
|
|
570
|
+
* @internal
|
|
571
|
+
*/
|
|
572
|
+
startDate?: Date | null;
|
|
573
|
+
/**
|
|
574
|
+
* Billing configuration for recurring charges.
|
|
575
|
+
* @internal
|
|
576
|
+
*/
|
|
577
|
+
billingSettings?: BillingSettings;
|
|
578
|
+
/**
|
|
579
|
+
* Whether the product/service/subscription access period is aligned with the billing period.
|
|
580
|
+
* @internal
|
|
581
|
+
*/
|
|
582
|
+
productPeriodAlignment?: ProductPeriodAlignment;
|
|
471
583
|
}
|
|
472
584
|
/** Frequency unit of recurring payment */
|
|
473
585
|
declare enum SubscriptionFrequency {
|
|
@@ -495,6 +607,12 @@ interface BillingSettings {
|
|
|
495
607
|
*/
|
|
496
608
|
anchorDay?: number | null;
|
|
497
609
|
}
|
|
610
|
+
declare enum ProductPeriodAlignment {
|
|
611
|
+
/** Billing period equals the product/service/subscription access period. */
|
|
612
|
+
ALIGNED_WITH_BILLING_PERIOD = "ALIGNED_WITH_BILLING_PERIOD",
|
|
613
|
+
/** Billing period is independent of the product/service/subscription access period. */
|
|
614
|
+
NOT_ALIGNED_WITH_BILLING_PERIOD = "NOT_ALIGNED_WITH_BILLING_PERIOD"
|
|
615
|
+
}
|
|
498
616
|
interface Title {
|
|
499
617
|
/**
|
|
500
618
|
* Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
|
|
@@ -578,6 +696,12 @@ interface ServiceProperties {
|
|
|
578
696
|
* @max 10000
|
|
579
697
|
*/
|
|
580
698
|
numberOfParticipants?: number | null;
|
|
699
|
+
/**
|
|
700
|
+
* Date and time the service is to be ended, in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.
|
|
701
|
+
* For example, the date and time a class will end.
|
|
702
|
+
* @internal
|
|
703
|
+
*/
|
|
704
|
+
endDate?: Date | null;
|
|
581
705
|
}
|
|
582
706
|
interface PriceDescription {
|
|
583
707
|
/**
|
|
@@ -649,6 +773,14 @@ interface AdditionalFee {
|
|
|
649
773
|
* > **Note:** Tax is not calculated in the returned `price` even when `taxDetails.taxable` is `true`.
|
|
650
774
|
*/
|
|
651
775
|
taxDetails?: TaxDetails;
|
|
776
|
+
/**
|
|
777
|
+
* Number of subscription cycle this fee applies to
|
|
778
|
+
* default None - all billing cycle
|
|
779
|
+
* @internal
|
|
780
|
+
* @min 1
|
|
781
|
+
* @max 999
|
|
782
|
+
*/
|
|
783
|
+
subscriptionCycles?: number | null;
|
|
652
784
|
}
|
|
653
785
|
/** Tax details. */
|
|
654
786
|
interface TaxDetails {
|
|
@@ -783,12 +915,23 @@ interface BasicItem {
|
|
|
783
915
|
_id?: string;
|
|
784
916
|
/** The name of the item. */
|
|
785
917
|
name?: string;
|
|
918
|
+
/**
|
|
919
|
+
* Item price range - the minimum and maximum prices of all the item's variants.
|
|
920
|
+
* @internal
|
|
921
|
+
* @readonly
|
|
922
|
+
*/
|
|
923
|
+
priceRange?: NumericPropertyRange;
|
|
786
924
|
/** Item Media items. */
|
|
787
925
|
image?: string[];
|
|
788
926
|
/** The current status of the inventory */
|
|
789
927
|
inStock?: boolean;
|
|
790
928
|
/** current version of an item. Each time the item is modified, its `revision` changes */
|
|
791
929
|
revision?: string | null;
|
|
930
|
+
/**
|
|
931
|
+
* True if the item has any subscription plan defined
|
|
932
|
+
* @internal
|
|
933
|
+
*/
|
|
934
|
+
isSubscription?: boolean;
|
|
792
935
|
/**
|
|
793
936
|
* Unique numeric ID
|
|
794
937
|
* @readonly
|
|
@@ -810,6 +953,13 @@ interface PagingMetadata {
|
|
|
810
953
|
total?: number | null;
|
|
811
954
|
/** Flag that indicates the server failed to calculate the `total` field. */
|
|
812
955
|
tooManyToCount?: boolean | null;
|
|
956
|
+
/**
|
|
957
|
+
* Indicates if there are more results after the current page.
|
|
958
|
+
* If `true`, another page of results can be retrieved.
|
|
959
|
+
* If `false`, this is the last page.
|
|
960
|
+
* @internal
|
|
961
|
+
*/
|
|
962
|
+
hasNext?: boolean | null;
|
|
813
963
|
}
|
|
814
964
|
interface CatalogSPIConfig {
|
|
815
965
|
/** Base URI which Wix eCommerce will call to access Catalog service plugin endpoints. For example, to call the Get Catalog Items endpoint at `https://my-external-catalog.com/get-catalog-items`, the base URI you provide here is `https://my-external-catalog.com`. */
|
|
@@ -827,6 +977,18 @@ interface AllItemsDiscountConfig {
|
|
|
827
977
|
* Default: `false`.
|
|
828
978
|
*/
|
|
829
979
|
enabled?: boolean;
|
|
980
|
+
/**
|
|
981
|
+
* Translation key for text to display to the site owner.
|
|
982
|
+
* __Deprecated.__ Use `name` instead.
|
|
983
|
+
* @internal
|
|
984
|
+
* @minLength 5
|
|
985
|
+
* @maxLength 30
|
|
986
|
+
* @deprecated Translation key for text to display to the site owner.
|
|
987
|
+
* __Deprecated.__ Use `name` instead.
|
|
988
|
+
* @replacedBy name
|
|
989
|
+
* @targetRemovalDate 2024-05-01
|
|
990
|
+
*/
|
|
991
|
+
translationKey?: string;
|
|
830
992
|
/**
|
|
831
993
|
* Translatable name for "all items discount" in the catalog.
|
|
832
994
|
* For example, for restaurant menus, this could be "All dishes".
|
|
@@ -843,6 +1005,18 @@ interface SpecificItemsDiscountConfig {
|
|
|
843
1005
|
* Default: `false`.
|
|
844
1006
|
*/
|
|
845
1007
|
enabled?: boolean;
|
|
1008
|
+
/**
|
|
1009
|
+
* Translation key for text to display to the site owner. deprecated use name instead .
|
|
1010
|
+
* For example, for restaurant menus, this could be "Specific dishes".
|
|
1011
|
+
* @internal
|
|
1012
|
+
* @minLength 5
|
|
1013
|
+
* @maxLength 30
|
|
1014
|
+
* @deprecated Translation key for text to display to the site owner. deprecated use name instead .
|
|
1015
|
+
* For example, for restaurant menus, this could be "Specific dishes".
|
|
1016
|
+
* @replacedBy name
|
|
1017
|
+
* @targetRemovalDate 2024-05-01
|
|
1018
|
+
*/
|
|
1019
|
+
translationKey?: string;
|
|
846
1020
|
/**
|
|
847
1021
|
* Translatable name for "all items discount" in the catalog.
|
|
848
1022
|
* @minLength 1
|
|
@@ -880,6 +1054,24 @@ interface Context {
|
|
|
880
1054
|
* @format GUID
|
|
881
1055
|
*/
|
|
882
1056
|
instanceId?: string | null;
|
|
1057
|
+
/**
|
|
1058
|
+
* Extension ID in Dev Center.
|
|
1059
|
+
* @internal
|
|
1060
|
+
* @maxLength 256
|
|
1061
|
+
*/
|
|
1062
|
+
appExtensionId?: string | null;
|
|
1063
|
+
/**
|
|
1064
|
+
* Extension type in Dev Center.
|
|
1065
|
+
* @internal
|
|
1066
|
+
* @maxLength 256
|
|
1067
|
+
*/
|
|
1068
|
+
appExtensionType?: string | null;
|
|
1069
|
+
/**
|
|
1070
|
+
* Invoked function.
|
|
1071
|
+
* @internal
|
|
1072
|
+
* @maxLength 256
|
|
1073
|
+
*/
|
|
1074
|
+
functionName?: string | null;
|
|
883
1075
|
}
|
|
884
1076
|
declare enum IdentityType {
|
|
885
1077
|
UNKNOWN = "UNKNOWN",
|
|
@@ -968,4 +1160,4 @@ declare const provideHandlers: ServicePluginDefinition<{
|
|
|
968
1160
|
getCatalogItems(payload: GetCatalogItemsEnvelope): GetCatalogItemsResponse | Promise<GetCatalogItemsResponse>;
|
|
969
1161
|
}>;
|
|
970
1162
|
|
|
971
|
-
export { type
|
|
1163
|
+
export { type BasicItem as $, PaymentOptionType as A, type BuyerInfo as B, type CatalogReferenceAndQuantity as C, type DescriptionLine as D, type ServiceProperties as E, type FreeTrialPeriod as F, type GetCatalogItemsRequest as G, type PriceDescription as H, type Item as I, type TaxableAddress as J, type TaxableAddressTaxableAddressDataOneOf as K, TaxableAddressType as L, type Policy as M, type AdditionalFee as N, type TaxDetails as O, type ProductName as P, type ModifierGroup as Q, type TranslatableString as R, type Scope as S, type Title as T, type ItemModifier as U, type PlatformFee as V, WeightUnit as W, ChargeType as X, type QueryCatalogItemsRequest as Y, type Paging as Z, type QueryCatalogItemsResponse as _, type CatalogReference as a, type NumericPropertyRange as a0, type PagingMetadata as a1, type CatalogSPIConfig as a2, type AllItemsDiscountConfig as a3, type SpecificItemsDiscountConfig as a4, type Context as a5, IdentityType as a6, type IdentificationData as a7, type IdentificationDataIdOneOf as a8, type GetCatalogItemsEnvelope as a9, type BuyerInfoIdOneOf as b, type GetCatalogItemsResponse as c, type ItemData as d, type ItemType as e, type ItemTypeItemTypeDataOneOf as f, ItemTypePreset as g, type DescriptionLineValueOneOf as h, type DescriptionLineDescriptionLineValueOneOf as i, type DescriptionLineName as j, type PlainTextValue as k, type Color as l, DescriptionLineType as m, type PhysicalProperties as n, type Dimensions as o, provideHandlers as p, DimensionsUnit as q, type Group as r, type SubscriptionOptionInfo as s, type SubscriptionSettings as t, SubscriptionFrequency as u, type BillingSettings as v, ProductPeriodAlignment as w, type Description as x, type SecuredMedia as y, FileType as z };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { p as provideHandlers$1 } from './interfaces-ecommerce-v1-catalog-provider.public-
|
|
2
|
-
export {
|
|
1
|
+
import { p as provideHandlers$1 } from './interfaces-ecommerce-v1-catalog-provider.public-CQVNMtC3.mjs';
|
|
2
|
+
export { N as AdditionalFee, a3 as AllItemsDiscountConfig, $ as BasicItem, v as BillingSettings, B as BuyerInfo, b as BuyerInfoIdOneOf, a as CatalogReference, C as CatalogReferenceAndQuantity, a2 as CatalogSPIConfig, X as ChargeType, l as Color, a5 as Context, x as Description, D as DescriptionLine, i as DescriptionLineDescriptionLineValueOneOf, j as DescriptionLineName, m as DescriptionLineType, h as DescriptionLineValueOneOf, o as Dimensions, q as DimensionsUnit, z as FileType, F as FreeTrialPeriod, G as GetCatalogItemsRequest, c as GetCatalogItemsResponse, r as Group, a7 as IdentificationData, a8 as IdentificationDataIdOneOf, a6 as IdentityType, I as Item, d as ItemData, U as ItemModifier, e as ItemType, f as ItemTypeItemTypeDataOneOf, g as ItemTypePreset, Q as ModifierGroup, a0 as NumericPropertyRange, Z as Paging, a1 as PagingMetadata, A as PaymentOptionType, n as PhysicalProperties, k as PlainTextValue, V as PlatformFee, M as Policy, H as PriceDescription, P as ProductName, w as ProductPeriodAlignment, Y as QueryCatalogItemsRequest, _ as QueryCatalogItemsResponse, S as Scope, y as SecuredMedia, E as ServiceProperties, a4 as SpecificItemsDiscountConfig, u as SubscriptionFrequency, s as SubscriptionOptionInfo, t as SubscriptionSettings, O as TaxDetails, J as TaxableAddress, K as TaxableAddressTaxableAddressDataOneOf, L as TaxableAddressType, T as Title, R as TranslatableString, W as WeightUnit } from './interfaces-ecommerce-v1-catalog-provider.public-CQVNMtC3.mjs';
|
|
3
3
|
import { BuildServicePluginDefinition } from '@wix/sdk-types';
|
|
4
4
|
|
|
5
5
|
declare const provideHandlers: BuildServicePluginDefinition<typeof provideHandlers$1> & typeof provideHandlers$1;
|
|
@@ -37,6 +37,11 @@ var SubscriptionFrequency = /* @__PURE__ */ ((SubscriptionFrequency2) => {
|
|
|
37
37
|
SubscriptionFrequency2["YEAR"] = "YEAR";
|
|
38
38
|
return SubscriptionFrequency2;
|
|
39
39
|
})(SubscriptionFrequency || {});
|
|
40
|
+
var ProductPeriodAlignment = /* @__PURE__ */ ((ProductPeriodAlignment2) => {
|
|
41
|
+
ProductPeriodAlignment2["ALIGNED_WITH_BILLING_PERIOD"] = "ALIGNED_WITH_BILLING_PERIOD";
|
|
42
|
+
ProductPeriodAlignment2["NOT_ALIGNED_WITH_BILLING_PERIOD"] = "NOT_ALIGNED_WITH_BILLING_PERIOD";
|
|
43
|
+
return ProductPeriodAlignment2;
|
|
44
|
+
})(ProductPeriodAlignment || {});
|
|
40
45
|
var FileType = /* @__PURE__ */ ((FileType2) => {
|
|
41
46
|
FileType2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
42
47
|
FileType2["SECURE_PICTURE"] = "SECURE_PICTURE";
|
|
@@ -140,6 +145,7 @@ export {
|
|
|
140
145
|
IdentityType,
|
|
141
146
|
ItemTypePreset,
|
|
142
147
|
PaymentOptionType,
|
|
148
|
+
ProductPeriodAlignment,
|
|
143
149
|
SubscriptionFrequency,
|
|
144
150
|
TaxableAddressType,
|
|
145
151
|
WeightUnit,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/service-plugins-types.ts","../../../src/interfaces-ecommerce-v1-catalog-provider.public.ts","../../../src/interfaces-ecommerce-v1-catalog-provider.context.ts"],"sourcesContent":["export interface GetCatalogItemsRequest {\n /**\n * Catalog reference details for the items to retrieve, including quantity of each item.\n * @minSize 1\n * @maxSize 300\n */\n catalogReferences?: CatalogReferenceAndQuantity[];\n /**\n * Weight measurement unit.\n *\n * By default, Wix sends the weight unit specified in the site's settings.\n */\n weightUnit?: WeightUnit;\n /**\n * Currency to return item prices in, in [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) format. For example, `USD` or `EUR`.\n *\n * By default, Wix sends the currency specified in the site's settings.\n * @format CURRENCY\n */\n currency?: string;\n}\n\nexport interface CatalogReferenceAndQuantity {\n /** Catalog and item reference info. Holds IDs for the item and the catalog it belongs to, as well as further optional details. This is identical in the request and response. */\n catalogReference?: CatalogReference;\n /** Item quantity. */\n quantity?: number;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport enum WeightUnit {\n /** Weight unit can't be classified due to an error. */\n UNSPECIFIED_WEIGHT_UNIT = 'UNSPECIFIED_WEIGHT_UNIT',\n /** Kilograms. */\n KG = 'KG',\n /** Pounds. */\n LB = 'LB',\n}\n\n/** Buyer Info */\nexport interface BuyerInfo extends BuyerInfoIdOneOf {\n /**\n * Visitor ID - if the buyer is **not** a site member.\n * @format GUID\n * @readonly\n */\n visitorId?: string;\n /**\n * Member ID - if the buyer is a site member.\n * @format GUID\n * @readonly\n */\n memberId?: string;\n /**\n * User ID - if the buyer (or cart owner) is a Wix user.\n * @format GUID\n * @readonly\n */\n userId?: string;\n /**\n * Contact ID. For more information, see [Contacts API](https://dev.wix.com/api/rest/contacts/contacts/introduction).\n * @format GUID\n */\n contactId?: string | null;\n /**\n * Buyer email address.\n * @format EMAIL\n */\n email?: string | null;\n}\n\n/** @oneof */\nexport interface BuyerInfoIdOneOf {\n /**\n * Visitor ID - if the buyer is **not** a site member.\n * @format GUID\n * @readonly\n */\n visitorId?: string;\n /**\n * Member ID - if the buyer is a site member.\n * @format GUID\n * @readonly\n */\n memberId?: string;\n /**\n * User ID - if the buyer (or cart owner) is a Wix user.\n * @format GUID\n * @readonly\n */\n userId?: string;\n}\n\nexport interface GetCatalogItemsResponse {\n /**\n * Details for each item, including catalog reference details and item data. Any items that don't exist in the catalog are excluded.\n * If none of the requested items exist in the catalog, this array must be empty.\n */\n catalogItems?: Item[];\n}\n\nexport interface Item {\n /** Catalog and item reference info. Holds IDs for the item and the catalog it belongs to, as well as further optional details. This is identical in the request and response. */\n catalogReference?: CatalogReference;\n /** Item data. Contains full details about the item. */\n data?: ItemData;\n}\n\nexport interface ItemData {\n /** __Required.__ Item name. */\n productName?: ProductName;\n /**\n * URL for the item's page on the site.\n *\n * This is used to link back to the relevant item page from the cart page. If not provided, the site URL is used.\n */\n url?: string;\n /** __Required.__ Item type. Either one of the preset types or a custom type. */\n itemType?: ItemType;\n /**\n * __Required.__ Item price with discounts applied. If a catalog-defined discount applies, the discount is reflected in this price.\n * @decimalValue options { gte:0, lte:1000000000000000 }\n */\n price?: string;\n /**\n * Item price **before** applying any catalog-defined discount.\n *\n * Default: Value of `price` field, if no catalog-defined discount applies.\n * @format DECIMAL_VALUE\n */\n fullPrice?: string | null;\n /**\n * The tax group ID associated with this item. Learn more about the [Tax Groups Service Plugin](https://dev.wix.com/docs/rest/business-solutions/e-commerce/service-plugins/tax-groups-integration-service-plugin/introduction).\n * @format GUID\n */\n taxGroupId?: string | null;\n /**\n * Line item description lines. Used for displaying the item in a cart, checkout or order. For example, if you want `Size: Large` to appear under the item name, create a description line with `\"name\": {\"original\": \"Size\"}` and `\"plainText\": {\"original\": \"Large\"}`.\n *\n * Default: No description line.\n * @maxSize 20\n */\n descriptionLines?: DescriptionLine[];\n /**\n * Line item image details. Supports images from the [Wix Media Manager](https://support.wix.com/en/article/wix-media-accessing-the-media-manager) only.\n *\n * To use an image from another source, first upload it to the Media Manager.\n * You can retrieve the ID, width and height of an image from the Wix Media Manager.\n */\n media?: string;\n /**\n * Quantity of the item available for purchase. Only return if the catalog manages inventory.\n * If not returned, a buyer can increase the quantity of this item to add to the cart or checkout without limit.\n * @max 100000000\n */\n quantityAvailable?: number | null;\n /** Physical properties of the item. Only return for physical items. When applicable, contains information such as SKU and item weight. */\n physicalProperties?: PhysicalProperties;\n /** Subscription option info. */\n subscriptionOptionInfo?: SubscriptionOptionInfo;\n /**\n * Type of selected payment option for current item.\n *\n * Default: `FULL_PAYMENT_ONLINE`\n */\n paymentOption?: PaymentOptionType;\n /** Service properties. When applicable, this contains information such as time and number of participants. */\n serviceProperties?: ServiceProperties;\n /**\n * Additional ID for the item in the catalog.\n * This field provides an additional identifier for the item if your flow requires another ID as well as `catalogReference.catalogItemId`.\n * Can be used for membership validation.\n *\n * Default: Same as `catalogReference.catalogItemId`.\n * @minLength 1\n * @maxLength 36\n */\n rootCatalogItemId?: string | null;\n /**\n * Additional description for the price. Return when additional information about the price is needed.\n *\n * For example, when `price` is `\"0\"` but additional details about the actual price are needed, such as `\"Starts at $67\"`.\n */\n priceDescription?: PriceDescription;\n /**\n * Partial payment to be paid upfront during the checkout. Return when `paymentOption` is `DEPOSIT_ONLINE`.\n *\n * Default: If `paymentOption` is `DEPOSIT_ONLINE` but `depositAmount` is not provided, the item is treated as if `paymentOption` is `FULL_PAYMENT_ONLINE`.\n * @format DECIMAL_VALUE\n */\n depositAmount?: string | null;\n /**\n * Delivery profile ID for the product.\n * @format GUID\n */\n deliveryProfileId?: string | null;\n /**\n * Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page.\n * @minLength 1\n * @maxLength 2500\n */\n consentRequiredPaymentPolicy?: string | null;\n /**\n * Whether the price is not yet defined, and will be updated after the order is created.\n *\n * Default: `false`\n */\n priceUndetermined?: boolean;\n /**\n * Whether the line item quantity is fixed and cannot be changed.\n *\n * Default: `false`\n */\n fixedQuantity?: boolean;\n /**\n * Whether to save the payment method on the order.\n *\n * Default: `false`\n */\n savePaymentMethod?: boolean;\n /** Address to use for tax calculation purposes. */\n taxableAddress?: TaxableAddress;\n /**\n * Policies to be displayed to the customer on the checkout page.\n * @maxSize 5\n */\n policies?: Policy[];\n /**\n * Additional Fees to be added to this item calculation.\n * @maxSize 5\n */\n additionalFees?: AdditionalFee[];\n /**\n * Whether the item can only be purchased by site members.\n *\n * Default: `false`\n */\n membersOnly?: boolean;\n /**\n * Modifier groups that were added to the item.\n * @maxSize 25\n */\n modifierGroups?: ModifierGroup[];\n}\n\nexport interface ProductName {\n /**\n * __Required.__ Item name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * Item name translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\nexport interface ItemType extends ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePreset;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\n/** @oneof */\nexport interface ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePreset;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\nexport enum ItemTypePreset {\n UNRECOGNISED = 'UNRECOGNISED',\n PHYSICAL = 'PHYSICAL',\n DIGITAL = 'DIGITAL',\n GIFT_CARD = 'GIFT_CARD',\n SERVICE = 'SERVICE',\n}\n\nexport interface DescriptionLine\n extends DescriptionLineValueOneOf,\n DescriptionLineDescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n /** Description line name. */\n name?: DescriptionLineName;\n}\n\n/** @oneof */\nexport interface DescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n}\n\n/** @oneof */\nexport interface DescriptionLineDescriptionLineValueOneOf {}\n\nexport interface DescriptionLineName {\n /**\n * Description line name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @maxLength 100\n */\n original?: string;\n /**\n * Description line name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 200\n */\n translated?: string | null;\n}\n\nexport interface PlainTextValue {\n /**\n * Description line plain text value in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @maxLength 600\n */\n original?: string;\n /**\n * Description line plain text value translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 600\n */\n translated?: string | null;\n}\n\nexport interface Color {\n /**\n * Description line color name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @maxLength 500\n */\n original?: string;\n /**\n * Description line color name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 500\n */\n translated?: string | null;\n /** HEX or RGB color code for display. */\n code?: string | null;\n}\n\nexport enum DescriptionLineType {\n /** Unrecognized type. */\n UNRECOGNISED = 'UNRECOGNISED',\n /** Plain text type. */\n PLAIN_TEXT = 'PLAIN_TEXT',\n /** Color type. */\n COLOR = 'COLOR',\n}\n\nexport interface PhysicalProperties {\n /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */\n weight?: number | null;\n /**\n * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).\n * @maxLength 40\n */\n sku?: string | null;\n /** Whether this line item is shippable. */\n shippable?: boolean;\n}\n\nexport interface Dimensions {\n /**\n * Length. Measurement unit is handled at the system level (metric/imperial).\n * @decimalValue options { gte:0, lte:999999999, maxScale:6 }\n */\n length?: string | null;\n /**\n * Width. Measurement unit is handled at the system level (metric/imperial).\n * @decimalValue options { gte:0, lte:999999999, maxScale:6 }\n */\n width?: string | null;\n /**\n * Height. Measurement unit is handled at the system level (metric/imperial).\n * @decimalValue options { gte:0, lte:999999999, maxScale:6 }\n */\n height?: string | null;\n /** Unit of measurement for dimensions (length, width, height). */\n unit?: DimensionsUnit;\n}\n\nexport enum DimensionsUnit {\n UNKNOWN_DIMENSIONS_UNIT = 'UNKNOWN_DIMENSIONS_UNIT',\n /** Millimeters. */\n MM = 'MM',\n /** Centimeters. */\n CM = 'CM',\n /** Meters. */\n M = 'M',\n /** Inches. */\n IN = 'IN',\n /** Feet. */\n FT = 'FT',\n /** Yards. */\n YD = 'YD',\n}\n\nexport interface Scope {\n /** Scope namespace (Wix Stores, Wix Bookings, Wix Events, Wix Pricing Plans) */\n namespace?: string;\n /** Coupon scope's applied group (e.g., event or ticket in Wix Events) */\n group?: Group;\n}\n\nexport interface Group {\n /** Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */\n name?: string;\n /** Item ID (when the coupon scope is limited to just one item). */\n entityId?: string | null;\n}\n\nexport interface SubscriptionOptionInfo {\n /** Subscription option settings. */\n subscriptionSettings?: SubscriptionSettings;\n /** Subscription option title. */\n title?: Title;\n /** Subscription option description. */\n description?: Description;\n}\n\nexport interface SubscriptionSettings {\n /** Frequency of recurring payment. */\n frequency?: SubscriptionFrequency;\n /**\n * Interval of recurring payment.\n *\n * Default: `1`.\n * If SubscriptionFrequency is Day the minimum interval is 7\n * @min 1\n * @max 3650\n */\n interval?: number | null;\n /** Whether subscription is renewed automatically at the end of each period. */\n autoRenewal?: boolean;\n /**\n * Number of billing cycles before subscription ends. Ignored if `autoRenewal` is `true`.\n * @min 1\n */\n billingCycles?: number | null;\n /** Whether to allow the customer to cancel the subscription.. */\n enableCustomerCancellation?: boolean;\n /**\n * Period until first cycle starts. If applied payNow will be 0\n * If None => no free trial\n */\n freeTrialPeriod?: FreeTrialPeriod;\n}\n\n/** Frequency unit of recurring payment */\nexport enum SubscriptionFrequency {\n UNDEFINED = 'UNDEFINED',\n DAY = 'DAY',\n WEEK = 'WEEK',\n MONTH = 'MONTH',\n YEAR = 'YEAR',\n}\n\nexport interface FreeTrialPeriod {\n /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */\n frequency?: SubscriptionFrequency;\n /**\n * Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial.\n * @min 1\n * @max 999\n */\n interval?: number;\n}\n\nexport interface BillingSettings {\n /**\n * Day of month (1-28) to anchor recurring billing to. When set, billing recurs on this day each cycle. Does not apply to weekly subscriptions.\n * @min 1\n * @max 28\n */\n anchorDay?: number | null;\n}\n\nexport interface Title {\n /**\n * Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @minLength 1\n * @maxLength 150\n */\n original?: string;\n /**\n * Subscription option name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 150\n */\n translated?: string | null;\n}\n\nexport interface Description {\n /**\n * Subscription option description.\n * @maxLength 500\n */\n original?: string;\n /**\n * Translated subscription option description.\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface SecuredMedia {\n /**\n * Media ID in Wix Media Manager.\n * @minLength 1\n * @maxLength 100\n */\n _id?: string;\n /**\n * Original filename.\n * @minLength 1\n * @maxLength 1000\n */\n fileName?: string;\n /** File type. */\n fileType?: FileType;\n}\n\nexport enum FileType {\n UNSPECIFIED = 'UNSPECIFIED',\n SECURE_PICTURE = 'SECURE_PICTURE',\n SECURE_VIDEO = 'SECURE_VIDEO',\n SECURE_DOCUMENT = 'SECURE_DOCUMENT',\n SECURE_MUSIC = 'SECURE_MUSIC',\n SECURE_ARCHIVE = 'SECURE_ARCHIVE',\n SECURE_RAW = 'SECURE_RAW',\n}\n\n/** Type of selected payment option for catalog item */\nexport enum PaymentOptionType {\n /** The entire payment for this item happens as part of the checkout. */\n FULL_PAYMENT_ONLINE = 'FULL_PAYMENT_ONLINE',\n /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */\n FULL_PAYMENT_OFFLINE = 'FULL_PAYMENT_OFFLINE',\n /** Payment for this item is done by charging a membership. Any remaining amount not covered by the membership, such as item modifiers, is paid online. */\n MEMBERSHIP = 'MEMBERSHIP',\n /** Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. */\n DEPOSIT_ONLINE = 'DEPOSIT_ONLINE',\n /** Payment for this item can only be done by charging a membership and must be manually redeemed in the dashboard by the site admin. When selected, `price` is `0`. */\n MEMBERSHIP_OFFLINE = 'MEMBERSHIP_OFFLINE',\n /**\n * Item price is charged to online membership. Any remaining amount not covered by the membership, such as item modifiers, is paid offline.\n * @documentationMaturity preview\n */\n MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER = 'MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER',\n}\n\nexport interface ServiceProperties {\n /**\n * Date and time the service is to be provided, in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.\n * For example, the start time of a class.\n */\n scheduledDate?: Date | null;\n /**\n * The number of people participating in the service. For example, the number of people attending a class or the number of people per hotel room.\n * @min 1\n * @max 10000\n */\n numberOfParticipants?: number | null;\n}\n\nexport interface PriceDescription {\n /**\n * __Required.__ Price description in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @minLength 1\n * @maxLength 100\n */\n original?: string;\n /**\n * Price description translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 100\n */\n translated?: string | null;\n}\n\nexport interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressType;\n}\n\n/** @oneof */\nexport interface TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressType;\n}\n\nexport enum TaxableAddressType {\n BUSINESS = 'BUSINESS',\n BILLING = 'BILLING',\n SHIPPING = 'SHIPPING',\n}\n\nexport interface Policy {\n /**\n * Policy title - should be translated\n * @minLength 1\n * @maxLength 29\n */\n title?: string | null;\n /**\n * Policy content - should be translated\n * @minLength 1\n * @maxLength 3000\n */\n content?: string;\n}\n\nexport interface AdditionalFee {\n /**\n * Additional fee's unique code or ID.\n * @minLength 1\n * @maxLength 100\n */\n code?: string | null;\n /**\n * Additional fee's name.\n *\n * Max: 50 characters\n * @minLength 1\n * @maxLength 50\n */\n name?: string;\n /**\n * Total additional fees. This `price` does not include any taxes that may apply to these additional fees.\n * @decimalValue options { gte:0, lte:1000000000000000, maxScale:2 }\n */\n price?: string;\n /**\n * Tax details.\n *\n * > **Note:** Tax is not calculated in the returned `price` even when `taxDetails.taxable` is `true`.\n */\n taxDetails?: TaxDetails;\n}\n\n/** Tax details. */\nexport interface TaxDetails {\n /** Whether additional fee is taxable. */\n taxable?: boolean;\n /**\n * Reserved for internal use.\n * @format GUID\n */\n taxGroupId?: string | null;\n}\n\nexport interface ModifierGroup {\n /**\n * Modifier group ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /** Modifier group name. */\n name?: TranslatableString;\n /**\n * List of modifiers in this group.\n * @minSize 1\n * @maxSize 25\n */\n modifiers?: ItemModifier[];\n}\n\nexport interface TranslatableString {\n /**\n * __Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * String translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\nexport interface ItemModifier {\n /**\n * Modifier ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /**\n * The quantity of this modifier.\n * @min 1\n * @max 100000\n */\n quantity?: number | null;\n /** Primary display label for the modifier. */\n label?: TranslatableString;\n /** Additional details. */\n details?: TranslatableString;\n /**\n * The price of the modifier.\n * @decimalValue options { gte:0, lte:1000000000000000, maxScale:3 }\n */\n price?: string | null;\n}\n\nexport interface PlatformFee {\n /** __Required.__ Platform fee name. */\n name?: TranslatableString;\n /** Platform fee charge type. */\n chargeType?: ChargeType;\n /**\n * Percentage rate charged as platform fee.\n *\n * The fee rate percentage expressed as a decimal fraction between 0 and 1. For example, `0.05` for 5%.\n * @format DECIMAL_VALUE\n * @decimalValue options { gt:0, lte:1, maxScale:4 }\n */\n percentageRate?: string;\n}\n\nexport enum ChargeType {\n /** The platform fee is passed on to the customer. */\n PASS_ON = 'PASS_ON',\n /** The platform fee is absorbed by the merchant. */\n ABSORBED = 'ABSORBED',\n}\n\nexport interface QueryCatalogItemsRequest {\n /**\n * A list of itemIDs to filter by. If exists, the result will only include the items with the IDs passed.\n * @minLength 1\n * @maxLength 100\n * @maxSize 100\n */\n catalogItemIds?: string[] | null;\n /**\n * An item name to filter by. If exists, the result will only include items with name that starts with this string.\n * @minLength 1\n * @maxLength 100\n */\n catalogItemName?: string | null;\n /** Paging options to limit and skip a number of items. */\n paging?: Paging;\n /**\n * Optional, if exist add filter by numericId gt last_numeric_id\n * https://dev.wix.com/api/rest/wix-stores/pagination#wix-stores_pagination_pagination\n */\n lastNumericId?: string | null;\n}\n\nexport interface Paging {\n /** Number of items to load. */\n limit?: number | null;\n /** Number of items to skip in the current sort order. */\n offset?: number | null;\n}\n\nexport interface QueryCatalogItemsResponse {\n /** Catalog info and item data. */\n catalogItems?: BasicItem[];\n /** Paging metadata. */\n metadata?: PagingMetadata;\n}\n\nexport interface BasicItem {\n /**\n * The ID of the item.\n * @minLength 1\n * @maxLength 100\n */\n _id?: string;\n /** The name of the item. */\n name?: string;\n /** Item Media items. */\n image?: string[];\n /** The current status of the inventory */\n inStock?: boolean;\n /** current version of an item. Each time the item is modified, its `revision` changes */\n revision?: string | null;\n /**\n * Unique numeric ID\n * @readonly\n */\n numericId?: string | null;\n}\n\nexport interface NumericPropertyRange {\n /** Minimum value. */\n minValue?: number;\n /** Maximum value. */\n maxValue?: number;\n}\n\nexport interface PagingMetadata {\n /** Number of items returned in the response. */\n count?: number | null;\n /** Offset that was requested. */\n offset?: number | null;\n /** Total number of items that match the query. */\n total?: number | null;\n /** Flag that indicates the server failed to calculate the `total` field. */\n tooManyToCount?: boolean | null;\n}\n\nexport interface CatalogSPIConfig {\n /** Base URI which Wix eCommerce will call to access Catalog service plugin endpoints. For example, to call the Get Catalog Items endpoint at `https://my-external-catalog.com/get-catalog-items`, the base URI you provide here is `https://my-external-catalog.com`. */\n deploymentUri?: string;\n /** Configuration details for discounts applied to all items in the catalog. */\n allItemsDiscount?: AllItemsDiscountConfig;\n /** Configuration details for discounts applied to specific items in the catalog. */\n specificItemsDiscount?: SpecificItemsDiscountConfig;\n}\n\n/** Configuration for all items discount functionality in the catalog. */\nexport interface AllItemsDiscountConfig {\n /**\n * Whether the discount is enabled.\n *\n * Default: `false`.\n */\n enabled?: boolean;\n /**\n * Translatable name for \"all items discount\" in the catalog.\n * For example, for restaurant menus, this could be \"All dishes\".\n * @minLength 1\n * @maxLength 100\n */\n name?: string | null;\n}\n\n/** Configuration for discount functionality in the catalog. */\nexport interface SpecificItemsDiscountConfig {\n /**\n * Whether the discount is enabled.\n *\n * Default: `false`.\n */\n enabled?: boolean;\n /**\n * Translatable name for \"all items discount\" in the catalog.\n * @minLength 1\n * @maxLength 100\n */\n name?: string | null;\n}\n\n/**\n * this message is not directly used by any service,\n * it exists to describe the expected parameters that SHOULD be provided to invoked Velo methods as part of open-platform.\n * e.g. SPIs, event-handlers, etc..\n * NOTE: this context object MUST be provided as the last argument in each Velo method signature.\n *\n * Example:\n * ```typescript\n * export function wixStores_onOrderCanceled({ event, metadata }: OrderCanceledEvent) {\n * ...\n * }\n * ```\n */\nexport interface Context {\n /** 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. */\n requestId?: string | null;\n /**\n * [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) 3-letter currency code.\n * @format CURRENCY\n */\n currency?: string | null;\n /** An object that describes the identity that triggered this request. */\n identity?: IdentificationData;\n /** 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\"`. */\n languages?: string[];\n /**\n * The service provider app's instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n}\n\nexport enum IdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: IdentityType;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n","import { ServicePluginDefinition } from '@wix/sdk-types';\nimport {\n Context,\n GetCatalogItemsRequest,\n GetCatalogItemsResponse,\n} from './service-plugins-types.js';\nimport { transformSDKImageToRESTImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformSDKPageURLV2ToRESTPageURLV2 } from '@wix/sdk-runtime/transformations/page-url-v2';\nimport { transformSDKFloatToRESTFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\n\nexport interface GetCatalogItemsEnvelope {\n request: GetCatalogItemsRequest;\n metadata: Context;\n}\n\nexport const provideHandlers = ServicePluginDefinition<{\n /**\n *\n * Retrieves data for specified items in a specified catalog.\n *\n * Wix calls this method whenever a cart or checkout is updated, and when an item is added to an order.\n *\n * The method receives a `catalogReferences` array. Each catalog reference in the array contains:\n * + The ID of the item whose latest information Wix needs to retrieve.\n * + The ID of the app providing the catalog containing the item.\n * + Optional details about preferences or customization of the item.\n *\n * The method also receives preferences for the currency and weight unit to be used in the response.\n *\n * Your external catalog can store and organize item details in any way you prefer.\n * When implementing the Catalog service plugin, learn how to [handle item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants) in a way that meets your needs.\n *\n * The method's response must contain a `catalogItems` array. Each item in the array must contain:\n * + A `catalogReference` object. This must be identical to the `catalogReference` object received in the request.\n * + A `data` object with full details about the item.\n *\n * > **Notes:**\n * > + If an item doesn't exist in the catalog, the response must exclude it from the `catalogItems` array in the response.\n * > + When none of the items requested exist in the catalog, `catalogItems` must contain an empty array.\n * > + Wix calls the method every time a cart or checkout is updated. If the response doesn't include an item that was already in the cart or checkout, Wix removes the item from the cart or checkout. */\n getCatalogItems(\n payload: GetCatalogItemsEnvelope\n ): GetCatalogItemsResponse | Promise<GetCatalogItemsResponse>;\n}>('ECOM_CATALOG', [\n {\n name: 'getCatalogItems',\n primaryHttpMappingPath: '/get-catalog-items',\n transformations: {\n toREST: (payload: any) => {\n const toRestResponse = transformPaths(payload, [\n {\n transformFn: transformSDKPageURLV2ToRESTPageURLV2,\n paths: [{ path: 'catalogItems.data.url' }],\n },\n {\n transformFn: transformSDKImageToRESTImage,\n paths: [{ path: 'catalogItems.data.media' }],\n },\n {\n transformFn: transformSDKFloatToRESTFloat,\n paths: [{ path: 'catalogItems.data.physicalProperties.weight' }],\n },\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n {\n path: 'catalogItems.data.subscriptionOptionInfo.subscriptionSettings.startDate',\n },\n { path: 'catalogItems.data.serviceProperties.scheduledDate' },\n { path: 'catalogItems.data.serviceProperties.endDate' },\n ],\n },\n ]);\n\n return renameKeysFromSDKRequestToRESTRequest(toRestResponse);\n },\n fromREST: (payload: any) => {\n const fromRestRequest = payload;\n\n return renameKeysFromRESTResponseToSDKResponse(fromRestRequest);\n },\n },\n },\n]);\n","import './interfaces-ecommerce-v1-catalog-provider.public.js';\nimport { createServicePluginModule } from '@wix/sdk-runtime/service-plugin-modules';\nimport { BuildServicePluginDefinition } from '@wix/sdk-types';\nimport { provideHandlers as publicProvideHandlers } from './interfaces-ecommerce-v1-catalog-provider.public.js';\n\nexport { publicProvideHandlers };\n\nexport const provideHandlers: BuildServicePluginDefinition<\n typeof publicProvideHandlers\n> &\n typeof publicProvideHandlers = createServicePluginModule(\n publicProvideHandlers\n);\n"],"mappings":";AA4DO,IAAK,aAAL,kBAAKA,gBAAL;AAEL,EAAAA,YAAA,6BAA0B;AAE1B,EAAAA,YAAA,QAAK;AAEL,EAAAA,YAAA,QAAK;AANK,SAAAA;AAAA,GAAA;AA4PL,IAAK,iBAAL,kBAAKC,oBAAL;AACL,EAAAA,gBAAA,kBAAe;AACf,EAAAA,gBAAA,cAAW;AACX,EAAAA,gBAAA,aAAU;AACV,EAAAA,gBAAA,eAAY;AACZ,EAAAA,gBAAA,aAAU;AALA,SAAAA;AAAA,GAAA;AA6EL,IAAK,sBAAL,kBAAKC,yBAAL;AAEL,EAAAA,qBAAA,kBAAe;AAEf,EAAAA,qBAAA,gBAAa;AAEb,EAAAA,qBAAA,WAAQ;AANE,SAAAA;AAAA,GAAA;AAyCL,IAAK,iBAAL,kBAAKC,oBAAL;AACL,EAAAA,gBAAA,6BAA0B;AAE1B,EAAAA,gBAAA,QAAK;AAEL,EAAAA,gBAAA,QAAK;AAEL,EAAAA,gBAAA,OAAI;AAEJ,EAAAA,gBAAA,QAAK;AAEL,EAAAA,gBAAA,QAAK;AAEL,EAAAA,gBAAA,QAAK;AAbK,SAAAA;AAAA,GAAA;AAoEL,IAAK,wBAAL,kBAAKC,2BAAL;AACL,EAAAA,uBAAA,eAAY;AACZ,EAAAA,uBAAA,SAAM;AACN,EAAAA,uBAAA,UAAO;AACP,EAAAA,uBAAA,WAAQ;AACR,EAAAA,uBAAA,UAAO;AALG,SAAAA;AAAA,GAAA;AA2EL,IAAK,WAAL,kBAAKC,cAAL;AACL,EAAAA,UAAA,iBAAc;AACd,EAAAA,UAAA,oBAAiB;AACjB,EAAAA,UAAA,kBAAe;AACf,EAAAA,UAAA,qBAAkB;AAClB,EAAAA,UAAA,kBAAe;AACf,EAAAA,UAAA,oBAAiB;AACjB,EAAAA,UAAA,gBAAa;AAPH,SAAAA;AAAA,GAAA;AAWL,IAAK,oBAAL,kBAAKC,uBAAL;AAEL,EAAAA,mBAAA,yBAAsB;AAEtB,EAAAA,mBAAA,0BAAuB;AAEvB,EAAAA,mBAAA,gBAAa;AAEb,EAAAA,mBAAA,oBAAiB;AAEjB,EAAAA,mBAAA,wBAAqB;AAKrB,EAAAA,mBAAA,8CAA2C;AAfjC,SAAAA;AAAA,GAAA;AA4DL,IAAK,qBAAL,kBAAKC,wBAAL;AACL,EAAAA,oBAAA,cAAW;AACX,EAAAA,oBAAA,aAAU;AACV,EAAAA,oBAAA,cAAW;AAHD,SAAAA;AAAA,GAAA;AA0IL,IAAK,aAAL,kBAAKC,gBAAL;AAEL,EAAAA,YAAA,aAAU;AAEV,EAAAA,YAAA,cAAW;AAJD,SAAAA;AAAA,GAAA;AA8JL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,aAAU;AACV,EAAAA,cAAA,uBAAoB;AACpB,EAAAA,cAAA,YAAS;AACT,EAAAA,cAAA,cAAW;AACX,EAAAA,cAAA,SAAM;AALI,SAAAA;AAAA,GAAA;;;AC56BZ,SAAS,+BAA+B;AAMxC,SAAS,oCAAoC;AAC7C,SAAS,4CAA4C;AACrD,SAAS,oCAAoC;AAC7C,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B;AAAA,EACE;AAAA,EACA;AAAA,OACK;AAOA,IAAM,kBAAkB,wBA4B5B,gBAAgB;AAAA,EACjB;AAAA,IACE,MAAM;AAAA,IACN,wBAAwB;AAAA,IACxB,iBAAiB;AAAA,MACf,QAAQ,CAAC,YAAiB;AACxB,cAAM,iBAAiB,eAAe,SAAS;AAAA,UAC7C;AAAA,YACE,aAAa;AAAA,YACb,OAAO,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAAA,UAC3C;AAAA,UACA;AAAA,YACE,aAAa;AAAA,YACb,OAAO,CAAC,EAAE,MAAM,0BAA0B,CAAC;AAAA,UAC7C;AAAA,UACA;AAAA,YACE,aAAa;AAAA,YACb,OAAO,CAAC,EAAE,MAAM,8CAA8C,CAAC;AAAA,UACjE;AAAA,UACA;AAAA,YACE,aAAa;AAAA,YACb,OAAO;AAAA,cACL;AAAA,gBACE,MAAM;AAAA,cACR;AAAA,cACA,EAAE,MAAM,oDAAoD;AAAA,cAC5D,EAAE,MAAM,8CAA8C;AAAA,YACxD;AAAA,UACF;AAAA,QACF,CAAC;AAED,eAAO,sCAAsC,cAAc;AAAA,MAC7D;AAAA,MACA,UAAU,CAAC,YAAiB;AAC1B,cAAM,kBAAkB;AAExB,eAAO,wCAAwC,eAAe;AAAA,MAChE;AAAA,IACF;AAAA,EACF;AACF,CAAC;;;ACxFD,SAAS,iCAAiC;AAMnC,IAAMC,mBAGoB;AAAA,EAC/B;AACF;","names":["WeightUnit","ItemTypePreset","DescriptionLineType","DimensionsUnit","SubscriptionFrequency","FileType","PaymentOptionType","TaxableAddressType","ChargeType","IdentityType","provideHandlers"]}
|
|
1
|
+
{"version":3,"sources":["../../../src/service-plugins-types.ts","../../../src/interfaces-ecommerce-v1-catalog-provider.public.ts","../../../src/interfaces-ecommerce-v1-catalog-provider.context.ts"],"sourcesContent":["export interface GetCatalogItemsRequest {\n /**\n * Catalog reference details for the items to retrieve, including quantity of each item.\n * @minSize 1\n * @maxSize 300\n */\n catalogReferences?: CatalogReferenceAndQuantity[];\n /**\n * Weight measurement unit.\n *\n * By default, Wix sends the weight unit specified in the site's settings.\n */\n weightUnit?: WeightUnit;\n /**\n * Currency to return item prices in, in [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) format. For example, `USD` or `EUR`.\n *\n * By default, Wix sends the currency specified in the site's settings.\n * @format CURRENCY\n */\n currency?: string;\n /**\n * The business location ID associated with the requested items.\n * Learn more about the [Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).\n * @internal\n * @format GUID\n */\n businessLocationId?: string | null;\n /**\n * Buyer information.\n * @internal\n */\n buyerInfo?: BuyerInfo;\n}\n\nexport interface CatalogReferenceAndQuantity {\n /** Catalog and item reference info. Holds IDs for the item and the catalog it belongs to, as well as further optional details. This is identical in the request and response. */\n catalogReference?: CatalogReference;\n /** Item quantity. */\n quantity?: number;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport enum WeightUnit {\n /** Weight unit can't be classified due to an error. */\n UNSPECIFIED_WEIGHT_UNIT = 'UNSPECIFIED_WEIGHT_UNIT',\n /** Kilograms. */\n KG = 'KG',\n /** Pounds. */\n LB = 'LB',\n}\n\n/** Buyer Info */\nexport interface BuyerInfo extends BuyerInfoIdOneOf {\n /**\n * Visitor ID - if the buyer is **not** a site member.\n * @format GUID\n * @readonly\n */\n visitorId?: string;\n /**\n * Member ID - if the buyer is a site member.\n * @format GUID\n * @readonly\n */\n memberId?: string;\n /**\n * User ID - if the buyer (or cart owner) is a Wix user.\n * @format GUID\n * @readonly\n */\n userId?: string;\n /**\n * Contact ID. For more information, see [Contacts API](https://dev.wix.com/api/rest/contacts/contacts/introduction).\n * @format GUID\n */\n contactId?: string | null;\n /**\n * Buyer email address.\n * @format EMAIL\n */\n email?: string | null;\n}\n\n/** @oneof */\nexport interface BuyerInfoIdOneOf {\n /**\n * Visitor ID - if the buyer is **not** a site member.\n * @format GUID\n * @readonly\n */\n visitorId?: string;\n /**\n * Member ID - if the buyer is a site member.\n * @format GUID\n * @readonly\n */\n memberId?: string;\n /**\n * User ID - if the buyer (or cart owner) is a Wix user.\n * @format GUID\n * @readonly\n */\n userId?: string;\n}\n\nexport interface GetCatalogItemsResponse {\n /**\n * Details for each item, including catalog reference details and item data. Any items that don't exist in the catalog are excluded.\n * If none of the requested items exist in the catalog, this array must be empty.\n */\n catalogItems?: Item[];\n}\n\nexport interface Item {\n /** Catalog and item reference info. Holds IDs for the item and the catalog it belongs to, as well as further optional details. This is identical in the request and response. */\n catalogReference?: CatalogReference;\n /** Item data. Contains full details about the item. */\n data?: ItemData;\n}\n\nexport interface ItemData {\n /** __Required.__ Item name. */\n productName?: ProductName;\n /**\n * URL for the item's page on the site.\n *\n * This is used to link back to the relevant item page from the cart page. If not provided, the site URL is used.\n */\n url?: string;\n /** __Required.__ Item type. Either one of the preset types or a custom type. */\n itemType?: ItemType;\n /**\n * __Required.__ Item price with discounts applied. If a catalog-defined discount applies, the discount is reflected in this price.\n * @decimalValue options { gte:0, lte:1000000000000000 }\n */\n price?: string;\n /**\n * Item price **before** applying any catalog-defined discount.\n *\n * Default: Value of `price` field, if no catalog-defined discount applies.\n * @format DECIMAL_VALUE\n */\n fullPrice?: string | null;\n /**\n * The tax group ID associated with this item. Learn more about the [Tax Groups Service Plugin](https://dev.wix.com/docs/rest/business-solutions/e-commerce/service-plugins/tax-groups-integration-service-plugin/introduction).\n * @format GUID\n */\n taxGroupId?: string | null;\n /**\n * Line item description lines. Used for displaying the item in a cart, checkout or order. For example, if you want `Size: Large` to appear under the item name, create a description line with `\"name\": {\"original\": \"Size\"}` and `\"plainText\": {\"original\": \"Large\"}`.\n *\n * Default: No description line.\n * @maxSize 20\n */\n descriptionLines?: DescriptionLine[];\n /**\n * Line item image details. Supports images from the [Wix Media Manager](https://support.wix.com/en/article/wix-media-accessing-the-media-manager) only.\n *\n * To use an image from another source, first upload it to the Media Manager.\n * You can retrieve the ID, width and height of an image from the Wix Media Manager.\n */\n media?: string;\n /**\n * Quantity of the item available for purchase. Only return if the catalog manages inventory.\n * If not returned, a buyer can increase the quantity of this item to add to the cart or checkout without limit.\n * @max 100000000\n */\n quantityAvailable?: number | null;\n /** Physical properties of the item. Only return for physical items. When applicable, contains information such as SKU and item weight. */\n physicalProperties?: PhysicalProperties;\n /**\n * Coupon scopes. These specify which app and items a coupon applies to.\n * Should be used by Bookings, Stores, and Events in line with the current [Coupons API](https://bo.wix.com/wix-docs/rest/stores/coupons/valid-scope-values).\n * @internal\n */\n couponScopes?: Scope[];\n /** Subscription option info. */\n subscriptionOptionInfo?: SubscriptionOptionInfo;\n /**\n * ID of the fulfiller for this item. This field is internal and only used by Stores.\n * @internal\n * @format GUID\n */\n fulfillerId?: string | null;\n /**\n * Digital file details. Required if `itemType.preset` is `DIGITAL`.\n * @internal\n */\n digitalFile?: SecuredMedia;\n /**\n * Deprecated. Use the `deliveryProfileId` instead.\n * Shipping group ID. This field is internal and only used by Stores.\n * @internal\n * @format GUID\n * @readonly\n * @deprecated Deprecated. Use the `deliveryProfileId` instead.\n * Shipping group ID. This field is internal and only used by Stores.\n * @targetRemovalDate 2025-02-13\n */\n shippingGroupId?: string | null;\n /**\n * Type of selected payment option for current item.\n *\n * Default: `FULL_PAYMENT_ONLINE`\n */\n paymentOption?: PaymentOptionType;\n /** Service properties. When applicable, this contains information such as time and number of participants. */\n serviceProperties?: ServiceProperties;\n /**\n * Additional ID for the item in the catalog.\n * This field provides an additional identifier for the item if your flow requires another ID as well as `catalogReference.catalogItemId`.\n * Can be used for membership validation.\n *\n * Default: Same as `catalogReference.catalogItemId`.\n * @minLength 1\n * @maxLength 36\n */\n rootCatalogItemId?: string | null;\n /**\n * Additional description for the price. Return when additional information about the price is needed.\n *\n * For example, when `price` is `\"0\"` but additional details about the actual price are needed, such as `\"Starts at $67\"`.\n */\n priceDescription?: PriceDescription;\n /**\n * Partial payment to be paid upfront during the checkout. Return when `paymentOption` is `DEPOSIT_ONLINE`.\n *\n * Default: If `paymentOption` is `DEPOSIT_ONLINE` but `depositAmount` is not provided, the item is treated as if `paymentOption` is `FULL_PAYMENT_ONLINE`.\n * @format DECIMAL_VALUE\n */\n depositAmount?: string | null;\n /**\n * Delivery profile ID for the product.\n * @format GUID\n */\n deliveryProfileId?: string | null;\n /**\n * Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page.\n * @minLength 1\n * @maxLength 2500\n */\n consentRequiredPaymentPolicy?: string | null;\n /**\n * Whether the price is not yet defined, and will be updated after the order is created.\n *\n * Default: `false`\n */\n priceUndetermined?: boolean;\n /**\n * Whether the line item quantity is fixed and cannot be changed.\n *\n * Default: `false`\n */\n fixedQuantity?: boolean;\n /**\n * Whether to save the payment method on the order.\n *\n * Default: `false`\n */\n savePaymentMethod?: boolean;\n /** Address to use for tax calculation purposes. */\n taxableAddress?: TaxableAddress;\n /**\n * ID of the app managing the inventory.\n * @internal\n * @format GUID\n */\n inventoryAppId?: string | null;\n /**\n * Policies to be displayed to the customer on the checkout page.\n * @maxSize 5\n */\n policies?: Policy[];\n /**\n * Additional Fees to be added to this item calculation.\n * @maxSize 5\n */\n additionalFees?: AdditionalFee[];\n /**\n * Whether the item can only be purchased by site members.\n *\n * Default: `false`\n */\n membersOnly?: boolean;\n /**\n * Modifier groups that were added to the item.\n * @maxSize 25\n */\n modifierGroups?: ModifierGroup[];\n /**\n * Platform fee to be added to this item calculation. This field is internal for Wix verticals.\n * @internal\n */\n platformFee?: PlatformFee;\n /**\n * ID of the app providing upsells for this item.\n * @internal\n * @format GUID\n */\n upsellOptionsAppId?: string | null;\n}\n\nexport interface ProductName {\n /**\n * __Required.__ Item name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * Item name translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\nexport interface ItemType extends ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePreset;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\n/** @oneof */\nexport interface ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePreset;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\nexport enum ItemTypePreset {\n UNRECOGNISED = 'UNRECOGNISED',\n PHYSICAL = 'PHYSICAL',\n DIGITAL = 'DIGITAL',\n GIFT_CARD = 'GIFT_CARD',\n SERVICE = 'SERVICE',\n}\n\nexport interface DescriptionLine\n extends DescriptionLineValueOneOf,\n DescriptionLineDescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n /**\n * Description line plain text value.\n * @internal\n * @deprecated\n */\n plainTextValue?: PlainTextValue;\n /**\n * Description line color.\n * @internal\n * @deprecated\n */\n color?: string;\n /** Description line name. */\n name?: DescriptionLineName;\n /**\n * Description line type.\n * @internal\n * @deprecated\n */\n lineType?: DescriptionLineType;\n}\n\n/** @oneof */\nexport interface DescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n}\n\n/** @oneof */\nexport interface DescriptionLineDescriptionLineValueOneOf {\n /**\n * Description line plain text value.\n * @internal\n * @deprecated\n */\n plainTextValue?: PlainTextValue;\n /**\n * Description line color.\n * @internal\n * @deprecated\n */\n color?: string;\n}\n\nexport interface DescriptionLineName {\n /**\n * Description line name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @maxLength 100\n */\n original?: string;\n /**\n * Description line name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 200\n */\n translated?: string | null;\n}\n\nexport interface PlainTextValue {\n /**\n * Description line plain text value in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @maxLength 600\n */\n original?: string;\n /**\n * Description line plain text value translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 600\n */\n translated?: string | null;\n}\n\nexport interface Color {\n /**\n * Description line color name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @maxLength 500\n */\n original?: string;\n /**\n * Description line color name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 500\n */\n translated?: string | null;\n /** HEX or RGB color code for display. */\n code?: string | null;\n}\n\nexport enum DescriptionLineType {\n /** Unrecognized type. */\n UNRECOGNISED = 'UNRECOGNISED',\n /** Plain text type. */\n PLAIN_TEXT = 'PLAIN_TEXT',\n /** Color type. */\n COLOR = 'COLOR',\n}\n\nexport interface PhysicalProperties {\n /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */\n weight?: number | null;\n /**\n * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).\n * @maxLength 40\n */\n sku?: string | null;\n /** Whether this line item is shippable. */\n shippable?: boolean;\n /**\n * Product dimensions (length, width, height of the physical product).\n * @internal\n */\n productDimensions?: Dimensions;\n /**\n * Package dimensions (length, width, height of the shipping package).\n * @internal\n */\n packageDimensions?: Dimensions;\n}\n\nexport interface Dimensions {\n /**\n * Length. Measurement unit is handled at the system level (metric/imperial).\n * @decimalValue options { gte:0, lte:999999999, maxScale:6 }\n */\n length?: string | null;\n /**\n * Width. Measurement unit is handled at the system level (metric/imperial).\n * @decimalValue options { gte:0, lte:999999999, maxScale:6 }\n */\n width?: string | null;\n /**\n * Height. Measurement unit is handled at the system level (metric/imperial).\n * @decimalValue options { gte:0, lte:999999999, maxScale:6 }\n */\n height?: string | null;\n /** Unit of measurement for dimensions (length, width, height). */\n unit?: DimensionsUnit;\n}\n\nexport enum DimensionsUnit {\n UNKNOWN_DIMENSIONS_UNIT = 'UNKNOWN_DIMENSIONS_UNIT',\n /** Millimeters. */\n MM = 'MM',\n /** Centimeters. */\n CM = 'CM',\n /** Meters. */\n M = 'M',\n /** Inches. */\n IN = 'IN',\n /** Feet. */\n FT = 'FT',\n /** Yards. */\n YD = 'YD',\n}\n\nexport interface Scope {\n /** Scope namespace (Wix Stores, Wix Bookings, Wix Events, Wix Pricing Plans) */\n namespace?: string;\n /** Coupon scope's applied group (e.g., event or ticket in Wix Events) */\n group?: Group;\n}\n\nexport interface Group {\n /** Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */\n name?: string;\n /** Item ID (when the coupon scope is limited to just one item). */\n entityId?: string | null;\n}\n\nexport interface SubscriptionOptionInfo {\n /** Subscription option settings. */\n subscriptionSettings?: SubscriptionSettings;\n /** Subscription option title. */\n title?: Title;\n /** Subscription option description. */\n description?: Description;\n}\n\nexport interface SubscriptionSettings {\n /** Frequency of recurring payment. */\n frequency?: SubscriptionFrequency;\n /**\n * Interval of recurring payment.\n *\n * Default: `1`.\n * If SubscriptionFrequency is Day the minimum interval is 7\n * @min 1\n * @max 3650\n */\n interval?: number | null;\n /** Whether subscription is renewed automatically at the end of each period. */\n autoRenewal?: boolean;\n /**\n * Number of billing cycles before subscription ends. Ignored if `autoRenewal` is `true`.\n * @min 1\n */\n billingCycles?: number | null;\n /** Whether to allow the customer to cancel the subscription.. */\n enableCustomerCancellation?: boolean;\n /**\n * Period until first cycle starts. If applied payNow will be 0\n * If None => no free trial\n */\n freeTrialPeriod?: FreeTrialPeriod;\n /**\n * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.\n * @internal\n */\n startDate?: Date | null;\n /**\n * Billing configuration for recurring charges.\n * @internal\n */\n billingSettings?: BillingSettings;\n /**\n * Whether the product/service/subscription access period is aligned with the billing period.\n * @internal\n */\n productPeriodAlignment?: ProductPeriodAlignment;\n}\n\n/** Frequency unit of recurring payment */\nexport enum SubscriptionFrequency {\n UNDEFINED = 'UNDEFINED',\n DAY = 'DAY',\n WEEK = 'WEEK',\n MONTH = 'MONTH',\n YEAR = 'YEAR',\n}\n\nexport interface FreeTrialPeriod {\n /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */\n frequency?: SubscriptionFrequency;\n /**\n * Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial.\n * @min 1\n * @max 999\n */\n interval?: number;\n}\n\nexport interface BillingSettings {\n /**\n * Day of month (1-28) to anchor recurring billing to. When set, billing recurs on this day each cycle. Does not apply to weekly subscriptions.\n * @min 1\n * @max 28\n */\n anchorDay?: number | null;\n}\n\nexport enum ProductPeriodAlignment {\n /** Billing period equals the product/service/subscription access period. */\n ALIGNED_WITH_BILLING_PERIOD = 'ALIGNED_WITH_BILLING_PERIOD',\n /** Billing period is independent of the product/service/subscription access period. */\n NOT_ALIGNED_WITH_BILLING_PERIOD = 'NOT_ALIGNED_WITH_BILLING_PERIOD',\n}\n\nexport interface Title {\n /**\n * Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @minLength 1\n * @maxLength 150\n */\n original?: string;\n /**\n * Subscription option name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 150\n */\n translated?: string | null;\n}\n\nexport interface Description {\n /**\n * Subscription option description.\n * @maxLength 500\n */\n original?: string;\n /**\n * Translated subscription option description.\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface SecuredMedia {\n /**\n * Media ID in Wix Media Manager.\n * @minLength 1\n * @maxLength 100\n */\n _id?: string;\n /**\n * Original filename.\n * @minLength 1\n * @maxLength 1000\n */\n fileName?: string;\n /** File type. */\n fileType?: FileType;\n}\n\nexport enum FileType {\n UNSPECIFIED = 'UNSPECIFIED',\n SECURE_PICTURE = 'SECURE_PICTURE',\n SECURE_VIDEO = 'SECURE_VIDEO',\n SECURE_DOCUMENT = 'SECURE_DOCUMENT',\n SECURE_MUSIC = 'SECURE_MUSIC',\n SECURE_ARCHIVE = 'SECURE_ARCHIVE',\n SECURE_RAW = 'SECURE_RAW',\n}\n\n/** Type of selected payment option for catalog item */\nexport enum PaymentOptionType {\n /** The entire payment for this item happens as part of the checkout. */\n FULL_PAYMENT_ONLINE = 'FULL_PAYMENT_ONLINE',\n /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */\n FULL_PAYMENT_OFFLINE = 'FULL_PAYMENT_OFFLINE',\n /** Payment for this item is done by charging a membership. Any remaining amount not covered by the membership, such as item modifiers, is paid online. */\n MEMBERSHIP = 'MEMBERSHIP',\n /** Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. */\n DEPOSIT_ONLINE = 'DEPOSIT_ONLINE',\n /** Payment for this item can only be done by charging a membership and must be manually redeemed in the dashboard by the site admin. When selected, `price` is `0`. */\n MEMBERSHIP_OFFLINE = 'MEMBERSHIP_OFFLINE',\n /**\n * Item price is charged to online membership. Any remaining amount not covered by the membership, such as item modifiers, is paid offline.\n * @documentationMaturity preview\n */\n MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER = 'MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER',\n}\n\nexport interface ServiceProperties {\n /**\n * Date and time the service is to be provided, in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.\n * For example, the start time of a class.\n */\n scheduledDate?: Date | null;\n /**\n * The number of people participating in the service. For example, the number of people attending a class or the number of people per hotel room.\n * @min 1\n * @max 10000\n */\n numberOfParticipants?: number | null;\n /**\n * Date and time the service is to be ended, in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.\n * For example, the date and time a class will end.\n * @internal\n */\n endDate?: Date | null;\n}\n\nexport interface PriceDescription {\n /**\n * __Required.__ Price description in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n * @minLength 1\n * @maxLength 100\n */\n original?: string;\n /**\n * Price description translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 100\n */\n translated?: string | null;\n}\n\nexport interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressType;\n}\n\n/** @oneof */\nexport interface TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressType;\n}\n\nexport enum TaxableAddressType {\n BUSINESS = 'BUSINESS',\n BILLING = 'BILLING',\n SHIPPING = 'SHIPPING',\n}\n\nexport interface Policy {\n /**\n * Policy title - should be translated\n * @minLength 1\n * @maxLength 29\n */\n title?: string | null;\n /**\n * Policy content - should be translated\n * @minLength 1\n * @maxLength 3000\n */\n content?: string;\n}\n\nexport interface AdditionalFee {\n /**\n * Additional fee's unique code or ID.\n * @minLength 1\n * @maxLength 100\n */\n code?: string | null;\n /**\n * Additional fee's name.\n *\n * Max: 50 characters\n * @minLength 1\n * @maxLength 50\n */\n name?: string;\n /**\n * Total additional fees. This `price` does not include any taxes that may apply to these additional fees.\n * @decimalValue options { gte:0, lte:1000000000000000, maxScale:2 }\n */\n price?: string;\n /**\n * Tax details.\n *\n * > **Note:** Tax is not calculated in the returned `price` even when `taxDetails.taxable` is `true`.\n */\n taxDetails?: TaxDetails;\n /**\n * Number of subscription cycle this fee applies to\n * default None - all billing cycle\n * @internal\n * @min 1\n * @max 999\n */\n subscriptionCycles?: number | null;\n}\n\n/** Tax details. */\nexport interface TaxDetails {\n /** Whether additional fee is taxable. */\n taxable?: boolean;\n /**\n * Reserved for internal use.\n * @format GUID\n */\n taxGroupId?: string | null;\n}\n\nexport interface ModifierGroup {\n /**\n * Modifier group ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /** Modifier group name. */\n name?: TranslatableString;\n /**\n * List of modifiers in this group.\n * @minSize 1\n * @maxSize 25\n */\n modifiers?: ItemModifier[];\n}\n\nexport interface TranslatableString {\n /**\n * __Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * String translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\nexport interface ItemModifier {\n /**\n * Modifier ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /**\n * The quantity of this modifier.\n * @min 1\n * @max 100000\n */\n quantity?: number | null;\n /** Primary display label for the modifier. */\n label?: TranslatableString;\n /** Additional details. */\n details?: TranslatableString;\n /**\n * The price of the modifier.\n * @decimalValue options { gte:0, lte:1000000000000000, maxScale:3 }\n */\n price?: string | null;\n}\n\nexport interface PlatformFee {\n /** __Required.__ Platform fee name. */\n name?: TranslatableString;\n /** Platform fee charge type. */\n chargeType?: ChargeType;\n /**\n * Percentage rate charged as platform fee.\n *\n * The fee rate percentage expressed as a decimal fraction between 0 and 1. For example, `0.05` for 5%.\n * @format DECIMAL_VALUE\n * @decimalValue options { gt:0, lte:1, maxScale:4 }\n */\n percentageRate?: string;\n}\n\nexport enum ChargeType {\n /** The platform fee is passed on to the customer. */\n PASS_ON = 'PASS_ON',\n /** The platform fee is absorbed by the merchant. */\n ABSORBED = 'ABSORBED',\n}\n\nexport interface QueryCatalogItemsRequest {\n /**\n * A list of itemIDs to filter by. If exists, the result will only include the items with the IDs passed.\n * @minLength 1\n * @maxLength 100\n * @maxSize 100\n */\n catalogItemIds?: string[] | null;\n /**\n * An item name to filter by. If exists, the result will only include items with name that starts with this string.\n * @minLength 1\n * @maxLength 100\n */\n catalogItemName?: string | null;\n /** Paging options to limit and skip a number of items. */\n paging?: Paging;\n /**\n * Optional, if exist add filter by numericId gt last_numeric_id\n * https://dev.wix.com/api/rest/wix-stores/pagination#wix-stores_pagination_pagination\n */\n lastNumericId?: string | null;\n}\n\nexport interface Paging {\n /** Number of items to load. */\n limit?: number | null;\n /** Number of items to skip in the current sort order. */\n offset?: number | null;\n}\n\nexport interface QueryCatalogItemsResponse {\n /** Catalog info and item data. */\n catalogItems?: BasicItem[];\n /** Paging metadata. */\n metadata?: PagingMetadata;\n}\n\nexport interface BasicItem {\n /**\n * The ID of the item.\n * @minLength 1\n * @maxLength 100\n */\n _id?: string;\n /** The name of the item. */\n name?: string;\n /**\n * Item price range - the minimum and maximum prices of all the item's variants.\n * @internal\n * @readonly\n */\n priceRange?: NumericPropertyRange;\n /** Item Media items. */\n image?: string[];\n /** The current status of the inventory */\n inStock?: boolean;\n /** current version of an item. Each time the item is modified, its `revision` changes */\n revision?: string | null;\n /**\n * True if the item has any subscription plan defined\n * @internal\n */\n isSubscription?: boolean;\n /**\n * Unique numeric ID\n * @readonly\n */\n numericId?: string | null;\n}\n\nexport interface NumericPropertyRange {\n /** Minimum value. */\n minValue?: number;\n /** Maximum value. */\n maxValue?: number;\n}\n\nexport interface PagingMetadata {\n /** Number of items returned in the response. */\n count?: number | null;\n /** Offset that was requested. */\n offset?: number | null;\n /** Total number of items that match the query. */\n total?: number | null;\n /** Flag that indicates the server failed to calculate the `total` field. */\n tooManyToCount?: boolean | null;\n /**\n * Indicates if there are more results after the current page.\n * If `true`, another page of results can be retrieved.\n * If `false`, this is the last page.\n * @internal\n */\n hasNext?: boolean | null;\n}\n\nexport interface CatalogSPIConfig {\n /** Base URI which Wix eCommerce will call to access Catalog service plugin endpoints. For example, to call the Get Catalog Items endpoint at `https://my-external-catalog.com/get-catalog-items`, the base URI you provide here is `https://my-external-catalog.com`. */\n deploymentUri?: string;\n /** Configuration details for discounts applied to all items in the catalog. */\n allItemsDiscount?: AllItemsDiscountConfig;\n /** Configuration details for discounts applied to specific items in the catalog. */\n specificItemsDiscount?: SpecificItemsDiscountConfig;\n}\n\n/** Configuration for all items discount functionality in the catalog. */\nexport interface AllItemsDiscountConfig {\n /**\n * Whether the discount is enabled.\n *\n * Default: `false`.\n */\n enabled?: boolean;\n /**\n * Translation key for text to display to the site owner.\n * __Deprecated.__ Use `name` instead.\n * @internal\n * @minLength 5\n * @maxLength 30\n * @deprecated Translation key for text to display to the site owner.\n * __Deprecated.__ Use `name` instead.\n * @replacedBy name\n * @targetRemovalDate 2024-05-01\n */\n translationKey?: string;\n /**\n * Translatable name for \"all items discount\" in the catalog.\n * For example, for restaurant menus, this could be \"All dishes\".\n * @minLength 1\n * @maxLength 100\n */\n name?: string | null;\n}\n\n/** Configuration for discount functionality in the catalog. */\nexport interface SpecificItemsDiscountConfig {\n /**\n * Whether the discount is enabled.\n *\n * Default: `false`.\n */\n enabled?: boolean;\n /**\n * Translation key for text to display to the site owner. deprecated use name instead .\n * For example, for restaurant menus, this could be \"Specific dishes\".\n * @internal\n * @minLength 5\n * @maxLength 30\n * @deprecated Translation key for text to display to the site owner. deprecated use name instead .\n * For example, for restaurant menus, this could be \"Specific dishes\".\n * @replacedBy name\n * @targetRemovalDate 2024-05-01\n */\n translationKey?: string;\n /**\n * Translatable name for \"all items discount\" in the catalog.\n * @minLength 1\n * @maxLength 100\n */\n name?: string | null;\n}\n\n/**\n * this message is not directly used by any service,\n * it exists to describe the expected parameters that SHOULD be provided to invoked Velo methods as part of open-platform.\n * e.g. SPIs, event-handlers, etc..\n * NOTE: this context object MUST be provided as the last argument in each Velo method signature.\n *\n * Example:\n * ```typescript\n * export function wixStores_onOrderCanceled({ event, metadata }: OrderCanceledEvent) {\n * ...\n * }\n * ```\n */\nexport interface Context {\n /** 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. */\n requestId?: string | null;\n /**\n * [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) 3-letter currency code.\n * @format CURRENCY\n */\n currency?: string | null;\n /** An object that describes the identity that triggered this request. */\n identity?: IdentificationData;\n /** 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\"`. */\n languages?: string[];\n /**\n * The service provider app's instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Extension ID in Dev Center.\n * @internal\n * @maxLength 256\n */\n appExtensionId?: string | null;\n /**\n * Extension type in Dev Center.\n * @internal\n * @maxLength 256\n */\n appExtensionType?: string | null;\n /**\n * Invoked function.\n * @internal\n * @maxLength 256\n */\n functionName?: string | null;\n}\n\nexport enum IdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: IdentityType;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n","import { ServicePluginDefinition } from '@wix/sdk-types';\nimport {\n Context,\n GetCatalogItemsRequest,\n GetCatalogItemsResponse,\n} from './service-plugins-types.js';\nimport { transformSDKImageToRESTImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformSDKPageURLV2ToRESTPageURLV2 } from '@wix/sdk-runtime/transformations/page-url-v2';\nimport { transformSDKFloatToRESTFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\n\nexport interface GetCatalogItemsEnvelope {\n request: GetCatalogItemsRequest;\n metadata: Context;\n}\n\nexport const provideHandlers = ServicePluginDefinition<{\n /**\n *\n * Retrieves data for specified items in a specified catalog.\n *\n * Wix calls this method whenever a cart or checkout is updated, and when an item is added to an order.\n *\n * The method receives a `catalogReferences` array. Each catalog reference in the array contains:\n * + The ID of the item whose latest information Wix needs to retrieve.\n * + The ID of the app providing the catalog containing the item.\n * + Optional details about preferences or customization of the item.\n *\n * The method also receives preferences for the currency and weight unit to be used in the response.\n *\n * Your external catalog can store and organize item details in any way you prefer.\n * When implementing the Catalog service plugin, learn how to [handle item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants) in a way that meets your needs.\n *\n * The method's response must contain a `catalogItems` array. Each item in the array must contain:\n * + A `catalogReference` object. This must be identical to the `catalogReference` object received in the request.\n * + A `data` object with full details about the item.\n *\n * > **Notes:**\n * > + If an item doesn't exist in the catalog, the response must exclude it from the `catalogItems` array in the response.\n * > + When none of the items requested exist in the catalog, `catalogItems` must contain an empty array.\n * > + Wix calls the method every time a cart or checkout is updated. If the response doesn't include an item that was already in the cart or checkout, Wix removes the item from the cart or checkout. */\n getCatalogItems(\n payload: GetCatalogItemsEnvelope\n ): GetCatalogItemsResponse | Promise<GetCatalogItemsResponse>;\n}>('ECOM_CATALOG', [\n {\n name: 'getCatalogItems',\n primaryHttpMappingPath: '/get-catalog-items',\n transformations: {\n toREST: (payload: any) => {\n const toRestResponse = transformPaths(payload, [\n {\n transformFn: transformSDKPageURLV2ToRESTPageURLV2,\n paths: [{ path: 'catalogItems.data.url' }],\n },\n {\n transformFn: transformSDKImageToRESTImage,\n paths: [{ path: 'catalogItems.data.media' }],\n },\n {\n transformFn: transformSDKFloatToRESTFloat,\n paths: [{ path: 'catalogItems.data.physicalProperties.weight' }],\n },\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [\n {\n path: 'catalogItems.data.subscriptionOptionInfo.subscriptionSettings.startDate',\n },\n { path: 'catalogItems.data.serviceProperties.scheduledDate' },\n { path: 'catalogItems.data.serviceProperties.endDate' },\n ],\n },\n ]);\n\n return renameKeysFromSDKRequestToRESTRequest(toRestResponse);\n },\n fromREST: (payload: any) => {\n const fromRestRequest = payload;\n\n return renameKeysFromRESTResponseToSDKResponse(fromRestRequest);\n },\n },\n },\n]);\n","import './interfaces-ecommerce-v1-catalog-provider.public.js';\nimport { createServicePluginModule } from '@wix/sdk-runtime/service-plugin-modules';\nimport { BuildServicePluginDefinition } from '@wix/sdk-types';\nimport { provideHandlers as publicProvideHandlers } from './interfaces-ecommerce-v1-catalog-provider.public.js';\n\nexport { publicProvideHandlers };\n\nexport const provideHandlers: BuildServicePluginDefinition<\n typeof publicProvideHandlers\n> &\n typeof publicProvideHandlers = createServicePluginModule(\n publicProvideHandlers\n);\n"],"mappings":"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","names":["WeightUnit","ItemTypePreset","DescriptionLineType","DimensionsUnit","SubscriptionFrequency","ProductPeriodAlignment","FileType","PaymentOptionType","TaxableAddressType","ChargeType","IdentityType","provideHandlers"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
1
|
+
import { a9 as GetCatalogItemsEnvelope, c as GetCatalogItemsResponse } from './interfaces-ecommerce-v1-catalog-provider.public-CQVNMtC3.mjs';
|
|
2
|
+
export { N as AdditionalFee, a3 as AllItemsDiscountConfig, $ as BasicItem, v as BillingSettings, B as BuyerInfo, b as BuyerInfoIdOneOf, a as CatalogReference, C as CatalogReferenceAndQuantity, a2 as CatalogSPIConfig, X as ChargeType, l as Color, a5 as Context, x as Description, D as DescriptionLine, i as DescriptionLineDescriptionLineValueOneOf, j as DescriptionLineName, m as DescriptionLineType, h as DescriptionLineValueOneOf, o as Dimensions, q as DimensionsUnit, z as FileType, F as FreeTrialPeriod, G as GetCatalogItemsRequest, r as Group, a7 as IdentificationData, a8 as IdentificationDataIdOneOf, a6 as IdentityType, I as Item, d as ItemData, U as ItemModifier, e as ItemType, f as ItemTypeItemTypeDataOneOf, g as ItemTypePreset, Q as ModifierGroup, a0 as NumericPropertyRange, Z as Paging, a1 as PagingMetadata, A as PaymentOptionType, n as PhysicalProperties, k as PlainTextValue, V as PlatformFee, M as Policy, H as PriceDescription, P as ProductName, w as ProductPeriodAlignment, Y as QueryCatalogItemsRequest, _ as QueryCatalogItemsResponse, S as Scope, y as SecuredMedia, E as ServiceProperties, a4 as SpecificItemsDiscountConfig, u as SubscriptionFrequency, s as SubscriptionOptionInfo, t as SubscriptionSettings, O as TaxDetails, J as TaxableAddress, K as TaxableAddressTaxableAddressDataOneOf, L as TaxableAddressType, T as Title, R as TranslatableString, W as WeightUnit } from './interfaces-ecommerce-v1-catalog-provider.public-CQVNMtC3.mjs';
|
|
3
3
|
import '@wix/sdk-types';
|
|
4
4
|
|
|
5
5
|
/**
|
|
@@ -37,6 +37,11 @@ var SubscriptionFrequency = /* @__PURE__ */ ((SubscriptionFrequency2) => {
|
|
|
37
37
|
SubscriptionFrequency2["YEAR"] = "YEAR";
|
|
38
38
|
return SubscriptionFrequency2;
|
|
39
39
|
})(SubscriptionFrequency || {});
|
|
40
|
+
var ProductPeriodAlignment = /* @__PURE__ */ ((ProductPeriodAlignment2) => {
|
|
41
|
+
ProductPeriodAlignment2["ALIGNED_WITH_BILLING_PERIOD"] = "ALIGNED_WITH_BILLING_PERIOD";
|
|
42
|
+
ProductPeriodAlignment2["NOT_ALIGNED_WITH_BILLING_PERIOD"] = "NOT_ALIGNED_WITH_BILLING_PERIOD";
|
|
43
|
+
return ProductPeriodAlignment2;
|
|
44
|
+
})(ProductPeriodAlignment || {});
|
|
40
45
|
var FileType = /* @__PURE__ */ ((FileType2) => {
|
|
41
46
|
FileType2["UNSPECIFIED"] = "UNSPECIFIED";
|
|
42
47
|
FileType2["SECURE_PICTURE"] = "SECURE_PICTURE";
|
|
@@ -83,6 +88,7 @@ export {
|
|
|
83
88
|
IdentityType,
|
|
84
89
|
ItemTypePreset,
|
|
85
90
|
PaymentOptionType,
|
|
91
|
+
ProductPeriodAlignment,
|
|
86
92
|
SubscriptionFrequency,
|
|
87
93
|
TaxableAddressType,
|
|
88
94
|
WeightUnit
|