@digital8/lighting-illusions-ts-sdk 0.0.1093 → 0.0.1095
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 +0 -6
- package/README.md +3 -6
- package/dist/apis/ProductApi.d.ts +5 -6
- package/dist/apis/ProductApi.js +2 -4
- package/dist/models/AttachAssetsOverlayTemplateRequest.d.ts +0 -6
- package/dist/models/AttachAssetsOverlayTemplateRequest.js +0 -2
- package/dist/models/ExternalApiLogResource.d.ts +1 -1
- package/dist/models/ExternalApiLogResource.js +3 -1
- package/dist/models/ProductChildResource.d.ts +6 -0
- package/dist/models/ProductChildResource.js +4 -0
- package/dist/models/StoreProductChildRequest.d.ts +2 -2
- package/dist/models/StoreProductChildRequest.js +2 -6
- package/dist/models/StoreProductChildRequestSitesInner.d.ts +2 -2
- package/dist/models/StoreProductChildRequestSitesInner.js +2 -6
- package/dist/models/UpdateProductChildRequest.d.ts +2 -2
- package/dist/models/UpdateProductChildRequest.js +2 -6
- package/dist/models/index.d.ts +0 -3
- package/dist/models/index.js +0 -3
- package/docs/AttachAssetsOverlayTemplateRequest.md +0 -2
- package/docs/ProductApi.md +6 -9
- package/docs/ProductChildResource.md +2 -0
- package/package.json +1 -1
- package/src/apis/ProductApi.ts +9 -16
- package/src/models/AttachAssetsOverlayTemplateRequest.ts +0 -8
- package/src/models/ExternalApiLogResource.ts +3 -2
- package/src/models/ProductChildResource.ts +9 -0
- package/src/models/StoreProductChildRequest.ts +4 -6
- package/src/models/StoreProductChildRequestSitesInner.ts +4 -6
- package/src/models/UpdateProductChildRequest.ts +4 -6
- package/src/models/index.ts +0 -3
- package/dist/models/AssetWithOverlayLinkResource.d.ts +0 -93
- package/dist/models/AssetWithOverlayLinkResource.js +0 -90
- package/dist/models/AssetWithOverlayLinkResourceArrayResponse.d.ts +0 -33
- package/dist/models/AssetWithOverlayLinkResourceArrayResponse.js +0 -50
- package/dist/models/ShowAssetsProductChildRequest.d.ts +0 -32
- package/dist/models/ShowAssetsProductChildRequest.js +0 -49
- package/docs/AssetWithOverlayLinkResource.md +0 -54
- package/docs/AssetWithOverlayLinkResourceArrayResponse.md +0 -34
- package/docs/ShowAssetsProductChildRequest.md +0 -34
- package/src/models/AssetWithOverlayLinkResource.ts +0 -163
- package/src/models/AssetWithOverlayLinkResourceArrayResponse.ts +0 -73
- package/src/models/ShowAssetsProductChildRequest.ts +0 -65
package/.openapi-generator/FILES
CHANGED
|
@@ -11,8 +11,6 @@ docs/AssetLiteResource.md
|
|
|
11
11
|
docs/AssetLiteResourceArrayResponse.md
|
|
12
12
|
docs/AssetResource.md
|
|
13
13
|
docs/AssetResourceArrayResponse.md
|
|
14
|
-
docs/AssetWithOverlayLinkResource.md
|
|
15
|
-
docs/AssetWithOverlayLinkResourceArrayResponse.md
|
|
16
14
|
docs/AttachAccessoriesProductChildRequest.md
|
|
17
15
|
docs/AttachAssetsOverlayTemplateRequest.md
|
|
18
16
|
docs/AttachAttributeProductTypeRequest.md
|
|
@@ -227,7 +225,6 @@ docs/ProductTypeResource.md
|
|
|
227
225
|
docs/ProductTypeResourceArrayResponse.md
|
|
228
226
|
docs/SEOResource.md
|
|
229
227
|
docs/SEOResourceArrayResponse.md
|
|
230
|
-
docs/ShowAssetsProductChildRequest.md
|
|
231
228
|
docs/SiteApi.md
|
|
232
229
|
docs/SiteConfigResource.md
|
|
233
230
|
docs/SiteConfigResourceArrayResponse.md
|
|
@@ -333,8 +330,6 @@ src/models/AssetLiteResource.ts
|
|
|
333
330
|
src/models/AssetLiteResourceArrayResponse.ts
|
|
334
331
|
src/models/AssetResource.ts
|
|
335
332
|
src/models/AssetResourceArrayResponse.ts
|
|
336
|
-
src/models/AssetWithOverlayLinkResource.ts
|
|
337
|
-
src/models/AssetWithOverlayLinkResourceArrayResponse.ts
|
|
338
333
|
src/models/AttachAccessoriesProductChildRequest.ts
|
|
339
334
|
src/models/AttachAssetsOverlayTemplateRequest.ts
|
|
340
335
|
src/models/AttachAttributeProductTypeRequest.ts
|
|
@@ -540,7 +535,6 @@ src/models/ProductTypeResource.ts
|
|
|
540
535
|
src/models/ProductTypeResourceArrayResponse.ts
|
|
541
536
|
src/models/SEOResource.ts
|
|
542
537
|
src/models/SEOResourceArrayResponse.ts
|
|
543
|
-
src/models/ShowAssetsProductChildRequest.ts
|
|
544
538
|
src/models/SiteConfigResource.ts
|
|
545
539
|
src/models/SiteConfigResourceArrayResponse.ts
|
|
546
540
|
src/models/SiteListResource.ts
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @digital8/lighting-illusions-ts-sdk@0.0.
|
|
1
|
+
# @digital8/lighting-illusions-ts-sdk@0.0.1095
|
|
2
2
|
|
|
3
3
|
A TypeScript SDK client for the localhost API.
|
|
4
4
|
|
|
@@ -113,7 +113,7 @@ All URIs are relative to *http://localhost/api*
|
|
|
113
113
|
*ProductApi* | [**getCompatibleProductsProductChild**](docs/ProductApi.md#getcompatibleproductsproductchild) | **POST** /admin-api/product/children/{productChild}/compatible-product/list | Auto-generated: getCompatibleProductsProductChild
|
|
114
114
|
*ProductApi* | [**indexProduct**](docs/ProductApi.md#indexproductoperation) | **POST** /admin-api/product/parent/list | Auto-generated: indexProduct
|
|
115
115
|
*ProductApi* | [**indexProductChild**](docs/ProductApi.md#indexproductchildoperation) | **POST** /admin-api/product/children/list | Auto-generated: indexProductChild
|
|
116
|
-
*ProductApi* | [**showAssetsProductChild**](docs/ProductApi.md#
|
|
116
|
+
*ProductApi* | [**showAssetsProductChild**](docs/ProductApi.md#showassetsproductchild) | **GET** /admin-api/product/children/{productChild}/assets | Auto-generated: showAssetsProductChild
|
|
117
117
|
*ProductApi* | [**showProduct**](docs/ProductApi.md#showproduct) | **GET** /admin-api/product/parent/{product} | Auto-generated: showProduct
|
|
118
118
|
*ProductApi* | [**showProductChild**](docs/ProductApi.md#showproductchild) | **GET** /admin-api/product/children/{productChild} | Auto-generated: showProductChild
|
|
119
119
|
*ProductApi* | [**storeProduct**](docs/ProductApi.md#storeproductoperation) | **POST** /admin-api/product/parent/create | Auto-generated: storeProduct
|
|
@@ -178,8 +178,6 @@ All URIs are relative to *http://localhost/api*
|
|
|
178
178
|
- [AssetLiteResourceArrayResponse](docs/AssetLiteResourceArrayResponse.md)
|
|
179
179
|
- [AssetResource](docs/AssetResource.md)
|
|
180
180
|
- [AssetResourceArrayResponse](docs/AssetResourceArrayResponse.md)
|
|
181
|
-
- [AssetWithOverlayLinkResource](docs/AssetWithOverlayLinkResource.md)
|
|
182
|
-
- [AssetWithOverlayLinkResourceArrayResponse](docs/AssetWithOverlayLinkResourceArrayResponse.md)
|
|
183
181
|
- [AttachAccessoriesProductChildRequest](docs/AttachAccessoriesProductChildRequest.md)
|
|
184
182
|
- [AttachAssetsOverlayTemplateRequest](docs/AttachAssetsOverlayTemplateRequest.md)
|
|
185
183
|
- [AttachAttributeProductTypeRequest](docs/AttachAttributeProductTypeRequest.md)
|
|
@@ -385,7 +383,6 @@ All URIs are relative to *http://localhost/api*
|
|
|
385
383
|
- [ProductTypeResourceArrayResponse](docs/ProductTypeResourceArrayResponse.md)
|
|
386
384
|
- [SEOResource](docs/SEOResource.md)
|
|
387
385
|
- [SEOResourceArrayResponse](docs/SEOResourceArrayResponse.md)
|
|
388
|
-
- [ShowAssetsProductChildRequest](docs/ShowAssetsProductChildRequest.md)
|
|
389
386
|
- [SiteConfigResource](docs/SiteConfigResource.md)
|
|
390
387
|
- [SiteConfigResourceArrayResponse](docs/SiteConfigResourceArrayResponse.md)
|
|
391
388
|
- [SiteListResource](docs/SiteListResource.md)
|
|
@@ -477,7 +474,7 @@ and is automatically generated by the
|
|
|
477
474
|
[OpenAPI Generator](https://openapi-generator.tech) project:
|
|
478
475
|
|
|
479
476
|
- API version: `1.0.0`
|
|
480
|
-
- Package version: `0.0.
|
|
477
|
+
- Package version: `0.0.1095`
|
|
481
478
|
- Generator version: `7.20.0`
|
|
482
479
|
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
|
|
483
480
|
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type {
|
|
13
|
+
import type { AssetResourceArrayResponse, AttachAccessoriesProductChildRequest, AttachDocumentsProductChildRequest, DetachDocumentsProductChildRequest, GenericResponse, GetAllProductChildRequest, GetAllProductRequest, IndexProductChildRequest, IndexProductRequest, PaginatedProductChildListResourceResponse, PaginatedProductListResourceResponse, ProductChildLiteResourceArrayResponse, ProductChildResource, ProductLiteResourceArrayResponse, ProductResource, StoreProductChildRequest, StoreProductRequest, UpdateProductChildRequest, UpdateProductRequest } from '../models/index';
|
|
14
14
|
export interface AttachAccessoriesProductChildOperationRequest {
|
|
15
15
|
productChild: number;
|
|
16
16
|
attachAccessoriesProductChildRequest?: AttachAccessoriesProductChildRequest;
|
|
@@ -61,9 +61,8 @@ export interface IndexProductOperationRequest {
|
|
|
61
61
|
export interface IndexProductChildOperationRequest {
|
|
62
62
|
indexProductChildRequest?: IndexProductChildRequest;
|
|
63
63
|
}
|
|
64
|
-
export interface
|
|
64
|
+
export interface ShowAssetsProductChildRequest {
|
|
65
65
|
productChild: number;
|
|
66
|
-
showAssetsProductChildRequest?: ShowAssetsProductChildRequest;
|
|
67
66
|
}
|
|
68
67
|
export interface ShowProductRequest {
|
|
69
68
|
product: number;
|
|
@@ -260,15 +259,15 @@ export declare class ProductApi extends runtime.BaseAPI {
|
|
|
260
259
|
/**
|
|
261
260
|
* Creates request options for showAssetsProductChild without sending the request
|
|
262
261
|
*/
|
|
263
|
-
showAssetsProductChildRequestOpts(requestParameters:
|
|
262
|
+
showAssetsProductChildRequestOpts(requestParameters: ShowAssetsProductChildRequest): Promise<runtime.RequestOpts>;
|
|
264
263
|
/**
|
|
265
264
|
* Auto-generated: showAssetsProductChild
|
|
266
265
|
*/
|
|
267
|
-
showAssetsProductChildRaw(requestParameters:
|
|
266
|
+
showAssetsProductChildRaw(requestParameters: ShowAssetsProductChildRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AssetResourceArrayResponse>>;
|
|
268
267
|
/**
|
|
269
268
|
* Auto-generated: showAssetsProductChild
|
|
270
269
|
*/
|
|
271
|
-
showAssetsProductChild(requestParameters:
|
|
270
|
+
showAssetsProductChild(requestParameters: ShowAssetsProductChildRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AssetResourceArrayResponse>;
|
|
272
271
|
/**
|
|
273
272
|
* Creates request options for showProduct without sending the request
|
|
274
273
|
*/
|
package/dist/apis/ProductApi.js
CHANGED
|
@@ -929,15 +929,13 @@ var ProductApi = /** @class */ (function (_super) {
|
|
|
929
929
|
}
|
|
930
930
|
queryParameters = {};
|
|
931
931
|
headerParameters = {};
|
|
932
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
933
932
|
urlPath = "/admin-api/product/children/{productChild}/assets";
|
|
934
933
|
urlPath = urlPath.replace("{".concat("productChild", "}"), encodeURIComponent(String(requestParameters['productChild'])));
|
|
935
934
|
return [2 /*return*/, {
|
|
936
935
|
path: urlPath,
|
|
937
|
-
method: '
|
|
936
|
+
method: 'GET',
|
|
938
937
|
headers: headerParameters,
|
|
939
938
|
query: queryParameters,
|
|
940
|
-
body: (0, index_1.ShowAssetsProductChildRequestToJSON)(requestParameters['showAssetsProductChildRequest']),
|
|
941
939
|
}];
|
|
942
940
|
});
|
|
943
941
|
});
|
|
@@ -956,7 +954,7 @@ var ProductApi = /** @class */ (function (_super) {
|
|
|
956
954
|
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
957
955
|
case 2:
|
|
958
956
|
response = _a.sent();
|
|
959
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
957
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.AssetResourceArrayResponseFromJSON)(jsonValue); })];
|
|
960
958
|
}
|
|
961
959
|
});
|
|
962
960
|
});
|
|
@@ -21,12 +21,6 @@ export interface AttachAssetsOverlayTemplateRequest {
|
|
|
21
21
|
* @memberof AttachAssetsOverlayTemplateRequest
|
|
22
22
|
*/
|
|
23
23
|
assetIds: Array<number>;
|
|
24
|
-
/**
|
|
25
|
-
*
|
|
26
|
-
* @type {boolean}
|
|
27
|
-
* @memberof AttachAssetsOverlayTemplateRequest
|
|
28
|
-
*/
|
|
29
|
-
syncAssets?: boolean;
|
|
30
24
|
}
|
|
31
25
|
/**
|
|
32
26
|
* Check if a given object implements the AttachAssetsOverlayTemplateRequest interface.
|
|
@@ -35,7 +35,6 @@ function AttachAssetsOverlayTemplateRequestFromJSONTyped(json, ignoreDiscriminat
|
|
|
35
35
|
}
|
|
36
36
|
return {
|
|
37
37
|
'assetIds': json['asset_ids'],
|
|
38
|
-
'syncAssets': json['sync_assets'] == null ? undefined : json['sync_assets'],
|
|
39
38
|
};
|
|
40
39
|
}
|
|
41
40
|
function AttachAssetsOverlayTemplateRequestToJSON(json) {
|
|
@@ -48,6 +47,5 @@ function AttachAssetsOverlayTemplateRequestToJSONTyped(value, ignoreDiscriminato
|
|
|
48
47
|
}
|
|
49
48
|
return {
|
|
50
49
|
'asset_ids': value['assetIds'],
|
|
51
|
-
'sync_assets': value['syncAssets'],
|
|
52
50
|
};
|
|
53
51
|
}
|
|
@@ -37,6 +37,8 @@ function instanceOfExternalApiLogResource(value) {
|
|
|
37
37
|
return false;
|
|
38
38
|
if (!('responseCode' in value) || value['responseCode'] === undefined)
|
|
39
39
|
return false;
|
|
40
|
+
if (!('requestPayload' in value) || value['requestPayload'] === undefined)
|
|
41
|
+
return false;
|
|
40
42
|
if (!('responsePayload' in value) || value['responsePayload'] === undefined)
|
|
41
43
|
return false;
|
|
42
44
|
if (!('site' in value) || value['site'] === undefined)
|
|
@@ -58,7 +60,7 @@ function ExternalApiLogResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
58
60
|
'exteranlApiLoggableId': json['exteranlApiLoggableId'],
|
|
59
61
|
'endpoint': json['endpoint'],
|
|
60
62
|
'responseCode': json['responseCode'],
|
|
61
|
-
'requestPayload': json['requestPayload']
|
|
63
|
+
'requestPayload': json['requestPayload'],
|
|
62
64
|
'responsePayload': json['responsePayload'],
|
|
63
65
|
'createdAt': json['createdAt'] == null ? undefined : json['createdAt'],
|
|
64
66
|
'site': (0, SiteLiteResource_1.SiteLiteResourceFromJSON)(json['site']),
|
|
@@ -198,6 +198,12 @@ export interface ProductChildResource {
|
|
|
198
198
|
* @memberof ProductChildResource
|
|
199
199
|
*/
|
|
200
200
|
productClassString: string;
|
|
201
|
+
/**
|
|
202
|
+
*
|
|
203
|
+
* @type {boolean}
|
|
204
|
+
* @memberof ProductChildResource
|
|
205
|
+
*/
|
|
206
|
+
isPrivilegedAdmin: boolean;
|
|
201
207
|
}
|
|
202
208
|
/**
|
|
203
209
|
* Check if a given object implements the ProductChildResource interface.
|
|
@@ -79,6 +79,8 @@ function instanceOfProductChildResource(value) {
|
|
|
79
79
|
return false;
|
|
80
80
|
if (!('productClassString' in value) || value['productClassString'] === undefined)
|
|
81
81
|
return false;
|
|
82
|
+
if (!('isPrivilegedAdmin' in value) || value['isPrivilegedAdmin'] === undefined)
|
|
83
|
+
return false;
|
|
82
84
|
return true;
|
|
83
85
|
}
|
|
84
86
|
function ProductChildResourceFromJSON(json) {
|
|
@@ -119,6 +121,7 @@ function ProductChildResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
119
121
|
'attributes': json['attributes'],
|
|
120
122
|
'productClasses': (json['productClasses'] == null ? null : json['productClasses'].map(ProductClassResource_1.ProductClassResourceFromJSON)),
|
|
121
123
|
'productClassString': json['productClassString'],
|
|
124
|
+
'isPrivilegedAdmin': json['isPrivilegedAdmin'],
|
|
122
125
|
};
|
|
123
126
|
}
|
|
124
127
|
function ProductChildResourceToJSON(json) {
|
|
@@ -160,5 +163,6 @@ function ProductChildResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
160
163
|
'attributes': value['attributes'],
|
|
161
164
|
'productClasses': (value['productClasses'] == null ? null : value['productClasses'].map(ProductClassResource_1.ProductClassResourceToJSON)),
|
|
162
165
|
'productClassString': value['productClassString'],
|
|
166
|
+
'isPrivilegedAdmin': value['isPrivilegedAdmin'],
|
|
163
167
|
};
|
|
164
168
|
}
|
|
@@ -35,13 +35,13 @@ export interface StoreProductChildRequest {
|
|
|
35
35
|
* @type {string}
|
|
36
36
|
* @memberof StoreProductChildRequest
|
|
37
37
|
*/
|
|
38
|
-
sku
|
|
38
|
+
sku?: string;
|
|
39
39
|
/**
|
|
40
40
|
*
|
|
41
41
|
* @type {string}
|
|
42
42
|
* @memberof StoreProductChildRequest
|
|
43
43
|
*/
|
|
44
|
-
model
|
|
44
|
+
model?: string;
|
|
45
45
|
/**
|
|
46
46
|
*
|
|
47
47
|
* @type {Date}
|
|
@@ -29,10 +29,6 @@ function instanceOfStoreProductChildRequest(value) {
|
|
|
29
29
|
return false;
|
|
30
30
|
if (!('name' in value) || value['name'] === undefined)
|
|
31
31
|
return false;
|
|
32
|
-
if (!('sku' in value) || value['sku'] === undefined)
|
|
33
|
-
return false;
|
|
34
|
-
if (!('model' in value) || value['model'] === undefined)
|
|
35
|
-
return false;
|
|
36
32
|
if (!('isWarrantyOverridden' in value) || value['isWarrantyOverridden'] === undefined)
|
|
37
33
|
return false;
|
|
38
34
|
if (!('hideFromFrontend' in value) || value['hideFromFrontend'] === undefined)
|
|
@@ -61,8 +57,8 @@ function StoreProductChildRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
61
57
|
return {
|
|
62
58
|
'productId': json['product_id'],
|
|
63
59
|
'name': json['name'],
|
|
64
|
-
'sku': json['sku'],
|
|
65
|
-
'model': json['model'],
|
|
60
|
+
'sku': json['sku'] == null ? undefined : json['sku'],
|
|
61
|
+
'model': json['model'] == null ? undefined : json['model'],
|
|
66
62
|
'newArrivalStartDate': json['new_arrival_start_date'] == null ? undefined : (new Date(json['new_arrival_start_date'])),
|
|
67
63
|
'newArrivalEndDate': json['new_arrival_end_date'] == null ? undefined : (new Date(json['new_arrival_end_date'])),
|
|
68
64
|
'warranty': json['warranty'] == null ? undefined : json['warranty'],
|
|
@@ -56,13 +56,13 @@ export interface StoreProductChildRequestSitesInner {
|
|
|
56
56
|
* @type {number}
|
|
57
57
|
* @memberof StoreProductChildRequestSitesInner
|
|
58
58
|
*/
|
|
59
|
-
rrpPrice
|
|
59
|
+
rrpPrice?: number;
|
|
60
60
|
/**
|
|
61
61
|
*
|
|
62
62
|
* @type {number}
|
|
63
63
|
* @memberof StoreProductChildRequestSitesInner
|
|
64
64
|
*/
|
|
65
|
-
salePrice
|
|
65
|
+
salePrice?: number;
|
|
66
66
|
/**
|
|
67
67
|
*
|
|
68
68
|
* @type {string}
|
|
@@ -32,10 +32,6 @@ function instanceOfStoreProductChildRequestSitesInner(value) {
|
|
|
32
32
|
return false;
|
|
33
33
|
if (!('description' in value) || value['description'] === undefined)
|
|
34
34
|
return false;
|
|
35
|
-
if (!('rrpPrice' in value) || value['rrpPrice'] === undefined)
|
|
36
|
-
return false;
|
|
37
|
-
if (!('salePrice' in value) || value['salePrice'] === undefined)
|
|
38
|
-
return false;
|
|
39
35
|
if (!('slug' in value) || value['slug'] === undefined)
|
|
40
36
|
return false;
|
|
41
37
|
if (!('isSlugOverridden' in value) || value['isSlugOverridden'] === undefined)
|
|
@@ -58,8 +54,8 @@ function StoreProductChildRequestSitesInnerFromJSONTyped(json, ignoreDiscriminat
|
|
|
58
54
|
'displayName': json['display_name'] == null ? undefined : json['display_name'],
|
|
59
55
|
'isDisplayNameOverridden': json['is_display_name_overridden'],
|
|
60
56
|
'description': json['description'],
|
|
61
|
-
'rrpPrice': json['rrp_price'],
|
|
62
|
-
'salePrice': json['sale_price'],
|
|
57
|
+
'rrpPrice': json['rrp_price'] == null ? undefined : json['rrp_price'],
|
|
58
|
+
'salePrice': json['sale_price'] == null ? undefined : json['sale_price'],
|
|
63
59
|
'slug': json['slug'],
|
|
64
60
|
'isSlugOverridden': json['is_slug_overridden'],
|
|
65
61
|
'documents': json['documents'],
|
|
@@ -28,13 +28,13 @@ export interface UpdateProductChildRequest {
|
|
|
28
28
|
* @type {string}
|
|
29
29
|
* @memberof UpdateProductChildRequest
|
|
30
30
|
*/
|
|
31
|
-
sku
|
|
31
|
+
sku?: string;
|
|
32
32
|
/**
|
|
33
33
|
*
|
|
34
34
|
* @type {string}
|
|
35
35
|
* @memberof UpdateProductChildRequest
|
|
36
36
|
*/
|
|
37
|
-
model
|
|
37
|
+
model?: string;
|
|
38
38
|
/**
|
|
39
39
|
*
|
|
40
40
|
* @type {Date}
|
|
@@ -26,10 +26,6 @@ var StoreProductChildRequestSitesInner_1 = require("./StoreProductChildRequestSi
|
|
|
26
26
|
function instanceOfUpdateProductChildRequest(value) {
|
|
27
27
|
if (!('name' in value) || value['name'] === undefined)
|
|
28
28
|
return false;
|
|
29
|
-
if (!('sku' in value) || value['sku'] === undefined)
|
|
30
|
-
return false;
|
|
31
|
-
if (!('model' in value) || value['model'] === undefined)
|
|
32
|
-
return false;
|
|
33
29
|
if (!('isWarrantyOverridden' in value) || value['isWarrantyOverridden'] === undefined)
|
|
34
30
|
return false;
|
|
35
31
|
if (!('hideFromFrontend' in value) || value['hideFromFrontend'] === undefined)
|
|
@@ -57,8 +53,8 @@ function UpdateProductChildRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
57
53
|
}
|
|
58
54
|
return {
|
|
59
55
|
'name': json['name'],
|
|
60
|
-
'sku': json['sku'],
|
|
61
|
-
'model': json['model'],
|
|
56
|
+
'sku': json['sku'] == null ? undefined : json['sku'],
|
|
57
|
+
'model': json['model'] == null ? undefined : json['model'],
|
|
62
58
|
'newArrivalStartDate': json['new_arrival_start_date'] == null ? undefined : (new Date(json['new_arrival_start_date'])),
|
|
63
59
|
'newArrivalEndDate': json['new_arrival_end_date'] == null ? undefined : (new Date(json['new_arrival_end_date'])),
|
|
64
60
|
'warranty': json['warranty'] == null ? undefined : json['warranty'],
|
package/dist/models/index.d.ts
CHANGED
|
@@ -6,8 +6,6 @@ export * from './AssetLiteResource';
|
|
|
6
6
|
export * from './AssetLiteResourceArrayResponse';
|
|
7
7
|
export * from './AssetResource';
|
|
8
8
|
export * from './AssetResourceArrayResponse';
|
|
9
|
-
export * from './AssetWithOverlayLinkResource';
|
|
10
|
-
export * from './AssetWithOverlayLinkResourceArrayResponse';
|
|
11
9
|
export * from './AttachAccessoriesProductChildRequest';
|
|
12
10
|
export * from './AttachAssetsOverlayTemplateRequest';
|
|
13
11
|
export * from './AttachAttributeProductTypeRequest';
|
|
@@ -213,7 +211,6 @@ export * from './ProductTypeResource';
|
|
|
213
211
|
export * from './ProductTypeResourceArrayResponse';
|
|
214
212
|
export * from './SEOResource';
|
|
215
213
|
export * from './SEOResourceArrayResponse';
|
|
216
|
-
export * from './ShowAssetsProductChildRequest';
|
|
217
214
|
export * from './SiteConfigResource';
|
|
218
215
|
export * from './SiteConfigResourceArrayResponse';
|
|
219
216
|
export * from './SiteListResource';
|
package/dist/models/index.js
CHANGED
|
@@ -24,8 +24,6 @@ __exportStar(require("./AssetLiteResource"), exports);
|
|
|
24
24
|
__exportStar(require("./AssetLiteResourceArrayResponse"), exports);
|
|
25
25
|
__exportStar(require("./AssetResource"), exports);
|
|
26
26
|
__exportStar(require("./AssetResourceArrayResponse"), exports);
|
|
27
|
-
__exportStar(require("./AssetWithOverlayLinkResource"), exports);
|
|
28
|
-
__exportStar(require("./AssetWithOverlayLinkResourceArrayResponse"), exports);
|
|
29
27
|
__exportStar(require("./AttachAccessoriesProductChildRequest"), exports);
|
|
30
28
|
__exportStar(require("./AttachAssetsOverlayTemplateRequest"), exports);
|
|
31
29
|
__exportStar(require("./AttachAttributeProductTypeRequest"), exports);
|
|
@@ -231,7 +229,6 @@ __exportStar(require("./ProductTypeResource"), exports);
|
|
|
231
229
|
__exportStar(require("./ProductTypeResourceArrayResponse"), exports);
|
|
232
230
|
__exportStar(require("./SEOResource"), exports);
|
|
233
231
|
__exportStar(require("./SEOResourceArrayResponse"), exports);
|
|
234
|
-
__exportStar(require("./ShowAssetsProductChildRequest"), exports);
|
|
235
232
|
__exportStar(require("./SiteConfigResource"), exports);
|
|
236
233
|
__exportStar(require("./SiteConfigResourceArrayResponse"), exports);
|
|
237
234
|
__exportStar(require("./SiteListResource"), exports);
|
|
@@ -7,7 +7,6 @@
|
|
|
7
7
|
Name | Type
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`assetIds` | Array<number>
|
|
10
|
-
`syncAssets` | boolean
|
|
11
10
|
|
|
12
11
|
## Example
|
|
13
12
|
|
|
@@ -17,7 +16,6 @@ import type { AttachAssetsOverlayTemplateRequest } from '@digital8/lighting-illu
|
|
|
17
16
|
// TODO: Update the object below with actual values
|
|
18
17
|
const example = {
|
|
19
18
|
"assetIds": null,
|
|
20
|
-
"syncAssets": null,
|
|
21
19
|
} satisfies AttachAssetsOverlayTemplateRequest
|
|
22
20
|
|
|
23
21
|
console.log(example)
|
package/docs/ProductApi.md
CHANGED
|
@@ -18,7 +18,7 @@ All URIs are relative to *http://localhost/api*
|
|
|
18
18
|
| [**getCompatibleProductsProductChild**](ProductApi.md#getcompatibleproductsproductchild) | **POST** /admin-api/product/children/{productChild}/compatible-product/list | Auto-generated: getCompatibleProductsProductChild |
|
|
19
19
|
| [**indexProduct**](ProductApi.md#indexproductoperation) | **POST** /admin-api/product/parent/list | Auto-generated: indexProduct |
|
|
20
20
|
| [**indexProductChild**](ProductApi.md#indexproductchildoperation) | **POST** /admin-api/product/children/list | Auto-generated: indexProductChild |
|
|
21
|
-
| [**showAssetsProductChild**](ProductApi.md#
|
|
21
|
+
| [**showAssetsProductChild**](ProductApi.md#showassetsproductchild) | **GET** /admin-api/product/children/{productChild}/assets | Auto-generated: showAssetsProductChild |
|
|
22
22
|
| [**showProduct**](ProductApi.md#showproduct) | **GET** /admin-api/product/parent/{product} | Auto-generated: showProduct |
|
|
23
23
|
| [**showProductChild**](ProductApi.md#showproductchild) | **GET** /admin-api/product/children/{productChild} | Auto-generated: showProductChild |
|
|
24
24
|
| [**storeProduct**](ProductApi.md#storeproductoperation) | **POST** /admin-api/product/parent/create | Auto-generated: storeProduct |
|
|
@@ -964,7 +964,7 @@ No authorization required
|
|
|
964
964
|
|
|
965
965
|
## showAssetsProductChild
|
|
966
966
|
|
|
967
|
-
>
|
|
967
|
+
> AssetResourceArrayResponse showAssetsProductChild(productChild)
|
|
968
968
|
|
|
969
969
|
Auto-generated: showAssetsProductChild
|
|
970
970
|
|
|
@@ -975,7 +975,7 @@ import {
|
|
|
975
975
|
Configuration,
|
|
976
976
|
ProductApi,
|
|
977
977
|
} from '@digital8/lighting-illusions-ts-sdk';
|
|
978
|
-
import type {
|
|
978
|
+
import type { ShowAssetsProductChildRequest } from '@digital8/lighting-illusions-ts-sdk';
|
|
979
979
|
|
|
980
980
|
async function example() {
|
|
981
981
|
console.log("🚀 Testing @digital8/lighting-illusions-ts-sdk SDK...");
|
|
@@ -984,9 +984,7 @@ async function example() {
|
|
|
984
984
|
const body = {
|
|
985
985
|
// number | The id of the productChild
|
|
986
986
|
productChild: 56,
|
|
987
|
-
|
|
988
|
-
showAssetsProductChildRequest: ...,
|
|
989
|
-
} satisfies ShowAssetsProductChildOperationRequest;
|
|
987
|
+
} satisfies ShowAssetsProductChildRequest;
|
|
990
988
|
|
|
991
989
|
try {
|
|
992
990
|
const data = await api.showAssetsProductChild(body);
|
|
@@ -1006,11 +1004,10 @@ example().catch(console.error);
|
|
|
1006
1004
|
| Name | Type | Description | Notes |
|
|
1007
1005
|
|------------- | ------------- | ------------- | -------------|
|
|
1008
1006
|
| **productChild** | `number` | The id of the productChild | [Defaults to `undefined`] |
|
|
1009
|
-
| **showAssetsProductChildRequest** | [ShowAssetsProductChildRequest](ShowAssetsProductChildRequest.md) | | [Optional] |
|
|
1010
1007
|
|
|
1011
1008
|
### Return type
|
|
1012
1009
|
|
|
1013
|
-
[**
|
|
1010
|
+
[**AssetResourceArrayResponse**](AssetResourceArrayResponse.md)
|
|
1014
1011
|
|
|
1015
1012
|
### Authorization
|
|
1016
1013
|
|
|
@@ -1018,7 +1015,7 @@ No authorization required
|
|
|
1018
1015
|
|
|
1019
1016
|
### HTTP request headers
|
|
1020
1017
|
|
|
1021
|
-
- **Content-Type**:
|
|
1018
|
+
- **Content-Type**: Not defined
|
|
1022
1019
|
- **Accept**: `application/json`
|
|
1023
1020
|
|
|
1024
1021
|
|
|
@@ -36,6 +36,7 @@ Name | Type
|
|
|
36
36
|
`attributes` | object
|
|
37
37
|
`productClasses` | [Array<ProductClassResource>](ProductClassResource.md)
|
|
38
38
|
`productClassString` | string
|
|
39
|
+
`isPrivilegedAdmin` | boolean
|
|
39
40
|
|
|
40
41
|
## Example
|
|
41
42
|
|
|
@@ -74,6 +75,7 @@ const example = {
|
|
|
74
75
|
"attributes": null,
|
|
75
76
|
"productClasses": null,
|
|
76
77
|
"productClassString": null,
|
|
78
|
+
"isPrivilegedAdmin": null,
|
|
77
79
|
} satisfies ProductChildResource
|
|
78
80
|
|
|
79
81
|
console.log(example)
|
package/package.json
CHANGED
package/src/apis/ProductApi.ts
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
|
|
16
16
|
import * as runtime from '../runtime';
|
|
17
17
|
import type {
|
|
18
|
-
|
|
18
|
+
AssetResourceArrayResponse,
|
|
19
19
|
AttachAccessoriesProductChildRequest,
|
|
20
20
|
AttachDocumentsProductChildRequest,
|
|
21
21
|
DetachDocumentsProductChildRequest,
|
|
@@ -30,15 +30,14 @@ import type {
|
|
|
30
30
|
ProductChildResource,
|
|
31
31
|
ProductLiteResourceArrayResponse,
|
|
32
32
|
ProductResource,
|
|
33
|
-
ShowAssetsProductChildRequest,
|
|
34
33
|
StoreProductChildRequest,
|
|
35
34
|
StoreProductRequest,
|
|
36
35
|
UpdateProductChildRequest,
|
|
37
36
|
UpdateProductRequest,
|
|
38
37
|
} from '../models/index';
|
|
39
38
|
import {
|
|
40
|
-
|
|
41
|
-
|
|
39
|
+
AssetResourceArrayResponseFromJSON,
|
|
40
|
+
AssetResourceArrayResponseToJSON,
|
|
42
41
|
AttachAccessoriesProductChildRequestFromJSON,
|
|
43
42
|
AttachAccessoriesProductChildRequestToJSON,
|
|
44
43
|
AttachDocumentsProductChildRequestFromJSON,
|
|
@@ -67,8 +66,6 @@ import {
|
|
|
67
66
|
ProductLiteResourceArrayResponseToJSON,
|
|
68
67
|
ProductResourceFromJSON,
|
|
69
68
|
ProductResourceToJSON,
|
|
70
|
-
ShowAssetsProductChildRequestFromJSON,
|
|
71
|
-
ShowAssetsProductChildRequestToJSON,
|
|
72
69
|
StoreProductChildRequestFromJSON,
|
|
73
70
|
StoreProductChildRequestToJSON,
|
|
74
71
|
StoreProductRequestFromJSON,
|
|
@@ -143,9 +140,8 @@ export interface IndexProductChildOperationRequest {
|
|
|
143
140
|
indexProductChildRequest?: IndexProductChildRequest;
|
|
144
141
|
}
|
|
145
142
|
|
|
146
|
-
export interface
|
|
143
|
+
export interface ShowAssetsProductChildRequest {
|
|
147
144
|
productChild: number;
|
|
148
|
-
showAssetsProductChildRequest?: ShowAssetsProductChildRequest;
|
|
149
145
|
}
|
|
150
146
|
|
|
151
147
|
export interface ShowProductRequest {
|
|
@@ -826,7 +822,7 @@ export class ProductApi extends runtime.BaseAPI {
|
|
|
826
822
|
/**
|
|
827
823
|
* Creates request options for showAssetsProductChild without sending the request
|
|
828
824
|
*/
|
|
829
|
-
async showAssetsProductChildRequestOpts(requestParameters:
|
|
825
|
+
async showAssetsProductChildRequestOpts(requestParameters: ShowAssetsProductChildRequest): Promise<runtime.RequestOpts> {
|
|
830
826
|
if (requestParameters['productChild'] == null) {
|
|
831
827
|
throw new runtime.RequiredError(
|
|
832
828
|
'productChild',
|
|
@@ -838,35 +834,32 @@ export class ProductApi extends runtime.BaseAPI {
|
|
|
838
834
|
|
|
839
835
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
840
836
|
|
|
841
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
842
|
-
|
|
843
837
|
|
|
844
838
|
let urlPath = `/admin-api/product/children/{productChild}/assets`;
|
|
845
839
|
urlPath = urlPath.replace(`{${"productChild"}}`, encodeURIComponent(String(requestParameters['productChild'])));
|
|
846
840
|
|
|
847
841
|
return {
|
|
848
842
|
path: urlPath,
|
|
849
|
-
method: '
|
|
843
|
+
method: 'GET',
|
|
850
844
|
headers: headerParameters,
|
|
851
845
|
query: queryParameters,
|
|
852
|
-
body: ShowAssetsProductChildRequestToJSON(requestParameters['showAssetsProductChildRequest']),
|
|
853
846
|
};
|
|
854
847
|
}
|
|
855
848
|
|
|
856
849
|
/**
|
|
857
850
|
* Auto-generated: showAssetsProductChild
|
|
858
851
|
*/
|
|
859
|
-
async showAssetsProductChildRaw(requestParameters:
|
|
852
|
+
async showAssetsProductChildRaw(requestParameters: ShowAssetsProductChildRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AssetResourceArrayResponse>> {
|
|
860
853
|
const requestOptions = await this.showAssetsProductChildRequestOpts(requestParameters);
|
|
861
854
|
const response = await this.request(requestOptions, initOverrides);
|
|
862
855
|
|
|
863
|
-
return new runtime.JSONApiResponse(response, (jsonValue) =>
|
|
856
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => AssetResourceArrayResponseFromJSON(jsonValue));
|
|
864
857
|
}
|
|
865
858
|
|
|
866
859
|
/**
|
|
867
860
|
* Auto-generated: showAssetsProductChild
|
|
868
861
|
*/
|
|
869
|
-
async showAssetsProductChild(requestParameters:
|
|
862
|
+
async showAssetsProductChild(requestParameters: ShowAssetsProductChildRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AssetResourceArrayResponse> {
|
|
870
863
|
const response = await this.showAssetsProductChildRaw(requestParameters, initOverrides);
|
|
871
864
|
return await response.value();
|
|
872
865
|
}
|
|
@@ -25,12 +25,6 @@ export interface AttachAssetsOverlayTemplateRequest {
|
|
|
25
25
|
* @memberof AttachAssetsOverlayTemplateRequest
|
|
26
26
|
*/
|
|
27
27
|
assetIds: Array<number>;
|
|
28
|
-
/**
|
|
29
|
-
*
|
|
30
|
-
* @type {boolean}
|
|
31
|
-
* @memberof AttachAssetsOverlayTemplateRequest
|
|
32
|
-
*/
|
|
33
|
-
syncAssets?: boolean;
|
|
34
28
|
}
|
|
35
29
|
|
|
36
30
|
/**
|
|
@@ -52,7 +46,6 @@ export function AttachAssetsOverlayTemplateRequestFromJSONTyped(json: any, ignor
|
|
|
52
46
|
return {
|
|
53
47
|
|
|
54
48
|
'assetIds': json['asset_ids'],
|
|
55
|
-
'syncAssets': json['sync_assets'] == null ? undefined : json['sync_assets'],
|
|
56
49
|
};
|
|
57
50
|
}
|
|
58
51
|
|
|
@@ -68,7 +61,6 @@ export function AttachAssetsOverlayTemplateRequestToJSONTyped(value?: AttachAsse
|
|
|
68
61
|
return {
|
|
69
62
|
|
|
70
63
|
'asset_ids': value['assetIds'],
|
|
71
|
-
'sync_assets': value['syncAssets'],
|
|
72
64
|
};
|
|
73
65
|
}
|
|
74
66
|
|
|
@@ -74,7 +74,7 @@ export interface ExternalApiLogResource {
|
|
|
74
74
|
* @type {string}
|
|
75
75
|
* @memberof ExternalApiLogResource
|
|
76
76
|
*/
|
|
77
|
-
requestPayload
|
|
77
|
+
requestPayload: string;
|
|
78
78
|
/**
|
|
79
79
|
*
|
|
80
80
|
* @type {string}
|
|
@@ -106,6 +106,7 @@ 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;
|
|
109
110
|
if (!('responsePayload' in value) || value['responsePayload'] === undefined) return false;
|
|
110
111
|
if (!('site' in value) || value['site'] === undefined) return false;
|
|
111
112
|
return true;
|
|
@@ -128,7 +129,7 @@ export function ExternalApiLogResourceFromJSONTyped(json: any, ignoreDiscriminat
|
|
|
128
129
|
'exteranlApiLoggableId': json['exteranlApiLoggableId'],
|
|
129
130
|
'endpoint': json['endpoint'],
|
|
130
131
|
'responseCode': json['responseCode'],
|
|
131
|
-
'requestPayload': json['requestPayload']
|
|
132
|
+
'requestPayload': json['requestPayload'],
|
|
132
133
|
'responsePayload': json['responsePayload'],
|
|
133
134
|
'createdAt': json['createdAt'] == null ? undefined : json['createdAt'],
|
|
134
135
|
'site': SiteLiteResourceFromJSON(json['site']),
|