@wix/stores 1.0.39 → 1.0.40
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/src/stores-catalog-v1-product-products.public.d.ts +2 -2
- package/build/cjs/src/stores-catalog-v1-product-products.public.js +5 -4
- package/build/cjs/src/stores-catalog-v1-product-products.public.js.map +1 -1
- package/build/cjs/src/stores-catalog-v1-product-products.types.d.ts +164 -158
- package/build/cjs/src/stores-catalog-v1-product-products.types.js +56 -44
- package/build/cjs/src/stores-catalog-v1-product-products.types.js.map +1 -1
- package/build/cjs/src/stores-catalog-v1-product-products.universal.d.ts +164 -168
- package/build/cjs/src/stores-catalog-v1-product-products.universal.js +58 -46
- package/build/cjs/src/stores-catalog-v1-product-products.universal.js.map +1 -1
- package/build/es/src/stores-catalog-v1-product-products.public.d.ts +2 -2
- package/build/es/src/stores-catalog-v1-product-products.public.js +1 -1
- package/build/es/src/stores-catalog-v1-product-products.public.js.map +1 -1
- package/build/es/src/stores-catalog-v1-product-products.types.d.ts +164 -158
- package/build/es/src/stores-catalog-v1-product-products.types.js +55 -43
- package/build/es/src/stores-catalog-v1-product-products.types.js.map +1 -1
- package/build/es/src/stores-catalog-v1-product-products.universal.d.ts +164 -168
- package/build/es/src/stores-catalog-v1-product-products.universal.js +57 -45
- package/build/es/src/stores-catalog-v1-product-products.universal.js.map +1 -1
- package/package.json +2 -2
|
@@ -2,5 +2,5 @@ import { HttpClient } from '@wix/sdk-types';
|
|
|
2
2
|
import { GetProductOptions } from './stores-catalog-v1-product-products.universal';
|
|
3
3
|
export declare function queryProducts(httpClient: HttpClient): () => import("./stores-catalog-v1-product-products.universal").ProductsQueryBuilder;
|
|
4
4
|
export declare function getProduct(httpClient: HttpClient): (_id: string, options?: GetProductOptions | undefined) => Promise<import("./stores-catalog-v1-product-products.universal").GetProductResponse>;
|
|
5
|
-
export { NodeType, WidthType, PluginContainerDataAlignment, Type, Target, TextAlignment, LineStyle, Width, Alignment, ViewMode, LayoutType, Orientation, Crop, ThumbnailsAlignment, Source, MapType, ViewRole, VoteRole, PollLayoutType, PollLayoutDirection, BackgroundType, DecorationType, FontType, AppType, InitialExpandedItems, Direction, VerticalAlignment, NullValue,
|
|
6
|
-
export { V1Product, RichContent, Node, NodeDataOneOf, NodeStyle, ButtonData, Border, Colors, PluginContainerData, PluginContainerDataWidth, PluginContainerDataWidthDataOneOf, Spoiler, Height, Styles, Link, LinkDataOneOf, Rel, CodeBlockData, TextStyle, DividerData, FileData, FileSource, FileSourceDataOneOf, PDFSettings, GalleryData, Rich_contentV1Media, Image, Video, Item, ItemDataOneOf, GalleryOptions, Layout, ItemStyle, Thumbnails, GIFData, GIF, HeadingData, HTMLData, HTMLDataDataOneOf, ImageData, LinkPreviewData, MapData, MapSettings, ParagraphData, PollData, Permissions, Option, PollSettings, PollLayout, OptionLayout, Gradient, Background, BackgroundBackgroundOneOf, PollDesign, OptionDesign, Poll, PollDataLayout, Design, TextData, Decoration, DecorationDataOneOf, AnchorData, ColorData, LinkData, MentionData, FontSizeData, AppEmbedData, AppEmbedDataAppDataOneOf, BookingData, EventData, VideoData, PlaybackOptions, EmbedData, Oembed, CollapsibleListData, TableData, Dimensions, TableCellData, CellStyle, BorderColors, ListValue, AudioData, OrderedListData, BulletedListData, BlockquoteData, Metadata, DocumentStyle, TextNodeStyle, V1Media, PlatformMedia, PlatformMediaMediaOneOf, VideoResolution, SeoSchema, Keyword, Tag, Settings,
|
|
5
|
+
export { NodeType, WidthType, PluginContainerDataAlignment, Type, Target, TextAlignment, LineStyle, Width, Alignment, ViewMode, LayoutType, Orientation, Crop, ThumbnailsAlignment, Source, MapType, ViewRole, VoteRole, PollLayoutType, PollLayoutDirection, BackgroundType, DecorationType, FontType, AppType, InitialExpandedItems, Direction, VerticalAlignment, NullValue, V1OptionType, ChoiceType, CustomizationType, PurchaseAvailabilityStatus, PreorderStatus, V1ProductType, MeasurementUnit, FileType, SortOrder, ProductType, InventoryStatus, MediaItemType, OptionType, DiscountType, } from './stores-catalog-v1-product-products.universal';
|
|
6
|
+
export { V1Product, V1ProductTypedPropertiesOneOf, RichContent, Node, NodeDataOneOf, NodeStyle, ButtonData, Border, Colors, PluginContainerData, PluginContainerDataWidth, PluginContainerDataWidthDataOneOf, Spoiler, Height, Styles, Link, LinkDataOneOf, Rel, CodeBlockData, TextStyle, DividerData, FileData, FileSource, FileSourceDataOneOf, PDFSettings, GalleryData, Rich_contentV1Media, Image, Video, Item, ItemDataOneOf, GalleryOptions, Layout, ItemStyle, Thumbnails, GIFData, GIF, HeadingData, HTMLData, HTMLDataDataOneOf, ImageData, LinkPreviewData, MapData, MapSettings, ParagraphData, PollData, Permissions, Option, PollSettings, PollLayout, OptionLayout, Gradient, Background, BackgroundBackgroundOneOf, PollDesign, OptionDesign, Poll, PollDataLayout, Design, TextData, Decoration, DecorationDataOneOf, AnchorData, ColorData, LinkData, MentionData, FontSizeData, AppEmbedData, AppEmbedDataAppDataOneOf, BookingData, EventData, VideoData, PlaybackOptions, EmbedData, Oembed, CollapsibleListData, TableData, Dimensions, TableCellData, CellStyle, BorderColors, ListValue, AudioData, OrderedListData, BulletedListData, BlockquoteData, Metadata, DocumentStyle, TextNodeStyle, V1Media, PlatformMedia, PlatformMediaMediaOneOf, VideoResolution, SeoSchema, Keyword, Tag, Settings, V1ProductOption, ProductChoice, ProductChoiceValueOneOf, MultipleColors, Brand, InfoSection, SubscriptionOptionInfo, Customization, CustomizationValueOneOf, TextInputValue, CheckboxValue, BreadCrumb, V1NumericPropertyRange, Inventory, V1PhysicalProperties, PricePerUnitSettings, V1CreateProductRequest, V1Variant, V1VariantTypedPropertiesOneOf, OptionChoice, PriceInfo, FixedMonetaryAmount, CostAndProfitInfo, PhysicalProperties, PricePerUnit, DigitalProperties, SecuredMedia, V1CreateProductResponse, V1GetProductRequest, V1GetProductResponse, V1UpdateProductRequest, V1UpdateProductResponse, V1DeleteProductRequest, V1DeleteProductResponse, V1QueryProductsRequest, CursorQuery, CursorQueryPagingMethodOneOf, Sorting, CursorPaging, V1QueryProductsResponse, CursorPagingMetadata, Cursors, SetProductOptionsRequest, OptionWithChoices, SetProductOptionsResponse, AddProductOptionChoicesRequest, AddProductOptionChoicesResponse, V1DeleteProductOptionsRequest, V1DeleteProductOptionsResponse, DeleteProductOptionChoicesRequest, DeleteProductOptionChoicesResponse, DomainEvent, DomainEventBodyOneOf, EntityCreatedEvent, EntityUpdatedEvent, EntityDeletedEvent, ActionEvent, ExtendedFieldsUpdatedEvent, Empty, Product, NumericPropertyRange, Stock, PriceData, FormattedPrice, CostAndProfitData, PricePerUnitData, AdditionalInfoSection, Ribbon, Media, MediaItem, MediaItemItemOneOf, MediaItemUrlAndSize, MediaItemVideo, CustomTextField, ProductOption, Choice, PageUrl, Discount, Variant, VariantDataWithNoStock, VariantStock, CreateProductRequest, CreateProductResponse, UpdateProductRequest, UpdateProductResponse, DeleteProductRequest, DeleteProductResponse, BulkDeleteProductsRequest, BulkDeleteProductsResponse, UpdateVariantsRequest, VariantOverride, UpdateVariantsResponse, ResetAllVariantDataRequest, ResetAllVariantDataResponse, AddProductsToCollectionRequest, AddProductsToCollectionResponse, RemoveProductsFromCollectionRequest, RemoveProductsFromCollectionResponse, AddProductMediaRequest, MediaDataForWrite, MediaDataForWriteMediaSourceOneOf, OptionAndChoice, AddProductMediaResponse, RemoveProductMediaRequest, RemoveProductMediaResponse, AddProductMediaToChoicesRequest, MediaAssignmentToChoice, AddProductMediaToChoicesResponse, RemoveProductMediaFromChoicesRequest, RemoveProductMediaFromChoicesResponse, DeleteProductOptionsRequest, DeleteProductOptionsResponse, SetCustomFieldsRequest, SetCustomFieldsResponse, RemoveCustomFieldsRequest, RemoveCustomFieldsResponse, RemoveProductBrandRequest, RemoveProductBrandResponse, BulkSetCustomFieldsRequest, BulkSetCustomFieldsResponse, BulkRemoveCustomFieldsRequest, BulkRemoveCustomFieldsResponse, CreateCollectionRequest, Collection, CreateCollectionResponse, UpdateCollectionRequest, UpdateCollectionResponse, DeleteCollectionRequest, DeleteCollectionResponse, RemoveProductRibbonRequest, RemoveProductRibbonResponse, BulkUpdateProductsRequest, SetValue, SetValueValueOneOf, BulkUpdateProductsResponse, BulkProductResult, ItemMetadata, ApplicationError, BulkActionMetadata, BulkUpdateProductsByFilterSyncRequest, BulkUpdateProductsByFilterSyncResponse, AllowedProductsCountLimitExceededErrorData, BulkAdjustProductPropertiesRequest, AdjustValue, AdjustValueValueOneOf, PropertyAdjustmentData, PropertyAdjustmentDataByOneOf, PercentageData, BulkAdjustProductPropertiesResponse, BulkAdjustProductPropertiesByFilterSyncRequest, BulkAdjustProductPropertiesByFilterSyncResponse, ProductCreated, ProductChanged, ProductDeleted, CollectionCreated, CollectionChanged, CollectionDeleted, VariantsChanged, VariantChanged, QueryProductsRequest, Query, Paging, QueryProductsResponse, PagingMetadata, QueryProductsPlatformizedRequest, PlatformQuery, PlatformQueryPagingMethodOneOf, PlatformPaging, QueryProductsPlatformizedResponse, PlatformPagingMetadata, QueryProductsWithBigPageLimitRequest, QueryWithBigPageLimit, PagingWithBigLimit, GetProductsRequest, GetProductsResponse, GetProductRequest, GetProductResponse, QueryCollectionsRequest, QueryCollectionsResponse, QueryCollectionsPlatformizedRequest, QueryCollectionsPlatformizedResponse, GetCollectionRequest, GetCollectionResponse, GetCollectionBySlugRequest, GetCollectionBySlugResponse, ProductOptionsAvailabilityRequest, ProductOptionsAvailabilityResponse, VariantData, QueryProductVariantsRequest, QueryProductVariantsResponse, QueryStoreVariantsRequest, QueryStoreVariantsResponse, StoreVariant, PreorderInfo, QueryStoreVariantsWithBigLimitRequest, UnlimitedPlatformQuery, UnlimitedPlatformQueryPagingMethodOneOf, UnlimitedPlatformPaging, UnlimitedPlatformCursorPaging, GetStoreVariantRequest, GetStoreVariantResponse, QueryCustomFieldsRequest, QueryCustomFieldsResponse, BulkQueryCustomFieldsRequest, BulkQueryCustomFieldsResponse, CustomFieldsContainer, AggregateProductsRequest, AggregateProductsResponse, ProductsQueryResult, ProductsQueryBuilder, GetProductOptions, } from './stores-catalog-v1-product-products.universal';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.DiscountType = exports.OptionType = exports.MediaItemType = exports.InventoryStatus = exports.ProductType = exports.SortOrder = exports.
|
|
3
|
+
exports.DiscountType = exports.OptionType = exports.MediaItemType = exports.InventoryStatus = exports.ProductType = exports.SortOrder = exports.FileType = exports.MeasurementUnit = exports.V1ProductType = exports.PreorderStatus = exports.PurchaseAvailabilityStatus = exports.CustomizationType = exports.ChoiceType = exports.V1OptionType = exports.NullValue = exports.VerticalAlignment = exports.Direction = exports.InitialExpandedItems = exports.AppType = exports.FontType = exports.DecorationType = exports.BackgroundType = exports.PollLayoutDirection = exports.PollLayoutType = exports.VoteRole = exports.ViewRole = exports.MapType = exports.Source = exports.ThumbnailsAlignment = exports.Crop = exports.Orientation = exports.LayoutType = exports.ViewMode = exports.Alignment = exports.Width = exports.LineStyle = exports.TextAlignment = exports.Target = exports.Type = exports.PluginContainerDataAlignment = exports.WidthType = exports.NodeType = exports.getProduct = exports.queryProducts = void 0;
|
|
4
4
|
const stores_catalog_v1_product_products_universal_1 = require("./stores-catalog-v1-product-products.universal");
|
|
5
5
|
function queryProducts(httpClient) {
|
|
6
6
|
return () => (0, stores_catalog_v1_product_products_universal_1.queryProducts)(
|
|
@@ -43,13 +43,14 @@ Object.defineProperty(exports, "InitialExpandedItems", { enumerable: true, get:
|
|
|
43
43
|
Object.defineProperty(exports, "Direction", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.Direction; } });
|
|
44
44
|
Object.defineProperty(exports, "VerticalAlignment", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.VerticalAlignment; } });
|
|
45
45
|
Object.defineProperty(exports, "NullValue", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.NullValue; } });
|
|
46
|
-
Object.defineProperty(exports, "MeasurementUnit", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.MeasurementUnit; } });
|
|
47
46
|
Object.defineProperty(exports, "V1OptionType", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.V1OptionType; } });
|
|
48
47
|
Object.defineProperty(exports, "ChoiceType", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.ChoiceType; } });
|
|
49
48
|
Object.defineProperty(exports, "CustomizationType", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.CustomizationType; } });
|
|
50
|
-
Object.defineProperty(exports, "
|
|
49
|
+
Object.defineProperty(exports, "PurchaseAvailabilityStatus", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.PurchaseAvailabilityStatus; } });
|
|
50
|
+
Object.defineProperty(exports, "PreorderStatus", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.PreorderStatus; } });
|
|
51
51
|
Object.defineProperty(exports, "V1ProductType", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.V1ProductType; } });
|
|
52
|
-
Object.defineProperty(exports, "
|
|
52
|
+
Object.defineProperty(exports, "MeasurementUnit", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.MeasurementUnit; } });
|
|
53
|
+
Object.defineProperty(exports, "FileType", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.FileType; } });
|
|
53
54
|
Object.defineProperty(exports, "SortOrder", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.SortOrder; } });
|
|
54
55
|
Object.defineProperty(exports, "ProductType", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.ProductType; } });
|
|
55
56
|
Object.defineProperty(exports, "InventoryStatus", { enumerable: true, get: function () { return stores_catalog_v1_product_products_universal_2.InventoryStatus; } });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stores-catalog-v1-product-products.public.js","sourceRoot":"","sources":["../../../src/stores-catalog-v1-product-products.public.ts"],"names":[],"mappings":";;;AACA,iHAIwD;AAExD,SAAgB,aAAa,CAAC,UAAsB;IAClD,OAAO,GAAG,EAAE,CACV,IAAA,4DAAsB;IACpB,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAND,sCAMC;AAED,SAAgB,UAAU,CAAC,UAAsB;IAC/C,OAAO,CAAC,GAAW,EAAE,OAA2B,EAAE,EAAE,CAClD,IAAA,yDAAmB,EACjB,GAAG,EACH,OAAO;IACP,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AARD,gCAQC;AAED,+
|
|
1
|
+
{"version":3,"file":"stores-catalog-v1-product-products.public.js","sourceRoot":"","sources":["../../../src/stores-catalog-v1-product-products.public.ts"],"names":[],"mappings":";;;AACA,iHAIwD;AAExD,SAAgB,aAAa,CAAC,UAAsB;IAClD,OAAO,GAAG,EAAE,CACV,IAAA,4DAAsB;IACpB,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAND,sCAMC;AAED,SAAgB,UAAU,CAAC,UAAsB;IAC/C,OAAO,CAAC,GAAW,EAAE,OAA2B,EAAE,EAAE,CAClD,IAAA,yDAAmB,EACjB,GAAG,EACH,OAAO;IACP,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AARD,gCAQC;AAED,+GA2CwD;AA1CtD,wIAAA,QAAQ,OAAA;AACR,yIAAA,SAAS,OAAA;AACT,4JAAA,4BAA4B,OAAA;AAC5B,oIAAA,IAAI,OAAA;AACJ,sIAAA,MAAM,OAAA;AACN,6IAAA,aAAa,OAAA;AACb,yIAAA,SAAS,OAAA;AACT,qIAAA,KAAK,OAAA;AACL,yIAAA,SAAS,OAAA;AACT,wIAAA,QAAQ,OAAA;AACR,0IAAA,UAAU,OAAA;AACV,2IAAA,WAAW,OAAA;AACX,oIAAA,IAAI,OAAA;AACJ,mJAAA,mBAAmB,OAAA;AACnB,sIAAA,MAAM,OAAA;AACN,uIAAA,OAAO,OAAA;AACP,wIAAA,QAAQ,OAAA;AACR,wIAAA,QAAQ,OAAA;AACR,8IAAA,cAAc,OAAA;AACd,mJAAA,mBAAmB,OAAA;AACnB,8IAAA,cAAc,OAAA;AACd,8IAAA,cAAc,OAAA;AACd,wIAAA,QAAQ,OAAA;AACR,uIAAA,OAAO,OAAA;AACP,oJAAA,oBAAoB,OAAA;AACpB,yIAAA,SAAS,OAAA;AACT,iJAAA,iBAAiB,OAAA;AACjB,yIAAA,SAAS,OAAA;AACT,4IAAA,YAAY,OAAA;AACZ,0IAAA,UAAU,OAAA;AACV,iJAAA,iBAAiB,OAAA;AACjB,0JAAA,0BAA0B,OAAA;AAC1B,8IAAA,cAAc,OAAA;AACd,6IAAA,aAAa,OAAA;AACb,+IAAA,eAAe,OAAA;AACf,wIAAA,QAAQ,OAAA;AACR,yIAAA,SAAS,OAAA;AACT,2IAAA,WAAW,OAAA;AACX,+IAAA,eAAe,OAAA;AACf,6IAAA,aAAa,OAAA;AACb,0IAAA,UAAU,OAAA;AACV,4IAAA,YAAY,OAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Product is the main entity of ProductService that can be used for lorem ipsum dolor */
|
|
2
|
-
export interface V1Product {
|
|
2
|
+
export interface V1Product extends V1ProductTypedPropertiesOneOf {
|
|
3
3
|
/** Product ID. Auto-generated on product creation. */
|
|
4
4
|
id?: string | null;
|
|
5
5
|
/** Represents the current state of an item. Each time the item is modified, its `revision` changes. for an update operation to succeed, you MUST pass the latest revision */
|
|
@@ -41,14 +41,9 @@ export interface V1Product {
|
|
|
41
41
|
/** Custom SEO data for the product. */
|
|
42
42
|
seoData?: SeoSchema;
|
|
43
43
|
/**
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
* For example - price per 100 gr. of cheese.
|
|
47
|
-
* Allowed only for `type` PHYSICAL.
|
|
48
|
-
* todo: move to `physical_properties` together with `weight_range`
|
|
44
|
+
* can set this field only on create
|
|
45
|
+
* for update, call SetProductOptions endpoint
|
|
49
46
|
*/
|
|
50
|
-
pricePerUnit?: PricePerUnitSettings;
|
|
51
|
-
/** for update, call AddProductOptions, AddProductOptionChoice or DeleteProductOptions endpoints */
|
|
52
47
|
options?: V1ProductOption[];
|
|
53
48
|
/** Optional - Brand. To assign existing brand to product provide `brand.id`, to create new brand omit `brand.id` and provide other brand data. */
|
|
54
49
|
brand?: Brand;
|
|
@@ -92,17 +87,16 @@ export interface V1Product {
|
|
|
92
87
|
* Product inventory (a materialized view by listening to inventory domain events).
|
|
93
88
|
* @readonly
|
|
94
89
|
*/
|
|
95
|
-
inventory?:
|
|
90
|
+
inventory?: Inventory;
|
|
96
91
|
/** Product type. Affects which properties product has. Also defines type of variants which allowed to be associated with this product. Product type must be provided on creation and cannot be changed. */
|
|
97
92
|
productType?: V1ProductType;
|
|
98
|
-
/**
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
weightRange?: V1NumericPropertyRange;
|
|
93
|
+
/** Physical properties, must be provided when `product_type` is PHYSICAL */
|
|
94
|
+
physicalOptions?: V1PhysicalProperties;
|
|
95
|
+
}
|
|
96
|
+
/** @oneof */
|
|
97
|
+
export interface V1ProductTypedPropertiesOneOf {
|
|
98
|
+
/** Physical properties, must be provided when `product_type` is PHYSICAL */
|
|
99
|
+
physicalOptions?: V1PhysicalProperties;
|
|
106
100
|
}
|
|
107
101
|
export interface PageUrlV2 {
|
|
108
102
|
/** The path to that page - e.g /product-page/a-product */
|
|
@@ -1410,36 +1404,6 @@ export interface Settings {
|
|
|
1410
1404
|
/** User-selected keyword terms for a specific page. */
|
|
1411
1405
|
keywords?: Keyword[];
|
|
1412
1406
|
}
|
|
1413
|
-
export interface PricePerUnitSettings {
|
|
1414
|
-
/** Quantity value. e.g to define price per unit product setting to price per 100 gr. Set this value to 100. */
|
|
1415
|
-
quantity?: number;
|
|
1416
|
-
/** Measurement unit, e.g to define price per unit product setting to price per 100 gr. Set this value to "G". */
|
|
1417
|
-
measurementUnit?: MeasurementUnit;
|
|
1418
|
-
}
|
|
1419
|
-
export declare enum MeasurementUnit {
|
|
1420
|
-
UNSPECIFIED = "UNSPECIFIED",
|
|
1421
|
-
ML = "ML",
|
|
1422
|
-
CL = "CL",
|
|
1423
|
-
L = "L",
|
|
1424
|
-
CBM = "CBM",
|
|
1425
|
-
MG = "MG",
|
|
1426
|
-
G = "G",
|
|
1427
|
-
KG = "KG",
|
|
1428
|
-
MM = "MM",
|
|
1429
|
-
CM = "CM",
|
|
1430
|
-
M = "M",
|
|
1431
|
-
SQM = "SQM",
|
|
1432
|
-
OZ = "OZ",
|
|
1433
|
-
LB = "LB",
|
|
1434
|
-
FLOZ = "FLOZ",
|
|
1435
|
-
PT = "PT",
|
|
1436
|
-
QT = "QT",
|
|
1437
|
-
GAL = "GAL",
|
|
1438
|
-
IN = "IN",
|
|
1439
|
-
FT = "FT",
|
|
1440
|
-
YD = "YD",
|
|
1441
|
-
SQFT = "SQFT"
|
|
1442
|
-
}
|
|
1443
1407
|
export interface V1ProductOption {
|
|
1444
1408
|
/** The id of the option */
|
|
1445
1409
|
optionId?: string;
|
|
@@ -1466,76 +1430,75 @@ export declare enum V1OptionType {
|
|
|
1466
1430
|
TEXT = "TEXT",
|
|
1467
1431
|
SWATCH = "SWATCH"
|
|
1468
1432
|
}
|
|
1469
|
-
export interface ProductChoice {
|
|
1470
|
-
/** The id of the choice */
|
|
1433
|
+
export interface ProductChoice extends ProductChoiceValueOneOf {
|
|
1434
|
+
/** The id of the choice. */
|
|
1471
1435
|
choiceId?: string;
|
|
1472
1436
|
/**
|
|
1473
|
-
*
|
|
1474
|
-
* todo: copy proto
|
|
1437
|
+
* The type of this choice. Materialized view field
|
|
1475
1438
|
* @readonly
|
|
1476
1439
|
*/
|
|
1477
|
-
|
|
1478
|
-
}
|
|
1479
|
-
export interface V1Choice extends V1ChoiceValueOneOf {
|
|
1440
|
+
choiceType?: ChoiceType;
|
|
1480
1441
|
/**
|
|
1481
|
-
*
|
|
1442
|
+
* A key based the choice name that will be used for CatalogSPI endpoints. Materialized view field.
|
|
1482
1443
|
* @readonly
|
|
1483
1444
|
*/
|
|
1484
|
-
|
|
1485
|
-
/**
|
|
1486
|
-
* The type of this choice.
|
|
1487
|
-
* Choices related to options of type SWATCH must have ONE_COLOR, MULTIPLE_COLORS or IMAGE choice type.
|
|
1488
|
-
* Choice related to options of type TEXT, must have TEXT choice type.
|
|
1489
|
-
*/
|
|
1490
|
-
choiceType?: ChoiceType;
|
|
1445
|
+
key?: string;
|
|
1491
1446
|
/**
|
|
1492
|
-
*
|
|
1447
|
+
* Choice name. Materialized view field.
|
|
1493
1448
|
* @readonly
|
|
1494
1449
|
*/
|
|
1495
|
-
key?: string | null;
|
|
1496
|
-
/** Choice name. */
|
|
1497
1450
|
name?: string;
|
|
1498
1451
|
/**
|
|
1499
|
-
*
|
|
1452
|
+
* One color - HEX or RGB color code for display.
|
|
1500
1453
|
* @readonly
|
|
1501
1454
|
*/
|
|
1502
|
-
numberOfProducts?: number;
|
|
1503
|
-
/** One color - HEX or RGB color code for display. */
|
|
1504
1455
|
colorCode?: string;
|
|
1505
1456
|
}
|
|
1506
1457
|
/** @oneof */
|
|
1507
|
-
export interface
|
|
1508
|
-
/**
|
|
1458
|
+
export interface ProductChoiceValueOneOf {
|
|
1459
|
+
/**
|
|
1460
|
+
* One color - HEX or RGB color code for display.
|
|
1461
|
+
* @readonly
|
|
1462
|
+
*/
|
|
1509
1463
|
colorCode?: string;
|
|
1510
1464
|
}
|
|
1511
1465
|
export declare enum ChoiceType {
|
|
1512
1466
|
UNKNOWN_CHOICE_TYPE = "UNKNOWN_CHOICE_TYPE",
|
|
1513
|
-
|
|
1467
|
+
TEXT_CHOICE = "TEXT_CHOICE",
|
|
1514
1468
|
ONE_COLOR = "ONE_COLOR",
|
|
1515
1469
|
MULTIPLE_COLORS = "MULTIPLE_COLORS",
|
|
1516
1470
|
IMAGE = "IMAGE"
|
|
1517
1471
|
}
|
|
1518
1472
|
export interface MultipleColors {
|
|
1519
|
-
/** A list of color codes */
|
|
1473
|
+
/** A list of color codes. */
|
|
1520
1474
|
colorCodes?: string[];
|
|
1521
1475
|
}
|
|
1522
1476
|
export interface Brand {
|
|
1523
1477
|
/** brand ID */
|
|
1524
|
-
id?: string
|
|
1525
|
-
/**
|
|
1526
|
-
|
|
1478
|
+
id?: string;
|
|
1479
|
+
/**
|
|
1480
|
+
* brand name. Translatable. Materialized field view.
|
|
1481
|
+
* @readonly
|
|
1482
|
+
*/
|
|
1483
|
+
name?: string;
|
|
1527
1484
|
}
|
|
1528
1485
|
export interface InfoSection {
|
|
1529
1486
|
/** info section id */
|
|
1530
1487
|
id?: string;
|
|
1531
|
-
/**
|
|
1488
|
+
/**
|
|
1489
|
+
* Product info section title. Translatable. Materialized view field.
|
|
1490
|
+
* @readonly
|
|
1491
|
+
*/
|
|
1532
1492
|
title?: string;
|
|
1533
|
-
/**
|
|
1493
|
+
/**
|
|
1494
|
+
* Product info section description. Translatable. Materialized view field.
|
|
1495
|
+
* @readonly
|
|
1496
|
+
*/
|
|
1534
1497
|
description?: string | null;
|
|
1535
1498
|
}
|
|
1536
1499
|
export interface SubscriptionOptionInfo {
|
|
1537
1500
|
/** The id of the subscription_option */
|
|
1538
|
-
|
|
1501
|
+
id?: string;
|
|
1539
1502
|
/** The visibility of the subscription_option. Default: true */
|
|
1540
1503
|
visible?: boolean | null;
|
|
1541
1504
|
/**
|
|
@@ -1554,15 +1517,15 @@ export interface Customization extends CustomizationValueOneOf {
|
|
|
1554
1517
|
title?: string;
|
|
1555
1518
|
/** Type. */
|
|
1556
1519
|
customizationType?: CustomizationType;
|
|
1557
|
-
/** Whether customer's input is mandatory */
|
|
1520
|
+
/** Whether customer's input is mandatory. */
|
|
1558
1521
|
mandatory?: boolean;
|
|
1559
1522
|
/** Text input configuration. Required when `type` is TEXT_INPUT. */
|
|
1560
|
-
|
|
1523
|
+
textInputOptions?: TextInputValue;
|
|
1561
1524
|
}
|
|
1562
1525
|
/** @oneof */
|
|
1563
1526
|
export interface CustomizationValueOneOf {
|
|
1564
1527
|
/** Text input configuration. Required when `type` is TEXT_INPUT. */
|
|
1565
|
-
|
|
1528
|
+
textInputOptions?: TextInputValue;
|
|
1566
1529
|
}
|
|
1567
1530
|
export declare enum CustomizationType {
|
|
1568
1531
|
UNKNOWN_TYPE = "UNKNOWN_TYPE",
|
|
@@ -1591,45 +1554,96 @@ export interface V1NumericPropertyRange {
|
|
|
1591
1554
|
/** Maximum value. */
|
|
1592
1555
|
maxValue?: number;
|
|
1593
1556
|
}
|
|
1594
|
-
|
|
1595
|
-
export interface ProductInventory {
|
|
1596
|
-
/**
|
|
1597
|
-
* inventory ID.
|
|
1598
|
-
* @readonly
|
|
1599
|
-
*/
|
|
1600
|
-
inventoryId?: string;
|
|
1557
|
+
export interface Inventory {
|
|
1601
1558
|
/**
|
|
1602
|
-
*
|
|
1559
|
+
* The current purchase availability status calculated based on variants
|
|
1603
1560
|
* @readonly
|
|
1604
1561
|
*/
|
|
1605
|
-
|
|
1562
|
+
purchaseAvailabilityStatus?: PurchaseAvailabilityStatus;
|
|
1606
1563
|
/**
|
|
1607
|
-
* The current status
|
|
1608
|
-
* + `IN_STOCK` - In stock
|
|
1609
|
-
* + `OUT_OF_STOCK` - Not in stock
|
|
1610
|
-
* + `PARTIALLY_OUT_OF_STOCK` - Some of the variants are not in stock
|
|
1564
|
+
* The current preorder status calculated based on variants
|
|
1611
1565
|
* @readonly
|
|
1612
1566
|
*/
|
|
1613
|
-
|
|
1567
|
+
preorderAvailabilityStatus?: PreorderStatus;
|
|
1614
1568
|
}
|
|
1615
|
-
export declare enum
|
|
1616
|
-
|
|
1569
|
+
export declare enum PurchaseAvailabilityStatus {
|
|
1570
|
+
UNKNOWN_PURCHASE_AVAILABILITY_STATUS = "UNKNOWN_PURCHASE_AVAILABILITY_STATUS",
|
|
1571
|
+
/** All variants in stock and available for purchase */
|
|
1617
1572
|
IN_STOCK = "IN_STOCK",
|
|
1573
|
+
/** All variants out of stock */
|
|
1618
1574
|
OUT_OF_STOCK = "OUT_OF_STOCK",
|
|
1575
|
+
/** Some ouf variants out of stock and some of them are in stock */
|
|
1619
1576
|
PARTIALLY_OUT_OF_STOCK = "PARTIALLY_OUT_OF_STOCK"
|
|
1620
1577
|
}
|
|
1578
|
+
export declare enum PreorderStatus {
|
|
1579
|
+
UNKNOWN_PREORDER_STATUS = "UNKNOWN_PREORDER_STATUS",
|
|
1580
|
+
/** All variants available for preorder */
|
|
1581
|
+
ALL_VARIANTS = "ALL_VARIANTS",
|
|
1582
|
+
/** No variants available for preorder */
|
|
1583
|
+
NO_VARIANTS = "NO_VARIANTS",
|
|
1584
|
+
/** Some variants available for preorder */
|
|
1585
|
+
SOME_VARIANTS = "SOME_VARIANTS"
|
|
1586
|
+
}
|
|
1621
1587
|
export declare enum V1ProductType {
|
|
1622
1588
|
UNKNOWN_PRODUCT_TYPE = "UNKNOWN_PRODUCT_TYPE",
|
|
1623
1589
|
PHYSICAL = "PHYSICAL",
|
|
1624
1590
|
DIGITAL = "DIGITAL"
|
|
1625
1591
|
}
|
|
1592
|
+
export interface V1PhysicalProperties {
|
|
1593
|
+
/**
|
|
1594
|
+
* Price per unit settings - base measurement unit and quantity in order to show price per unit data on the product page.
|
|
1595
|
+
* This setting is fixed for a product. The specific price per unit value for each variant is set on each variant
|
|
1596
|
+
* For example - price per 100 gr. of cheese.
|
|
1597
|
+
* Allowed only for `type` PHYSICAL.
|
|
1598
|
+
*/
|
|
1599
|
+
pricePerUnit?: PricePerUnitSettings;
|
|
1600
|
+
/** Fulfiller id */
|
|
1601
|
+
fulfillerId?: string | null;
|
|
1602
|
+
/**
|
|
1603
|
+
* Product weight range. The minimum and maximum weights of all the variants.
|
|
1604
|
+
* this is needed for bulk adjust product properties action, and also exist in the current API.
|
|
1605
|
+
* @readonly
|
|
1606
|
+
*/
|
|
1607
|
+
weightRange?: V1NumericPropertyRange;
|
|
1608
|
+
}
|
|
1609
|
+
export interface PricePerUnitSettings {
|
|
1610
|
+
/** Quantity value. e.g to define price per unit product setting to price per 100 gr. Set this value to 100. */
|
|
1611
|
+
quantity?: number;
|
|
1612
|
+
/** Measurement unit, e.g to define price per unit product setting to price per 100 gr. Set this value to "G". */
|
|
1613
|
+
measurementUnit?: MeasurementUnit;
|
|
1614
|
+
}
|
|
1615
|
+
export declare enum MeasurementUnit {
|
|
1616
|
+
UNSPECIFIED = "UNSPECIFIED",
|
|
1617
|
+
ML = "ML",
|
|
1618
|
+
CL = "CL",
|
|
1619
|
+
L = "L",
|
|
1620
|
+
CBM = "CBM",
|
|
1621
|
+
MG = "MG",
|
|
1622
|
+
G = "G",
|
|
1623
|
+
KG = "KG",
|
|
1624
|
+
MM = "MM",
|
|
1625
|
+
CM = "CM",
|
|
1626
|
+
M = "M",
|
|
1627
|
+
SQM = "SQM",
|
|
1628
|
+
OZ = "OZ",
|
|
1629
|
+
LB = "LB",
|
|
1630
|
+
FLOZ = "FLOZ",
|
|
1631
|
+
PT = "PT",
|
|
1632
|
+
QT = "QT",
|
|
1633
|
+
GAL = "GAL",
|
|
1634
|
+
IN = "IN",
|
|
1635
|
+
FT = "FT",
|
|
1636
|
+
YD = "YD",
|
|
1637
|
+
SQFT = "SQFT"
|
|
1638
|
+
}
|
|
1626
1639
|
export interface V1CreateProductRequest {
|
|
1627
1640
|
/** Product to be created */
|
|
1628
1641
|
product?: V1Product;
|
|
1642
|
+
/** variants to be created for given product. */
|
|
1629
1643
|
variants?: V1Variant[];
|
|
1630
1644
|
}
|
|
1631
1645
|
/** Variant is the main entity of VariantService that can be used for lorem ipsum dolor */
|
|
1632
|
-
export interface V1Variant {
|
|
1646
|
+
export interface V1Variant extends V1VariantTypedPropertiesOneOf {
|
|
1633
1647
|
/**
|
|
1634
1648
|
* Variant ID
|
|
1635
1649
|
* @readonly
|
|
@@ -1666,12 +1680,6 @@ export interface V1Variant {
|
|
|
1666
1680
|
* @readonly
|
|
1667
1681
|
*/
|
|
1668
1682
|
currency?: string;
|
|
1669
|
-
/** Variant SKU (stock keeping unit) */
|
|
1670
|
-
sku?: string | null;
|
|
1671
|
-
/** Variant shipping weight. Allowed only when `product_type` PHYSICAL. */
|
|
1672
|
-
weight?: number | null;
|
|
1673
|
-
/** Whether the variant is visible to customers. Default is true */
|
|
1674
|
-
visible?: boolean | null;
|
|
1675
1683
|
/**
|
|
1676
1684
|
* Variant inventory stock status, Generated automatically based on InventoryItems of this variant.
|
|
1677
1685
|
* @readonly
|
|
@@ -1704,6 +1712,17 @@ export interface V1Variant {
|
|
|
1704
1712
|
* @readonly
|
|
1705
1713
|
*/
|
|
1706
1714
|
productType?: V1ProductType;
|
|
1715
|
+
/** Physical properties. Can be provided when `product_type` PHYSICAL */
|
|
1716
|
+
physicalOptions?: PhysicalProperties;
|
|
1717
|
+
/** Digital properties. Can be provided when `product_type` DIGITAL */
|
|
1718
|
+
digitalOptions?: DigitalProperties;
|
|
1719
|
+
}
|
|
1720
|
+
/** @oneof */
|
|
1721
|
+
export interface V1VariantTypedPropertiesOneOf {
|
|
1722
|
+
/** Physical properties. Can be provided when `product_type` PHYSICAL */
|
|
1723
|
+
physicalOptions?: PhysicalProperties;
|
|
1724
|
+
/** Digital properties. Can be provided when `product_type` DIGITAL */
|
|
1725
|
+
digitalOptions?: DigitalProperties;
|
|
1707
1726
|
}
|
|
1708
1727
|
export interface OptionChoice {
|
|
1709
1728
|
/** The id of the option, should be unique per variant */
|
|
@@ -1717,20 +1736,10 @@ export interface OptionChoice {
|
|
|
1717
1736
|
choiceName?: string;
|
|
1718
1737
|
}
|
|
1719
1738
|
export interface PriceInfo {
|
|
1720
|
-
/** Variant price
|
|
1721
|
-
|
|
1722
|
-
/**
|
|
1723
|
-
* Discount data based on the product
|
|
1724
|
-
* @readonly
|
|
1725
|
-
*/
|
|
1726
|
-
discount?: DiscountData;
|
|
1727
|
-
/**
|
|
1728
|
-
* Discounted variant price (if no discounted price is set, the variant price is returned)
|
|
1729
|
-
* @readonly
|
|
1730
|
-
*/
|
|
1739
|
+
/** Variant price. Must be greater or equal to 0. */
|
|
1740
|
+
basePrice?: FixedMonetaryAmount;
|
|
1741
|
+
/** Discounted variant price. If not provided will be equal to `base_price`. Must be greater or equal to 0. */
|
|
1731
1742
|
discountedPrice?: FixedMonetaryAmount;
|
|
1732
|
-
/** Price per unit info, in order to show price per unit on the product page, for example €4.00 / 100g. Allowed only for `product_type` PHYSICAL */
|
|
1733
|
-
pricePerUnit?: PricePerUnit;
|
|
1734
1743
|
}
|
|
1735
1744
|
export interface FixedMonetaryAmount {
|
|
1736
1745
|
/** Monetary amount. Decimal string with a period as a decimal separator (e.g., 3.99). Optionally, a single (-), to indicate that the amount is negative. */
|
|
@@ -1742,34 +1751,28 @@ export interface FixedMonetaryAmount {
|
|
|
1742
1751
|
*/
|
|
1743
1752
|
formattedValue?: string | null;
|
|
1744
1753
|
}
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
/** No discount */
|
|
1760
|
-
NONE = "NONE",
|
|
1761
|
-
/** Fixed amount discount */
|
|
1762
|
-
AMOUNT = "AMOUNT",
|
|
1763
|
-
/** Percentage off discount */
|
|
1764
|
-
PERCENT = "PERCENT"
|
|
1765
|
-
}
|
|
1766
|
-
export interface PercentDiscountValue {
|
|
1767
|
-
/** The percentage value of the discount - from 0 to 100 */
|
|
1768
|
-
value?: number;
|
|
1754
|
+
export interface CostAndProfitInfo {
|
|
1755
|
+
/** Item cost. */
|
|
1756
|
+
itemCost?: FixedMonetaryAmount;
|
|
1757
|
+
/**
|
|
1758
|
+
* Profit. Calculated by reducing `cost` from `discounted_price`.
|
|
1759
|
+
* @readonly
|
|
1760
|
+
*/
|
|
1761
|
+
profit?: FixedMonetaryAmount;
|
|
1762
|
+
/**
|
|
1763
|
+
* Profit Margin. Calculated by dividing `profit` by `discounted_price`.
|
|
1764
|
+
* The result is rounded to 4 decimal places.
|
|
1765
|
+
* @readonly
|
|
1766
|
+
*/
|
|
1767
|
+
profitMargin?: number;
|
|
1769
1768
|
}
|
|
1770
|
-
export interface
|
|
1771
|
-
/**
|
|
1772
|
-
|
|
1769
|
+
export interface PhysicalProperties {
|
|
1770
|
+
/** Variant shipping weight. */
|
|
1771
|
+
weight?: number | null;
|
|
1772
|
+
/** Price per unit info, in order to show price per unit on the product page, for example €4.00 / 100g. Allowed only for `product_type` PHYSICAL */
|
|
1773
|
+
pricePerUnit?: PricePerUnit;
|
|
1774
|
+
/** Variant SKU (stock keeping unit) */
|
|
1775
|
+
sku?: string | null;
|
|
1773
1776
|
}
|
|
1774
1777
|
export interface PricePerUnit {
|
|
1775
1778
|
/**
|
|
@@ -1789,20 +1792,23 @@ export interface PricePerUnit {
|
|
|
1789
1792
|
*/
|
|
1790
1793
|
description?: string | null;
|
|
1791
1794
|
}
|
|
1792
|
-
export interface
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
/**
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1795
|
+
export interface DigitalProperties {
|
|
1796
|
+
}
|
|
1797
|
+
export interface SecuredMedia {
|
|
1798
|
+
/** Media ID in media manager. */
|
|
1799
|
+
id?: string;
|
|
1800
|
+
/** Original file name. */
|
|
1801
|
+
fileName?: string;
|
|
1802
|
+
/** File type. */
|
|
1803
|
+
fileType?: FileType;
|
|
1804
|
+
}
|
|
1805
|
+
export declare enum FileType {
|
|
1806
|
+
UNSPECIFIED = "UNSPECIFIED",
|
|
1807
|
+
SECURE_PICTURE = "SECURE_PICTURE",
|
|
1808
|
+
SECURE_VIDEO = "SECURE_VIDEO",
|
|
1809
|
+
SECURE_DOCUMENT = "SECURE_DOCUMENT",
|
|
1810
|
+
SECURE_MUSIC = "SECURE_MUSIC",
|
|
1811
|
+
SECURE_ARCHIVE = "SECURE_ARCHIVE"
|
|
1806
1812
|
}
|
|
1807
1813
|
export interface V1CreateProductResponse {
|
|
1808
1814
|
/** The created Product */
|