@wix/auto_sdk_stores_inventory 1.0.83 → 1.0.85
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 +21 -21
- package/build/cjs/index.js +121 -171
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +197 -197
- package/build/cjs/index.typings.js +104 -154
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +178 -178
- package/build/cjs/meta.js +90 -140
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +21 -21
- package/build/es/index.mjs +121 -171
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +197 -197
- package/build/es/index.typings.mjs +104 -154
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +178 -178
- package/build/es/meta.mjs +90 -140
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +21 -21
- package/build/internal/cjs/index.typings.d.ts +242 -242
- package/build/internal/cjs/meta.d.ts +190 -190
- package/build/internal/es/index.d.mts +21 -21
- package/build/internal/es/index.typings.d.mts +242 -242
- package/build/internal/es/meta.d.mts +190 -190
- package/package.json +2 -2
|
@@ -68,195 +68,6 @@ interface PreorderInfo {
|
|
|
68
68
|
*/
|
|
69
69
|
limit?: number | null;
|
|
70
70
|
}
|
|
71
|
-
interface UpdateInventoryVariantsRequest {
|
|
72
|
-
/** Inventory item. */
|
|
73
|
-
inventoryItem: InventoryItemV2;
|
|
74
|
-
/** @internal */
|
|
75
|
-
reason?: ReasonTypeWithLiterals;
|
|
76
|
-
}
|
|
77
|
-
declare enum ReasonType {
|
|
78
|
-
/** Unknown reason. */
|
|
79
|
-
UNKNOWN = "UNKNOWN",
|
|
80
|
-
/** Order related. */
|
|
81
|
-
ORDER = "ORDER",
|
|
82
|
-
/** Manual adjustment. */
|
|
83
|
-
MANUAL = "MANUAL",
|
|
84
|
-
/** Reverting an inventory change. */
|
|
85
|
-
REVERT_INVENTORY_CHANGE = "REVERT_INVENTORY_CHANGE"
|
|
86
|
-
}
|
|
87
|
-
/** @enumType */
|
|
88
|
-
type ReasonTypeWithLiterals = ReasonType | 'UNKNOWN' | 'ORDER' | 'MANUAL' | 'REVERT_INVENTORY_CHANGE';
|
|
89
|
-
interface UpdateInventoryVariantsResponse {
|
|
90
|
-
}
|
|
91
|
-
interface BulkUpdateInventoryVariantsRequest extends BulkUpdateInventoryVariantsRequestActionOneOf {
|
|
92
|
-
/** Change availability. */
|
|
93
|
-
setInStock?: boolean | null;
|
|
94
|
-
/** Set new quantity. */
|
|
95
|
-
setQuantity?: number | null;
|
|
96
|
-
/**
|
|
97
|
-
* Number to increment inventory by.
|
|
98
|
-
* @min 1
|
|
99
|
-
*/
|
|
100
|
-
incrementBy?: number | null;
|
|
101
|
-
/**
|
|
102
|
-
* Number to decrement inventory by.
|
|
103
|
-
* @min 1
|
|
104
|
-
*/
|
|
105
|
-
decrementBy?: number | null;
|
|
106
|
-
/** Variants filter. Learn more about [API query language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language). */
|
|
107
|
-
filter?: Record<string, any> | null;
|
|
108
|
-
/** @internal */
|
|
109
|
-
reason?: ReasonTypeWithLiterals;
|
|
110
|
-
/** @internal */
|
|
111
|
-
changeTrackingMethod?: boolean;
|
|
112
|
-
}
|
|
113
|
-
/** @oneof */
|
|
114
|
-
interface BulkUpdateInventoryVariantsRequestActionOneOf {
|
|
115
|
-
/** Change availability. */
|
|
116
|
-
setInStock?: boolean | null;
|
|
117
|
-
/** Set new quantity. */
|
|
118
|
-
setQuantity?: number | null;
|
|
119
|
-
/**
|
|
120
|
-
* Number to increment inventory by.
|
|
121
|
-
* @min 1
|
|
122
|
-
*/
|
|
123
|
-
incrementBy?: number | null;
|
|
124
|
-
/**
|
|
125
|
-
* Number to decrement inventory by.
|
|
126
|
-
* @min 1
|
|
127
|
-
*/
|
|
128
|
-
decrementBy?: number | null;
|
|
129
|
-
}
|
|
130
|
-
interface BulkUpdateInventoryVariantsResponse {
|
|
131
|
-
}
|
|
132
|
-
interface BulkUpdateInventoryItemsRequest {
|
|
133
|
-
/** Variants filter */
|
|
134
|
-
variantsFilter?: Record<string, any> | null;
|
|
135
|
-
/** Whether inventory is being tracked. */
|
|
136
|
-
trackInventory?: boolean | null;
|
|
137
|
-
}
|
|
138
|
-
interface BulkUpdateInventoryItemsResponse {
|
|
139
|
-
}
|
|
140
|
-
interface DecrementInventoryRequest {
|
|
141
|
-
/**
|
|
142
|
-
* Item or product to decrement.
|
|
143
|
-
* @minSize 1
|
|
144
|
-
* @maxSize 300
|
|
145
|
-
*/
|
|
146
|
-
decrementData?: DecrementData[];
|
|
147
|
-
/** @internal */
|
|
148
|
-
reason?: ReasonTypeWithLiterals;
|
|
149
|
-
/** @internal */
|
|
150
|
-
restrictInventoryValue?: boolean;
|
|
151
|
-
}
|
|
152
|
-
interface DecrementData extends DecrementDataIdOneOf {
|
|
153
|
-
/**
|
|
154
|
-
* Inventory item ID.
|
|
155
|
-
* @maxLength 36
|
|
156
|
-
*/
|
|
157
|
-
inventoryId?: string;
|
|
158
|
-
/**
|
|
159
|
-
* @internal
|
|
160
|
-
* @internal
|
|
161
|
-
* @maxLength 36
|
|
162
|
-
* @deprecated Deprecated: use productId.
|
|
163
|
-
* @replacedBy product_id
|
|
164
|
-
* @targetRemovalDate 2024-12-31
|
|
165
|
-
*/
|
|
166
|
-
externalId?: string;
|
|
167
|
-
/**
|
|
168
|
-
* Product ID.
|
|
169
|
-
* @maxLength 36
|
|
170
|
-
*/
|
|
171
|
-
productId?: string;
|
|
172
|
-
/**
|
|
173
|
-
* Variant ID.
|
|
174
|
-
* @format GUID
|
|
175
|
-
*/
|
|
176
|
-
variantId?: string;
|
|
177
|
-
/**
|
|
178
|
-
* Number to decrement inventory by.
|
|
179
|
-
* @min 1
|
|
180
|
-
*/
|
|
181
|
-
decrementBy?: number;
|
|
182
|
-
/**
|
|
183
|
-
* Whether the request to decrement the item's inventory was made as part of a purchase that includes preorder items.
|
|
184
|
-
* If true and the item is available for preorder, we allow negative inventory.
|
|
185
|
-
* If false and the item is not available for preorder, we allow regular buy flow (no negative inventory).
|
|
186
|
-
*/
|
|
187
|
-
preorderRequest?: boolean;
|
|
188
|
-
}
|
|
189
|
-
/** @oneof */
|
|
190
|
-
interface DecrementDataIdOneOf {
|
|
191
|
-
/**
|
|
192
|
-
* Inventory item ID.
|
|
193
|
-
* @maxLength 36
|
|
194
|
-
*/
|
|
195
|
-
inventoryId?: string;
|
|
196
|
-
/**
|
|
197
|
-
* @internal
|
|
198
|
-
* @internal
|
|
199
|
-
* @maxLength 36
|
|
200
|
-
* @deprecated Deprecated: use productId.
|
|
201
|
-
* @replacedBy product_id
|
|
202
|
-
* @targetRemovalDate 2024-12-31
|
|
203
|
-
*/
|
|
204
|
-
externalId?: string;
|
|
205
|
-
/**
|
|
206
|
-
* Product ID.
|
|
207
|
-
* @maxLength 36
|
|
208
|
-
*/
|
|
209
|
-
productId?: string;
|
|
210
|
-
}
|
|
211
|
-
interface DecrementInventoryResponse {
|
|
212
|
-
}
|
|
213
|
-
interface IncrementInventoryRequest {
|
|
214
|
-
/**
|
|
215
|
-
* Item or product to increment.
|
|
216
|
-
* @minSize 1
|
|
217
|
-
* @maxSize 300
|
|
218
|
-
*/
|
|
219
|
-
incrementData?: IncrementData[];
|
|
220
|
-
/** @internal */
|
|
221
|
-
reason?: ReasonTypeWithLiterals;
|
|
222
|
-
}
|
|
223
|
-
interface IncrementData extends IncrementDataIdOneOf {
|
|
224
|
-
/**
|
|
225
|
-
* Inventory item ID.
|
|
226
|
-
* @maxLength 36
|
|
227
|
-
*/
|
|
228
|
-
inventoryId?: string;
|
|
229
|
-
/**
|
|
230
|
-
* Product ID.
|
|
231
|
-
* @maxLength 36
|
|
232
|
-
*/
|
|
233
|
-
productId?: string;
|
|
234
|
-
/**
|
|
235
|
-
* Variant ID.
|
|
236
|
-
* @format GUID
|
|
237
|
-
*/
|
|
238
|
-
variantId?: string;
|
|
239
|
-
/**
|
|
240
|
-
* Number to increment inventory by.
|
|
241
|
-
* @min 1
|
|
242
|
-
*/
|
|
243
|
-
incrementBy?: number;
|
|
244
|
-
}
|
|
245
|
-
/** @oneof */
|
|
246
|
-
interface IncrementDataIdOneOf {
|
|
247
|
-
/**
|
|
248
|
-
* Inventory item ID.
|
|
249
|
-
* @maxLength 36
|
|
250
|
-
*/
|
|
251
|
-
inventoryId?: string;
|
|
252
|
-
/**
|
|
253
|
-
* Product ID.
|
|
254
|
-
* @maxLength 36
|
|
255
|
-
*/
|
|
256
|
-
productId?: string;
|
|
257
|
-
}
|
|
258
|
-
interface IncrementInventoryResponse {
|
|
259
|
-
}
|
|
260
71
|
interface InventoryItemChanged {
|
|
261
72
|
/** Inventory item ID. */
|
|
262
73
|
inventoryItemId?: string;
|
|
@@ -318,6 +129,18 @@ interface ChangedInventoryVariantData {
|
|
|
318
129
|
/** Whether the variant is available for preorder. When `true`, the variant is out of stock and preorder is enabled on inventory level. */
|
|
319
130
|
availableForPreorder?: boolean;
|
|
320
131
|
}
|
|
132
|
+
declare enum ReasonType {
|
|
133
|
+
/** Unknown reason. */
|
|
134
|
+
UNKNOWN = "UNKNOWN",
|
|
135
|
+
/** Order related. */
|
|
136
|
+
ORDER = "ORDER",
|
|
137
|
+
/** Manual adjustment. */
|
|
138
|
+
MANUAL = "MANUAL",
|
|
139
|
+
/** Reverting an inventory change. */
|
|
140
|
+
REVERT_INVENTORY_CHANGE = "REVERT_INVENTORY_CHANGE"
|
|
141
|
+
}
|
|
142
|
+
/** @enumType */
|
|
143
|
+
type ReasonTypeWithLiterals = ReasonType | 'UNKNOWN' | 'ORDER' | 'MANUAL' | 'REVERT_INVENTORY_CHANGE';
|
|
321
144
|
interface GetInventoryVariantsRequest extends GetInventoryVariantsRequestIdOneOf {
|
|
322
145
|
/** Inventory item ID. */
|
|
323
146
|
inventoryId: string;
|
|
@@ -487,6 +310,183 @@ interface AccountInfo {
|
|
|
487
310
|
*/
|
|
488
311
|
siteId?: string | null;
|
|
489
312
|
}
|
|
313
|
+
interface UpdateInventoryVariantsRequest {
|
|
314
|
+
/** Inventory item. */
|
|
315
|
+
inventoryItem: InventoryItemV2;
|
|
316
|
+
/** @internal */
|
|
317
|
+
reason?: ReasonTypeWithLiterals;
|
|
318
|
+
}
|
|
319
|
+
interface UpdateInventoryVariantsResponse {
|
|
320
|
+
}
|
|
321
|
+
interface BulkUpdateInventoryVariantsRequest extends BulkUpdateInventoryVariantsRequestActionOneOf {
|
|
322
|
+
/** Change availability. */
|
|
323
|
+
setInStock?: boolean | null;
|
|
324
|
+
/** Set new quantity. */
|
|
325
|
+
setQuantity?: number | null;
|
|
326
|
+
/**
|
|
327
|
+
* Number to increment inventory by.
|
|
328
|
+
* @min 1
|
|
329
|
+
*/
|
|
330
|
+
incrementBy?: number | null;
|
|
331
|
+
/**
|
|
332
|
+
* Number to decrement inventory by.
|
|
333
|
+
* @min 1
|
|
334
|
+
*/
|
|
335
|
+
decrementBy?: number | null;
|
|
336
|
+
/** Variants filter. Learn more about [API query language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language). */
|
|
337
|
+
filter?: Record<string, any> | null;
|
|
338
|
+
/** @internal */
|
|
339
|
+
reason?: ReasonTypeWithLiterals;
|
|
340
|
+
/** @internal */
|
|
341
|
+
changeTrackingMethod?: boolean;
|
|
342
|
+
}
|
|
343
|
+
/** @oneof */
|
|
344
|
+
interface BulkUpdateInventoryVariantsRequestActionOneOf {
|
|
345
|
+
/** Change availability. */
|
|
346
|
+
setInStock?: boolean | null;
|
|
347
|
+
/** Set new quantity. */
|
|
348
|
+
setQuantity?: number | null;
|
|
349
|
+
/**
|
|
350
|
+
* Number to increment inventory by.
|
|
351
|
+
* @min 1
|
|
352
|
+
*/
|
|
353
|
+
incrementBy?: number | null;
|
|
354
|
+
/**
|
|
355
|
+
* Number to decrement inventory by.
|
|
356
|
+
* @min 1
|
|
357
|
+
*/
|
|
358
|
+
decrementBy?: number | null;
|
|
359
|
+
}
|
|
360
|
+
interface BulkUpdateInventoryVariantsResponse {
|
|
361
|
+
}
|
|
362
|
+
interface BulkUpdateInventoryItemsRequest {
|
|
363
|
+
/** Variants filter */
|
|
364
|
+
variantsFilter?: Record<string, any> | null;
|
|
365
|
+
/** Whether inventory is being tracked. */
|
|
366
|
+
trackInventory?: boolean | null;
|
|
367
|
+
}
|
|
368
|
+
interface BulkUpdateInventoryItemsResponse {
|
|
369
|
+
}
|
|
370
|
+
interface DecrementInventoryRequest {
|
|
371
|
+
/**
|
|
372
|
+
* Item or product to decrement.
|
|
373
|
+
* @minSize 1
|
|
374
|
+
* @maxSize 300
|
|
375
|
+
*/
|
|
376
|
+
decrementData?: DecrementData[];
|
|
377
|
+
/** @internal */
|
|
378
|
+
reason?: ReasonTypeWithLiterals;
|
|
379
|
+
/** @internal */
|
|
380
|
+
restrictInventoryValue?: boolean;
|
|
381
|
+
}
|
|
382
|
+
interface DecrementData extends DecrementDataIdOneOf {
|
|
383
|
+
/**
|
|
384
|
+
* Inventory item ID.
|
|
385
|
+
* @maxLength 36
|
|
386
|
+
*/
|
|
387
|
+
inventoryId?: string;
|
|
388
|
+
/**
|
|
389
|
+
* @internal
|
|
390
|
+
* @internal
|
|
391
|
+
* @maxLength 36
|
|
392
|
+
* @deprecated Deprecated: use productId.
|
|
393
|
+
* @replacedBy product_id
|
|
394
|
+
* @targetRemovalDate 2024-12-31
|
|
395
|
+
*/
|
|
396
|
+
externalId?: string;
|
|
397
|
+
/**
|
|
398
|
+
* Product ID.
|
|
399
|
+
* @maxLength 36
|
|
400
|
+
*/
|
|
401
|
+
productId?: string;
|
|
402
|
+
/**
|
|
403
|
+
* Variant ID.
|
|
404
|
+
* @format GUID
|
|
405
|
+
*/
|
|
406
|
+
variantId?: string;
|
|
407
|
+
/**
|
|
408
|
+
* Number to decrement inventory by.
|
|
409
|
+
* @min 1
|
|
410
|
+
*/
|
|
411
|
+
decrementBy?: number;
|
|
412
|
+
/**
|
|
413
|
+
* Whether the request to decrement the item's inventory was made as part of a purchase that includes preorder items.
|
|
414
|
+
* If true and the item is available for preorder, we allow negative inventory.
|
|
415
|
+
* If false and the item is not available for preorder, we allow regular buy flow (no negative inventory).
|
|
416
|
+
*/
|
|
417
|
+
preorderRequest?: boolean;
|
|
418
|
+
}
|
|
419
|
+
/** @oneof */
|
|
420
|
+
interface DecrementDataIdOneOf {
|
|
421
|
+
/**
|
|
422
|
+
* Inventory item ID.
|
|
423
|
+
* @maxLength 36
|
|
424
|
+
*/
|
|
425
|
+
inventoryId?: string;
|
|
426
|
+
/**
|
|
427
|
+
* @internal
|
|
428
|
+
* @internal
|
|
429
|
+
* @maxLength 36
|
|
430
|
+
* @deprecated Deprecated: use productId.
|
|
431
|
+
* @replacedBy product_id
|
|
432
|
+
* @targetRemovalDate 2024-12-31
|
|
433
|
+
*/
|
|
434
|
+
externalId?: string;
|
|
435
|
+
/**
|
|
436
|
+
* Product ID.
|
|
437
|
+
* @maxLength 36
|
|
438
|
+
*/
|
|
439
|
+
productId?: string;
|
|
440
|
+
}
|
|
441
|
+
interface DecrementInventoryResponse {
|
|
442
|
+
}
|
|
443
|
+
interface IncrementInventoryRequest {
|
|
444
|
+
/**
|
|
445
|
+
* Item or product to increment.
|
|
446
|
+
* @minSize 1
|
|
447
|
+
* @maxSize 300
|
|
448
|
+
*/
|
|
449
|
+
incrementData?: IncrementData[];
|
|
450
|
+
/** @internal */
|
|
451
|
+
reason?: ReasonTypeWithLiterals;
|
|
452
|
+
}
|
|
453
|
+
interface IncrementData extends IncrementDataIdOneOf {
|
|
454
|
+
/**
|
|
455
|
+
* Inventory item ID.
|
|
456
|
+
* @maxLength 36
|
|
457
|
+
*/
|
|
458
|
+
inventoryId?: string;
|
|
459
|
+
/**
|
|
460
|
+
* Product ID.
|
|
461
|
+
* @maxLength 36
|
|
462
|
+
*/
|
|
463
|
+
productId?: string;
|
|
464
|
+
/**
|
|
465
|
+
* Variant ID.
|
|
466
|
+
* @format GUID
|
|
467
|
+
*/
|
|
468
|
+
variantId?: string;
|
|
469
|
+
/**
|
|
470
|
+
* Number to increment inventory by.
|
|
471
|
+
* @min 1
|
|
472
|
+
*/
|
|
473
|
+
incrementBy?: number;
|
|
474
|
+
}
|
|
475
|
+
/** @oneof */
|
|
476
|
+
interface IncrementDataIdOneOf {
|
|
477
|
+
/**
|
|
478
|
+
* Inventory item ID.
|
|
479
|
+
* @maxLength 36
|
|
480
|
+
*/
|
|
481
|
+
inventoryId?: string;
|
|
482
|
+
/**
|
|
483
|
+
* Product ID.
|
|
484
|
+
* @maxLength 36
|
|
485
|
+
*/
|
|
486
|
+
productId?: string;
|
|
487
|
+
}
|
|
488
|
+
interface IncrementInventoryResponse {
|
|
489
|
+
}
|
|
490
490
|
interface BaseEventMetadata {
|
|
491
491
|
/**
|
|
492
492
|
* App instance ID.
|
|
@@ -549,6 +549,59 @@ interface InventoryVariantsChangedEnvelope {
|
|
|
549
549
|
* @slug inventory_variants_changed
|
|
550
550
|
*/
|
|
551
551
|
declare function onInventoryVariantsChanged(handler: (event: InventoryVariantsChangedEnvelope) => void | Promise<void>): void;
|
|
552
|
+
/**
|
|
553
|
+
* Gets inventory variant information based on the specified option choices.
|
|
554
|
+
*
|
|
555
|
+
*
|
|
556
|
+
* The `getInventoryVariants()` function returns a Promise that resolves to the specified inventory variant information.
|
|
557
|
+
* @param inventoryId - Inventory item ID.
|
|
558
|
+
* @public
|
|
559
|
+
* @requiredField inventoryId
|
|
560
|
+
* @permissionId WIX_STORES.READ_INVENTORY
|
|
561
|
+
* @applicableIdentity APP
|
|
562
|
+
* @fqn wix.inventory.api.v1.InventoryReadApi.GetInventoryVariants
|
|
563
|
+
*/
|
|
564
|
+
declare function getInventoryVariants(inventoryId: string, options?: GetInventoryVariantsOptions): Promise<NonNullablePaths<GetInventoryVariantsResponse, `inventoryItem.variants` | `inventoryItem.variants.${number}.variantId` | `inventoryItem.variants.${number}.availableForPreorder` | `inventoryItem.numericId` | `inventoryItem.preorderInfo.enabled`, 3>>;
|
|
565
|
+
interface GetInventoryVariantsOptions extends GetInventoryVariantsOptionsIdOneOf {
|
|
566
|
+
/**
|
|
567
|
+
* @internal
|
|
568
|
+
* @internal
|
|
569
|
+
* @deprecated Deprecated (use productID instead).
|
|
570
|
+
* @replacedBy product_id
|
|
571
|
+
* @targetRemovalDate 2024-12-31
|
|
572
|
+
*/
|
|
573
|
+
externalId?: string;
|
|
574
|
+
/** Product ID. */
|
|
575
|
+
productId?: string;
|
|
576
|
+
/** Variant IDs to query for this inventory item (optional). */
|
|
577
|
+
variantIds?: string[];
|
|
578
|
+
}
|
|
579
|
+
/** @oneof */
|
|
580
|
+
interface GetInventoryVariantsOptionsIdOneOf {
|
|
581
|
+
/** Inventory item ID. */
|
|
582
|
+
inventoryId?: string;
|
|
583
|
+
/**
|
|
584
|
+
* @internal
|
|
585
|
+
* @deprecated Deprecated (use productID instead).
|
|
586
|
+
* @replacedBy product_id
|
|
587
|
+
* @targetRemovalDate 2024-12-31
|
|
588
|
+
*/
|
|
589
|
+
externalId?: string;
|
|
590
|
+
/** Product ID. */
|
|
591
|
+
productId?: string;
|
|
592
|
+
}
|
|
593
|
+
/**
|
|
594
|
+
* Returns a list of inventory items, given the provided paging, sorting and filtering.
|
|
595
|
+
* @public
|
|
596
|
+
* @permissionId WIX_STORES.READ_INVENTORY
|
|
597
|
+
* @applicableIdentity APP
|
|
598
|
+
* @fqn wix.inventory.api.v1.InventoryReadApi.QueryInventory
|
|
599
|
+
*/
|
|
600
|
+
declare function queryInventory(options?: QueryInventoryOptions): Promise<NonNullablePaths<QueryInventoryResponse, `inventoryItems` | `inventoryItems.${number}.numericId` | `inventoryItems.${number}.preorderInfo.enabled` | `metadata.items` | `metadata.offset` | `totalResults`, 3>>;
|
|
601
|
+
interface QueryInventoryOptions {
|
|
602
|
+
/** Information about paging, filters, sorting. */
|
|
603
|
+
query?: Query;
|
|
604
|
+
}
|
|
552
605
|
/**
|
|
553
606
|
* Updates product inventory, including total quantity, whether the product is in stock, and whether the product inventory is tracked.
|
|
554
607
|
*
|
|
@@ -625,58 +678,5 @@ declare function decrementInventory(decrementData: DecrementData[]): Promise<voi
|
|
|
625
678
|
* @fqn wix.inventory.api.v1.InventoryWriteApi.IncrementInventory
|
|
626
679
|
*/
|
|
627
680
|
declare function incrementInventory(incrementData: IncrementData[]): Promise<void>;
|
|
628
|
-
/**
|
|
629
|
-
* Gets inventory variant information based on the specified option choices.
|
|
630
|
-
*
|
|
631
|
-
*
|
|
632
|
-
* The `getInventoryVariants()` function returns a Promise that resolves to the specified inventory variant information.
|
|
633
|
-
* @param inventoryId - Inventory item ID.
|
|
634
|
-
* @public
|
|
635
|
-
* @requiredField inventoryId
|
|
636
|
-
* @permissionId WIX_STORES.READ_INVENTORY
|
|
637
|
-
* @applicableIdentity APP
|
|
638
|
-
* @fqn wix.inventory.api.v1.InventoryReadApi.GetInventoryVariants
|
|
639
|
-
*/
|
|
640
|
-
declare function getInventoryVariants(inventoryId: string, options?: GetInventoryVariantsOptions): Promise<NonNullablePaths<GetInventoryVariantsResponse, `inventoryItem.variants` | `inventoryItem.variants.${number}.variantId` | `inventoryItem.variants.${number}.availableForPreorder` | `inventoryItem.numericId` | `inventoryItem.preorderInfo.enabled`, 3>>;
|
|
641
|
-
interface GetInventoryVariantsOptions extends GetInventoryVariantsOptionsIdOneOf {
|
|
642
|
-
/**
|
|
643
|
-
* @internal
|
|
644
|
-
* @internal
|
|
645
|
-
* @deprecated Deprecated (use productID instead).
|
|
646
|
-
* @replacedBy product_id
|
|
647
|
-
* @targetRemovalDate 2024-12-31
|
|
648
|
-
*/
|
|
649
|
-
externalId?: string;
|
|
650
|
-
/** Product ID. */
|
|
651
|
-
productId?: string;
|
|
652
|
-
/** Variant IDs to query for this inventory item (optional). */
|
|
653
|
-
variantIds?: string[];
|
|
654
|
-
}
|
|
655
|
-
/** @oneof */
|
|
656
|
-
interface GetInventoryVariantsOptionsIdOneOf {
|
|
657
|
-
/** Inventory item ID. */
|
|
658
|
-
inventoryId?: string;
|
|
659
|
-
/**
|
|
660
|
-
* @internal
|
|
661
|
-
* @deprecated Deprecated (use productID instead).
|
|
662
|
-
* @replacedBy product_id
|
|
663
|
-
* @targetRemovalDate 2024-12-31
|
|
664
|
-
*/
|
|
665
|
-
externalId?: string;
|
|
666
|
-
/** Product ID. */
|
|
667
|
-
productId?: string;
|
|
668
|
-
}
|
|
669
|
-
/**
|
|
670
|
-
* Returns a list of inventory items, given the provided paging, sorting and filtering.
|
|
671
|
-
* @public
|
|
672
|
-
* @permissionId WIX_STORES.READ_INVENTORY
|
|
673
|
-
* @applicableIdentity APP
|
|
674
|
-
* @fqn wix.inventory.api.v1.InventoryReadApi.QueryInventory
|
|
675
|
-
*/
|
|
676
|
-
declare function queryInventory(options?: QueryInventoryOptions): Promise<NonNullablePaths<QueryInventoryResponse, `inventoryItems` | `inventoryItems.${number}.numericId` | `inventoryItems.${number}.preorderInfo.enabled` | `metadata.items` | `metadata.offset` | `totalResults`, 3>>;
|
|
677
|
-
interface QueryInventoryOptions {
|
|
678
|
-
/** Information about paging, filters, sorting. */
|
|
679
|
-
query?: Query;
|
|
680
|
-
}
|
|
681
681
|
|
|
682
682
|
export { type AccountInfo, type BaseEventMetadata, type BulkUpdateInventoryItemsRequest, type BulkUpdateInventoryItemsResponse, type BulkUpdateInventoryVariantsRequest, type BulkUpdateInventoryVariantsRequestActionOneOf, type BulkUpdateInventoryVariantsResponse, type ChangedInventoryVariant, type ChangedInventoryVariantData, type DecrementData, type DecrementDataIdOneOf, type DecrementInventoryRequest, type DecrementInventoryResponse, type GetInventoryItemsRequest, type GetInventoryItemsResponse, type GetInventoryVariantsOptions, type GetInventoryVariantsOptionsIdOneOf, type GetInventoryVariantsRequest, type GetInventoryVariantsRequestIdOneOf, type GetInventoryVariantsResponse, type IdentificationData, type IdentificationDataIdOneOf, type IncrementData, type IncrementDataIdOneOf, type IncrementInventoryRequest, type IncrementInventoryResponse, type InventoryItemChanged, type InventoryItemChangedEnvelope, type InventoryItemV2, type InventoryVariantV2, type InventoryVariantsChanged, type InventoryVariantsChangedEnvelope, type MessageEnvelope, type Paging, type PagingMetadata, type PreorderInfo, type Query, type QueryInventoryOptions, type QueryInventoryRequest, type QueryInventoryResponse, ReasonType, type ReasonTypeWithLiterals, type UpdateInventoryVariantsInventoryItem, type UpdateInventoryVariantsRequest, type UpdateInventoryVariantsResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, decrementInventory, getInventoryVariants, incrementInventory, onInventoryItemChanged, onInventoryVariantsChanged, queryInventory, updateInventoryVariants };
|