@teemill/product-catalog 1.14.0 → 1.16.0

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/api.ts CHANGED
@@ -4,7 +4,7 @@
4
4
  * Product Catalog API
5
5
  * Manage Product Catalog A catalog product is an object that represents a product listing that can be purchased from the given project. It contains a combination of design applications and a warehouse product, plus listing information such as title, description and tags.
6
6
  *
7
- * The version of the OpenAPI document: 1.14.0
7
+ * The version of the OpenAPI document: 1.16.0
8
8
  * Contact: hello@teemill.com
9
9
  *
10
10
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -23,6 +23,19 @@ import type { RequestArgs } from './base';
23
23
  // @ts-ignore
24
24
  import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError, operationServerMap } from './base';
25
25
 
26
+ /**
27
+ *
28
+ * @export
29
+ * @interface AdditionalFile
30
+ */
31
+ export interface AdditionalFile {
32
+ /**
33
+ * Publicly available file URL.
34
+ * @type {string}
35
+ * @memberof AdditionalFile
36
+ */
37
+ 'src'?: string;
38
+ }
26
39
  /**
27
40
  *
28
41
  * @export
@@ -53,7 +66,7 @@ export interface Application {
53
66
  * @type {string}
54
67
  * @memberof Application
55
68
  */
56
- 'technology': string;
69
+ 'technology': ApplicationTechnologyEnum;
57
70
  /**
58
71
  * Placement of the application. Available placements depend on the chosen product and technology.
59
72
  * @type {string}
@@ -66,8 +79,27 @@ export interface Application {
66
79
  * @memberof Application
67
80
  */
68
81
  'src': string;
82
+ /**
83
+ *
84
+ * @type {ApplicationMockup}
85
+ * @memberof Application
86
+ */
87
+ 'mockup'?: ApplicationMockup;
69
88
  }
70
89
 
90
+ export const ApplicationTechnologyEnum = {
91
+ Dtg: 'dtg',
92
+ Embroidery: 'embroidery',
93
+ Dtf: 'dtf',
94
+ Pretreat: 'pretreat',
95
+ MugSublimation: 'mug_sublimation',
96
+ ManualPrint: 'manual_print',
97
+ AdditionalApplication: 'additional_application',
98
+ NotebookSublimation: 'notebook_sublimation',
99
+ DuplexPrint: 'duplex_print'
100
+ } as const;
101
+
102
+ export type ApplicationTechnologyEnum = typeof ApplicationTechnologyEnum[keyof typeof ApplicationTechnologyEnum];
71
103
  export const ApplicationPlacementEnum = {
72
104
  Front: 'front',
73
105
  Back: 'back',
@@ -78,6 +110,25 @@ export const ApplicationPlacementEnum = {
78
110
 
79
111
  export type ApplicationPlacementEnum = typeof ApplicationPlacementEnum[keyof typeof ApplicationPlacementEnum];
80
112
 
113
+ /**
114
+ *
115
+ * @export
116
+ * @interface ApplicationMockup
117
+ */
118
+ export interface ApplicationMockup {
119
+ /**
120
+ * Drive image URL. If provided, this will be used as the mockup image for the variant application rather than generating a new one.
121
+ * @type {string}
122
+ * @memberof ApplicationMockup
123
+ */
124
+ 'file': string;
125
+ /**
126
+ * Publicly available mockup image URL. This is a preview of the mockup image for the given application.
127
+ * @type {string}
128
+ * @memberof ApplicationMockup
129
+ */
130
+ 'preview'?: string;
131
+ }
81
132
  /**
82
133
  *
83
134
  * @export
@@ -185,6 +236,12 @@ export interface CreateProductRequest {
185
236
  * @memberof CreateProductRequest
186
237
  */
187
238
  'tags'?: Array<string>;
239
+ /**
240
+ * Internal tags used for internal searching and filtering.
241
+ * @type {Array<string>}
242
+ * @memberof CreateProductRequest
243
+ */
244
+ 'internalTags'?: Array<string>;
188
245
  /**
189
246
  * Variants
190
247
  * @type {Array<CreateProductVariant>}
@@ -199,10 +256,23 @@ export interface CreateProductRequest {
199
256
  'images'?: Array<CreateProductRequestImagesInner>;
200
257
  /**
201
258
  * Additional files to attach to the product. For example, original design files e.g. PSD, AI, etc.
202
- * @type {Array<CreateProductRequestImagesInner>}
259
+ * @type {Array<CreateProductRequestAdditionalFilesInner>}
203
260
  * @memberof CreateProductRequest
204
261
  */
205
- 'additionalFiles'?: Array<CreateProductRequestImagesInner>;
262
+ 'additionalFiles'?: Array<CreateProductRequestAdditionalFilesInner>;
263
+ }
264
+ /**
265
+ *
266
+ * @export
267
+ * @interface CreateProductRequestAdditionalFilesInner
268
+ */
269
+ export interface CreateProductRequestAdditionalFilesInner {
270
+ /**
271
+ * Publicly available file URL.
272
+ * @type {string}
273
+ * @memberof CreateProductRequestAdditionalFilesInner
274
+ */
275
+ 'src'?: string;
206
276
  }
207
277
  /**
208
278
  *
@@ -262,10 +332,10 @@ export interface CreateProductVariant {
262
332
  'applications'?: Array<Application>;
263
333
  /**
264
334
  * Only use if you want to override the main product image. If not provided, mockups will be generated using the design applications and the warehouse product provided. Accepts PNG and JPEG files.
265
- * @type {Array<CreateProductRequestImagesInner>}
335
+ * @type {Array<CreateProductVariantImagesInner>}
266
336
  * @memberof CreateProductVariant
267
337
  */
268
- 'images'?: Array<CreateProductRequestImagesInner>;
338
+ 'images'?: Array<CreateProductVariantImagesInner>;
269
339
  }
