@digital8/lighting-illusions-ts-sdk 0.0.992 → 0.0.993
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/.openapi-generator/FILES +6 -0
- package/README.md +8 -3
- package/dist/apis/AttributeApi.d.ts +16 -1
- package/dist/apis/AttributeApi.js +58 -0
- package/dist/apis/ProductCategoryApi.d.ts +23 -4
- package/dist/apis/ProductCategoryApi.js +71 -7
- package/dist/models/CategoryAutomationRuleResource.d.ts +3 -3
- package/dist/models/CategoryAutomationRuleResource.js +3 -5
- package/dist/models/ExternalApiLogResource.d.ts +1 -1
- package/dist/models/ExternalApiLogResource.js +1 -3
- package/dist/models/GetAllProductChildRequest.d.ts +6 -0
- package/dist/models/GetAllProductChildRequest.js +2 -0
- package/dist/models/GetHierarchyProductCategoryRequest.d.ts +32 -0
- package/dist/models/GetHierarchyProductCategoryRequest.js +51 -0
- package/dist/models/IndexAttributeValueRequest.d.ts +105 -0
- package/dist/models/IndexAttributeValueRequest.js +88 -0
- package/dist/models/IndexProductCategoryRequest.d.ts +2 -0
- package/dist/models/IndexProductCategoryRequest.js +3 -1
- package/dist/models/IndexProductChildRequest.d.ts +6 -0
- package/dist/models/IndexProductChildRequest.js +2 -0
- package/dist/models/PaginatedAttributeValueResourceResponse.d.ts +40 -0
- package/dist/models/PaginatedAttributeValueResourceResponse.js +57 -0
- package/dist/models/PreviewAutomationRulesResource.d.ts +0 -6
- package/dist/models/PreviewAutomationRulesResource.js +0 -2
- package/dist/models/ProductAggregationResource.d.ts +2 -2
- package/dist/models/ProductCategoryResource.d.ts +6 -0
- package/dist/models/ProductCategoryResource.js +4 -0
- package/dist/models/ProductChildResource.d.ts +6 -0
- package/dist/models/ProductChildResource.js +4 -0
- package/dist/models/ProductChildSiteDetailResource.d.ts +18 -0
- package/dist/models/ProductChildSiteDetailResource.js +12 -0
- package/dist/models/StoreProductCategoryRequestAutomationRulesInner.d.ts +3 -3
- package/dist/models/StoreProductCategoryRequestAutomationRulesInner.js +3 -5
- package/dist/models/StoreProductChildRequest.d.ts +7 -1
- package/dist/models/StoreProductChildRequest.js +6 -4
- package/dist/models/StoreProductChildRequestSitesInner.d.ts +18 -0
- package/dist/models/StoreProductChildRequestSitesInner.js +12 -0
- package/dist/models/UpdateProductChildRequest.d.ts +12 -0
- package/dist/models/UpdateProductChildRequest.js +6 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/docs/AttributeApi.md +66 -0
- package/docs/CategoryAutomationRuleResource.md +3 -3
- package/docs/GetAllProductChildRequest.md +2 -0
- package/docs/GetHierarchyProductCategoryRequest.md +34 -0
- package/docs/IndexAttributeValueRequest.md +50 -0
- package/docs/IndexProductChildRequest.md +2 -0
- package/docs/PaginatedAttributeValueResourceResponse.md +36 -0
- package/docs/PreviewAutomationRulesResource.md +0 -2
- package/docs/ProductAggregationResource.md +1 -1
- package/docs/ProductCategoryApi.md +83 -6
- package/docs/ProductCategoryResource.md +2 -0
- package/docs/ProductChildResource.md +2 -0
- package/docs/ProductChildSiteDetailResource.md +6 -0
- package/docs/StoreProductCategoryRequestAutomationRulesInner.md +2 -2
- package/docs/StoreProductChildRequest.md +2 -0
- package/docs/StoreProductChildRequestSitesInner.md +6 -0
- package/docs/UpdateProductChildRequest.md +4 -0
- package/package.json +1 -1
- package/src/apis/AttributeApi.ts +50 -0
- package/src/apis/ProductCategoryApi.ts +72 -6
- package/src/models/CategoryAutomationRuleResource.ts +6 -7
- package/src/models/ExternalApiLogResource.ts +2 -3
- package/src/models/GetAllProductChildRequest.ts +8 -0
- package/src/models/GetHierarchyProductCategoryRequest.ts +66 -0
- package/src/models/IndexAttributeValueRequest.ts +159 -0
- package/src/models/IndexProductCategoryRequest.ts +3 -1
- package/src/models/IndexProductChildRequest.ts +8 -0
- package/src/models/PaginatedAttributeValueResourceResponse.ts +90 -0
- package/src/models/PreviewAutomationRulesResource.ts +0 -8
- package/src/models/ProductAggregationResource.ts +2 -2
- package/src/models/ProductCategoryResource.ts +9 -0
- package/src/models/ProductChildResource.ts +9 -0
- package/src/models/ProductChildSiteDetailResource.ts +27 -0
- package/src/models/StoreProductCategoryRequestAutomationRulesInner.ts +6 -7
- package/src/models/StoreProductChildRequest.ts +12 -4
- package/src/models/StoreProductChildRequestSitesInner.ts +27 -0
- package/src/models/UpdateProductChildRequest.ts +17 -0
- package/src/models/index.ts +3 -0
|
@@ -8,9 +8,10 @@ All URIs are relative to *http://localhost/api*
|
|
|
8
8
|
| [**bulkDetachProductsProductCategory**](ProductCategoryApi.md#bulkdetachproductsproductcategory) | **DELETE** /admin-api/product-category/{productCategory}/bulk-detach-products | Auto-generated: bulkDetachProductsProductCategory |
|
|
9
9
|
| [**destroyProductCategory**](ProductCategoryApi.md#destroyproductcategory) | **DELETE** /admin-api/product-category/{productCategory}/delete | Auto-generated: destroyProductCategory |
|
|
10
10
|
| [**detachProductsProductCategory**](ProductCategoryApi.md#detachproductsproductcategoryoperation) | **POST** /admin-api/product-category/{productCategory}/detach-products | Auto-generated: detachProductsProductCategory |
|
|
11
|
+
| [**getAllChildrenProductCategory**](ProductCategoryApi.md#getallchildrenproductcategory) | **POST** /admin-api/product-category/{productCategory}/children/all | Auto-generated: getAllChildrenProductCategory |
|
|
11
12
|
| [**getAllProductCategory**](ProductCategoryApi.md#getallproductcategoryoperation) | **POST** /admin-api/product-category/all | Auto-generated: getAllProductCategory |
|
|
12
13
|
| [**getChildrenProductCategory**](ProductCategoryApi.md#getchildrenproductcategory) | **GET** /admin-api/product-category/{productCategory}/children | Auto-generated: getChildrenProductCategory |
|
|
13
|
-
| [**getHierarchyProductCategory**](ProductCategoryApi.md#
|
|
14
|
+
| [**getHierarchyProductCategory**](ProductCategoryApi.md#gethierarchyproductcategoryoperation) | **POST** /admin-api/product-category/hierarchy | Auto-generated: getHierarchyProductCategory |
|
|
14
15
|
| [**indexProductCategory**](ProductCategoryApi.md#indexproductcategoryoperation) | **POST** /admin-api/product-category/list | Auto-generated: indexProductCategory |
|
|
15
16
|
| [**previewAutomationRulesProductCategory**](ProductCategoryApi.md#previewautomationrulesproductcategoryoperation) | **POST** /admin-api/product-category/preview-automation-rules | Auto-generated: previewAutomationRulesProductCategory |
|
|
16
17
|
| [**showProductCategory**](ProductCategoryApi.md#showproductcategory) | **GET** /admin-api/product-category/{productCategory} | Auto-generated: showProductCategory |
|
|
@@ -285,6 +286,74 @@ No authorization required
|
|
|
285
286
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
286
287
|
|
|
287
288
|
|
|
289
|
+
## getAllChildrenProductCategory
|
|
290
|
+
|
|
291
|
+
> ProductCategoryListResourceArrayResponse getAllChildrenProductCategory(productCategory, getAllProductCategoryRequest)
|
|
292
|
+
|
|
293
|
+
Auto-generated: getAllChildrenProductCategory
|
|
294
|
+
|
|
295
|
+
### Example
|
|
296
|
+
|
|
297
|
+
```ts
|
|
298
|
+
import {
|
|
299
|
+
Configuration,
|
|
300
|
+
ProductCategoryApi,
|
|
301
|
+
} from '@digital8/lighting-illusions-ts-sdk';
|
|
302
|
+
import type { GetAllChildrenProductCategoryRequest } from '@digital8/lighting-illusions-ts-sdk';
|
|
303
|
+
|
|
304
|
+
async function example() {
|
|
305
|
+
console.log("🚀 Testing @digital8/lighting-illusions-ts-sdk SDK...");
|
|
306
|
+
const api = new ProductCategoryApi();
|
|
307
|
+
|
|
308
|
+
const body = {
|
|
309
|
+
// number | The id of the productCategory
|
|
310
|
+
productCategory: 56,
|
|
311
|
+
// GetAllProductCategoryRequest (optional)
|
|
312
|
+
getAllProductCategoryRequest: ...,
|
|
313
|
+
} satisfies GetAllChildrenProductCategoryRequest;
|
|
314
|
+
|
|
315
|
+
try {
|
|
316
|
+
const data = await api.getAllChildrenProductCategory(body);
|
|
317
|
+
console.log(data);
|
|
318
|
+
} catch (error) {
|
|
319
|
+
console.error(error);
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
// Run the test
|
|
324
|
+
example().catch(console.error);
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
### Parameters
|
|
328
|
+
|
|
329
|
+
|
|
330
|
+
| Name | Type | Description | Notes |
|
|
331
|
+
|------------- | ------------- | ------------- | -------------|
|
|
332
|
+
| **productCategory** | `number` | The id of the productCategory | [Defaults to `undefined`] |
|
|
333
|
+
| **getAllProductCategoryRequest** | [GetAllProductCategoryRequest](GetAllProductCategoryRequest.md) | | [Optional] |
|
|
334
|
+
|
|
335
|
+
### Return type
|
|
336
|
+
|
|
337
|
+
[**ProductCategoryListResourceArrayResponse**](ProductCategoryListResourceArrayResponse.md)
|
|
338
|
+
|
|
339
|
+
### Authorization
|
|
340
|
+
|
|
341
|
+
No authorization required
|
|
342
|
+
|
|
343
|
+
### HTTP request headers
|
|
344
|
+
|
|
345
|
+
- **Content-Type**: `application/json`
|
|
346
|
+
- **Accept**: `application/json`
|
|
347
|
+
|
|
348
|
+
|
|
349
|
+
### HTTP response details
|
|
350
|
+
| Status code | Description | Response headers |
|
|
351
|
+
|-------------|-------------|------------------|
|
|
352
|
+
| **200** | Successful resource response | - |
|
|
353
|
+
|
|
354
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
355
|
+
|
|
356
|
+
|
|
288
357
|
## getAllProductCategory
|
|
289
358
|
|
|
290
359
|
> ProductCategoryLiteResourceArrayResponse getAllProductCategory(getAllProductCategoryRequest)
|
|
@@ -420,7 +489,7 @@ No authorization required
|
|
|
420
489
|
|
|
421
490
|
## getHierarchyProductCategory
|
|
422
491
|
|
|
423
|
-
> ProductCategoryHierarchyResourceArrayResponse getHierarchyProductCategory()
|
|
492
|
+
> ProductCategoryHierarchyResourceArrayResponse getHierarchyProductCategory(getHierarchyProductCategoryRequest)
|
|
424
493
|
|
|
425
494
|
Auto-generated: getHierarchyProductCategory
|
|
426
495
|
|
|
@@ -431,14 +500,19 @@ import {
|
|
|
431
500
|
Configuration,
|
|
432
501
|
ProductCategoryApi,
|
|
433
502
|
} from '@digital8/lighting-illusions-ts-sdk';
|
|
434
|
-
import type {
|
|
503
|
+
import type { GetHierarchyProductCategoryOperationRequest } from '@digital8/lighting-illusions-ts-sdk';
|
|
435
504
|
|
|
436
505
|
async function example() {
|
|
437
506
|
console.log("🚀 Testing @digital8/lighting-illusions-ts-sdk SDK...");
|
|
438
507
|
const api = new ProductCategoryApi();
|
|
439
508
|
|
|
509
|
+
const body = {
|
|
510
|
+
// GetHierarchyProductCategoryRequest (optional)
|
|
511
|
+
getHierarchyProductCategoryRequest: ...,
|
|
512
|
+
} satisfies GetHierarchyProductCategoryOperationRequest;
|
|
513
|
+
|
|
440
514
|
try {
|
|
441
|
-
const data = await api.getHierarchyProductCategory();
|
|
515
|
+
const data = await api.getHierarchyProductCategory(body);
|
|
442
516
|
console.log(data);
|
|
443
517
|
} catch (error) {
|
|
444
518
|
console.error(error);
|
|
@@ -451,7 +525,10 @@ example().catch(console.error);
|
|
|
451
525
|
|
|
452
526
|
### Parameters
|
|
453
527
|
|
|
454
|
-
|
|
528
|
+
|
|
529
|
+
| Name | Type | Description | Notes |
|
|
530
|
+
|------------- | ------------- | ------------- | -------------|
|
|
531
|
+
| **getHierarchyProductCategoryRequest** | [GetHierarchyProductCategoryRequest](GetHierarchyProductCategoryRequest.md) | | [Optional] |
|
|
455
532
|
|
|
456
533
|
### Return type
|
|
457
534
|
|
|
@@ -463,7 +540,7 @@ No authorization required
|
|
|
463
540
|
|
|
464
541
|
### HTTP request headers
|
|
465
542
|
|
|
466
|
-
- **Content-Type**:
|
|
543
|
+
- **Content-Type**: `application/json`
|
|
467
544
|
- **Accept**: `application/json`
|
|
468
545
|
|
|
469
546
|
|
|
@@ -21,6 +21,7 @@ Name | Type
|
|
|
21
21
|
`site` | [SiteLiteResource](SiteLiteResource.md)
|
|
22
22
|
`seo` | [Array<SEOResource>](SEOResource.md)
|
|
23
23
|
`descriptions` | [Array<DescriptionResource>](DescriptionResource.md)
|
|
24
|
+
`linkedProductsCount` | number
|
|
24
25
|
|
|
25
26
|
## Example
|
|
26
27
|
|
|
@@ -44,6 +45,7 @@ const example = {
|
|
|
44
45
|
"site": null,
|
|
45
46
|
"seo": null,
|
|
46
47
|
"descriptions": null,
|
|
48
|
+
"linkedProductsCount": null,
|
|
47
49
|
} satisfies ProductCategoryResource
|
|
48
50
|
|
|
49
51
|
console.log(example)
|
|
@@ -12,6 +12,7 @@ Name | Type
|
|
|
12
12
|
`modelNumber` | string
|
|
13
13
|
`weight` | number
|
|
14
14
|
`warranty` | string
|
|
15
|
+
`isWarrantyOverridden` | boolean
|
|
15
16
|
`stock` | number
|
|
16
17
|
`sku` | number
|
|
17
18
|
`buyPrice` | number
|
|
@@ -46,6 +47,7 @@ const example = {
|
|
|
46
47
|
"modelNumber": null,
|
|
47
48
|
"weight": null,
|
|
48
49
|
"warranty": null,
|
|
50
|
+
"isWarrantyOverridden": null,
|
|
49
51
|
"stock": null,
|
|
50
52
|
"sku": null,
|
|
51
53
|
"buyPrice": null,
|
|
@@ -9,9 +9,12 @@ Name | Type
|
|
|
9
9
|
`id` | number
|
|
10
10
|
`site` | [SiteLiteResource](SiteLiteResource.md)
|
|
11
11
|
`name` | string
|
|
12
|
+
`isNameOverridden` | boolean
|
|
12
13
|
`slug` | string
|
|
14
|
+
`isSlugOverridden` | boolean
|
|
13
15
|
`description` | string
|
|
14
16
|
`displayName` | string
|
|
17
|
+
`isDisplayNameOverridden` | boolean
|
|
15
18
|
`rrpPrice` | number
|
|
16
19
|
`salePrice` | number
|
|
17
20
|
`isDisabled` | boolean
|
|
@@ -29,9 +32,12 @@ const example = {
|
|
|
29
32
|
"id": null,
|
|
30
33
|
"site": null,
|
|
31
34
|
"name": null,
|
|
35
|
+
"isNameOverridden": null,
|
|
32
36
|
"slug": null,
|
|
37
|
+
"isSlugOverridden": null,
|
|
33
38
|
"description": null,
|
|
34
39
|
"displayName": null,
|
|
40
|
+
"isDisplayNameOverridden": null,
|
|
35
41
|
"rrpPrice": null,
|
|
36
42
|
"salePrice": null,
|
|
37
43
|
"isDisabled": null,
|
|
@@ -11,7 +11,7 @@ Name | Type
|
|
|
11
11
|
`groupId` | number
|
|
12
12
|
`relatedId` | string
|
|
13
13
|
`value` | string
|
|
14
|
-
`
|
|
14
|
+
`valueId` | number
|
|
15
15
|
|
|
16
16
|
## Example
|
|
17
17
|
|
|
@@ -25,7 +25,7 @@ const example = {
|
|
|
25
25
|
"groupId": null,
|
|
26
26
|
"relatedId": null,
|
|
27
27
|
"value": null,
|
|
28
|
-
"
|
|
28
|
+
"valueId": null,
|
|
29
29
|
} satisfies StoreProductCategoryRequestAutomationRulesInner
|
|
30
30
|
|
|
31
31
|
console.log(example)
|
|
@@ -13,6 +13,7 @@ Name | Type
|
|
|
13
13
|
`newArrivalStartDate` | Date
|
|
14
14
|
`newArrivalEndDate` | Date
|
|
15
15
|
`warranty` | string
|
|
16
|
+
`isWarrantyOverridden` | boolean
|
|
16
17
|
`hideFromFrontend` | boolean
|
|
17
18
|
`excludeFromSearch` | boolean
|
|
18
19
|
`allowOversell` | boolean
|
|
@@ -39,6 +40,7 @@ const example = {
|
|
|
39
40
|
"newArrivalStartDate": null,
|
|
40
41
|
"newArrivalEndDate": null,
|
|
41
42
|
"warranty": null,
|
|
43
|
+
"isWarrantyOverridden": null,
|
|
42
44
|
"hideFromFrontend": null,
|
|
43
45
|
"excludeFromSearch": null,
|
|
44
46
|
"allowOversell": null,
|
|
@@ -8,11 +8,14 @@ Name | Type
|
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`siteId` | number
|
|
10
10
|
`name` | string
|
|
11
|
+
`isNameOverridden` | boolean
|
|
11
12
|
`displayName` | string
|
|
13
|
+
`isDisplayNameOverridden` | boolean
|
|
12
14
|
`description` | string
|
|
13
15
|
`rrpPrice` | number
|
|
14
16
|
`salePrice` | number
|
|
15
17
|
`slug` | string
|
|
18
|
+
`isSlugOverridden` | boolean
|
|
16
19
|
`documents` | Array<number>
|
|
17
20
|
`seoTitle` | string
|
|
18
21
|
`seoDescription` | string
|
|
@@ -26,11 +29,14 @@ import type { StoreProductChildRequestSitesInner } from '@digital8/lighting-illu
|
|
|
26
29
|
const example = {
|
|
27
30
|
"siteId": null,
|
|
28
31
|
"name": null,
|
|
32
|
+
"isNameOverridden": null,
|
|
29
33
|
"displayName": null,
|
|
34
|
+
"isDisplayNameOverridden": null,
|
|
30
35
|
"description": null,
|
|
31
36
|
"rrpPrice": null,
|
|
32
37
|
"salePrice": null,
|
|
33
38
|
"slug": null,
|
|
39
|
+
"isSlugOverridden": null,
|
|
34
40
|
"documents": null,
|
|
35
41
|
"seoTitle": null,
|
|
36
42
|
"seoDescription": null,
|
|
@@ -12,6 +12,7 @@ Name | Type
|
|
|
12
12
|
`newArrivalStartDate` | Date
|
|
13
13
|
`newArrivalEndDate` | Date
|
|
14
14
|
`warranty` | string
|
|
15
|
+
`isWarrantyOverridden` | boolean
|
|
15
16
|
`hideFromFrontend` | boolean
|
|
16
17
|
`excludeFromSearch` | boolean
|
|
17
18
|
`allowOversell` | boolean
|
|
@@ -19,6 +20,7 @@ Name | Type
|
|
|
19
20
|
`popularityScore` | number
|
|
20
21
|
`stock` | number
|
|
21
22
|
`sites` | [Array<StoreProductChildRequestSitesInner>](StoreProductChildRequestSitesInner.md)
|
|
23
|
+
`accessories` | Array<number>
|
|
22
24
|
`assets` | [Array<UpdateProductChildRequestAssetsInner>](UpdateProductChildRequestAssetsInner.md)
|
|
23
25
|
|
|
24
26
|
## Example
|
|
@@ -34,6 +36,7 @@ const example = {
|
|
|
34
36
|
"newArrivalStartDate": null,
|
|
35
37
|
"newArrivalEndDate": null,
|
|
36
38
|
"warranty": null,
|
|
39
|
+
"isWarrantyOverridden": null,
|
|
37
40
|
"hideFromFrontend": null,
|
|
38
41
|
"excludeFromSearch": null,
|
|
39
42
|
"allowOversell": null,
|
|
@@ -41,6 +44,7 @@ const example = {
|
|
|
41
44
|
"popularityScore": null,
|
|
42
45
|
"stock": null,
|
|
43
46
|
"sites": null,
|
|
47
|
+
"accessories": null,
|
|
44
48
|
"assets": null,
|
|
45
49
|
} satisfies UpdateProductChildRequest
|
|
46
50
|
|
package/package.json
CHANGED
package/src/apis/AttributeApi.ts
CHANGED
|
@@ -23,8 +23,10 @@ import type {
|
|
|
23
23
|
GenericResponse,
|
|
24
24
|
GetAllAttributeRequest,
|
|
25
25
|
IndexAttributeRequest,
|
|
26
|
+
IndexAttributeValueRequest,
|
|
26
27
|
ModelAttributeResourceArrayResponse,
|
|
27
28
|
PaginatedAttributeListResourceResponse,
|
|
29
|
+
PaginatedAttributeValueResourceResponse,
|
|
28
30
|
StoreAttributeRequest,
|
|
29
31
|
StoreAttributeValueRequest,
|
|
30
32
|
UpdateAttributeRequest,
|
|
@@ -49,10 +51,14 @@ import {
|
|
|
49
51
|
GetAllAttributeRequestToJSON,
|
|
50
52
|
IndexAttributeRequestFromJSON,
|
|
51
53
|
IndexAttributeRequestToJSON,
|
|
54
|
+
IndexAttributeValueRequestFromJSON,
|
|
55
|
+
IndexAttributeValueRequestToJSON,
|
|
52
56
|
ModelAttributeResourceArrayResponseFromJSON,
|
|
53
57
|
ModelAttributeResourceArrayResponseToJSON,
|
|
54
58
|
PaginatedAttributeListResourceResponseFromJSON,
|
|
55
59
|
PaginatedAttributeListResourceResponseToJSON,
|
|
60
|
+
PaginatedAttributeValueResourceResponseFromJSON,
|
|
61
|
+
PaginatedAttributeValueResourceResponseToJSON,
|
|
56
62
|
StoreAttributeRequestFromJSON,
|
|
57
63
|
StoreAttributeRequestToJSON,
|
|
58
64
|
StoreAttributeValueRequestFromJSON,
|
|
@@ -94,6 +100,10 @@ export interface IndexAttributeOperationRequest {
|
|
|
94
100
|
indexAttributeRequest?: IndexAttributeRequest;
|
|
95
101
|
}
|
|
96
102
|
|
|
103
|
+
export interface IndexAttributeValueOperationRequest {
|
|
104
|
+
indexAttributeValueRequest?: IndexAttributeValueRequest;
|
|
105
|
+
}
|
|
106
|
+
|
|
97
107
|
export interface ShowAttributeRequest {
|
|
98
108
|
attribute: number;
|
|
99
109
|
}
|
|
@@ -409,6 +419,46 @@ export class AttributeApi extends runtime.BaseAPI {
|
|
|
409
419
|
return await response.value();
|
|
410
420
|
}
|
|
411
421
|
|
|
422
|
+
/**
|
|
423
|
+
* Creates request options for indexAttributeValue without sending the request
|
|
424
|
+
*/
|
|
425
|
+
async indexAttributeValueRequestOpts(requestParameters: IndexAttributeValueOperationRequest): Promise<runtime.RequestOpts> {
|
|
426
|
+
const queryParameters: any = {};
|
|
427
|
+
|
|
428
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
429
|
+
|
|
430
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
431
|
+
|
|
432
|
+
|
|
433
|
+
let urlPath = `/admin-api/attribute/value/list`;
|
|
434
|
+
|
|
435
|
+
return {
|
|
436
|
+
path: urlPath,
|
|
437
|
+
method: 'POST',
|
|
438
|
+
headers: headerParameters,
|
|
439
|
+
query: queryParameters,
|
|
440
|
+
body: IndexAttributeValueRequestToJSON(requestParameters['indexAttributeValueRequest']),
|
|
441
|
+
};
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
/**
|
|
445
|
+
* Auto-generated: indexAttributeValue
|
|
446
|
+
*/
|
|
447
|
+
async indexAttributeValueRaw(requestParameters: IndexAttributeValueOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedAttributeValueResourceResponse>> {
|
|
448
|
+
const requestOptions = await this.indexAttributeValueRequestOpts(requestParameters);
|
|
449
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
450
|
+
|
|
451
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => PaginatedAttributeValueResourceResponseFromJSON(jsonValue));
|
|
452
|
+
}
|
|
453
|
+
|
|
454
|
+
/**
|
|
455
|
+
* Auto-generated: indexAttributeValue
|
|
456
|
+
*/
|
|
457
|
+
async indexAttributeValue(requestParameters: IndexAttributeValueOperationRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedAttributeValueResourceResponse> {
|
|
458
|
+
const response = await this.indexAttributeValueRaw(requestParameters, initOverrides);
|
|
459
|
+
return await response.value();
|
|
460
|
+
}
|
|
461
|
+
|
|
412
462
|
/**
|
|
413
463
|
* Creates request options for showAttribute without sending the request
|
|
414
464
|
*/
|
|
@@ -19,11 +19,13 @@ import type {
|
|
|
19
19
|
DetachProductsProductCategoryRequest,
|
|
20
20
|
GenericResponse,
|
|
21
21
|
GetAllProductCategoryRequest,
|
|
22
|
+
GetHierarchyProductCategoryRequest,
|
|
22
23
|
IndexProductCategoryRequest,
|
|
23
24
|
PaginatedProductCategoryListResourceResponse,
|
|
24
25
|
PreviewAutomationRulesProductCategoryRequest,
|
|
25
26
|
PreviewAutomationRulesResource,
|
|
26
27
|
ProductCategoryHierarchyResourceArrayResponse,
|
|
28
|
+
ProductCategoryListResourceArrayResponse,
|
|
27
29
|
ProductCategoryLiteResourceArrayResponse,
|
|
28
30
|
ProductCategoryResource,
|
|
29
31
|
StoreProductCategoryRequest,
|
|
@@ -38,6 +40,8 @@ import {
|
|
|
38
40
|
GenericResponseToJSON,
|
|
39
41
|
GetAllProductCategoryRequestFromJSON,
|
|
40
42
|
GetAllProductCategoryRequestToJSON,
|
|
43
|
+
GetHierarchyProductCategoryRequestFromJSON,
|
|
44
|
+
GetHierarchyProductCategoryRequestToJSON,
|
|
41
45
|
IndexProductCategoryRequestFromJSON,
|
|
42
46
|
IndexProductCategoryRequestToJSON,
|
|
43
47
|
PaginatedProductCategoryListResourceResponseFromJSON,
|
|
@@ -48,6 +52,8 @@ import {
|
|
|
48
52
|
PreviewAutomationRulesResourceToJSON,
|
|
49
53
|
ProductCategoryHierarchyResourceArrayResponseFromJSON,
|
|
50
54
|
ProductCategoryHierarchyResourceArrayResponseToJSON,
|
|
55
|
+
ProductCategoryListResourceArrayResponseFromJSON,
|
|
56
|
+
ProductCategoryListResourceArrayResponseToJSON,
|
|
51
57
|
ProductCategoryLiteResourceArrayResponseFromJSON,
|
|
52
58
|
ProductCategoryLiteResourceArrayResponseToJSON,
|
|
53
59
|
ProductCategoryResourceFromJSON,
|
|
@@ -76,6 +82,11 @@ export interface DetachProductsProductCategoryOperationRequest {
|
|
|
76
82
|
detachProductsProductCategoryRequest?: DetachProductsProductCategoryRequest;
|
|
77
83
|
}
|
|
78
84
|
|
|
85
|
+
export interface GetAllChildrenProductCategoryRequest {
|
|
86
|
+
productCategory: number;
|
|
87
|
+
getAllProductCategoryRequest?: GetAllProductCategoryRequest;
|
|
88
|
+
}
|
|
89
|
+
|
|
79
90
|
export interface GetAllProductCategoryOperationRequest {
|
|
80
91
|
getAllProductCategoryRequest?: GetAllProductCategoryRequest;
|
|
81
92
|
}
|
|
@@ -85,6 +96,10 @@ export interface GetChildrenProductCategoryRequest {
|
|
|
85
96
|
indexProductCategoryRequest?: IndexProductCategoryRequest;
|
|
86
97
|
}
|
|
87
98
|
|
|
99
|
+
export interface GetHierarchyProductCategoryOperationRequest {
|
|
100
|
+
getHierarchyProductCategoryRequest?: GetHierarchyProductCategoryRequest;
|
|
101
|
+
}
|
|
102
|
+
|
|
88
103
|
export interface IndexProductCategoryOperationRequest {
|
|
89
104
|
indexProductCategoryRequest?: IndexProductCategoryRequest;
|
|
90
105
|
}
|
|
@@ -297,6 +312,54 @@ export class ProductCategoryApi extends runtime.BaseAPI {
|
|
|
297
312
|
return await response.value();
|
|
298
313
|
}
|
|
299
314
|
|
|
315
|
+
/**
|
|
316
|
+
* Creates request options for getAllChildrenProductCategory without sending the request
|
|
317
|
+
*/
|
|
318
|
+
async getAllChildrenProductCategoryRequestOpts(requestParameters: GetAllChildrenProductCategoryRequest): Promise<runtime.RequestOpts> {
|
|
319
|
+
if (requestParameters['productCategory'] == null) {
|
|
320
|
+
throw new runtime.RequiredError(
|
|
321
|
+
'productCategory',
|
|
322
|
+
'Required parameter "productCategory" was null or undefined when calling getAllChildrenProductCategory().'
|
|
323
|
+
);
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
const queryParameters: any = {};
|
|
327
|
+
|
|
328
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
329
|
+
|
|
330
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
331
|
+
|
|
332
|
+
|
|
333
|
+
let urlPath = `/admin-api/product-category/{productCategory}/children/all`;
|
|
334
|
+
urlPath = urlPath.replace(`{${"productCategory"}}`, encodeURIComponent(String(requestParameters['productCategory'])));
|
|
335
|
+
|
|
336
|
+
return {
|
|
337
|
+
path: urlPath,
|
|
338
|
+
method: 'POST',
|
|
339
|
+
headers: headerParameters,
|
|
340
|
+
query: queryParameters,
|
|
341
|
+
body: GetAllProductCategoryRequestToJSON(requestParameters['getAllProductCategoryRequest']),
|
|
342
|
+
};
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* Auto-generated: getAllChildrenProductCategory
|
|
347
|
+
*/
|
|
348
|
+
async getAllChildrenProductCategoryRaw(requestParameters: GetAllChildrenProductCategoryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProductCategoryListResourceArrayResponse>> {
|
|
349
|
+
const requestOptions = await this.getAllChildrenProductCategoryRequestOpts(requestParameters);
|
|
350
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
351
|
+
|
|
352
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ProductCategoryListResourceArrayResponseFromJSON(jsonValue));
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
/**
|
|
356
|
+
* Auto-generated: getAllChildrenProductCategory
|
|
357
|
+
*/
|
|
358
|
+
async getAllChildrenProductCategory(requestParameters: GetAllChildrenProductCategoryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductCategoryListResourceArrayResponse> {
|
|
359
|
+
const response = await this.getAllChildrenProductCategoryRaw(requestParameters, initOverrides);
|
|
360
|
+
return await response.value();
|
|
361
|
+
}
|
|
362
|
+
|
|
300
363
|
/**
|
|
301
364
|
* Creates request options for getAllProductCategory without sending the request
|
|
302
365
|
*/
|
|
@@ -388,27 +451,30 @@ export class ProductCategoryApi extends runtime.BaseAPI {
|
|
|
388
451
|
/**
|
|
389
452
|
* Creates request options for getHierarchyProductCategory without sending the request
|
|
390
453
|
*/
|
|
391
|
-
async getHierarchyProductCategoryRequestOpts(): Promise<runtime.RequestOpts> {
|
|
454
|
+
async getHierarchyProductCategoryRequestOpts(requestParameters: GetHierarchyProductCategoryOperationRequest): Promise<runtime.RequestOpts> {
|
|
392
455
|
const queryParameters: any = {};
|
|
393
456
|
|
|
394
457
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
395
458
|
|
|
459
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
460
|
+
|
|
396
461
|
|
|
397
462
|
let urlPath = `/admin-api/product-category/hierarchy`;
|
|
398
463
|
|
|
399
464
|
return {
|
|
400
465
|
path: urlPath,
|
|
401
|
-
method: '
|
|
466
|
+
method: 'POST',
|
|
402
467
|
headers: headerParameters,
|
|
403
468
|
query: queryParameters,
|
|
469
|
+
body: GetHierarchyProductCategoryRequestToJSON(requestParameters['getHierarchyProductCategoryRequest']),
|
|
404
470
|
};
|
|
405
471
|
}
|
|
406
472
|
|
|
407
473
|
/**
|
|
408
474
|
* Auto-generated: getHierarchyProductCategory
|
|
409
475
|
*/
|
|
410
|
-
async getHierarchyProductCategoryRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProductCategoryHierarchyResourceArrayResponse>> {
|
|
411
|
-
const requestOptions = await this.getHierarchyProductCategoryRequestOpts();
|
|
476
|
+
async getHierarchyProductCategoryRaw(requestParameters: GetHierarchyProductCategoryOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProductCategoryHierarchyResourceArrayResponse>> {
|
|
477
|
+
const requestOptions = await this.getHierarchyProductCategoryRequestOpts(requestParameters);
|
|
412
478
|
const response = await this.request(requestOptions, initOverrides);
|
|
413
479
|
|
|
414
480
|
return new runtime.JSONApiResponse(response, (jsonValue) => ProductCategoryHierarchyResourceArrayResponseFromJSON(jsonValue));
|
|
@@ -417,8 +483,8 @@ export class ProductCategoryApi extends runtime.BaseAPI {
|
|
|
417
483
|
/**
|
|
418
484
|
* Auto-generated: getHierarchyProductCategory
|
|
419
485
|
*/
|
|
420
|
-
async getHierarchyProductCategory(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductCategoryHierarchyResourceArrayResponse> {
|
|
421
|
-
const response = await this.getHierarchyProductCategoryRaw(initOverrides);
|
|
486
|
+
async getHierarchyProductCategory(requestParameters: GetHierarchyProductCategoryOperationRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductCategoryHierarchyResourceArrayResponse> {
|
|
487
|
+
const response = await this.getHierarchyProductCategoryRaw(requestParameters, initOverrides);
|
|
422
488
|
return await response.value();
|
|
423
489
|
}
|
|
424
490
|
|
|
@@ -39,10 +39,10 @@ export interface CategoryAutomationRuleResource {
|
|
|
39
39
|
comparisonType: object;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
|
-
* @type {
|
|
42
|
+
* @type {string}
|
|
43
43
|
* @memberof CategoryAutomationRuleResource
|
|
44
44
|
*/
|
|
45
|
-
groupId
|
|
45
|
+
groupId?: string | null;
|
|
46
46
|
/**
|
|
47
47
|
*
|
|
48
48
|
* @type {string}
|
|
@@ -60,7 +60,7 @@ export interface CategoryAutomationRuleResource {
|
|
|
60
60
|
* @type {string}
|
|
61
61
|
* @memberof CategoryAutomationRuleResource
|
|
62
62
|
*/
|
|
63
|
-
|
|
63
|
+
valueId?: string | null;
|
|
64
64
|
}
|
|
65
65
|
|
|
66
66
|
/**
|
|
@@ -69,7 +69,6 @@ export interface CategoryAutomationRuleResource {
|
|
|
69
69
|
export function instanceOfCategoryAutomationRuleResource(value: object): value is CategoryAutomationRuleResource {
|
|
70
70
|
if (!('fieldType' in value) || value['fieldType'] === undefined) return false;
|
|
71
71
|
if (!('comparisonType' in value) || value['comparisonType'] === undefined) return false;
|
|
72
|
-
if (!('groupId' in value) || value['groupId'] === undefined) return false;
|
|
73
72
|
if (!('value' in value) || value['value'] === undefined) return false;
|
|
74
73
|
return true;
|
|
75
74
|
}
|
|
@@ -87,10 +86,10 @@ export function CategoryAutomationRuleResourceFromJSONTyped(json: any, ignoreDis
|
|
|
87
86
|
'id': json['id'] == null ? undefined : json['id'],
|
|
88
87
|
'fieldType': json['fieldType'],
|
|
89
88
|
'comparisonType': json['comparisonType'],
|
|
90
|
-
'groupId': json['groupId'],
|
|
89
|
+
'groupId': json['groupId'] == null ? undefined : json['groupId'],
|
|
91
90
|
'relatedId': json['relatedId'] == null ? undefined : json['relatedId'],
|
|
92
91
|
'value': json['value'],
|
|
93
|
-
'
|
|
92
|
+
'valueId': json['valueId'] == null ? undefined : json['valueId'],
|
|
94
93
|
};
|
|
95
94
|
}
|
|
96
95
|
|
|
@@ -111,7 +110,7 @@ export function CategoryAutomationRuleResourceToJSONTyped(value?: CategoryAutoma
|
|
|
111
110
|
'groupId': value['groupId'],
|
|
112
111
|
'relatedId': value['relatedId'],
|
|
113
112
|
'value': value['value'],
|
|
114
|
-
'
|
|
113
|
+
'valueId': value['valueId'],
|
|
115
114
|
};
|
|
116
115
|
}
|
|
117
116
|
|
|
@@ -74,7 +74,7 @@ export interface ExternalApiLogResource {
|
|
|
74
74
|
* @type {string}
|
|
75
75
|
* @memberof ExternalApiLogResource
|
|
76
76
|
*/
|
|
77
|
-
requestPayload
|
|
77
|
+
requestPayload?: string | null;
|
|
78
78
|
/**
|
|
79
79
|
*
|
|
80
80
|
* @type {string}
|
|
@@ -106,7 +106,6 @@ export function instanceOfExternalApiLogResource(value: object): value is Extern
|
|
|
106
106
|
if (!('exteranlApiLoggableId' in value) || value['exteranlApiLoggableId'] === undefined) return false;
|
|
107
107
|
if (!('endpoint' in value) || value['endpoint'] === undefined) return false;
|
|
108
108
|
if (!('responseCode' in value) || value['responseCode'] === undefined) return false;
|
|
109
|
-
if (!('requestPayload' in value) || value['requestPayload'] === undefined) return false;
|
|
110
109
|
if (!('responsePayload' in value) || value['responsePayload'] === undefined) return false;
|
|
111
110
|
if (!('site' in value) || value['site'] === undefined) return false;
|
|
112
111
|
return true;
|
|
@@ -129,7 +128,7 @@ export function ExternalApiLogResourceFromJSONTyped(json: any, ignoreDiscriminat
|
|
|
129
128
|
'exteranlApiLoggableId': json['exteranlApiLoggableId'],
|
|
130
129
|
'endpoint': json['endpoint'],
|
|
131
130
|
'responseCode': json['responseCode'],
|
|
132
|
-
'requestPayload': json['requestPayload'],
|
|
131
|
+
'requestPayload': json['requestPayload'] == null ? undefined : json['requestPayload'],
|
|
133
132
|
'responsePayload': json['responsePayload'],
|
|
134
133
|
'createdAt': json['createdAt'] == null ? undefined : json['createdAt'],
|
|
135
134
|
'site': SiteLiteResourceFromJSON(json['site']),
|
|
@@ -91,6 +91,12 @@ export interface GetAllProductChildRequest {
|
|
|
91
91
|
* @memberof GetAllProductChildRequest
|
|
92
92
|
*/
|
|
93
93
|
productTypeId?: Array<string>;
|
|
94
|
+
/**
|
|
95
|
+
*
|
|
96
|
+
* @type {Array<string>}
|
|
97
|
+
* @memberof GetAllProductChildRequest
|
|
98
|
+
*/
|
|
99
|
+
parentIsAccessory?: Array<string>;
|
|
94
100
|
}
|
|
95
101
|
|
|
96
102
|
|
|
@@ -163,6 +169,7 @@ export function GetAllProductChildRequestFromJSONTyped(json: any, ignoreDiscrimi
|
|
|
163
169
|
'categoryId': json['category-id'] == null ? undefined : json['category-id'],
|
|
164
170
|
'supplierId': json['supplier-id'] == null ? undefined : json['supplier-id'],
|
|
165
171
|
'productTypeId': json['productType-id'] == null ? undefined : json['productType-id'],
|
|
172
|
+
'parentIsAccessory': json['parent-is_accessory'] == null ? undefined : json['parent-is_accessory'],
|
|
166
173
|
};
|
|
167
174
|
}
|
|
168
175
|
|
|
@@ -189,6 +196,7 @@ export function GetAllProductChildRequestToJSONTyped(value?: GetAllProductChildR
|
|
|
189
196
|
'category-id': value['categoryId'],
|
|
190
197
|
'supplier-id': value['supplierId'],
|
|
191
198
|
'productType-id': value['productTypeId'],
|
|
199
|
+
'parent-is_accessory': value['parentIsAccessory'],
|
|
192
200
|
};
|
|
193
201
|
}
|
|
194
202
|
|