@wix/stores 1.0.134 → 1.0.136
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/context.d.ts +5 -5
- package/build/cjs/context.js +5 -5
- package/build/cjs/context.js.map +1 -1
- package/build/cjs/index.d.ts +5 -6
- package/build/cjs/index.js +6 -7
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/meta.d.ts +5 -6
- package/build/cjs/meta.js +6 -7
- package/build/cjs/meta.js.map +1 -1
- package/build/es/context.d.ts +5 -5
- package/build/es/context.js +5 -5
- package/build/es/context.js.map +1 -1
- package/build/es/index.d.ts +5 -6
- package/build/es/index.js +5 -6
- package/build/es/index.js.map +1 -1
- package/build/es/meta.d.ts +5 -6
- package/build/es/meta.js +5 -6
- package/build/es/meta.js.map +1 -1
- package/package.json +15 -9
- package/build/cjs/index.typings.d.ts +0 -6
- package/build/cjs/index.typings.js +0 -33
- package/build/cjs/index.typings.js.map +0 -1
- package/build/cjs/src/platform-v1-wishlist.context.d.ts +0 -3
- package/build/cjs/src/platform-v1-wishlist.context.js +0 -22
- package/build/cjs/src/platform-v1-wishlist.context.js.map +0 -1
- package/build/cjs/src/platform-v1-wishlist.http.d.ts +0 -3
- package/build/cjs/src/platform-v1-wishlist.http.js +0 -91
- package/build/cjs/src/platform-v1-wishlist.http.js.map +0 -1
- package/build/cjs/src/platform-v1-wishlist.meta.d.ts +0 -13
- package/build/cjs/src/platform-v1-wishlist.meta.js +0 -47
- package/build/cjs/src/platform-v1-wishlist.meta.js.map +0 -1
- package/build/cjs/src/platform-v1-wishlist.public.d.ts +0 -15
- package/build/cjs/src/platform-v1-wishlist.public.js +0 -12
- package/build/cjs/src/platform-v1-wishlist.public.js.map +0 -1
- package/build/cjs/src/platform-v1-wishlist.types.d.ts +0 -104
- package/build/cjs/src/platform-v1-wishlist.types.js +0 -3
- package/build/cjs/src/platform-v1-wishlist.types.js.map +0 -1
- package/build/cjs/src/platform-v1-wishlist.universal.d.ts +0 -121
- package/build/cjs/src/platform-v1-wishlist.universal.js +0 -106
- package/build/cjs/src/platform-v1-wishlist.universal.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-collection.context.d.ts +0 -5
- package/build/cjs/src/stores-catalog-v1-collection.context.js +0 -56
- package/build/cjs/src/stores-catalog-v1-collection.context.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-collection.http.d.ts +0 -10
- package/build/cjs/src/stores-catalog-v1-collection.http.js +0 -110
- package/build/cjs/src/stores-catalog-v1-collection.http.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-collection.meta.d.ts +0 -19
- package/build/cjs/src/stores-catalog-v1-collection.meta.js +0 -85
- package/build/cjs/src/stores-catalog-v1-collection.meta.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-collection.public.d.ts +0 -59
- package/build/cjs/src/stores-catalog-v1-collection.public.js +0 -27
- package/build/cjs/src/stores-catalog-v1-collection.public.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-collection.types.d.ts +0 -414
- package/build/cjs/src/stores-catalog-v1-collection.types.js +0 -18
- package/build/cjs/src/stores-catalog-v1-collection.types.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-collection.universal.d.ts +0 -452
- package/build/cjs/src/stores-catalog-v1-collection.universal.js +0 -225
- package/build/cjs/src/stores-catalog-v1-collection.universal.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-product.context.d.ts +0 -35
- package/build/cjs/src/stores-catalog-v1-product.context.js +0 -566
- package/build/cjs/src/stores-catalog-v1-product.context.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-product.http.d.ts +0 -89
- package/build/cjs/src/stores-catalog-v1-product.http.js +0 -1716
- package/build/cjs/src/stores-catalog-v1-product.http.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-product.meta.d.ts +0 -95
- package/build/cjs/src/stores-catalog-v1-product.meta.js +0 -655
- package/build/cjs/src/stores-catalog-v1-product.meta.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-product.public.d.ts +0 -1216
- package/build/cjs/src/stores-catalog-v1-product.public.js +0 -221
- package/build/cjs/src/stores-catalog-v1-product.public.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-product.types.d.ts +0 -4235
- package/build/cjs/src/stores-catalog-v1-product.types.js +0 -78
- package/build/cjs/src/stores-catalog-v1-product.types.js.map +0 -1
- package/build/cjs/src/stores-catalog-v1-product.universal.d.ts +0 -5074
- package/build/cjs/src/stores-catalog-v1-product.universal.js +0 -2220
- package/build/cjs/src/stores-catalog-v1-product.universal.js.map +0 -1
- package/build/cjs/src/stores-v1-abandoned-cart.http.d.ts +0 -6
- package/build/cjs/src/stores-v1-abandoned-cart.http.js +0 -103
- package/build/cjs/src/stores-v1-abandoned-cart.http.js.map +0 -1
- package/build/cjs/src/stores-v1-abandoned-cart.meta.d.ts +0 -16
- package/build/cjs/src/stores-v1-abandoned-cart.meta.js +0 -66
- package/build/cjs/src/stores-v1-abandoned-cart.meta.js.map +0 -1
- package/build/cjs/src/stores-v1-abandoned-cart.public.d.ts +0 -19
- package/build/cjs/src/stores-v1-abandoned-cart.public.js +0 -22
- package/build/cjs/src/stores-v1-abandoned-cart.public.js.map +0 -1
- package/build/cjs/src/stores-v1-abandoned-cart.types.d.ts +0 -216
- package/build/cjs/src/stores-v1-abandoned-cart.types.js +0 -30
- package/build/cjs/src/stores-v1-abandoned-cart.types.js.map +0 -1
- package/build/cjs/src/stores-v1-abandoned-cart.universal.d.ts +0 -246
- package/build/cjs/src/stores-v1-abandoned-cart.universal.js +0 -189
- package/build/cjs/src/stores-v1-abandoned-cart.universal.js.map +0 -1
- package/build/cjs/src/stores-v1-subscription-option.context.d.ts +0 -14
- package/build/cjs/src/stores-v1-subscription-option.context.js +0 -209
- package/build/cjs/src/stores-v1-subscription-option.context.js.map +0 -1
- package/build/cjs/src/stores-v1-subscription-option.http.d.ts +0 -128
- package/build/cjs/src/stores-v1-subscription-option.http.js +0 -466
- package/build/cjs/src/stores-v1-subscription-option.http.js.map +0 -1
- package/build/cjs/src/stores-v1-subscription-option.meta.d.ts +0 -40
- package/build/cjs/src/stores-v1-subscription-option.meta.js +0 -258
- package/build/cjs/src/stores-v1-subscription-option.meta.js.map +0 -1
- package/build/cjs/src/stores-v1-subscription-option.public.d.ts +0 -46
- package/build/cjs/src/stores-v1-subscription-option.public.js +0 -81
- package/build/cjs/src/stores-v1-subscription-option.public.js.map +0 -1
- package/build/cjs/src/stores-v1-subscription-option.types.d.ts +0 -351
- package/build/cjs/src/stores-v1-subscription-option.types.js +0 -20
- package/build/cjs/src/stores-v1-subscription-option.types.js.map +0 -1
- package/build/cjs/src/stores-v1-subscription-option.universal.d.ts +0 -646
- package/build/cjs/src/stores-v1-subscription-option.universal.js +0 -893
- package/build/cjs/src/stores-v1-subscription-option.universal.js.map +0 -1
- package/build/cjs/src/stores-v2-inventory.context.d.ts +0 -7
- package/build/cjs/src/stores-v2-inventory.context.js +0 -90
- package/build/cjs/src/stores-v2-inventory.context.js.map +0 -1
- package/build/cjs/src/stores-v2-inventory.http.d.ts +0 -31
- package/build/cjs/src/stores-v2-inventory.http.js +0 -289
- package/build/cjs/src/stores-v2-inventory.http.js.map +0 -1
- package/build/cjs/src/stores-v2-inventory.meta.d.ts +0 -21
- package/build/cjs/src/stores-v2-inventory.meta.js +0 -125
- package/build/cjs/src/stores-v2-inventory.meta.js.map +0 -1
- package/build/cjs/src/stores-v2-inventory.public.d.ts +0 -13
- package/build/cjs/src/stores-v2-inventory.public.js +0 -41
- package/build/cjs/src/stores-v2-inventory.public.js.map +0 -1
- package/build/cjs/src/stores-v2-inventory.types.d.ts +0 -283
- package/build/cjs/src/stores-v2-inventory.types.js +0 -11
- package/build/cjs/src/stores-v2-inventory.types.js.map +0 -1
- package/build/cjs/src/stores-v2-inventory.universal.d.ts +0 -425
- package/build/cjs/src/stores-v2-inventory.universal.js +0 -382
- package/build/cjs/src/stores-v2-inventory.universal.js.map +0 -1
- package/build/es/index.typings.d.ts +0 -6
- package/build/es/index.typings.js +0 -7
- package/build/es/index.typings.js.map +0 -1
- package/build/es/src/platform-v1-wishlist.context.d.ts +0 -3
- package/build/es/src/platform-v1-wishlist.context.js +0 -18
- package/build/es/src/platform-v1-wishlist.context.js.map +0 -1
- package/build/es/src/platform-v1-wishlist.http.d.ts +0 -3
- package/build/es/src/platform-v1-wishlist.http.js +0 -87
- package/build/es/src/platform-v1-wishlist.http.js.map +0 -1
- package/build/es/src/platform-v1-wishlist.meta.d.ts +0 -13
- package/build/es/src/platform-v1-wishlist.meta.js +0 -20
- package/build/es/src/platform-v1-wishlist.meta.js.map +0 -1
- package/build/es/src/platform-v1-wishlist.public.d.ts +0 -15
- package/build/es/src/platform-v1-wishlist.public.js +0 -8
- package/build/es/src/platform-v1-wishlist.public.js.map +0 -1
- package/build/es/src/platform-v1-wishlist.types.d.ts +0 -104
- package/build/es/src/platform-v1-wishlist.types.js +0 -2
- package/build/es/src/platform-v1-wishlist.types.js.map +0 -1
- package/build/es/src/platform-v1-wishlist.universal.d.ts +0 -121
- package/build/es/src/platform-v1-wishlist.universal.js +0 -79
- package/build/es/src/platform-v1-wishlist.universal.js.map +0 -1
- package/build/es/src/stores-catalog-v1-collection.context.d.ts +0 -5
- package/build/es/src/stores-catalog-v1-collection.context.js +0 -50
- package/build/es/src/stores-catalog-v1-collection.context.js.map +0 -1
- package/build/es/src/stores-catalog-v1-collection.http.d.ts +0 -10
- package/build/es/src/stores-catalog-v1-collection.http.js +0 -104
- package/build/es/src/stores-catalog-v1-collection.http.js.map +0 -1
- package/build/es/src/stores-catalog-v1-collection.meta.d.ts +0 -19
- package/build/es/src/stores-catalog-v1-collection.meta.js +0 -56
- package/build/es/src/stores-catalog-v1-collection.meta.js.map +0 -1
- package/build/es/src/stores-catalog-v1-collection.public.d.ts +0 -59
- package/build/es/src/stores-catalog-v1-collection.public.js +0 -19
- package/build/es/src/stores-catalog-v1-collection.public.js.map +0 -1
- package/build/es/src/stores-catalog-v1-collection.types.d.ts +0 -414
- package/build/es/src/stores-catalog-v1-collection.types.js +0 -15
- package/build/es/src/stores-catalog-v1-collection.types.js.map +0 -1
- package/build/es/src/stores-catalog-v1-collection.universal.d.ts +0 -452
- package/build/es/src/stores-catalog-v1-collection.universal.js +0 -196
- package/build/es/src/stores-catalog-v1-collection.universal.js.map +0 -1
- package/build/es/src/stores-catalog-v1-product.context.d.ts +0 -35
- package/build/es/src/stores-catalog-v1-product.context.js +0 -530
- package/build/es/src/stores-catalog-v1-product.context.js.map +0 -1
- package/build/es/src/stores-catalog-v1-product.http.d.ts +0 -89
- package/build/es/src/stores-catalog-v1-product.http.js +0 -1680
- package/build/es/src/stores-catalog-v1-product.http.js.map +0 -1
- package/build/es/src/stores-catalog-v1-product.meta.d.ts +0 -95
- package/build/es/src/stores-catalog-v1-product.meta.js +0 -596
- package/build/es/src/stores-catalog-v1-product.meta.js.map +0 -1
- package/build/es/src/stores-catalog-v1-product.public.d.ts +0 -1216
- package/build/es/src/stores-catalog-v1-product.public.js +0 -170
- package/build/es/src/stores-catalog-v1-product.public.js.map +0 -1
- package/build/es/src/stores-catalog-v1-product.types.d.ts +0 -4235
- package/build/es/src/stores-catalog-v1-product.types.js +0 -75
- package/build/es/src/stores-catalog-v1-product.types.js.map +0 -1
- package/build/es/src/stores-catalog-v1-product.universal.d.ts +0 -5074
- package/build/es/src/stores-catalog-v1-product.universal.js +0 -2161
- package/build/es/src/stores-catalog-v1-product.universal.js.map +0 -1
- package/build/es/src/stores-v1-abandoned-cart.http.d.ts +0 -6
- package/build/es/src/stores-v1-abandoned-cart.http.js +0 -98
- package/build/es/src/stores-v1-abandoned-cart.http.js.map +0 -1
- package/build/es/src/stores-v1-abandoned-cart.meta.d.ts +0 -16
- package/build/es/src/stores-v1-abandoned-cart.meta.js +0 -38
- package/build/es/src/stores-v1-abandoned-cart.meta.js.map +0 -1
- package/build/es/src/stores-v1-abandoned-cart.public.d.ts +0 -19
- package/build/es/src/stores-v1-abandoned-cart.public.js +0 -14
- package/build/es/src/stores-v1-abandoned-cart.public.js.map +0 -1
- package/build/es/src/stores-v1-abandoned-cart.types.d.ts +0 -216
- package/build/es/src/stores-v1-abandoned-cart.types.js +0 -27
- package/build/es/src/stores-v1-abandoned-cart.types.js.map +0 -1
- package/build/es/src/stores-v1-abandoned-cart.universal.d.ts +0 -246
- package/build/es/src/stores-v1-abandoned-cart.universal.js +0 -161
- package/build/es/src/stores-v1-abandoned-cart.universal.js.map +0 -1
- package/build/es/src/stores-v1-subscription-option.context.d.ts +0 -14
- package/build/es/src/stores-v1-subscription-option.context.js +0 -194
- package/build/es/src/stores-v1-subscription-option.context.js.map +0 -1
- package/build/es/src/stores-v1-subscription-option.http.d.ts +0 -128
- package/build/es/src/stores-v1-subscription-option.http.js +0 -451
- package/build/es/src/stores-v1-subscription-option.http.js.map +0 -1
- package/build/es/src/stores-v1-subscription-option.meta.d.ts +0 -40
- package/build/es/src/stores-v1-subscription-option.meta.js +0 -220
- package/build/es/src/stores-v1-subscription-option.meta.js.map +0 -1
- package/build/es/src/stores-v1-subscription-option.public.d.ts +0 -46
- package/build/es/src/stores-v1-subscription-option.public.js +0 -64
- package/build/es/src/stores-v1-subscription-option.public.js.map +0 -1
- package/build/es/src/stores-v1-subscription-option.types.d.ts +0 -351
- package/build/es/src/stores-v1-subscription-option.types.js +0 -17
- package/build/es/src/stores-v1-subscription-option.types.js.map +0 -1
- package/build/es/src/stores-v1-subscription-option.universal.d.ts +0 -646
- package/build/es/src/stores-v1-subscription-option.universal.js +0 -855
- package/build/es/src/stores-v1-subscription-option.universal.js.map +0 -1
- package/build/es/src/stores-v2-inventory.context.d.ts +0 -7
- package/build/es/src/stores-v2-inventory.context.js +0 -82
- package/build/es/src/stores-v2-inventory.context.js.map +0 -1
- package/build/es/src/stores-v2-inventory.http.d.ts +0 -31
- package/build/es/src/stores-v2-inventory.http.js +0 -281
- package/build/es/src/stores-v2-inventory.http.js.map +0 -1
- package/build/es/src/stores-v2-inventory.meta.d.ts +0 -21
- package/build/es/src/stores-v2-inventory.meta.js +0 -94
- package/build/es/src/stores-v2-inventory.meta.js.map +0 -1
- package/build/es/src/stores-v2-inventory.public.d.ts +0 -13
- package/build/es/src/stores-v2-inventory.public.js +0 -30
- package/build/es/src/stores-v2-inventory.public.js.map +0 -1
- package/build/es/src/stores-v2-inventory.types.d.ts +0 -283
- package/build/es/src/stores-v2-inventory.types.js +0 -8
- package/build/es/src/stores-v2-inventory.types.js.map +0 -1
- package/build/es/src/stores-v2-inventory.universal.d.ts +0 -425
- package/build/es/src/stores-v2-inventory.universal.js +0 -351
- package/build/es/src/stores-v2-inventory.universal.js.map +0 -1
|
@@ -1,425 +0,0 @@
|
|
|
1
|
-
import { EventDefinition } from '@wix/sdk-types';
|
|
2
|
-
export interface InventoryItemV2 {
|
|
3
|
-
/** Inventory item ID. */
|
|
4
|
-
_id?: string | null;
|
|
5
|
-
/**
|
|
6
|
-
* @internal
|
|
7
|
-
* @internal
|
|
8
|
-
* @readonly
|
|
9
|
-
*/
|
|
10
|
-
externalId?: string | null;
|
|
11
|
-
/**
|
|
12
|
-
* Product ID.
|
|
13
|
-
* @readonly
|
|
14
|
-
*/
|
|
15
|
-
productId?: string | null;
|
|
16
|
-
/** Whether quantity is being tracked. */
|
|
17
|
-
trackQuantity?: boolean | null;
|
|
18
|
-
/** Variants associated with this inventory item. */
|
|
19
|
-
variants?: InventoryVariantV2[];
|
|
20
|
-
/**
|
|
21
|
-
* Last updated timestamp.
|
|
22
|
-
* @readonly
|
|
23
|
-
*/
|
|
24
|
-
lastUpdated?: Date;
|
|
25
|
-
/**
|
|
26
|
-
* Inventory’s unique numeric ID (assigned in ascending order).
|
|
27
|
-
* Primarily for sorting and filtering when crawling all inventories.
|
|
28
|
-
* @readonly
|
|
29
|
-
*/
|
|
30
|
-
numericId?: string;
|
|
31
|
-
/** Preorder information. */
|
|
32
|
-
preorderInfo?: PreorderInfo;
|
|
33
|
-
}
|
|
34
|
-
export interface InventoryVariantV2 {
|
|
35
|
-
/** Variant ID. */
|
|
36
|
-
variantId?: string;
|
|
37
|
-
/** Whether the product is listed as in stock. */
|
|
38
|
-
inStock?: boolean | null;
|
|
39
|
-
/** Quantity currently left in inventory. */
|
|
40
|
-
quantity?: number | null;
|
|
41
|
-
/**
|
|
42
|
-
* Whether the variant is available for preorder. When `true`, the variant is out of stock and preorder is enabled on inventory level.
|
|
43
|
-
* @readonly
|
|
44
|
-
*/
|
|
45
|
-
availableForPreorder?: boolean;
|
|
46
|
-
}
|
|
47
|
-
export interface PreorderInfo {
|
|
48
|
-
/** Whether the item is available for preorder. */
|
|
49
|
-
enabled?: boolean;
|
|
50
|
-
/** A message the buyer will see when the item is out of stock and preorder is enabled. */
|
|
51
|
-
message?: string | null;
|
|
52
|
-
/** Number of products that can be preordered after stock reaches zero. */
|
|
53
|
-
limit?: number | null;
|
|
54
|
-
}
|
|
55
|
-
export interface InventoryItemChanged {
|
|
56
|
-
/** Inventory item ID. */
|
|
57
|
-
inventoryItemId?: string;
|
|
58
|
-
/**
|
|
59
|
-
* @internal
|
|
60
|
-
* @internal */
|
|
61
|
-
externalId?: string;
|
|
62
|
-
/** Product ID. */
|
|
63
|
-
productId?: string;
|
|
64
|
-
/** Whether inventory is being tracked. */
|
|
65
|
-
trackInventory?: boolean;
|
|
66
|
-
/** Preorder information. */
|
|
67
|
-
preorderInfo?: PreorderInfo;
|
|
68
|
-
/** Date and time the inventory item was last updated. */
|
|
69
|
-
_updatedDate?: Date;
|
|
70
|
-
}
|
|
71
|
-
export interface InventoryVariantsChanged {
|
|
72
|
-
/** Inventory item ID. */
|
|
73
|
-
inventoryItemId?: string;
|
|
74
|
-
/**
|
|
75
|
-
* @internal
|
|
76
|
-
* @internal */
|
|
77
|
-
externalId?: string;
|
|
78
|
-
/** Product ID. */
|
|
79
|
-
productId?: string;
|
|
80
|
-
/** Information about changed variants. */
|
|
81
|
-
variants?: ChangedInventoryVariant[];
|
|
82
|
-
/** Date and time the inventory variant item was last updated. */
|
|
83
|
-
_updatedDate?: Date;
|
|
84
|
-
}
|
|
85
|
-
export interface ChangedInventoryVariant {
|
|
86
|
-
/** Variant ID. */
|
|
87
|
-
_id?: string;
|
|
88
|
-
/** Previous inventory variant data. */
|
|
89
|
-
oldValue?: ChangedInventoryVariantData;
|
|
90
|
-
/** Current inventory variant data. */
|
|
91
|
-
newValue?: ChangedInventoryVariantData;
|
|
92
|
-
}
|
|
93
|
-
export interface ChangedInventoryVariantData {
|
|
94
|
-
/** Inventory variant quantity. */
|
|
95
|
-
quantity?: number | null;
|
|
96
|
-
/** Whether the product variant is in stock. */
|
|
97
|
-
inStock?: boolean;
|
|
98
|
-
/** Whether the variant is available for preorder. When `true`, the variant is out of stock and preorder is enabled on inventory level. */
|
|
99
|
-
availableForPreorder?: boolean;
|
|
100
|
-
}
|
|
101
|
-
export declare enum ReasonType {
|
|
102
|
-
UNKNOWN = "UNKNOWN",
|
|
103
|
-
ORDER = "ORDER",
|
|
104
|
-
MANUAL = "MANUAL",
|
|
105
|
-
REVERT_INVENTORY_CHANGE = "REVERT_INVENTORY_CHANGE"
|
|
106
|
-
}
|
|
107
|
-
export interface GetInventoryVariantsRequest extends GetInventoryVariantsRequestIdOneOf {
|
|
108
|
-
/** Inventory item ID. */
|
|
109
|
-
inventoryId: string;
|
|
110
|
-
/**
|
|
111
|
-
* @internal
|
|
112
|
-
* @internal */
|
|
113
|
-
externalId?: string;
|
|
114
|
-
/** Product ID. */
|
|
115
|
-
productId?: string;
|
|
116
|
-
/** Variant IDs to query for this inventory item (optional). */
|
|
117
|
-
variantIds?: string[];
|
|
118
|
-
}
|
|
119
|
-
/** @oneof */
|
|
120
|
-
export interface GetInventoryVariantsRequestIdOneOf {
|
|
121
|
-
/** Inventory item ID. */
|
|
122
|
-
inventoryId?: string;
|
|
123
|
-
/**
|
|
124
|
-
* @internal
|
|
125
|
-
* @internal */
|
|
126
|
-
externalId?: string;
|
|
127
|
-
/** Product ID. */
|
|
128
|
-
productId?: string;
|
|
129
|
-
}
|
|
130
|
-
export interface GetInventoryVariantsResponse {
|
|
131
|
-
/** Inventory item. */
|
|
132
|
-
inventoryItem?: InventoryItemV2;
|
|
133
|
-
}
|
|
134
|
-
export interface GetInventoryItemsRequest {
|
|
135
|
-
/** Product IDs */
|
|
136
|
-
productIds?: string[];
|
|
137
|
-
}
|
|
138
|
-
export interface GetInventoryItemsResponse {
|
|
139
|
-
/** Inventory items. */
|
|
140
|
-
inventoryItems?: InventoryItemV2[];
|
|
141
|
-
}
|
|
142
|
-
export interface QueryInventoryRequest {
|
|
143
|
-
/** Information about paging, filters, sorting. */
|
|
144
|
-
query?: Query;
|
|
145
|
-
}
|
|
146
|
-
export interface Query {
|
|
147
|
-
/** Paging options to limit and skip the number of items. */
|
|
148
|
-
paging?: Paging;
|
|
149
|
-
/** Filter string */
|
|
150
|
-
filter?: string | null;
|
|
151
|
-
/** Sort string */
|
|
152
|
-
sort?: string | null;
|
|
153
|
-
}
|
|
154
|
-
export interface Paging {
|
|
155
|
-
/** Amount of items to load per page */
|
|
156
|
-
limit?: number | null;
|
|
157
|
-
/** Number of items to skip in the display (relevant for all pages after the first) */
|
|
158
|
-
offset?: number | null;
|
|
159
|
-
}
|
|
160
|
-
export interface QueryInventoryResponse {
|
|
161
|
-
/** Inventory items. */
|
|
162
|
-
inventoryItems?: InventoryItemV2[];
|
|
163
|
-
/** Display metadata. */
|
|
164
|
-
metadata?: PagingMetadata;
|
|
165
|
-
/** Number of total results. */
|
|
166
|
-
totalResults?: number;
|
|
167
|
-
}
|
|
168
|
-
export interface PagingMetadata {
|
|
169
|
-
/** Amount of items to load per page */
|
|
170
|
-
items?: number;
|
|
171
|
-
/** Number of items to skip in the display (relevant for all pages after the first) */
|
|
172
|
-
offset?: number;
|
|
173
|
-
}
|
|
174
|
-
export interface UpdateInventoryVariantsRequest {
|
|
175
|
-
/** Inventory item. */
|
|
176
|
-
inventoryItem: InventoryItemV2;
|
|
177
|
-
}
|
|
178
|
-
export interface UpdateInventoryVariantsResponse {
|
|
179
|
-
}
|
|
180
|
-
export interface BulkUpdateInventoryVariantsRequest extends BulkUpdateInventoryVariantsRequestActionOneOf {
|
|
181
|
-
/** Change availability. */
|
|
182
|
-
setInStock?: boolean | null;
|
|
183
|
-
/** Set new quantity. */
|
|
184
|
-
setQuantity?: number | null;
|
|
185
|
-
/** Number to increment inventory by. */
|
|
186
|
-
incrementBy?: number | null;
|
|
187
|
-
/** Number to decrement inventory by. */
|
|
188
|
-
decrementBy?: number | null;
|
|
189
|
-
/** Variants filter. See documentation [here](https://bo.wix.com/wix-docs/rnd/platformization-guidelines/api-query-language#platformization-guidelines_api-query-language_defining-in-protobuf) */
|
|
190
|
-
filter?: Record<string, any> | null;
|
|
191
|
-
}
|
|
192
|
-
/** @oneof */
|
|
193
|
-
export interface BulkUpdateInventoryVariantsRequestActionOneOf {
|
|
194
|
-
/** Change availability. */
|
|
195
|
-
setInStock?: boolean | null;
|
|
196
|
-
/** Set new quantity. */
|
|
197
|
-
setQuantity?: number | null;
|
|
198
|
-
/** Number to increment inventory by. */
|
|
199
|
-
incrementBy?: number | null;
|
|
200
|
-
/** Number to decrement inventory by. */
|
|
201
|
-
decrementBy?: number | null;
|
|
202
|
-
}
|
|
203
|
-
export interface BulkUpdateInventoryVariantsResponse {
|
|
204
|
-
}
|
|
205
|
-
export interface BulkUpdateInventoryItemsRequest {
|
|
206
|
-
/** Variants filter */
|
|
207
|
-
variantsFilter?: Record<string, any> | null;
|
|
208
|
-
/** Whether inventory is being tracked. */
|
|
209
|
-
trackInventory?: boolean | null;
|
|
210
|
-
}
|
|
211
|
-
export interface BulkUpdateInventoryItemsResponse {
|
|
212
|
-
}
|
|
213
|
-
export interface DecrementInventoryRequest {
|
|
214
|
-
/** Item or product to decrement. */
|
|
215
|
-
decrementData?: DecrementData[];
|
|
216
|
-
}
|
|
217
|
-
export interface DecrementData extends DecrementDataIdOneOf {
|
|
218
|
-
/** Inventory item ID. */
|
|
219
|
-
inventoryId?: string;
|
|
220
|
-
/**
|
|
221
|
-
* @internal
|
|
222
|
-
* @internal */
|
|
223
|
-
externalId?: string;
|
|
224
|
-
/** Product ID. */
|
|
225
|
-
productId?: string;
|
|
226
|
-
/** Variant ID. */
|
|
227
|
-
variantId?: string;
|
|
228
|
-
/** Number to decrement inventory by. */
|
|
229
|
-
decrementBy?: number;
|
|
230
|
-
/**
|
|
231
|
-
* Whether the request to decrement the item's inventory was made as part of a purchase that includes preorder items.
|
|
232
|
-
* If true and the item is available for preorder, we allow negative inventory.
|
|
233
|
-
* If false and the item is not available for preorder, we allow regular buy flow (no negative inventory).
|
|
234
|
-
*/
|
|
235
|
-
preorderRequest?: boolean;
|
|
236
|
-
}
|
|
237
|
-
/** @oneof */
|
|
238
|
-
export interface DecrementDataIdOneOf {
|
|
239
|
-
/** Inventory item ID. */
|
|
240
|
-
inventoryId?: string;
|
|
241
|
-
/**
|
|
242
|
-
* @internal
|
|
243
|
-
* @internal */
|
|
244
|
-
externalId?: string;
|
|
245
|
-
/** Product ID. */
|
|
246
|
-
productId?: string;
|
|
247
|
-
}
|
|
248
|
-
export interface DecrementInventoryResponse {
|
|
249
|
-
}
|
|
250
|
-
export interface IncrementInventoryRequest {
|
|
251
|
-
/** Item or product to increment. */
|
|
252
|
-
incrementData?: IncrementData[];
|
|
253
|
-
}
|
|
254
|
-
export interface IncrementData extends IncrementDataIdOneOf {
|
|
255
|
-
/** Inventory item ID. */
|
|
256
|
-
inventoryId?: string;
|
|
257
|
-
/** Product ID. */
|
|
258
|
-
productId?: string;
|
|
259
|
-
/** Variant ID. */
|
|
260
|
-
variantId?: string;
|
|
261
|
-
/** Number to increment inventory by. */
|
|
262
|
-
incrementBy?: number;
|
|
263
|
-
}
|
|
264
|
-
/** @oneof */
|
|
265
|
-
export interface IncrementDataIdOneOf {
|
|
266
|
-
/** Inventory item ID. */
|
|
267
|
-
inventoryId?: string;
|
|
268
|
-
/** Product ID. */
|
|
269
|
-
productId?: string;
|
|
270
|
-
}
|
|
271
|
-
export interface IncrementInventoryResponse {
|
|
272
|
-
}
|
|
273
|
-
export interface GetInventoryVariantsResponseNonNullableFields {
|
|
274
|
-
inventoryItem?: {
|
|
275
|
-
variants: {
|
|
276
|
-
variantId: string;
|
|
277
|
-
availableForPreorder: boolean;
|
|
278
|
-
}[];
|
|
279
|
-
numericId: string;
|
|
280
|
-
preorderInfo?: {
|
|
281
|
-
enabled: boolean;
|
|
282
|
-
};
|
|
283
|
-
};
|
|
284
|
-
}
|
|
285
|
-
export interface QueryInventoryResponseNonNullableFields {
|
|
286
|
-
inventoryItems: {
|
|
287
|
-
variants: {
|
|
288
|
-
variantId: string;
|
|
289
|
-
availableForPreorder: boolean;
|
|
290
|
-
}[];
|
|
291
|
-
numericId: string;
|
|
292
|
-
preorderInfo?: {
|
|
293
|
-
enabled: boolean;
|
|
294
|
-
};
|
|
295
|
-
}[];
|
|
296
|
-
metadata?: {
|
|
297
|
-
items: number;
|
|
298
|
-
offset: number;
|
|
299
|
-
};
|
|
300
|
-
totalResults: number;
|
|
301
|
-
}
|
|
302
|
-
export declare const onInventoryItemChanged: EventDefinition<InventoryItemChanged, "com.wix.ecommerce.inventory.api.v1.InventoryItemChanged">;
|
|
303
|
-
export declare const onInventoryVariantsChanged: EventDefinition<InventoryVariantsChanged, "com.wix.ecommerce.inventory.api.v1.InventoryVariantsChanged">;
|
|
304
|
-
/**
|
|
305
|
-
* Gets inventory variant information based on the specified option choices.
|
|
306
|
-
*
|
|
307
|
-
*
|
|
308
|
-
* The `getInventoryVariants()` function returns a Promise that resolves to the specified inventory variant information.
|
|
309
|
-
* @param inventoryId - Inventory item ID.
|
|
310
|
-
* @public
|
|
311
|
-
* @requiredField inventoryId
|
|
312
|
-
* @permissionScope Manage Stores - all permissions
|
|
313
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
|
|
314
|
-
* @permissionScope Manage Products
|
|
315
|
-
* @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS
|
|
316
|
-
* @permissionScope Read Stores - all read permissions
|
|
317
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.READ-STORES
|
|
318
|
-
* @permissionScope Read Products
|
|
319
|
-
* @permissionScopeId SCOPE.DC-STORES.READ-PRODUCTS
|
|
320
|
-
* @applicableIdentity APP
|
|
321
|
-
*/
|
|
322
|
-
export declare function getInventoryVariants(inventoryId: string, options?: GetInventoryVariantsOptions): Promise<GetInventoryVariantsResponse & GetInventoryVariantsResponseNonNullableFields>;
|
|
323
|
-
export interface GetInventoryVariantsOptions extends GetInventoryVariantsRequestIdOneOf {
|
|
324
|
-
/**
|
|
325
|
-
* @internal
|
|
326
|
-
* @internal */
|
|
327
|
-
externalId?: string;
|
|
328
|
-
/** Product ID. */
|
|
329
|
-
productId?: string;
|
|
330
|
-
/** Variant IDs to query for this inventory item (optional). */
|
|
331
|
-
variantIds?: string[];
|
|
332
|
-
}
|
|
333
|
-
/**
|
|
334
|
-
* Returns a list of inventory items, given the provided paging, sorting and filtering.
|
|
335
|
-
* @public
|
|
336
|
-
* @documentationMaturity preview
|
|
337
|
-
* @permissionScope Manage Stores - all permissions
|
|
338
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
|
|
339
|
-
* @permissionScope Manage Products
|
|
340
|
-
* @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS
|
|
341
|
-
* @permissionScope Read Stores - all read permissions
|
|
342
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.READ-STORES
|
|
343
|
-
* @permissionScope Read Products
|
|
344
|
-
* @permissionScopeId SCOPE.DC-STORES.READ-PRODUCTS
|
|
345
|
-
* @applicableIdentity APP
|
|
346
|
-
*/
|
|
347
|
-
export declare function queryInventory(options?: QueryInventoryOptions): Promise<QueryInventoryResponse & QueryInventoryResponseNonNullableFields>;
|
|
348
|
-
export interface QueryInventoryOptions {
|
|
349
|
-
/** Information about paging, filters, sorting. */
|
|
350
|
-
query?: Query;
|
|
351
|
-
}
|
|
352
|
-
/**
|
|
353
|
-
* Updates product inventory, including total quantity, whether the product is in stock, and whether the product inventory is tracked.
|
|
354
|
-
*
|
|
355
|
-
*
|
|
356
|
-
* The `updateInventoryVariants()` function is a Promise that resolves to the updated inventory variant data.
|
|
357
|
-
* @param productId - Product ID.
|
|
358
|
-
* @public
|
|
359
|
-
* @requiredField inventoryItem
|
|
360
|
-
* @requiredField productId
|
|
361
|
-
* @param inventoryItem - Inventory item to update.
|
|
362
|
-
* @permissionScope Manage Stores - all permissions
|
|
363
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
|
|
364
|
-
* @permissionScope Manage Products
|
|
365
|
-
* @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS
|
|
366
|
-
* @applicableIdentity APP
|
|
367
|
-
*/
|
|
368
|
-
export declare function updateInventoryVariants(productId: string | null, inventoryItem: UpdateInventoryVariantsInventoryItem): Promise<void>;
|
|
369
|
-
export interface UpdateInventoryVariantsInventoryItem {
|
|
370
|
-
/** Inventory item ID. */
|
|
371
|
-
_id?: string | null;
|
|
372
|
-
/**
|
|
373
|
-
* @internal
|
|
374
|
-
* @internal
|
|
375
|
-
* @readonly
|
|
376
|
-
*/
|
|
377
|
-
externalId?: string | null;
|
|
378
|
-
/** Whether quantity is being tracked. */
|
|
379
|
-
trackQuantity?: boolean | null;
|
|
380
|
-
/** Variants associated with this inventory item. */
|
|
381
|
-
variants?: InventoryVariantV2[];
|
|
382
|
-
/**
|
|
383
|
-
* Last updated timestamp.
|
|
384
|
-
* @readonly
|
|
385
|
-
*/
|
|
386
|
-
lastUpdated?: Date;
|
|
387
|
-
/**
|
|
388
|
-
* Inventory’s unique numeric ID (assigned in ascending order).
|
|
389
|
-
* Primarily for sorting and filtering when crawling all inventories.
|
|
390
|
-
* @readonly
|
|
391
|
-
*/
|
|
392
|
-
numericId?: string;
|
|
393
|
-
/** Preorder information. */
|
|
394
|
-
preorderInfo?: PreorderInfo;
|
|
395
|
-
}
|
|
396
|
-
/**
|
|
397
|
-
* Subtracts a set number of items from inventory.
|
|
398
|
-
*
|
|
399
|
-
*
|
|
400
|
-
* The `decrementInventory()` function returns a Promise that is resolved when the specified item's quantity has been updated in the inventory.
|
|
401
|
-
* @param decrementData - Item or product to decrement.
|
|
402
|
-
* @public
|
|
403
|
-
* @requiredField decrementData
|
|
404
|
-
* @permissionScope Manage Stores - all permissions
|
|
405
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
|
|
406
|
-
* @permissionScope Manage Products
|
|
407
|
-
* @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS
|
|
408
|
-
* @applicableIdentity APP
|
|
409
|
-
*/
|
|
410
|
-
export declare function decrementInventory(decrementData: DecrementData[]): Promise<void>;
|
|
411
|
-
/**
|
|
412
|
-
* Adds a set number of items to inventory.
|
|
413
|
-
*
|
|
414
|
-
*
|
|
415
|
-
* The `incrementInventory()` function returns a Promise that is resolved when the specified item's quantity has been updated in the inventory.
|
|
416
|
-
* @param incrementData - Item or product to increment.
|
|
417
|
-
* @public
|
|
418
|
-
* @requiredField incrementData
|
|
419
|
-
* @permissionScope Manage Stores - all permissions
|
|
420
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
|
|
421
|
-
* @permissionScope Manage Products
|
|
422
|
-
* @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS
|
|
423
|
-
* @applicableIdentity APP
|
|
424
|
-
*/
|
|
425
|
-
export declare function incrementInventory(incrementData: IncrementData[]): Promise<void>;
|