270
340
  /**
271
341
  *
@@ -278,7 +348,7 @@ export interface CreateProductVariantAttributesInner {
278
348
  * @type {string}
279
349
  * @memberof CreateProductVariantAttributesInner
280
350
  */
281
- 'name': string;
351
+ 'name': CreateProductVariantAttributesInnerNameEnum;
282
352
  /**
283
353
  * Attribute value
284
354
  * @type {string}
@@ -286,6 +356,27 @@ export interface CreateProductVariantAttributesInner {
286
356
  */
287
357
  'value': string;
288
358
  }
359
+
360
+ export const CreateProductVariantAttributesInnerNameEnum = {
361
+ Size: 'Size',
362
+ Colour: 'Colour'
363
+ } as const;
364
+
365
+ export type CreateProductVariantAttributesInnerNameEnum = typeof CreateProductVariantAttributesInnerNameEnum[keyof typeof CreateProductVariantAttributesInnerNameEnum];
366
+
367
+ /**
368
+ *
369
+ * @export
370
+ * @interface CreateProductVariantImagesInner
371
+ */
372
+ export interface CreateProductVariantImagesInner {
373
+ /**
374
+ * Publicly available file URL.
375
+ * @type {string}
376
+ * @memberof CreateProductVariantImagesInner
377
+ */
378
+ 'src'?: string;
379
+ }
289
380
  /**
290
381
  * Variant retail price including tax.
291
382
  * @export
@@ -303,8 +394,15 @@ export interface CreateProductVariantRetailPrice {
303
394
  * @type {string}
304
395
  * @memberof CreateProductVariantRetailPrice
305
396
  */
306
- 'currencyCode': string;
397
+ 'currencyCode': CreateProductVariantRetailPriceCurrencyCodeEnum;
307
398
  }
399
+
400
+ export const CreateProductVariantRetailPriceCurrencyCodeEnum = {
401
+ Gbp: 'GBP'
402
+ } as const;
403
+
404
+ export type CreateProductVariantRetailPriceCurrencyCodeEnum = typeof CreateProductVariantRetailPriceCurrencyCodeEnum[keyof typeof CreateProductVariantRetailPriceCurrencyCodeEnum];
405
+
308
406
  /**
309
407
  * Image description
310
408
  * @export
@@ -357,28 +455,28 @@ export interface Image {
357
455
  /**
358
456
  *
359
457
  * @export
360
- * @interface ImportProducts200Response
458
+ * @interface ImageFile
361
459
  */
