@emilgroup/insurance-sdk 1.0.2 → 1.0.3

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.
@@ -59,9 +59,21 @@ import { ListProductsResponseClass } from '../models';
59
59
  // @ts-ignore
60
60
  import { StoreProductFactorsResponseClass } from '../models';
61
61
  // @ts-ignore
62
+ import { UpdatePremiumFormulaRequestDto } from '../models';
63
+ // @ts-ignore
64
+ import { UpdatePremiumFormulaResponseClass } from '../models';
65
+ // @ts-ignore
66
+ import { UpdateProductFieldRequestDto } from '../models';
67
+ // @ts-ignore
68
+ import { UpdateProductFieldResponseClass } from '../models';
69
+ // @ts-ignore
62
70
  import { UpdateProductRequestDto } from '../models';
63
71
  // @ts-ignore
64
72
  import { UpdateProductResponseClass } from '../models';
73
+ // @ts-ignore
74
+ import { UpdateProductVersionRequestDto } from '../models';
75
+ // @ts-ignore
76
+ import { UpdateProductVersionResponseClass } from '../models';
65
77
  // URLSearchParams not necessarily used
66
78
  // @ts-ignore
67
79
  import { URL, URLSearchParams } from 'url';
@@ -213,6 +225,51 @@ export const ProductsApiAxiosParamCreator = function (configuration?: Configurat
213
225
  options: localVarRequestOptions,
214
226
  };
215
227
  },
228
+ /**
229
+ * Permanently deletes the premium formula. Supply the unique id that was returned when you created the premium formula and this will delete it.
230
+ * @summary Delete the premium formula
231
+ * @param {number} id
232
+ * @param {string} [authorization] Bearer Token
233
+ * @param {*} [options] Override http request option.
234
+ * @throws {RequiredError}
235
+ */
236
+ deletePremiumFormula: async (id: number, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
237
+ // verify required parameter 'id' is not null or undefined
238
+ assertParamExists('deletePremiumFormula', 'id', id)
239
+ const localVarPath = `/insuranceservice/v1/premium-formulas/{id}`
240
+ .replace(`{${"id"}}`, encodeURIComponent(String(id)));
241
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
242
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
243
+ let baseOptions;
244
+ let baseAccessToken;
245
+ if (configuration) {
246
+ baseOptions = configuration.baseOptions;
247
+ baseAccessToken = configuration.accessToken;
248
+ }
249
+
250
+ const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
251
+ const localVarHeaderParameter = {} as any;
252
+ const localVarQueryParameter = {} as any;
253
+
254
+ // authentication bearer required
255
+ // http bearer authentication required
256
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
257
+
258
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
259
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
260
+ }
261
+
262
+
263
+
264
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
265
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
266
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
267
+
268
+ return {
269
+ url: toPathString(localVarUrlObj),
270
+ options: localVarRequestOptions,
271
+ };
272
+ },
216
273
  /**
217
274
  * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
218
275
  * @summary Delete the product
@@ -249,6 +306,51 @@ export const ProductsApiAxiosParamCreator = function (configuration?: Configurat
249
306
 
250
307
 
251
308
 
309
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
310
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
311
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
312
+
313
+ return {
314
+ url: toPathString(localVarUrlObj),
315
+ options: localVarRequestOptions,
316
+ };
317
+ },
318
+ /**
319
+ * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
320
+ * @summary Delete the product
321
+ * @param {string} id
322
+ * @param {string} [authorization] Bearer Token
323
+ * @param {*} [options] Override http request option.
324
+ * @throws {RequiredError}
325
+ */
326
+ deleteProductField: async (id: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
327
+ // verify required parameter 'id' is not null or undefined
328
+ assertParamExists('deleteProductField', 'id', id)
329
+ const localVarPath = `/insuranceservice/v1/product-fields/{id}`
330
+ .replace(`{${"id"}}`, encodeURIComponent(String(id)));
331
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
332
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
333
+ let baseOptions;
334
+ let baseAccessToken;
335
+ if (configuration) {
336
+ baseOptions = configuration.baseOptions;
337
+ baseAccessToken = configuration.accessToken;
338
+ }
339
+
340
+ const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
341
+ const localVarHeaderParameter = {} as any;
342
+ const localVarQueryParameter = {} as any;
343
+
344
+ // authentication bearer required
345
+ // http bearer authentication required
346
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
347
+
348
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
349
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
350
+ }
351
+
352
+
353
+
252
354
  setSearchParams(localVarUrlObj, localVarQueryParameter);