362
- export interface ImportProducts200Response {
460
+ export interface ImageFile {
363
461
  /**
364
- * Id of the product import
462
+ * Publicly available file URL.
365
463
  * @type {string}
366
- * @memberof ImportProducts200Response
464
+ * @memberof ImageFile
367
465
  */
368
- 'importId'?: string;
466
+ 'src'?: string;
369
467
  }
370
468
  /**
371
469
  *
372
470
  * @export
373
- * @interface ModelFile
471
+ * @interface ImportProducts200Response
374
472
  */
375
- export interface ModelFile {
473
+ export interface ImportProducts200Response {
376
474
  /**
377
- * Publicly available file URL.
475
+ * Id of the product import
378
476
  * @type {string}
379
- * @memberof ModelFile
477
+ * @memberof ImportProducts200Response
380
478
  */
381
- 'src'?: string;
479
+ 'importId'?: string;
382
480
  }
383
481
  /**
384
482
  * Standard price definition that defines the amount, tax rate and currency.
@@ -397,8 +495,15 @@ export interface Price {
397
495
  * @type {string}
398
496
  * @memberof Price
399
497
  */
400
- 'currencyCode'?: string;
498
+ 'currencyCode'?: PriceCurrencyCodeEnum;
401
499
  }
500
+
501
+ export const PriceCurrencyCodeEnum = {
502
+ Gbp: 'GBP'
503
+ } as const;
504
+
505
+ export type PriceCurrencyCodeEnum = typeof PriceCurrencyCodeEnum[keyof typeof PriceCurrencyCodeEnum];
506
+
402
507
  /**
403
508
  *
404
509
  * @export
@@ -453,6 +558,12 @@ export interface Product {
453
558
  * @memberof Product
454
559
  */
455
560
  'tags'?: Array<string>;
561
+ /**
562
+ *
563
+ * @type {Array<string>}
564
+ * @memberof Product
565
+ */
566
+ 'internalTags'?: Array<string>;
456
567
  /**
457
568
  *
458
569
  * @type {string}
@@ -602,6 +713,12 @@ export interface UpdateProductRequest {
602
713
  * @memberof UpdateProductRequest
603
714
  */
604
715
  'tags'?: Array<string>;
716
+ /**
717
+ * Additional product tags used for internal searching and filtering.
718
+ * @type {Array<string>}
719
+ * @memberof UpdateProductRequest
720
+ */
721
+ 'internalTags'?: Array<string>;
605
722
  /**
606
723
  * Variants
607
724
  * @type {Array<CreateProductVariant>}
@@ -610,16 +727,16 @@ export interface UpdateProductRequest {
610
727
  'variants'?: Array<CreateProductVariant>;
611
728
  /**
612
729
  * Images to attach to the product. For example, photos of models using/wearing the product.
613
- * @type {Array<any>}
730
+ * @type {Array<ImageFile>}
614
731
  * @memberof UpdateProductRequest
615
732
  */
616
- 'images'?: Array<any>;
733
+ 'images'?: Array<ImageFile>;
617
734
  /**
618
735
  * Additional files to attach to the product. For example, original design files e.g. PSD, AI, etc.
619
- * @type {Array<any>}
736
+ * @type {Array<AdditionalFile>}
620
737
  * @memberof UpdateProductRequest
621
738
  */
622
- 'additionalFiles'?: Array<any>;
739
+ 'additionalFiles'?: Array<AdditionalFile>;
623
740
  }
624
741
  /**
625
742
  *
@@ -1194,77 +1311,227 @@ export const ProductsApiFactory = function (configuration?: Configuration, baseP
1194
1311
  /**
1195
1312
  * Creates a new catalog product based on a given warehouse product with the variants and design applications provided. To select a warehouse product to base this product on, use the GFN Catalog API to list available options.
1196
1313
  * @summary Create product
1197
- * @param {string} project What project it is
1198
- * @param {CreateProductRequest} [createProductRequest]
1314
+ * @param {ProductsApiCreateProductRequest} requestParameters Request parameters.
1199
1315
  * @param {*} [options] Override http request option.
1200
1316
  * @throws {RequiredError}
1201
1317
  */
1202
- createProduct(project: string, createProductRequest?: CreateProductRequest, options?: any): AxiosPromise<Product> {
1203
- return localVarFp.createProduct(project, createProductRequest, options).then((request) => request(axios, basePath));
1318
+ createProduct(requestParameters: ProductsApiCreateProductRequest, options?: RawAxiosRequestConfig): AxiosPromise<Product> {
1319
+ return localVarFp.createProduct(requestParameters.project, requestParameters.createProductRequest, options).then((request) => request(axios, basePath));
1204
1320
  },
1205
1321
  /**
1206
1322
  * Deletes a catalog product
1207
1323
  * @summary Delete catalog product
1208
- * @param {string} project What project it is
1209
- * @param {string} productId Product\&#39;s unique identifier
1324
+ * @param {ProductsApiDeleteProductRequest} requestParameters Request parameters.
1210
1325
  * @param {*} [options] Override http request option.
1211
1326
  * @throws {RequiredError}
1212
1327
  */
1213
- deleteProduct(project: string, productId: string, options?: any): AxiosPromise<void> {
1214
- return localVarFp.deleteProduct(project, productId, options).then((request) => request(axios, basePath));
1328
+ deleteProduct(requestParameters: ProductsApiDeleteProductRequest, options?: RawAxiosRequestConfig): AxiosPromise<void> {
1329
+ return localVarFp.deleteProduct(requestParameters.project, requestParameters.productId, options).then((request) => request(axios, basePath));
1215
1330
  },
1216
1331
  /**
1217
1332
  * Gets a product by a given ID.
1218
1333
  * @summary Get product
1219
- * @param {string} project What project it is
1220
- * @param {string} productId Product\&#39;s unique identifier
1221
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1334
+ * @param {ProductsApiGetProductRequest} requestParameters Request parameters.
1222
1335
  * @param {*} [options] Override http request option.
1223
1336
  * @throws {RequiredError}
1224
1337
  */
1225
- getProduct(project: string, productId: string, fields?: string, options?: any): AxiosPromise<Product> {
1226
- return localVarFp.getProduct(project, productId, fields, options).then((request) => request(axios, basePath));
1338
+ getProduct(requestParameters: ProductsApiGetProductRequest, options?: RawAxiosRequestConfig): AxiosPromise<Product> {
1339
+ return localVarFp.getProduct(requestParameters.project, requestParameters.productId, requestParameters.fields, options).then((request) => request(axios, basePath));
1227
1340
  },
1228
1341
  /**
1229
1342
  * Lists all enabled store listing products attached to the given project.
1230
1343
  * @summary List products
1231
- * @param {string} project What project it is
1232
- * @param {number} [pageToken] Page reference token
1233
- * @param {string} [search] Search term to filter based on product tags.
1234
- * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
1235
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1344
+ * @param {ProductsApiGetProductsRequest} requestParameters Request parameters.
1236
1345
  * @param {*} [options] Override http request option.
1237
1346
  * @throws {RequiredError}
1238
1347
  */
1239
- getProducts(project: string, pageToken?: number, search?: string, pageSize?: number, fields?: string, options?: any): AxiosPromise<ProductsResponse> {
1240
- return localVarFp.getProducts(project, pageToken, search, pageSize, fields, options).then((request) => request(axios, basePath));
1348
+ getProducts(requestParameters: ProductsApiGetProductsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ProductsResponse> {
1349
+ return localVarFp.getProducts(requestParameters.project, requestParameters.pageToken, requestParameters.search, requestParameters.pageSize, requestParameters.fields, options).then((request) => request(axios, basePath));
1241
1350
  },
1242
1351
  /**
1243
1352
  * Initiates a product import from a CSV file. The result will be available as a notification within the dashboard.
1244
1353
  * @summary Import products
1245
- * @param {string} project What project it is
1246
- * @param {string} [body] A data URL of a CSV file containing data for one or more products.
1354
+ * @param {ProductsApiImportProductsRequest} requestParameters Request parameters.
1247
1355
  * @param {*} [options] Override http request option.
1248
1356
  * @throws {RequiredError}
1249
1357
  */
1250
- importProducts(project: string, body?: string, options?: any): AxiosPromise<ImportProducts200Response> {
1251
- return localVarFp.importProducts(project, body, options).then((request) => request(axios, basePath));
1358
+ importProducts(requestParameters: ProductsApiImportProductsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ImportProducts200Response> {
1359
+ return localVarFp.importProducts(requestParameters.project, requestParameters.body, options).then((request) => request(axios, basePath));
1252
1360
  },
1253
1361
  /**
1254
1362
  * Updates a product by a given ID.
1255
1363
  * @summary Update product
1256
- * @param {string} project What project it is
1257
- * @param {string} productId Product\&#39;s unique identifier
1258
- * @param {UpdateProductRequest} [updateProductRequest]
1364
+ * @param {ProductsApiUpdateProductRequest} requestParameters Request parameters.
1259
1365
  * @param {*} [options] Override http request option.
1260
1366
  * @throws {RequiredError}
1261
1367
  */
1262
- updateProduct(project: string, productId: string, updateProductRequest?: UpdateProductRequest, options?: any): AxiosPromise<Product> {
1263
- return localVarFp.updateProduct(project, productId, updateProductRequest, options).then((request) => request(axios, basePath));
1368
+ updateProduct(requestParameters: ProductsApiUpdateProductRequest, options?: RawAxiosRequestConfig): AxiosPromise<Product> {
1369
+ return localVarFp.updateProduct(requestParameters.project, requestParameters.productId, requestParameters.updateProductRequest, options).then((request) => request(axios, basePath));
1264
1370
  },
1265
1371
  };
1266
1372
  };
1267
1373
 
1374
+ /**
1375
+ * Request parameters for createProduct operation in ProductsApi.
1376
+ * @export
1377
+ * @interface ProductsApiCreateProductRequest
1378
+ */
1379
+ export interface ProductsApiCreateProductRequest {
1380
+ /**
1381
+ * What project it is
1382
+ * @type {string}
1383
+ * @memberof ProductsApiCreateProduct
1384
+ */
1385
+ readonly project: string
1386
+
1387
+ /**
1388
+ *
1389
+ * @type {CreateProductRequest}
1390
+ * @memberof ProductsApiCreateProduct
1391
+ */
1392
+ readonly createProductRequest?: CreateProductRequest
1393
+ }
1394
+
1395
+ /**
1396
+ * Request parameters for deleteProduct operation in ProductsApi.
1397
+ * @export
1398
+ * @interface ProductsApiDeleteProductRequest
1399
+ */
1400
+ export interface ProductsApiDeleteProductRequest {
1401
+ /**
1402
+ * What project it is
1403
+ * @type {string}
1404
+ * @memberof ProductsApiDeleteProduct
1405
+ */
1406
+ readonly project: string
1407
+
1408
+ /**
1409
+ * Product\&#39;s unique identifier
1410
+ * @type {string}
1411
+ * @memberof ProductsApiDeleteProduct
1412
+ */
1413
+ readonly productId: string
1414
+ }
1415
+
1416
+ /**
1417
+ * Request parameters for getProduct operation in ProductsApi.
1418
+ * @export
1419
+ * @interface ProductsApiGetProductRequest
1420
+ */
1421
+ export interface ProductsApiGetProductRequest {
1422
+ /**
1423
+ * What project it is
1424
+ * @type {string}
1425
+ * @memberof ProductsApiGetProduct
1426
+ */
1427
+ readonly project: string
1428
+
1429
+ /**
1430
+ * Product\&#39;s unique identifier
1431
+ * @type {string}
1432
+ * @memberof ProductsApiGetProduct
1433
+ */
1434
+ readonly productId: string
1435
+
1436
+ /**
1437
+ * Filter response fields to only include a subset of the resource.
1438
+ * @type {string}
1439
+ * @memberof ProductsApiGetProduct
1440
+ */
1441
+ readonly fields?: string
1442
+ }
1443
+
1444
+ /**
1445
+ * Request parameters for getProducts operation in ProductsApi.
1446
+ * @export
1447
+ * @interface ProductsApiGetProductsRequest
1448
+ */
1449
+ export interface ProductsApiGetProductsRequest {
1450
+ /**
1451
+ * What project it is
1452
+ * @type {string}
1453
+ * @memberof ProductsApiGetProducts
1454
+ */
1455
+ readonly project: string
1456
+
1457
+ /**
1458
+ * Page reference token
1459
+ * @type {number}
1460
+ * @memberof ProductsApiGetProducts
1461
+ */
1462
+ readonly pageToken?: number
1463
+
1464
+ /**
1465
+ * Search term to filter based on product tags.
1466
+ * @type {string}
1467
+ * @memberof ProductsApiGetProducts
1468
+ */
1469
+ readonly search?: string
1470
+
1471
+ /**
1472
+ * Max page size. This is the maximum page size that will be returned, but it might be smaller.
1473
+ * @type {number}
1474
+ * @memberof ProductsApiGetProducts
1475
+ */
1476
+ readonly pageSize?: number
1477
+
1478
+ /**
1479
+ * Filter response fields to only include a subset of the resource.
1480
+ * @type {string}
1481
+ * @memberof ProductsApiGetProducts
1482
+ */
1483
+ readonly fields?: string
1484
+ }
1485
+
1486
+ /**
1487
+ * Request parameters for importProducts operation in ProductsApi.
1488
+ * @export
1489
+ * @interface ProductsApiImportProductsRequest
1490
+ */
1491
+ export interface ProductsApiImportProductsRequest {
1492
+ /**
1493
+ * What project it is
1494
+ * @type {string}
1495
+ * @memberof ProductsApiImportProducts
1496
+ */
1497
+ readonly project: string
1498
+
1499
+ /**
1500
+ * A data URL of a CSV file containing data for one or more products.
1501
+ * @type {string}
1502
+ * @memberof ProductsApiImportProducts
1503
+ */
1504
+ readonly body?: string
1505
+ }
1506
+
1507
+ /**
1508
+ * Request parameters for updateProduct operation in ProductsApi.
1509
+ * @export
1510
+ * @interface ProductsApiUpdateProductRequest
1511
+ */
1512
+ export interface ProductsApiUpdateProductRequest {
1513
+ /**
1514
+ * What project it is
1515
+ * @type {string}
1516
+ * @memberof ProductsApiUpdateProduct
1517
+ */
1518
+ readonly project: string
1519
+
1520
+ /**
1521
+ * Product\&#39;s unique identifier
1522
+ * @type {string}
1523
+ * @memberof ProductsApiUpdateProduct
1524
+ */
1525
+ readonly productId: string
1526
+
1527
+ /**
1528
+ *
1529
+ * @type {UpdateProductRequest}
1530
+ * @memberof ProductsApiUpdateProduct
1531
+ */
1532
+ readonly updateProductRequest?: UpdateProductRequest
1533
+ }
1534
+
1268
1535
  /**
1269
1536
  * ProductsApi - object-oriented interface
1270
1537
  * @export
@@ -1275,84 +1542,73 @@ export class ProductsApi extends BaseAPI {
1275
1542
  /**
1276
1543
  * Creates a new catalog product based on a given warehouse product with the variants and design applications provided. To select a warehouse product to base this product on, use the GFN Catalog API to list available options.
1277
1544
  * @summary Create product
1278
- * @param {string} project What project it is
1279
- * @param {CreateProductRequest} [createProductRequest]
1545
+ * @param {ProductsApiCreateProductRequest} requestParameters Request parameters.
1280
1546
  * @param {*} [options] Override http request option.
1281
1547
  * @throws {RequiredError}
1282
1548
  * @memberof ProductsApi
1283
1549
  */
1284
- public createProduct(project: string, createProductRequest?: CreateProductRequest, options?: RawAxiosRequestConfig) {
1285
- return ProductsApiFp(this.configuration).createProduct(project, createProductRequest, options).then((request) => request(this.axios, this.basePath));
1550
+ public createProduct(requestParameters: ProductsApiCreateProductRequest, options?: RawAxiosRequestConfig) {
1551
+ return ProductsApiFp(this.configuration).createProduct(requestParameters.project, requestParameters.createProductRequest, options).then((request) => request(this.axios, this.basePath));
1286
1552
  }
1287
1553
 
1288
1554
  /**
1289
1555
  * Deletes a catalog product
1290
1556
  * @summary Delete catalog product
1291
- * @param {string} project What project it is
1292
- * @param {string} productId Product\&#39;s unique identifier
1557
+ * @param {ProductsApiDeleteProductRequest} requestParameters Request parameters.
1293
1558
  * @param {*} [options] Override http request option.
1294
1559
  * @throws {RequiredError}
1295
1560
  * @memberof ProductsApi
1296
1561
  */
1297
- public deleteProduct(project: string, productId: string, options?: RawAxiosRequestConfig) {
1298
- return ProductsApiFp(this.configuration).deleteProduct(project, productId, options).then((request) => request(this.axios, this.basePath));
1562
+ public deleteProduct(requestParameters: ProductsApiDeleteProductRequest, options?: RawAxiosRequestConfig) {
1563
+ return ProductsApiFp(this.configuration).deleteProduct(requestParameters.project, requestParameters.productId, options).then((request) => request(this.axios, this.basePath));
1299
1564
  }
1300
1565
 
1301
1566
  /**
1302
1567
  * Gets a product by a given ID.
1303
1568
  * @summary Get product
1304
- * @param {string} project What project it is
1305
- * @param {string} productId Product\&#39;s unique identifier
1306
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1569
+ * @param {ProductsApiGetProductRequest} requestParameters Request parameters.
1307
1570
  * @param {*} [options] Override http request option.
1308
1571
  * @throws {RequiredError}
1309
1572
  * @memberof ProductsApi
1310
1573
  */
1311
- public getProduct(project: string, productId: string, fields?: string, options?: RawAxiosRequestConfig) {
1312
- return ProductsApiFp(this.configuration).getProduct(project, productId, fields, options).then((request) => request(this.axios, this.basePath));
1574
+ public getProduct(requestParameters: ProductsApiGetProductRequest, options?: RawAxiosRequestConfig) {
1575
+ return ProductsApiFp(this.configuration).getProduct(requestParameters.project, requestParameters.productId, requestParameters.fields, options).then((request) => request(this.axios, this.basePath));
1313
1576
  }
1314
1577
 
1315
1578
  /**
1316
1579
  * Lists all enabled store listing products attached to the given project.
1317
1580
  * @summary List products
1318
- * @param {string} project What project it is
1319
- * @param {number} [pageToken] Page reference token
1320
- * @param {string} [search] Search term to filter based on product tags.
1321
- * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
1322
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1581
+ * @param {ProductsApiGetProductsRequest} requestParameters Request parameters.
1323
1582
  * @param {*} [options] Override http request option.
1324
1583
  * @throws {RequiredError}
1325
1584
  * @memberof ProductsApi
1326
1585
  */
1327
- public getProducts(project: string, pageToken?: number, search?: string, pageSize?: number, fields?: string, options?: RawAxiosRequestConfig) {
1328
- return ProductsApiFp(this.configuration).getProducts(project, pageToken, search, pageSize, fields, options).then((request) => request(this.axios, this.basePath));
1586
+ public getProducts(requestParameters: ProductsApiGetProductsRequest, options?: RawAxiosRequestConfig) {
1587
+ return ProductsApiFp(this.configuration).getProducts(requestParameters.project, requestParameters.pageToken, requestParameters.search, requestParameters.pageSize, requestParameters.fields, options).then((request) => request(this.axios, this.basePath));
1329
1588
  }
1330
1589
 
1331
1590
  /**
1332
1591
  * Initiates a product import from a CSV file. The result will be available as a notification within the dashboard.
1333
1592
  * @summary Import products
1334
- * @param {string} project What project it is
1335
- * @param {string} [body] A data URL of a CSV file containing data for one or more products.
1593
+ * @param {ProductsApiImportProductsRequest} requestParameters Request parameters.
1336
1594
  * @param {*} [options] Override http request option.
1337
1595
  * @throws {RequiredError}
1338
1596
  * @memberof ProductsApi
1339
1597
  */
1340
- public importProducts(project: string, body?: string, options?: RawAxiosRequestConfig) {
1341
- return ProductsApiFp(this.configuration).importProducts(project, body, options).then((request) => request(this.axios, this.basePath));
1598
+ public importProducts(requestParameters: ProductsApiImportProductsRequest, options?: RawAxiosRequestConfig) {
1599
+ return ProductsApiFp(this.configuration).importProducts(requestParameters.project, requestParameters.body, options).then((request) => request(this.axios, this.basePath));
1342
1600
  }
1343
1601
 
1344
1602
  /**
1345
1603
  * Updates a product by a given ID.
1346
1604
  * @summary Update product
1347
- * @param {string} project What project it is
1348
- * @param {string} productId Product\&#39;s unique identifier
1349
- * @param {UpdateProductRequest} [updateProductRequest]
1605
+ * @param {ProductsApiUpdateProductRequest} requestParameters Request parameters.
1350
1606
  * @param {*} [options] Override http request option.
1351
1607
  * @throws {RequiredError}
1352
1608
  * @memberof ProductsApi
1353
1609
  */
1354
- public updateProduct(project: string, productId: string, updateProductRequest?: UpdateProductRequest, options?: RawAxiosRequestConfig) {
1355
- return ProductsApiFp(this.configuration).updateProduct(project, productId, updateProductRequest, options).then((request) => request(this.axios, this.basePath));
1610
+ public updateProduct(requestParameters: ProductsApiUpdateProductRequest, options?: RawAxiosRequestConfig) {
1611
+ return ProductsApiFp(this.configuration).updateProduct(requestParameters.project, requestParameters.productId, requestParameters.updateProductRequest, options).then((request) => request(this.axios, this.basePath));
1356
1612
  }
1357
1613
  }
1358
1614
 
@@ -1536,32 +1792,96 @@ export const VariantsApiFactory = function (configuration?: Configuration, baseP
1536
1792
  /**
1537
1793
  * Gets a variant by a given ID.
1538
1794
  * @summary Get variant
1539
- * @param {string} project What project it is
1540
- * @param {string} variantId Variants unique identifier
1541
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1795
+ * @param {VariantsApiGetVariantRequest} requestParameters Request parameters.
1542
1796
  * @param {*} [options] Override http request option.
1543
1797
  * @throws {RequiredError}
1544
1798
  */
1545
- getVariant(project: string, variantId: string, fields?: string, options?: any): AxiosPromise<Variant> {
1546
- return localVarFp.getVariant(project, variantId, fields, options).then((request) => request(axios, basePath));
1799
+ getVariant(requestParameters: VariantsApiGetVariantRequest, options?: RawAxiosRequestConfig): AxiosPromise<Variant> {
1800
+ return localVarFp.getVariant(requestParameters.project, requestParameters.variantId, requestParameters.fields, options).then((request) => request(axios, basePath));
1547
1801
  },
1548
1802
  /**
1549
1803
  * Lists all variants that belong to enabled products attached to the given project.
1550
1804
  * @summary List variants
1551
- * @param {string} project What project it is
1552
- * @param {string} [search] Search term to filter based on product tags.
1553
- * @param {number} [pageToken] Page reference token
1554
- * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
1555
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1805
+ * @param {VariantsApiListVariantsRequest} requestParameters Request parameters.
1556
1806
  * @param {*} [options] Override http request option.
1557
1807
  * @throws {RequiredError}
1558
1808
  */
1559
- listVariants(project: string, search?: string, pageToken?: number, pageSize?: number, fields?: string, options?: any): AxiosPromise<VariantsResponse> {
1560
- return localVarFp.listVariants(project, search, pageToken, pageSize, fields, options).then((request) => request(axios, basePath));
1809
+ listVariants(requestParameters: VariantsApiListVariantsRequest, options?: RawAxiosRequestConfig): AxiosPromise<VariantsResponse> {
1810
+ return localVarFp.listVariants(requestParameters.project, requestParameters.search, requestParameters.pageToken, requestParameters.pageSize, requestParameters.fields, options).then((request) => request(axios, basePath));
1561
1811
  },
1562
1812
  };
1563
1813
  };
1564
1814
 
1815
+ /**
1816
+ * Request parameters for getVariant operation in VariantsApi.
1817
+ * @export
1818
+ * @interface VariantsApiGetVariantRequest
1819
+ */
1820
+ export interface VariantsApiGetVariantRequest {
1821
+ /**
1822
+ * What project it is
1823
+ * @type {string}
1824
+ * @memberof VariantsApiGetVariant
1825
+ */
1826
+ readonly project: string
1827
+
1828
+ /**
1829
+ * Variants unique identifier
1830
+ * @type {string}
1831
+ * @memberof VariantsApiGetVariant
1832
+ */
1833
+ readonly variantId: string
1834
+
1835
+ /**
1836
+ * Filter response fields to only include a subset of the resource.
1837
+ * @type {string}
1838
+ * @memberof VariantsApiGetVariant
1839
+ */
1840
+ readonly fields?: string
1841
+ }
1842
+
1843
+ /**
1844
+ * Request parameters for listVariants operation in VariantsApi.
1845
+ * @export
1846
+ * @interface VariantsApiListVariantsRequest
1847
+ */
1848
+ export interface VariantsApiListVariantsRequest {
1849
+ /**
1850
+ * What project it is
1851
+ * @type {string}
1852
+ * @memberof VariantsApiListVariants
1853
+ */
1854
+ readonly project: string
1855
+
1856
+ /**
1857
+ * Search term to filter based on product tags.
1858
+ * @type {string}
1859
+ * @memberof VariantsApiListVariants
1860
+ */
1861
+ readonly search?: string
1862
+
1863
+ /**
1864
+ * Page reference token
1865
+ * @type {number}
1866
+ * @memberof VariantsApiListVariants
1867
+ */
1868
+ readonly pageToken?: number
1869
+
1870
+ /**
1871
+ * Max page size. This is the maximum page size that will be returned, but it might be smaller.
1872
+ * @type {number}
1873
+ * @memberof VariantsApiListVariants
1874
+ */
1875
+ readonly pageSize?: number
1876
+
1877
+ /**
1878
+ * Filter response fields to only include a subset of the resource.
1879
+ * @type {string}
1880
+ * @memberof VariantsApiListVariants
1881
+ */
1882
+ readonly fields?: string
1883
+ }
1884
+
1565
1885
  /**
1566
1886
  * VariantsApi - object-oriented interface
1567
1887
  * @export
@@ -1572,31 +1892,25 @@ export class VariantsApi extends BaseAPI {
1572
1892
  /**
1573
1893
  * Gets a variant by a given ID.
1574
1894
  * @summary Get variant
1575
- * @param {string} project What project it is
1576
- * @param {string} variantId Variants unique identifier
1577
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1895
+ * @param {VariantsApiGetVariantRequest} requestParameters Request parameters.
1578
1896
  * @param {*} [options] Override http request option.
1579
1897
  * @throws {RequiredError}
1580
1898
  * @memberof VariantsApi
1581
1899
  */
1582
- public getVariant(project: string, variantId: string, fields?: string, options?: RawAxiosRequestConfig) {
1583
- return VariantsApiFp(this.configuration).getVariant(project, variantId, fields, options).then((request) => request(this.axios, this.basePath));
1900
+ public getVariant(requestParameters: VariantsApiGetVariantRequest, options?: RawAxiosRequestConfig) {
1901
+ return VariantsApiFp(this.configuration).getVariant(requestParameters.project, requestParameters.variantId, requestParameters.fields, options).then((request) => request(this.axios, this.basePath));
1584
1902
  }
1585
1903
 
1586
1904
  /**
1587
1905
  * Lists all variants that belong to enabled products attached to the given project.
1588
1906
  * @summary List variants
1589
- * @param {string} project What project it is
1590
- * @param {string} [search] Search term to filter based on product tags.
1591
- * @param {number} [pageToken] Page reference token
1592
- * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
1593
- * @param {string} [fields] Filter response fields to only include a subset of the resource.
1907
+ * @param {VariantsApiListVariantsRequest} requestParameters Request parameters.
1594
1908
  * @param {*} [options] Override http request option.
1595
1909
  * @throws {RequiredError}
1596
1910
  * @memberof VariantsApi
1597
1911
  */
1598
- public listVariants(project: string, search?: string, pageToken?: number, pageSize?: number, fields?: string, options?: RawAxiosRequestConfig) {
1599
- return VariantsApiFp(this.configuration).listVariants(project, search, pageToken, pageSize, fields, options).then((request) => request(this.axios, this.basePath));
1912
+ public listVariants(requestParameters: VariantsApiListVariantsRequest, options?: RawAxiosRequestConfig) {
1913
+ return VariantsApiFp(this.configuration).listVariants(requestParameters.project, requestParameters.search, requestParameters.pageToken, requestParameters.pageSize, requestParameters.fields, options).then((request) => request(this.axios, this.basePath));
1600
1914
  }
1601
1915
  }
1602
1916