253
355
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
254
356
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
@@ -1000,6 +1102,57 @@ export const ProductsApiAxiosParamCreator = function (configuration?: Configurat
1000
1102
  options: localVarRequestOptions,
1001
1103
  };
1002
1104
  },
1105
+ /**
1106
+ * Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1107
+ * @summary Update the premium formula
1108
+ * @param {number} id
1109
+ * @param {UpdatePremiumFormulaRequestDto} updatePremiumFormulaRequestDto
1110
+ * @param {string} [authorization] Bearer Token
1111
+ * @param {*} [options] Override http request option.
1112
+ * @throws {RequiredError}
1113
+ */
1114
+ updatePremiumFormula: async (id: number, updatePremiumFormulaRequestDto: UpdatePremiumFormulaRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
1115
+ // verify required parameter 'id' is not null or undefined
1116
+ assertParamExists('updatePremiumFormula', 'id', id)
1117
+ // verify required parameter 'updatePremiumFormulaRequestDto' is not null or undefined
1118
+ assertParamExists('updatePremiumFormula', 'updatePremiumFormulaRequestDto', updatePremiumFormulaRequestDto)
1119
+ const localVarPath = `/insuranceservice/v1/premium-formulas/{id}`
1120
+ .replace(`{${"id"}}`, encodeURIComponent(String(id)));
1121
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1122
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
1123
+ let baseOptions;
1124
+ let baseAccessToken;
1125
+ if (configuration) {
1126
+ baseOptions = configuration.baseOptions;
1127
+ baseAccessToken = configuration.accessToken;
1128
+ }
1129
+
1130
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
1131
+ const localVarHeaderParameter = {} as any;
1132
+ const localVarQueryParameter = {} as any;
1133
+
1134
+ // authentication bearer required
1135
+ // http bearer authentication required
1136
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
1137
+
1138
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
1139
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
1140
+ }
1141
+
1142
+
1143
+
1144
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1145
+
1146
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1147
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1148
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1149
+ localVarRequestOptions.data = serializeDataIfNeeded(updatePremiumFormulaRequestDto, localVarRequestOptions, configuration)
1150
+
1151
+ return {
1152
+ url: toPathString(localVarUrlObj),
1153
+ options: localVarRequestOptions,
1154
+ };
1155
+ },
1003
1156
  /**
1004
1157
  * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1005
1158
  * @summary Update the product
@@ -1051,6 +1204,108 @@ export const ProductsApiAxiosParamCreator = function (configuration?: Configurat
1051
1204
  options: localVarRequestOptions,
1052
1205
  };
1053
1206
  },
1207
+ /**
1208
+ * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1209
+ * @summary Update the product
1210
+ * @param {string} id
1211
+ * @param {UpdateProductFieldRequestDto} updateProductFieldRequestDto
1212
+ * @param {string} [authorization] Bearer Token
1213
+ * @param {*} [options] Override http request option.
1214
+ * @throws {RequiredError}
1215
+ */
1216
+ updateProductField: async (id: string, updateProductFieldRequestDto: UpdateProductFieldRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
1217
+ // verify required parameter 'id' is not null or undefined
1218
+ assertParamExists('updateProductField', 'id', id)
1219
+ // verify required parameter 'updateProductFieldRequestDto' is not null or undefined
1220
+ assertParamExists('updateProductField', 'updateProductFieldRequestDto', updateProductFieldRequestDto)
1221
+ const localVarPath = `/insuranceservice/v1/product-fields/{id}`
1222
+ .replace(`{${"id"}}`, encodeURIComponent(String(id)));
1223
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1224
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
1225
+ let baseOptions;
1226
+ let baseAccessToken;
1227
+ if (configuration) {
1228
+ baseOptions = configuration.baseOptions;
1229
+ baseAccessToken = configuration.accessToken;
1230
+ }
1231
+
1232
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
1233
+ const localVarHeaderParameter = {} as any;
1234
+ const localVarQueryParameter = {} as any;
1235
+
1236
+ // authentication bearer required
1237
+ // http bearer authentication required
1238
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
1239
+
1240
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
1241
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
1242
+ }
1243
+
1244
+
1245
+
1246
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1247
+
1248
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1249
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1250
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1251
+ localVarRequestOptions.data = serializeDataIfNeeded(updateProductFieldRequestDto, localVarRequestOptions, configuration)
1252
+
1253
+ return {
1254
+ url: toPathString(localVarUrlObj),
1255
+ options: localVarRequestOptions,
1256
+ };
1257
+ },
1258
+ /**
1259
+ * Updates the specified product version by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1260
+ * @summary Update the product version
1261
+ * @param {number} id
1262
+ * @param {UpdateProductVersionRequestDto} updateProductVersionRequestDto
1263
+ * @param {string} [authorization] Bearer Token
1264
+ * @param {*} [options] Override http request option.
1265
+ * @throws {RequiredError}
1266
+ */
1267
+ updateProductVersion: async (id: number, updateProductVersionRequestDto: UpdateProductVersionRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
1268
+ // verify required parameter 'id' is not null or undefined
1269
+ assertParamExists('updateProductVersion', 'id', id)
1270
+ // verify required parameter 'updateProductVersionRequestDto' is not null or undefined
1271
+ assertParamExists('updateProductVersion', 'updateProductVersionRequestDto', updateProductVersionRequestDto)
1272
+ const localVarPath = `/insuranceservice/v1/product-versions/{id}`
1273
+ .replace(`{${"id"}}`, encodeURIComponent(String(id)));
1274
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1275
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
1276
+ let baseOptions;
1277
+ let baseAccessToken;
1278
+ if (configuration) {
1279
+ baseOptions = configuration.baseOptions;
1280
+ baseAccessToken = configuration.accessToken;
1281
+ }
1282
+
1283
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
1284
+ const localVarHeaderParameter = {} as any;
1285
+ const localVarQueryParameter = {} as any;
1286
+
1287
+ // authentication bearer required
1288
+ // http bearer authentication required
1289
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
1290
+
1291
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
1292
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
1293
+ }
1294
+
1295
+
1296
+
1297
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1298
+
1299
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1300
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1301
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1302
+ localVarRequestOptions.data = serializeDataIfNeeded(updateProductVersionRequestDto, localVarRequestOptions, configuration)
1303
+
1304
+ return {
1305
+ url: toPathString(localVarUrlObj),
1306
+ options: localVarRequestOptions,
1307
+ };
1308
+ },
1054
1309
  /**
1055
1310
  * Validate a CSV file containing all product factors. The columns must be in the following order: group,label,key,name,value.
1056
1311
  * @summary Validate product factors
@@ -1147,6 +1402,18 @@ export const ProductsApiFp = function(configuration?: Configuration) {
1147
1402
  const localVarAxiosArgs = await localVarAxiosParamCreator.createProductField(createProductFieldRequestDto, authorization, options);
1148
1403
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1149
1404
  },
1405
+ /**
1406
+ * Permanently deletes the premium formula. Supply the unique id that was returned when you created the premium formula and this will delete it.
1407
+ * @summary Delete the premium formula
1408
+ * @param {number} id
1409
+ * @param {string} [authorization] Bearer Token
1410
+ * @param {*} [options] Override http request option.
1411
+ * @throws {RequiredError}
1412
+ */
1413
+ async deletePremiumFormula(id: number, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<object>> {
1414
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deletePremiumFormula(id, authorization, options);
1415
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1416
+ },
1150
1417
  /**
1151
1418
  * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
1152
1419
  * @summary Delete the product
@@ -1159,6 +1426,18 @@ export const ProductsApiFp = function(configuration?: Configuration) {
1159
1426
  const localVarAxiosArgs = await localVarAxiosParamCreator.deleteProduct(id, authorization, options);
1160
1427
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1161
1428
  },
1429
+ /**
1430
+ * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
1431
+ * @summary Delete the product
1432
+ * @param {string} id
1433
+ * @param {string} [authorization] Bearer Token
1434
+ * @param {*} [options] Override http request option.
1435
+ * @throws {RequiredError}
1436
+ */
1437
+ async deleteProductField(id: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
1438
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteProductField(id, authorization, options);
1439
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1440
+ },
1162
1441
  /**
1163
1442
  * Retrieves the details of the premium formula that was previously created. Supply the unique premium formula id that was returned when you created it and Emil Api will return the corresponding premium formula information.
1164
1443
  * @summary Retrieve the premium formula
@@ -1338,6 +1617,19 @@ export const ProductsApiFp = function(configuration?: Configuration) {
1338
1617
  const localVarAxiosArgs = await localVarAxiosParamCreator.storeProductFactors(authorization, productVersionId, factors, options);
1339
1618
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1340
1619
  },
1620
+ /**
1621
+ * Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1622
+ * @summary Update the premium formula
1623
+ * @param {number} id
1624
+ * @param {UpdatePremiumFormulaRequestDto} updatePremiumFormulaRequestDto
1625
+ * @param {string} [authorization] Bearer Token
1626
+ * @param {*} [options] Override http request option.
1627
+ * @throws {RequiredError}
1628
+ */
1629
+ async updatePremiumFormula(id: number, updatePremiumFormulaRequestDto: UpdatePremiumFormulaRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdatePremiumFormulaResponseClass>> {
1630
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updatePremiumFormula(id, updatePremiumFormulaRequestDto, authorization, options);
1631
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1632
+ },
1341
1633
  /**
1342
1634
  * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1343
1635
  * @summary Update the product
@@ -1351,6 +1643,32 @@ export const ProductsApiFp = function(configuration?: Configuration) {
1351
1643
  const localVarAxiosArgs = await localVarAxiosParamCreator.updateProduct(id, updateProductRequestDto, authorization, options);
1352
1644
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1353
1645
  },
1646
+ /**
1647
+ * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1648
+ * @summary Update the product
1649
+ * @param {string} id
1650
+ * @param {UpdateProductFieldRequestDto} updateProductFieldRequestDto
1651
+ * @param {string} [authorization] Bearer Token
1652
+ * @param {*} [options] Override http request option.
1653
+ * @throws {RequiredError}
1654
+ */
1655
+ async updateProductField(id: string, updateProductFieldRequestDto: UpdateProductFieldRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdateProductFieldResponseClass>> {
1656
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateProductField(id, updateProductFieldRequestDto, authorization, options);
1657
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1658
+ },
1659
+ /**
1660
+ * Updates the specified product version by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1661
+ * @summary Update the product version
1662
+ * @param {number} id
1663
+ * @param {UpdateProductVersionRequestDto} updateProductVersionRequestDto
1664
+ * @param {string} [authorization] Bearer Token
1665
+ * @param {*} [options] Override http request option.
1666
+ * @throws {RequiredError}
1667
+ */
1668
+ async updateProductVersion(id: number, updateProductVersionRequestDto: UpdateProductVersionRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdateProductVersionResponseClass>> {
1669
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateProductVersion(id, updateProductVersionRequestDto, authorization, options);
1670
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1671
+ },
1354
1672
  /**
1355
1673
  * Validate a CSV file containing all product factors. The columns must be in the following order: group,label,key,name,value.
1356
1674
  * @summary Validate product factors
@@ -1406,6 +1724,17 @@ export const ProductsApiFactory = function (configuration?: Configuration, baseP
1406
1724
  createProductField(createProductFieldRequestDto: CreateProductFieldRequestDto, authorization?: string, options?: any): AxiosPromise<CreateProductFieldResponseClass> {
1407
1725
  return localVarFp.createProductField(createProductFieldRequestDto, authorization, options).then((request) => request(axios, basePath));
1408
1726
  },
1727
+ /**
1728
+ * Permanently deletes the premium formula. Supply the unique id that was returned when you created the premium formula and this will delete it.
1729
+ * @summary Delete the premium formula
1730
+ * @param {number} id
1731
+ * @param {string} [authorization] Bearer Token
1732
+ * @param {*} [options] Override http request option.
1733
+ * @throws {RequiredError}
1734
+ */
1735
+ deletePremiumFormula(id: number, authorization?: string, options?: any): AxiosPromise<object> {
1736
+ return localVarFp.deletePremiumFormula(id, authorization, options).then((request) => request(axios, basePath));
1737
+ },
1409
1738
  /**
1410
1739
  * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
1411
1740
  * @summary Delete the product
@@ -1417,6 +1746,17 @@ export const ProductsApiFactory = function (configuration?: Configuration, baseP
1417
1746
  deleteProduct(id: number, authorization?: string, options?: any): AxiosPromise<object> {
1418
1747
  return localVarFp.deleteProduct(id, authorization, options).then((request) => request(axios, basePath));
1419
1748
  },
1749
+ /**
1750
+ * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
1751
+ * @summary Delete the product
1752
+ * @param {string} id
1753
+ * @param {string} [authorization] Bearer Token
1754
+ * @param {*} [options] Override http request option.
1755
+ * @throws {RequiredError}
1756
+ */
1757
+ deleteProductField(id: string, authorization?: string, options?: any): AxiosPromise<void> {
1758
+ return localVarFp.deleteProductField(id, authorization, options).then((request) => request(axios, basePath));
1759
+ },
1420
1760
  /**
1421
1761
  * Retrieves the details of the premium formula that was previously created. Supply the unique premium formula id that was returned when you created it and Emil Api will return the corresponding premium formula information.
1422
1762
  * @summary Retrieve the premium formula
@@ -1584,6 +1924,18 @@ export const ProductsApiFactory = function (configuration?: Configuration, baseP
1584
1924
  storeProductFactors(authorization?: string, productVersionId?: number, factors?: any, options?: any): AxiosPromise<StoreProductFactorsResponseClass> {
1585
1925
  return localVarFp.storeProductFactors(authorization, productVersionId, factors, options).then((request) => request(axios, basePath));
1586
1926
  },
1927
+ /**
1928
+ * Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1929
+ * @summary Update the premium formula
1930
+ * @param {number} id
1931
+ * @param {UpdatePremiumFormulaRequestDto} updatePremiumFormulaRequestDto
1932
+ * @param {string} [authorization] Bearer Token
1933
+ * @param {*} [options] Override http request option.
1934
+ * @throws {RequiredError}
1935
+ */
1936
+ updatePremiumFormula(id: number, updatePremiumFormulaRequestDto: UpdatePremiumFormulaRequestDto, authorization?: string, options?: any): AxiosPromise<UpdatePremiumFormulaResponseClass> {
1937
+ return localVarFp.updatePremiumFormula(id, updatePremiumFormulaRequestDto, authorization, options).then((request) => request(axios, basePath));
1938
+ },
1587
1939
  /**
1588
1940
  * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1589
1941
  * @summary Update the product
@@ -1596,6 +1948,30 @@ export const ProductsApiFactory = function (configuration?: Configuration, baseP
1596
1948
  updateProduct(id: number, updateProductRequestDto: UpdateProductRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateProductResponseClass> {
1597
1949
  return localVarFp.updateProduct(id, updateProductRequestDto, authorization, options).then((request) => request(axios, basePath));
1598
1950
  },
1951
+ /**
1952
+ * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1953
+ * @summary Update the product
1954
+ * @param {string} id
1955
+ * @param {UpdateProductFieldRequestDto} updateProductFieldRequestDto
1956
+ * @param {string} [authorization] Bearer Token
1957
+ * @param {*} [options] Override http request option.
1958
+ * @throws {RequiredError}
1959
+ */
1960
+ updateProductField(id: string, updateProductFieldRequestDto: UpdateProductFieldRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateProductFieldResponseClass> {
1961
+ return localVarFp.updateProductField(id, updateProductFieldRequestDto, authorization, options).then((request) => request(axios, basePath));
1962
+ },
1963
+ /**
1964
+ * Updates the specified product version by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
1965
+ * @summary Update the product version
1966
+ * @param {number} id
1967
+ * @param {UpdateProductVersionRequestDto} updateProductVersionRequestDto
1968
+ * @param {string} [authorization] Bearer Token
1969
+ * @param {*} [options] Override http request option.
1970
+ * @throws {RequiredError}
1971
+ */
1972
+ updateProductVersion(id: number, updateProductVersionRequestDto: UpdateProductVersionRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateProductVersionResponseClass> {
1973
+ return localVarFp.updateProductVersion(id, updateProductVersionRequestDto, authorization, options).then((request) => request(axios, basePath));
1974
+ },
1599
1975
  /**
1600
1976
  * Validate a CSV file containing all product factors. The columns must be in the following order: group,label,key,name,value.
1601
1977
  * @summary Validate product factors
@@ -1673,6 +2049,27 @@ export interface ProductsApiCreateProductFieldRequest {
1673
2049
  readonly authorization?: string
1674
2050
  }
1675
2051
 
2052
+ /**
2053
+ * Request parameters for deletePremiumFormula operation in ProductsApi.
2054
+ * @export
2055
+ * @interface ProductsApiDeletePremiumFormulaRequest
2056
+ */
2057
+ export interface ProductsApiDeletePremiumFormulaRequest {
2058
+ /**
2059
+ *
2060
+ * @type {number}
2061
+ * @memberof ProductsApiDeletePremiumFormula
2062
+ */
2063
+ readonly id: number
2064
+
2065
+ /**
2066
+ * Bearer Token
2067
+ * @type {string}
2068
+ * @memberof ProductsApiDeletePremiumFormula
2069
+ */
2070
+ readonly authorization?: string
2071
+ }
2072
+
1676
2073
  /**
1677
2074
  * Request parameters for deleteProduct operation in ProductsApi.
1678
2075
  * @export
@@ -1694,6 +2091,27 @@ export interface ProductsApiDeleteProductRequest {
1694
2091
  readonly authorization?: string
1695
2092
  }
1696
2093
 
2094
+ /**
2095
+ * Request parameters for deleteProductField operation in ProductsApi.
2096
+ * @export
2097
+ * @interface ProductsApiDeleteProductFieldRequest
2098
+ */
2099
+ export interface ProductsApiDeleteProductFieldRequest {
2100
+ /**
2101
+ *
2102
+ * @type {string}
2103
+ * @memberof ProductsApiDeleteProductField
2104
+ */
2105
+ readonly id: string
2106
+
2107
+ /**
2108
+ * Bearer Token
2109
+ * @type {string}
2110
+ * @memberof ProductsApiDeleteProductField
2111
+ */
2112
+ readonly authorization?: string
2113
+ }
2114
+
1697
2115
  /**
1698
2116
  * Request parameters for getPremiumFormula operation in ProductsApi.
1699
2117
  * @export
@@ -2191,6 +2609,34 @@ export interface ProductsApiStoreProductFactorsRequest {
2191
2609
  readonly factors?: any
2192
2610
  }
2193
2611
 
2612
+ /**
2613
+ * Request parameters for updatePremiumFormula operation in ProductsApi.
2614
+ * @export
2615
+ * @interface ProductsApiUpdatePremiumFormulaRequest
2616
+ */
2617
+ export interface ProductsApiUpdatePremiumFormulaRequest {
2618
+ /**
2619
+ *
2620
+ * @type {number}
2621
+ * @memberof ProductsApiUpdatePremiumFormula
2622
+ */
2623
+ readonly id: number
2624
+
2625
+ /**
2626
+ *
2627
+ * @type {UpdatePremiumFormulaRequestDto}
2628
+ * @memberof ProductsApiUpdatePremiumFormula
2629
+ */
2630
+ readonly updatePremiumFormulaRequestDto: UpdatePremiumFormulaRequestDto
2631
+
2632
+ /**
2633
+ * Bearer Token
2634
+ * @type {string}
2635
+ * @memberof ProductsApiUpdatePremiumFormula
2636
+ */
2637
+ readonly authorization?: string
2638
+ }
2639
+
2194
2640
  /**
2195
2641
  * Request parameters for updateProduct operation in ProductsApi.
2196
2642
  * @export
@@ -2219,6 +2665,62 @@ export interface ProductsApiUpdateProductRequest {
2219
2665
  readonly authorization?: string
2220
2666
  }
2221
2667
 
2668
+ /**
2669
+ * Request parameters for updateProductField operation in ProductsApi.
2670
+ * @export
2671
+ * @interface ProductsApiUpdateProductFieldRequest
2672
+ */
2673
+ export interface ProductsApiUpdateProductFieldRequest {
2674
+ /**
2675
+ *
2676
+ * @type {string}
2677
+ * @memberof ProductsApiUpdateProductField
2678
+ */
2679
+ readonly id: string
2680
+
2681
+ /**
2682
+ *
2683
+ * @type {UpdateProductFieldRequestDto}
2684
+ * @memberof ProductsApiUpdateProductField
2685
+ */
2686
+ readonly updateProductFieldRequestDto: UpdateProductFieldRequestDto
2687
+
2688
+ /**
2689
+ * Bearer Token
2690
+ * @type {string}
2691
+ * @memberof ProductsApiUpdateProductField
2692
+ */
2693
+ readonly authorization?: string
2694
+ }
2695
+
2696
+ /**
2697
+ * Request parameters for updateProductVersion operation in ProductsApi.
2698
+ * @export
2699
+ * @interface ProductsApiUpdateProductVersionRequest
2700
+ */
2701
+ export interface ProductsApiUpdateProductVersionRequest {
2702
+ /**
2703
+ *
2704
+ * @type {number}
2705
+ * @memberof ProductsApiUpdateProductVersion
2706
+ */
2707
+ readonly id: number
2708
+
2709
+ /**
2710
+ *
2711
+ * @type {UpdateProductVersionRequestDto}
2712
+ * @memberof ProductsApiUpdateProductVersion
2713
+ */
2714
+ readonly updateProductVersionRequestDto: UpdateProductVersionRequestDto
2715
+
2716
+ /**
2717
+ * Bearer Token
2718
+ * @type {string}
2719
+ * @memberof ProductsApiUpdateProductVersion
2720
+ */
2721
+ readonly authorization?: string
2722
+ }
2723
+
2222
2724
  /**
2223
2725
  * Request parameters for validateProductFactors operation in ProductsApi.
2224
2726
  * @export
@@ -2283,6 +2785,18 @@ export class ProductsApi extends BaseAPI {
2283
2785
  return ProductsApiFp(this.configuration).createProductField(requestParameters.createProductFieldRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2284
2786
  }
2285
2787
 
2788
+ /**
2789
+ * Permanently deletes the premium formula. Supply the unique id that was returned when you created the premium formula and this will delete it.
2790
+ * @summary Delete the premium formula
2791
+ * @param {ProductsApiDeletePremiumFormulaRequest} requestParameters Request parameters.
2792
+ * @param {*} [options] Override http request option.
2793
+ * @throws {RequiredError}
2794
+ * @memberof ProductsApi
2795
+ */
2796
+ public deletePremiumFormula(requestParameters: ProductsApiDeletePremiumFormulaRequest, options?: AxiosRequestConfig) {
2797
+ return ProductsApiFp(this.configuration).deletePremiumFormula(requestParameters.id, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2798
+ }
2799
+
2286
2800
  /**
2287
2801
  * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
2288
2802
  * @summary Delete the product
@@ -2295,6 +2809,18 @@ export class ProductsApi extends BaseAPI {
2295
2809
  return ProductsApiFp(this.configuration).deleteProduct(requestParameters.id, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2296
2810
  }
2297
2811
 
2812
+ /**
2813
+ * Permanently deletes the product. Supply the unique id that was returned when you created the product and this will delete it.
2814
+ * @summary Delete the product
2815
+ * @param {ProductsApiDeleteProductFieldRequest} requestParameters Request parameters.
2816
+ * @param {*} [options] Override http request option.
2817
+ * @throws {RequiredError}
2818
+ * @memberof ProductsApi
2819
+ */
2820
+ public deleteProductField(requestParameters: ProductsApiDeleteProductFieldRequest, options?: AxiosRequestConfig) {
2821
+ return ProductsApiFp(this.configuration).deleteProductField(requestParameters.id, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2822
+ }
2823
+
2298
2824
  /**
2299
2825
  * Retrieves the details of the premium formula that was previously created. Supply the unique premium formula id that was returned when you created it and Emil Api will return the corresponding premium formula information.
2300
2826
  * @summary Retrieve the premium formula
@@ -2439,6 +2965,18 @@ export class ProductsApi extends BaseAPI {
2439
2965
  return ProductsApiFp(this.configuration).storeProductFactors(requestParameters.authorization, requestParameters.productVersionId, requestParameters.factors, options).then((request) => request(this.axios, this.basePath));
2440
2966
  }
2441
2967
 
2968
+ /**
2969
+ * Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
2970
+ * @summary Update the premium formula
2971
+ * @param {ProductsApiUpdatePremiumFormulaRequest} requestParameters Request parameters.
2972
+ * @param {*} [options] Override http request option.
2973
+ * @throws {RequiredError}
2974
+ * @memberof ProductsApi
2975
+ */
2976
+ public updatePremiumFormula(requestParameters: ProductsApiUpdatePremiumFormulaRequest, options?: AxiosRequestConfig) {
2977
+ return ProductsApiFp(this.configuration).updatePremiumFormula(requestParameters.id, requestParameters.updatePremiumFormulaRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2978
+ }
2979
+
2442
2980
  /**
2443
2981
  * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
2444
2982
  * @summary Update the product
@@ -2451,6 +2989,30 @@ export class ProductsApi extends BaseAPI {
2451
2989
  return ProductsApiFp(this.configuration).updateProduct(requestParameters.id, requestParameters.updateProductRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2452
2990
  }
2453
2991
 
2992
+ /**
2993
+ * Updates the specified product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
2994
+ * @summary Update the product
2995
+ * @param {ProductsApiUpdateProductFieldRequest} requestParameters Request parameters.
2996
+ * @param {*} [options] Override http request option.
2997
+ * @throws {RequiredError}
2998
+ * @memberof ProductsApi
2999
+ */
3000
+ public updateProductField(requestParameters: ProductsApiUpdateProductFieldRequest, options?: AxiosRequestConfig) {
3001
+ return ProductsApiFp(this.configuration).updateProductField(requestParameters.id, requestParameters.updateProductFieldRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
3002
+ }
3003
+
3004
+ /**
3005
+ * Updates the specified product version by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
3006
+ * @summary Update the product version
3007
+ * @param {ProductsApiUpdateProductVersionRequest} requestParameters Request parameters.
3008
+ * @param {*} [options] Override http request option.
3009
+ * @throws {RequiredError}
3010
+ * @memberof ProductsApi
3011
+ */
3012
+ public updateProductVersion(requestParameters: ProductsApiUpdateProductVersionRequest, options?: AxiosRequestConfig) {
3013
+ return ProductsApiFp(this.configuration).updateProductVersion(requestParameters.id, requestParameters.updateProductVersionRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
3014
+ }
3015
+
2454
3016
  /**
2455
3017
  * Validate a CSV file containing all product factors. The columns must be in the following order: group,label,key,name,value.
2456
3018
  * @summary Validate product factors