@cosmotech/api-ts 2.0.13-dev → 2.3.9

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/dist/api.js CHANGED
@@ -2,10 +2,10 @@
2
2
  /* tslint:disable */
3
3
  /* eslint-disable */
4
4
  /**
5
- * Cosmo Tech Plaform API
5
+ * Cosmo Tech Platform API
6
6
  * Cosmo Tech Platform API
7
7
  *
8
- * The version of the OpenAPI document: 2.0.13-dev
8
+ * The version of the OpenAPI document: 2.3.9
9
9
  * Contact: platform@cosmotech.com
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -73,7 +73,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
73
73
  }
74
74
  };
75
75
  Object.defineProperty(exports, "__esModule", { value: true });
76
- exports.WorkspaceApi = exports.WorkspaceApiFactory = exports.WorkspaceApiFp = exports.WorkspaceApiAxiosParamCreator = exports.ValidatorApi = exports.ValidatorApiFactory = exports.ValidatorApiFp = exports.ValidatorApiAxiosParamCreator = exports.UserApi = exports.UserApiFactory = exports.UserApiFp = exports.UserApiAxiosParamCreator = exports.SolutionApi = exports.SolutionApiFactory = exports.SolutionApiFp = exports.SolutionApiAxiosParamCreator = exports.ScenariorunApi = exports.ScenariorunApiFactory = exports.ScenariorunApiFp = exports.ScenariorunApiAxiosParamCreator = exports.ScenarioApi = exports.ScenarioApiFactory = exports.ScenarioApiFp = exports.ScenarioApiAxiosParamCreator = exports.OrganizationApi = exports.OrganizationApiFactory = exports.OrganizationApiFp = exports.OrganizationApiAxiosParamCreator = exports.DatasetApi = exports.DatasetApiFactory = exports.DatasetApiFp = exports.DatasetApiAxiosParamCreator = exports.ConnectorApi = exports.ConnectorApiFactory = exports.ConnectorApiFp = exports.ConnectorApiAxiosParamCreator = exports.ValidatorRunStateEnum = exports.UserPlatformRolesEnum = exports.ScenarioValidationStatus = exports.ScenarioRunState = exports.ScenarioRunSearchStateEnum = exports.ScenarioJobState = exports.RunTemplateStepSource = exports.RunTemplateHandlerId = exports.ConnectorIoTypesEnum = void 0;
76
+ exports.WorkspaceApi = exports.WorkspaceApiFactory = exports.WorkspaceApiFp = exports.WorkspaceApiAxiosParamCreator = exports.ValidatorApi = exports.ValidatorApiFactory = exports.ValidatorApiFp = exports.ValidatorApiAxiosParamCreator = exports.UserApi = exports.UserApiFactory = exports.UserApiFp = exports.UserApiAxiosParamCreator = exports.TwingraphApi = exports.TwingraphApiFactory = exports.TwingraphApiFp = exports.TwingraphApiAxiosParamCreator = exports.SolutionApi = exports.SolutionApiFactory = exports.SolutionApiFp = exports.SolutionApiAxiosParamCreator = exports.ScenariorunApi = exports.ScenariorunApiFactory = exports.ScenariorunApiFp = exports.ScenariorunApiAxiosParamCreator = exports.ScenarioApi = exports.ScenarioApiFactory = exports.ScenarioApiFp = exports.ScenarioApiAxiosParamCreator = exports.OrganizationApi = exports.OrganizationApiFactory = exports.OrganizationApiFp = exports.OrganizationApiAxiosParamCreator = exports.DatasetApi = exports.DatasetApiFactory = exports.DatasetApiFp = exports.DatasetApiAxiosParamCreator = exports.ConnectorApi = exports.ConnectorApiFactory = exports.ConnectorApiFp = exports.ConnectorApiAxiosParamCreator = exports.ValidatorRunStateEnum = exports.UserPlatformRolesEnum = exports.SourceInfoTypeEnum = exports.ScenarioValidationStatus = exports.ScenarioRunState = exports.ScenarioRunSearchStateEnum = exports.ScenarioJobState = exports.RunTemplateStepSource = exports.RunTemplateHandlerId = exports.ConnectorIoTypesEnum = void 0;
77
77
  var axios_1 = require("axios");
78
78
  // Some imports not used depending on template conditions
79
79
  // @ts-ignore
@@ -157,6 +157,10 @@ exports.ScenarioValidationStatus = {
157
157
  Unknown: 'Unknown',
158
158
  Validated: 'Validated'
159
159
  };
160
+ exports.SourceInfoTypeEnum = {
161
+ Adt: 'ADT',
162
+ Storage: 'Storage'
163
+ };
160
164
  exports.UserPlatformRolesEnum = {
161
165
  Admin: 'Admin',
162
166
  User: 'User',
@@ -5272,10 +5276,11 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5272
5276
  *
5273
5277
  * @summary Delete all historical ScenarioRuns in the Organization
5274
5278
  * @param {string} organizationId the Organization identifier
5279
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
5275
5280
  * @param {*} [options] Override http request option.
5276
5281
  * @throws {RequiredError}
5277
5282
  */
5278
- deleteHistoricalDataOrganization: function (organizationId, options) {
5283
+ deleteHistoricalDataOrganization: function (organizationId, deleteUnknown, options) {
5279
5284
  if (options === void 0) { options = {}; }
5280
5285
  return __awaiter(_this, void 0, void 0, function () {
5281
5286
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
@@ -5300,6 +5305,9 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5300
5305
  // authentication oAuth2AuthCode required
5301
5306
  // oauth required
5302
5307
  _a.sent();
5308
+ if (deleteUnknown !== undefined) {
5309
+ localVarQueryParameter['deleteUnknown'] = deleteUnknown;
5310
+ }
5303
5311
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
5304
5312
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
5305
5313
  localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
@@ -5313,13 +5321,15 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5313
5321
  },
5314
5322
  /**
5315
5323
  *
5316
- * @summary Delete all historical ScenarioRuns in the Workspace
5324
+ * @summary Delete all historical ScenarioRuns in the Scenario
5317
5325
  * @param {string} organizationId the Organization identifier
5318
5326
  * @param {string} workspaceId the Workspace identifier
5327
+ * @param {string} scenarioId the Scenario identifier
5328
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
5319
5329
  * @param {*} [options] Override http request option.
5320
5330
  * @throws {RequiredError}
5321
5331
  */
5322
- deleteHistoricalDataWorkspace: function (organizationId, workspaceId, options) {
5332
+ deleteHistoricalDataScenario: function (organizationId, workspaceId, scenarioId, deleteUnknown, options) {
5323
5333
  if (options === void 0) { options = {}; }
5324
5334
  return __awaiter(_this, void 0, void 0, function () {
5325
5335
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
@@ -5327,12 +5337,15 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5327
5337
  switch (_a.label) {
5328
5338
  case 0:
5329
5339
  // verify required parameter 'organizationId' is not null or undefined
5330
- common_1.assertParamExists('deleteHistoricalDataWorkspace', 'organizationId', organizationId);
5340
+ common_1.assertParamExists('deleteHistoricalDataScenario', 'organizationId', organizationId);
5331
5341
  // verify required parameter 'workspaceId' is not null or undefined
5332
- common_1.assertParamExists('deleteHistoricalDataWorkspace', 'workspaceId', workspaceId);
5333
- localVarPath = "/organizations/{organization_id}/workspaces/{workspace_id}/scenarioruns/historicaldata"
5342
+ common_1.assertParamExists('deleteHistoricalDataScenario', 'workspaceId', workspaceId);
5343
+ // verify required parameter 'scenarioId' is not null or undefined
5344
+ common_1.assertParamExists('deleteHistoricalDataScenario', 'scenarioId', scenarioId);
5345
+ localVarPath = "/organizations/{organization_id}/workspaces/{workspace_id}/scenarios/{scenario_id}/scenarioruns/historicaldata"
5334
5346
  .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
5335
- .replace("{" + "workspace_id" + "}", encodeURIComponent(String(workspaceId)));
5347
+ .replace("{" + "workspace_id" + "}", encodeURIComponent(String(workspaceId)))
5348
+ .replace("{" + "scenario_id" + "}", encodeURIComponent(String(scenarioId)));
5336
5349
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
5337
5350
  if (configuration) {
5338
5351
  baseOptions = configuration.baseOptions;
@@ -5347,6 +5360,9 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5347
5360
  // authentication oAuth2AuthCode required
5348
5361
  // oauth required
5349
5362
  _a.sent();
5363
+ if (deleteUnknown !== undefined) {
5364
+ localVarQueryParameter['deleteUnknown'] = deleteUnknown;
5365
+ }
5350
5366
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
5351
5367
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
5352
5368
  localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
@@ -5360,14 +5376,14 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5360
5376
  },
5361
5377
  /**
5362
5378
  *
5363
- * @summary Delete all historical ScenarioRuns for the Scenario
5379
+ * @summary Delete all historical ScenarioRuns in the Workspace
5364
5380
  * @param {string} organizationId the Organization identifier
5365
5381
  * @param {string} workspaceId the Workspace identifier
5366
- * @param {string} scenarioId the Scenario identifier
5382
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
5367
5383
  * @param {*} [options] Override http request option.
5368
5384
  * @throws {RequiredError}
5369
5385
  */
5370
- deleteHistoricalScenarioRunsByScenario: function (organizationId, workspaceId, scenarioId, options) {
5386
+ deleteHistoricalDataWorkspace: function (organizationId, workspaceId, deleteUnknown, options) {
5371
5387
  if (options === void 0) { options = {}; }
5372
5388
  return __awaiter(_this, void 0, void 0, function () {
5373
5389
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
@@ -5375,15 +5391,12 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5375
5391
  switch (_a.label) {
5376
5392
  case 0:
5377
5393
  // verify required parameter 'organizationId' is not null or undefined
5378
- common_1.assertParamExists('deleteHistoricalScenarioRunsByScenario', 'organizationId', organizationId);
5394
+ common_1.assertParamExists('deleteHistoricalDataWorkspace', 'organizationId', organizationId);
5379
5395
  // verify required parameter 'workspaceId' is not null or undefined
5380
- common_1.assertParamExists('deleteHistoricalScenarioRunsByScenario', 'workspaceId', workspaceId);
5381
- // verify required parameter 'scenarioId' is not null or undefined
5382
- common_1.assertParamExists('deleteHistoricalScenarioRunsByScenario', 'scenarioId', scenarioId);
5383
- localVarPath = "/organizations/{organization_id}/workspaces/{workspace_id}/scenarios/{scenario_id}/scenarioruns"
5396
+ common_1.assertParamExists('deleteHistoricalDataWorkspace', 'workspaceId', workspaceId);
5397
+ localVarPath = "/organizations/{organization_id}/workspaces/{workspace_id}/scenarioruns/historicaldata"
5384
5398
  .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
5385
- .replace("{" + "workspace_id" + "}", encodeURIComponent(String(workspaceId)))
5386
- .replace("{" + "scenario_id" + "}", encodeURIComponent(String(scenarioId)));
5399
+ .replace("{" + "workspace_id" + "}", encodeURIComponent(String(workspaceId)));
5387
5400
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
5388
5401
  if (configuration) {
5389
5402
  baseOptions = configuration.baseOptions;
@@ -5398,6 +5411,9 @@ exports.ScenariorunApiAxiosParamCreator = function (configuration) {
5398
5411
  // authentication oAuth2AuthCode required
5399
5412
  // oauth required
5400
5413
  _a.sent();
5414
+ if (deleteUnknown !== undefined) {
5415
+ localVarQueryParameter['deleteUnknown'] = deleteUnknown;
5416
+ }
5401
5417
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
5402
5418
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
5403
5419
  localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
@@ -5949,15 +5965,16 @@ exports.ScenariorunApiFp = function (configuration) {
5949
5965
  *
5950
5966
  * @summary Delete all historical ScenarioRuns in the Organization
5951
5967
  * @param {string} organizationId the Organization identifier
5968
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
5952
5969
  * @param {*} [options] Override http request option.
5953
5970
  * @throws {RequiredError}
5954
5971
  */
5955
- deleteHistoricalDataOrganization: function (organizationId, options) {
5972
+ deleteHistoricalDataOrganization: function (organizationId, deleteUnknown, options) {
5956
5973
  return __awaiter(this, void 0, void 0, function () {
5957
5974
  var localVarAxiosArgs;
5958
5975
  return __generator(this, function (_a) {
5959
5976
  switch (_a.label) {
5960
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteHistoricalDataOrganization(organizationId, options)];
5977
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteHistoricalDataOrganization(organizationId, deleteUnknown, options)];
5961
5978
  case 1:
5962
5979
  localVarAxiosArgs = _a.sent();
5963
5980
  return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
@@ -5967,18 +5984,20 @@ exports.ScenariorunApiFp = function (configuration) {
5967
5984
  },
5968
5985
  /**
5969
5986
  *
5970
- * @summary Delete all historical ScenarioRuns in the Workspace
5987
+ * @summary Delete all historical ScenarioRuns in the Scenario
5971
5988
  * @param {string} organizationId the Organization identifier
5972
5989
  * @param {string} workspaceId the Workspace identifier
5990
+ * @param {string} scenarioId the Scenario identifier
5991
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
5973
5992
  * @param {*} [options] Override http request option.
5974
5993
  * @throws {RequiredError}
5975
5994
  */
5976
- deleteHistoricalDataWorkspace: function (organizationId, workspaceId, options) {
5995
+ deleteHistoricalDataScenario: function (organizationId, workspaceId, scenarioId, deleteUnknown, options) {
5977
5996
  return __awaiter(this, void 0, void 0, function () {
5978
5997
  var localVarAxiosArgs;
5979
5998
  return __generator(this, function (_a) {
5980
5999
  switch (_a.label) {
5981
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteHistoricalDataWorkspace(organizationId, workspaceId, options)];
6000
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteHistoricalDataScenario(organizationId, workspaceId, scenarioId, deleteUnknown, options)];
5982
6001
  case 1:
5983
6002
  localVarAxiosArgs = _a.sent();
5984
6003
  return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
@@ -5988,19 +6007,19 @@ exports.ScenariorunApiFp = function (configuration) {
5988
6007
  },
5989
6008
  /**
5990
6009
  *
5991
- * @summary Delete all historical ScenarioRuns for the Scenario
6010
+ * @summary Delete all historical ScenarioRuns in the Workspace
5992
6011
  * @param {string} organizationId the Organization identifier
5993
6012
  * @param {string} workspaceId the Workspace identifier
5994
- * @param {string} scenarioId the Scenario identifier
6013
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
5995
6014
  * @param {*} [options] Override http request option.
5996
6015
  * @throws {RequiredError}
5997
6016
  */
5998
- deleteHistoricalScenarioRunsByScenario: function (organizationId, workspaceId, scenarioId, options) {
6017
+ deleteHistoricalDataWorkspace: function (organizationId, workspaceId, deleteUnknown, options) {
5999
6018
  return __awaiter(this, void 0, void 0, function () {
6000
6019
  var localVarAxiosArgs;
6001
6020
  return __generator(this, function (_a) {
6002
6021
  switch (_a.label) {
6003
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteHistoricalScenarioRunsByScenario(organizationId, workspaceId, scenarioId, options)];
6022
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteHistoricalDataWorkspace(organizationId, workspaceId, deleteUnknown, options)];
6004
6023
  case 1:
6005
6024
  localVarAxiosArgs = _a.sent();
6006
6025
  return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
@@ -6254,34 +6273,37 @@ exports.ScenariorunApiFactory = function (configuration, basePath, axios) {
6254
6273
  *
6255
6274
  * @summary Delete all historical ScenarioRuns in the Organization
6256
6275
  * @param {string} organizationId the Organization identifier
6276
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
6257
6277
  * @param {*} [options] Override http request option.
6258
6278
  * @throws {RequiredError}
6259
6279
  */
6260
- deleteHistoricalDataOrganization: function (organizationId, options) {
6261
- return localVarFp.deleteHistoricalDataOrganization(organizationId, options).then(function (request) { return request(axios, basePath); });
6280
+ deleteHistoricalDataOrganization: function (organizationId, deleteUnknown, options) {
6281
+ return localVarFp.deleteHistoricalDataOrganization(organizationId, deleteUnknown, options).then(function (request) { return request(axios, basePath); });
6262
6282
  },
6263
6283
  /**
6264
6284
  *
6265
- * @summary Delete all historical ScenarioRuns in the Workspace
6285
+ * @summary Delete all historical ScenarioRuns in the Scenario
6266
6286
  * @param {string} organizationId the Organization identifier
6267
6287
  * @param {string} workspaceId the Workspace identifier
6288
+ * @param {string} scenarioId the Scenario identifier
6289
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
6268
6290
  * @param {*} [options] Override http request option.
6269
6291
  * @throws {RequiredError}
6270
6292
  */
6271
- deleteHistoricalDataWorkspace: function (organizationId, workspaceId, options) {
6272
- return localVarFp.deleteHistoricalDataWorkspace(organizationId, workspaceId, options).then(function (request) { return request(axios, basePath); });
6293
+ deleteHistoricalDataScenario: function (organizationId, workspaceId, scenarioId, deleteUnknown, options) {
6294
+ return localVarFp.deleteHistoricalDataScenario(organizationId, workspaceId, scenarioId, deleteUnknown, options).then(function (request) { return request(axios, basePath); });
6273
6295
  },
6274
6296
  /**
6275
6297
  *
6276
- * @summary Delete all historical ScenarioRuns for the Scenario
6298
+ * @summary Delete all historical ScenarioRuns in the Workspace
6277
6299
  * @param {string} organizationId the Organization identifier
6278
6300
  * @param {string} workspaceId the Workspace identifier
6279
- * @param {string} scenarioId the Scenario identifier
6301
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
6280
6302
  * @param {*} [options] Override http request option.
6281
6303
  * @throws {RequiredError}
6282
6304
  */
6283
- deleteHistoricalScenarioRunsByScenario: function (organizationId, workspaceId, scenarioId, options) {
6284
- return localVarFp.deleteHistoricalScenarioRunsByScenario(organizationId, workspaceId, scenarioId, options).then(function (request) { return request(axios, basePath); });
6305
+ deleteHistoricalDataWorkspace: function (organizationId, workspaceId, deleteUnknown, options) {
6306
+ return localVarFp.deleteHistoricalDataWorkspace(organizationId, workspaceId, deleteUnknown, options).then(function (request) { return request(axios, basePath); });
6285
6307
  },
6286
6308
  /**
6287
6309
  *
@@ -6423,40 +6445,43 @@ var ScenariorunApi = /** @class */ (function (_super) {
6423
6445
  *
6424
6446
  * @summary Delete all historical ScenarioRuns in the Organization
6425
6447
  * @param {string} organizationId the Organization identifier
6448
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
6426
6449
  * @param {*} [options] Override http request option.
6427
6450
  * @throws {RequiredError}
6428
6451
  * @memberof ScenariorunApi
6429
6452
  */
6430
- ScenariorunApi.prototype.deleteHistoricalDataOrganization = function (organizationId, options) {
6453
+ ScenariorunApi.prototype.deleteHistoricalDataOrganization = function (organizationId, deleteUnknown, options) {
6431
6454
  var _this = this;
6432
- return exports.ScenariorunApiFp(this.configuration).deleteHistoricalDataOrganization(organizationId, options).then(function (request) { return request(_this.axios, _this.basePath); });
6455
+ return exports.ScenariorunApiFp(this.configuration).deleteHistoricalDataOrganization(organizationId, deleteUnknown, options).then(function (request) { return request(_this.axios, _this.basePath); });
6433
6456
  };
6434
6457
  /**
6435
6458
  *
6436
- * @summary Delete all historical ScenarioRuns in the Workspace
6459
+ * @summary Delete all historical ScenarioRuns in the Scenario
6437
6460
  * @param {string} organizationId the Organization identifier
6438
6461
  * @param {string} workspaceId the Workspace identifier
6462
+ * @param {string} scenarioId the Scenario identifier
6463
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
6439
6464
  * @param {*} [options] Override http request option.
6440
6465
  * @throws {RequiredError}
6441
6466
  * @memberof ScenariorunApi
6442
6467
  */
6443
- ScenariorunApi.prototype.deleteHistoricalDataWorkspace = function (organizationId, workspaceId, options) {
6468
+ ScenariorunApi.prototype.deleteHistoricalDataScenario = function (organizationId, workspaceId, scenarioId, deleteUnknown, options) {
6444
6469
  var _this = this;
6445
- return exports.ScenariorunApiFp(this.configuration).deleteHistoricalDataWorkspace(organizationId, workspaceId, options).then(function (request) { return request(_this.axios, _this.basePath); });
6470
+ return exports.ScenariorunApiFp(this.configuration).deleteHistoricalDataScenario(organizationId, workspaceId, scenarioId, deleteUnknown, options).then(function (request) { return request(_this.axios, _this.basePath); });
6446
6471
  };
6447
6472
  /**
6448
6473
  *
6449
- * @summary Delete all historical ScenarioRuns for the Scenario
6474
+ * @summary Delete all historical ScenarioRuns in the Workspace
6450
6475
  * @param {string} organizationId the Organization identifier
6451
6476
  * @param {string} workspaceId the Workspace identifier
6452
- * @param {string} scenarioId the Scenario identifier
6477
+ * @param {boolean} [deleteUnknown] condition to delete runs with an Unknown status
6453
6478
  * @param {*} [options] Override http request option.
6454
6479
  * @throws {RequiredError}
6455
6480
  * @memberof ScenariorunApi
6456
6481
  */
6457
- ScenariorunApi.prototype.deleteHistoricalScenarioRunsByScenario = function (organizationId, workspaceId, scenarioId, options) {
6482
+ ScenariorunApi.prototype.deleteHistoricalDataWorkspace = function (organizationId, workspaceId, deleteUnknown, options) {
6458
6483
  var _this = this;
6459
- return exports.ScenariorunApiFp(this.configuration).deleteHistoricalScenarioRunsByScenario(organizationId, workspaceId, scenarioId, options).then(function (request) { return request(_this.axios, _this.basePath); });
6484
+ return exports.ScenariorunApiFp(this.configuration).deleteHistoricalDataWorkspace(organizationId, workspaceId, deleteUnknown, options).then(function (request) { return request(_this.axios, _this.basePath); });
6460
6485
  };
6461
6486
  /**
6462
6487
  *
@@ -8119,31 +8144,38 @@ var SolutionApi = /** @class */ (function (_super) {
8119
8144
  }(base_1.BaseAPI));
8120
8145
  exports.SolutionApi = SolutionApi;
8121
8146
  /**
8122
- * UserApi - axios parameter creator
8147
+ * TwingraphApi - axios parameter creator
8123
8148
  * @export
8124
8149
  */
8125
- exports.UserApiAxiosParamCreator = function (configuration) {
8150
+ exports.TwingraphApiAxiosParamCreator = function (configuration) {
8126
8151
  var _this = this;
8127
8152
  return {
8128
8153
  /**
8129
- *
8130
- * @summary Authorize an User with OAuth2. Delegated to configured OAuth2 service
8154
+ * Launch a mass delete job
8155
+ * @param {string} organizationId the Organization identifier
8156
+ * @param {string} graphId the Graph Identifier
8131
8157
  * @param {*} [options] Override http request option.
8132
8158
  * @throws {RequiredError}
8133
8159
  */
8134
- authorizeUser: function (options) {
8160
+ _delete: function (organizationId, graphId, options) {
8135
8161
  if (options === void 0) { options = {}; }
8136
8162
  return __awaiter(_this, void 0, void 0, function () {
8137
8163
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8138
8164
  return __generator(this, function (_a) {
8139
8165
  switch (_a.label) {
8140
8166
  case 0:
8141
- localVarPath = "/oauth2/authorize";
8167
+ // verify required parameter 'organizationId' is not null or undefined
8168
+ common_1.assertParamExists('_delete', 'organizationId', organizationId);
8169
+ // verify required parameter 'graphId' is not null or undefined
8170
+ common_1.assertParamExists('_delete', 'graphId', graphId);
8171
+ localVarPath = "/organizations/{organization_id}/twingraph/{graph_id}"
8172
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
8173
+ .replace("{" + "graph_id" + "}", encodeURIComponent(String(graphId)));
8142
8174
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8143
8175
  if (configuration) {
8144
8176
  baseOptions = configuration.baseOptions;
8145
8177
  }
8146
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8178
+ localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
8147
8179
  localVarHeaderParameter = {};
8148
8180
  localVarQueryParameter = {};
8149
8181
  // authentication oAuth2AuthCode required
@@ -8165,19 +8197,22 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8165
8197
  });
8166
8198
  },
8167
8199
  /**
8168
- *
8169
- * @summary List all Users
8200
+ * Return the list of all graphs stored in the organization
8201
+ * @param {string} organizationId the Organization identifier
8170
8202
  * @param {*} [options] Override http request option.
8171
8203
  * @throws {RequiredError}
8172
8204
  */
8173
- findAllUsers: function (options) {
8205
+ findAllTwingraphs: function (organizationId, options) {
8174
8206
  if (options === void 0) { options = {}; }
8175
8207
  return __awaiter(_this, void 0, void 0, function () {
8176
8208
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8177
8209
  return __generator(this, function (_a) {
8178
8210
  switch (_a.label) {
8179
8211
  case 0:
8180
- localVarPath = "/users";
8212
+ // verify required parameter 'organizationId' is not null or undefined
8213
+ common_1.assertParamExists('findAllTwingraphs', 'organizationId', organizationId);
8214
+ localVarPath = "/organizations/{organization_id}/twingraphs"
8215
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)));
8181
8216
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8182
8217
  if (configuration) {
8183
8218
  baseOptions = configuration.baseOptions;
@@ -8204,23 +8239,26 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8204
8239
  });
8205
8240
  },
8206
8241
  /**
8207
- *
8208
- * @summary Get the details of an user
8209
- * @param {string} userId the User identifier
8242
+ * Return the metaData of the specified graph
8243
+ * @param {string} organizationId the Organization identifier
8244
+ * @param {string} graphId the Graph Identifier
8210
8245
  * @param {*} [options] Override http request option.
8211
8246
  * @throws {RequiredError}
8212
8247
  */
8213
- findUserById: function (userId, options) {
8248
+ getGraphMetaData: function (organizationId, graphId, options) {
8214
8249
  if (options === void 0) { options = {}; }
8215
8250
  return __awaiter(_this, void 0, void 0, function () {
8216
8251
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8217
8252
  return __generator(this, function (_a) {
8218
8253
  switch (_a.label) {
8219
8254
  case 0:
8220
- // verify required parameter 'userId' is not null or undefined
8221
- common_1.assertParamExists('findUserById', 'userId', userId);
8222
- localVarPath = "/users/{user_id}"
8223
- .replace("{" + "user_id" + "}", encodeURIComponent(String(userId)));
8255
+ // verify required parameter 'organizationId' is not null or undefined
8256
+ common_1.assertParamExists('getGraphMetaData', 'organizationId', organizationId);
8257
+ // verify required parameter 'graphId' is not null or undefined
8258
+ common_1.assertParamExists('getGraphMetaData', 'graphId', graphId);
8259
+ localVarPath = "/organizations/{organization_id}/twingraph/{graph_id}/metadata"
8260
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
8261
+ .replace("{" + "graph_id" + "}", encodeURIComponent(String(graphId)));
8224
8262
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8225
8263
  if (configuration) {
8226
8264
  baseOptions = configuration.baseOptions;
@@ -8247,24 +8285,30 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8247
8285
  });
8248
8286
  },
8249
8287
  /**
8250
- *
8251
- * @summary Get the details of the logged-in User
8288
+ * Import a new version of a twin graph
8289
+ * @param {string} organizationId the Organization identifier
8290
+ * @param {TwinGraphImport} twinGraphImport the graph to import
8252
8291
  * @param {*} [options] Override http request option.
8253
8292
  * @throws {RequiredError}
8254
8293
  */
8255
- getCurrentUser: function (options) {
8294
+ importGraph: function (organizationId, twinGraphImport, options) {
8256
8295
  if (options === void 0) { options = {}; }
8257
8296
  return __awaiter(_this, void 0, void 0, function () {
8258
8297
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8259
8298
  return __generator(this, function (_a) {
8260
8299
  switch (_a.label) {
8261
8300
  case 0:
8262
- localVarPath = "/users/me";
8301
+ // verify required parameter 'organizationId' is not null or undefined
8302
+ common_1.assertParamExists('importGraph', 'organizationId', organizationId);
8303
+ // verify required parameter 'twinGraphImport' is not null or undefined
8304
+ common_1.assertParamExists('importGraph', 'twinGraphImport', twinGraphImport);
8305
+ localVarPath = "/organizations/{organization_id}/twingraph/import"
8306
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)));
8263
8307
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8264
8308
  if (configuration) {
8265
8309
  baseOptions = configuration.baseOptions;
8266
8310
  }
8267
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8311
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
8268
8312
  localVarHeaderParameter = {};
8269
8313
  localVarQueryParameter = {};
8270
8314
  // authentication oAuth2AuthCode required
@@ -8274,9 +8318,11 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8274
8318
  // authentication oAuth2AuthCode required
8275
8319
  // oauth required
8276
8320
  _a.sent();
8321
+ localVarHeaderParameter['Content-Type'] = 'application/json';
8277
8322
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8278
8323
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8279
8324
  localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8325
+ localVarRequestOptions.data = common_1.serializeDataIfNeeded(twinGraphImport, localVarRequestOptions, configuration);
8280
8326
  return [2 /*return*/, {
8281
8327
  url: common_1.toPathString(localVarUrlObj),
8282
8328
  options: localVarRequestOptions,
@@ -8286,13 +8332,13 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8286
8332
  });
8287
8333
  },
8288
8334
  /**
8289
- *
8290
- * @summary Get the details of a logged-in User with roles for an Organization
8335
+ * Get the status of a job
8291
8336
  * @param {string} organizationId the Organization identifier
8337
+ * @param {string} jobId the job identifier
8292
8338
  * @param {*} [options] Override http request option.
8293
8339
  * @throws {RequiredError}
8294
8340
  */
8295
- getOrganizationCurrentUser: function (organizationId, options) {
8341
+ jobStatus: function (organizationId, jobId, options) {
8296
8342
  if (options === void 0) { options = {}; }
8297
8343
  return __awaiter(_this, void 0, void 0, function () {
8298
8344
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
@@ -8300,9 +8346,12 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8300
8346
  switch (_a.label) {
8301
8347
  case 0:
8302
8348
  // verify required parameter 'organizationId' is not null or undefined
8303
- common_1.assertParamExists('getOrganizationCurrentUser', 'organizationId', organizationId);
8304
- localVarPath = "/organizations/{organization_id}/me"
8305
- .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)));
8349
+ common_1.assertParamExists('jobStatus', 'organizationId', organizationId);
8350
+ // verify required parameter 'jobId' is not null or undefined
8351
+ common_1.assertParamExists('jobStatus', 'jobId', jobId);
8352
+ localVarPath = "/organizations/{organization_id}/job/{job_id}/status"
8353
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
8354
+ .replace("{" + "job_id" + "}", encodeURIComponent(String(jobId)));
8306
8355
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8307
8356
  if (configuration) {
8308
8357
  baseOptions = configuration.baseOptions;
@@ -8329,14 +8378,14 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8329
8378
  });
8330
8379
  },
8331
8380
  /**
8332
- *
8333
- * @summary Get the details of the logged-in user with roles for a Workspace
8381
+ * Run a query on a graph instance
8334
8382
  * @param {string} organizationId the Organization identifier
8335
- * @param {string} workspaceId the Workspace identifier
8383
+ * @param {string} graphId the Graph Identifier
8384
+ * @param {TwinGraphQuery} twinGraphQuery the query to run
8336
8385
  * @param {*} [options] Override http request option.
8337
8386
  * @throws {RequiredError}
8338
8387
  */
8339
- getWorkspaceCurrentUser: function (organizationId, workspaceId, options) {
8388
+ query: function (organizationId, graphId, twinGraphQuery, options) {
8340
8389
  if (options === void 0) { options = {}; }
8341
8390
  return __awaiter(_this, void 0, void 0, function () {
8342
8391
  var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
@@ -8344,17 +8393,19 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8344
8393
  switch (_a.label) {
8345
8394
  case 0:
8346
8395
  // verify required parameter 'organizationId' is not null or undefined
8347
- common_1.assertParamExists('getWorkspaceCurrentUser', 'organizationId', organizationId);
8348
- // verify required parameter 'workspaceId' is not null or undefined
8349
- common_1.assertParamExists('getWorkspaceCurrentUser', 'workspaceId', workspaceId);
8350
- localVarPath = "/organizations/{organization_id}/workspaces/{workspace_id}/me"
8396
+ common_1.assertParamExists('query', 'organizationId', organizationId);
8397
+ // verify required parameter 'graphId' is not null or undefined
8398
+ common_1.assertParamExists('query', 'graphId', graphId);
8399
+ // verify required parameter 'twinGraphQuery' is not null or undefined
8400
+ common_1.assertParamExists('query', 'twinGraphQuery', twinGraphQuery);
8401
+ localVarPath = "/organizations/{organization_id}/twingraph/{graph_id}/query"
8351
8402
  .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
8352
- .replace("{" + "workspace_id" + "}", encodeURIComponent(String(workspaceId)));
8403
+ .replace("{" + "graph_id" + "}", encodeURIComponent(String(graphId)));
8353
8404
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8354
8405
  if (configuration) {
8355
8406
  baseOptions = configuration.baseOptions;
8356
8407
  }
8357
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8408
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
8358
8409
  localVarHeaderParameter = {};
8359
8410
  localVarQueryParameter = {};
8360
8411
  // authentication oAuth2AuthCode required
@@ -8364,9 +8415,11 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8364
8415
  // authentication oAuth2AuthCode required
8365
8416
  // oauth required
8366
8417
  _a.sent();
8418
+ localVarHeaderParameter['Content-Type'] = 'application/json';
8367
8419
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8368
8420
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8369
8421
  localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8422
+ localVarRequestOptions.data = common_1.serializeDataIfNeeded(twinGraphQuery, localVarRequestOptions, configuration);
8370
8423
  return [2 /*return*/, {
8371
8424
  url: common_1.toPathString(localVarUrlObj),
8372
8425
  options: localVarRequestOptions,
@@ -8375,186 +8428,729 @@ exports.UserApiAxiosParamCreator = function (configuration) {
8375
8428
  });
8376
8429
  });
8377
8430
  },
8431
+ };
8432
+ };
8433
+ /**
8434
+ * TwingraphApi - functional programming interface
8435
+ * @export
8436
+ */
8437
+ exports.TwingraphApiFp = function (configuration) {
8438
+ var localVarAxiosParamCreator = exports.TwingraphApiAxiosParamCreator(configuration);
8439
+ return {
8378
8440
  /**
8379
- *
8380
- * @summary Register a new user
8381
- * @param {User} user the User to register
8441
+ * Launch a mass delete job
8442
+ * @param {string} organizationId the Organization identifier
8443
+ * @param {string} graphId the Graph Identifier
8382
8444
  * @param {*} [options] Override http request option.
8383
8445
  * @throws {RequiredError}
8384
8446
  */
8385
- registerUser: function (user, options) {
8386
- if (options === void 0) { options = {}; }
8387
- return __awaiter(_this, void 0, void 0, function () {
8388
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8447
+ _delete: function (organizationId, graphId, options) {
8448
+ return __awaiter(this, void 0, void 0, function () {
8449
+ var localVarAxiosArgs;
8389
8450
  return __generator(this, function (_a) {
8390
8451
  switch (_a.label) {
8391
- case 0:
8392
- // verify required parameter 'user' is not null or undefined
8393
- common_1.assertParamExists('registerUser', 'user', user);
8394
- localVarPath = "/users";
8395
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8396
- if (configuration) {
8397
- baseOptions = configuration.baseOptions;
8398
- }
8399
- localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
8400
- localVarHeaderParameter = {};
8401
- localVarQueryParameter = {};
8402
- // authentication oAuth2AuthCode required
8403
- // oauth required
8404
- return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8452
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator._delete(organizationId, graphId, options)];
8405
8453
  case 1:
8406
- // authentication oAuth2AuthCode required
8407
- // oauth required
8408
- _a.sent();
8409
- localVarHeaderParameter['Content-Type'] = 'application/json';
8410
- common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8411
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8412
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8413
- localVarRequestOptions.data = common_1.serializeDataIfNeeded(user, localVarRequestOptions, configuration);
8414
- return [2 /*return*/, {
8415
- url: common_1.toPathString(localVarUrlObj),
8416
- options: localVarRequestOptions,
8417
- }];
8454
+ localVarAxiosArgs = _a.sent();
8455
+ return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
8418
8456
  }
8419
8457
  });
8420
8458
  });
8421
8459
  },
8422
8460
  /**
8423
- *
8424
- * @summary test platform API call
8461
+ * Return the list of all graphs stored in the organization
8462
+ * @param {string} organizationId the Organization identifier
8425
8463
  * @param {*} [options] Override http request option.
8426
8464
  * @throws {RequiredError}
8427
8465
  */
8428
- testPlatform: function (options) {
8429
- if (options === void 0) { options = {}; }
8430
- return __awaiter(_this, void 0, void 0, function () {
8431
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8466
+ findAllTwingraphs: function (organizationId, options) {
8467
+ return __awaiter(this, void 0, void 0, function () {
8468
+ var localVarAxiosArgs;
8432
8469
  return __generator(this, function (_a) {
8433
8470
  switch (_a.label) {
8434
- case 0:
8435
- localVarPath = "/test";
8436
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8437
- if (configuration) {
8438
- baseOptions = configuration.baseOptions;
8439
- }
8440
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8441
- localVarHeaderParameter = {};
8442
- localVarQueryParameter = {};
8443
- // authentication oAuth2AuthCode required
8444
- // oauth required
8445
- return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8471
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.findAllTwingraphs(organizationId, options)];
8446
8472
  case 1:
8447
- // authentication oAuth2AuthCode required
8448
- // oauth required
8449
- _a.sent();
8450
- common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8451
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8452
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8453
- return [2 /*return*/, {
8454
- url: common_1.toPathString(localVarUrlObj),
8455
- options: localVarRequestOptions,
8456
- }];
8473
+ localVarAxiosArgs = _a.sent();
8474
+ return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
8457
8475
  }
8458
8476
  });
8459
8477
  });
8460
8478
  },
8461
8479
  /**
8462
- *
8463
- * @summary Unregister an user
8464
- * @param {string} userId the User identifier
8480
+ * Return the metaData of the specified graph
8481
+ * @param {string} organizationId the Organization identifier
8482
+ * @param {string} graphId the Graph Identifier
8465
8483
  * @param {*} [options] Override http request option.
8466
8484
  * @throws {RequiredError}
8467
8485
  */
8468
- unregisterUser: function (userId, options) {
8469
- if (options === void 0) { options = {}; }
8470
- return __awaiter(_this, void 0, void 0, function () {
8471
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8486
+ getGraphMetaData: function (organizationId, graphId, options) {
8487
+ return __awaiter(this, void 0, void 0, function () {
8488
+ var localVarAxiosArgs;
8472
8489
  return __generator(this, function (_a) {
8473
8490
  switch (_a.label) {
8474
- case 0:
8475
- // verify required parameter 'userId' is not null or undefined
8476
- common_1.assertParamExists('unregisterUser', 'userId', userId);
8477
- localVarPath = "/users/{user_id}"
8478
- .replace("{" + "user_id" + "}", encodeURIComponent(String(userId)));
8479
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8480
- if (configuration) {
8481
- baseOptions = configuration.baseOptions;
8482
- }
8483
- localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
8484
- localVarHeaderParameter = {};
8485
- localVarQueryParameter = {};
8486
- // authentication oAuth2AuthCode required
8487
- // oauth required
8488
- return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8491
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.getGraphMetaData(organizationId, graphId, options)];
8489
8492
  case 1:
8490
- // authentication oAuth2AuthCode required
8491
- // oauth required
8492
- _a.sent();
8493
- common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8494
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8495
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8496
- return [2 /*return*/, {
8497
- url: common_1.toPathString(localVarUrlObj),
8498
- options: localVarRequestOptions,
8499
- }];
8493
+ localVarAxiosArgs = _a.sent();
8494
+ return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
8500
8495
  }
8501
8496
  });
8502
8497
  });
8503
8498
  },
8504
8499
  /**
8505
- *
8506
- * @summary Update a User
8507
- * @param {string} userId the User identifier
8508
- * @param {User} user the new User details. Organization membership is handled via the /organizations endpoint.
8500
+ * Import a new version of a twin graph
8501
+ * @param {string} organizationId the Organization identifier
8502
+ * @param {TwinGraphImport} twinGraphImport the graph to import
8509
8503
  * @param {*} [options] Override http request option.
8510
8504
  * @throws {RequiredError}
8511
8505
  */
8512
- updateUser: function (userId, user, options) {
8513
- if (options === void 0) { options = {}; }
8514
- return __awaiter(_this, void 0, void 0, function () {
8515
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8506
+ importGraph: function (organizationId, twinGraphImport, options) {
8507
+ return __awaiter(this, void 0, void 0, function () {
8508
+ var localVarAxiosArgs;
8516
8509
  return __generator(this, function (_a) {
8517
8510
  switch (_a.label) {
8518
- case 0:
8519
- // verify required parameter 'userId' is not null or undefined
8520
- common_1.assertParamExists('updateUser', 'userId', userId);
8521
- // verify required parameter 'user' is not null or undefined
8522
- common_1.assertParamExists('updateUser', 'user', user);
8523
- localVarPath = "/users/{user_id}"
8524
- .replace("{" + "user_id" + "}", encodeURIComponent(String(userId)));
8525
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8526
- if (configuration) {
8527
- baseOptions = configuration.baseOptions;
8528
- }
8529
- localVarRequestOptions = __assign(__assign({ method: 'PATCH' }, baseOptions), options);
8530
- localVarHeaderParameter = {};
8531
- localVarQueryParameter = {};
8532
- // authentication oAuth2AuthCode required
8533
- // oauth required
8534
- return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8511
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.importGraph(organizationId, twinGraphImport, options)];
8535
8512
  case 1:
8536
- // authentication oAuth2AuthCode required
8537
- // oauth required
8538
- _a.sent();
8539
- localVarHeaderParameter['Content-Type'] = 'application/json';
8540
- common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8541
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8542
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8543
- localVarRequestOptions.data = common_1.serializeDataIfNeeded(user, localVarRequestOptions, configuration);
8544
- return [2 /*return*/, {
8545
- url: common_1.toPathString(localVarUrlObj),
8546
- options: localVarRequestOptions,
8547
- }];
8513
+ localVarAxiosArgs = _a.sent();
8514
+ return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
8548
8515
  }
8549
8516
  });
8550
8517
  });
8551
8518
  },
8552
- };
8553
- };
8554
- /**
8555
- * UserApi - functional programming interface
8556
- * @export
8557
- */
8519
+ /**
8520
+ * Get the status of a job
8521
+ * @param {string} organizationId the Organization identifier
8522
+ * @param {string} jobId the job identifier
8523
+ * @param {*} [options] Override http request option.
8524
+ * @throws {RequiredError}
8525
+ */
8526
+ jobStatus: function (organizationId, jobId, options) {
8527
+ return __awaiter(this, void 0, void 0, function () {
8528
+ var localVarAxiosArgs;
8529
+ return __generator(this, function (_a) {
8530
+ switch (_a.label) {
8531
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.jobStatus(organizationId, jobId, options)];
8532
+ case 1:
8533
+ localVarAxiosArgs = _a.sent();
8534
+ return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
8535
+ }
8536
+ });
8537
+ });
8538
+ },
8539
+ /**
8540
+ * Run a query on a graph instance
8541
+ * @param {string} organizationId the Organization identifier
8542
+ * @param {string} graphId the Graph Identifier
8543
+ * @param {TwinGraphQuery} twinGraphQuery the query to run
8544
+ * @param {*} [options] Override http request option.
8545
+ * @throws {RequiredError}
8546
+ */
8547
+ query: function (organizationId, graphId, twinGraphQuery, options) {
8548
+ return __awaiter(this, void 0, void 0, function () {
8549
+ var localVarAxiosArgs;
8550
+ return __generator(this, function (_a) {
8551
+ switch (_a.label) {
8552
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.query(organizationId, graphId, twinGraphQuery, options)];
8553
+ case 1:
8554
+ localVarAxiosArgs = _a.sent();
8555
+ return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
8556
+ }
8557
+ });
8558
+ });
8559
+ },
8560
+ };
8561
+ };
8562
+ /**
8563
+ * TwingraphApi - factory interface
8564
+ * @export
8565
+ */
8566
+ exports.TwingraphApiFactory = function (configuration, basePath, axios) {
8567
+ var localVarFp = exports.TwingraphApiFp(configuration);
8568
+ return {
8569
+ /**
8570
+ * Launch a mass delete job
8571
+ * @param {string} organizationId the Organization identifier
8572
+ * @param {string} graphId the Graph Identifier
8573
+ * @param {*} [options] Override http request option.
8574
+ * @throws {RequiredError}
8575
+ */
8576
+ _delete: function (organizationId, graphId, options) {
8577
+ return localVarFp._delete(organizationId, graphId, options).then(function (request) { return request(axios, basePath); });
8578
+ },
8579
+ /**
8580
+ * Return the list of all graphs stored in the organization
8581
+ * @param {string} organizationId the Organization identifier
8582
+ * @param {*} [options] Override http request option.
8583
+ * @throws {RequiredError}
8584
+ */
8585
+ findAllTwingraphs: function (organizationId, options) {
8586
+ return localVarFp.findAllTwingraphs(organizationId, options).then(function (request) { return request(axios, basePath); });
8587
+ },
8588
+ /**
8589
+ * Return the metaData of the specified graph
8590
+ * @param {string} organizationId the Organization identifier
8591
+ * @param {string} graphId the Graph Identifier
8592
+ * @param {*} [options] Override http request option.
8593
+ * @throws {RequiredError}
8594
+ */
8595
+ getGraphMetaData: function (organizationId, graphId, options) {
8596
+ return localVarFp.getGraphMetaData(organizationId, graphId, options).then(function (request) { return request(axios, basePath); });
8597
+ },
8598
+ /**
8599
+ * Import a new version of a twin graph
8600
+ * @param {string} organizationId the Organization identifier
8601
+ * @param {TwinGraphImport} twinGraphImport the graph to import
8602
+ * @param {*} [options] Override http request option.
8603
+ * @throws {RequiredError}
8604
+ */
8605
+ importGraph: function (organizationId, twinGraphImport, options) {
8606
+ return localVarFp.importGraph(organizationId, twinGraphImport, options).then(function (request) { return request(axios, basePath); });
8607
+ },
8608
+ /**
8609
+ * Get the status of a job
8610
+ * @param {string} organizationId the Organization identifier
8611
+ * @param {string} jobId the job identifier
8612
+ * @param {*} [options] Override http request option.
8613
+ * @throws {RequiredError}
8614
+ */
8615
+ jobStatus: function (organizationId, jobId, options) {
8616
+ return localVarFp.jobStatus(organizationId, jobId, options).then(function (request) { return request(axios, basePath); });
8617
+ },
8618
+ /**
8619
+ * Run a query on a graph instance
8620
+ * @param {string} organizationId the Organization identifier
8621
+ * @param {string} graphId the Graph Identifier
8622
+ * @param {TwinGraphQuery} twinGraphQuery the query to run
8623
+ * @param {*} [options] Override http request option.
8624
+ * @throws {RequiredError}
8625
+ */
8626
+ query: function (organizationId, graphId, twinGraphQuery, options) {
8627
+ return localVarFp.query(organizationId, graphId, twinGraphQuery, options).then(function (request) { return request(axios, basePath); });
8628
+ },
8629
+ };
8630
+ };
8631
+ /**
8632
+ * TwingraphApi - object-oriented interface
8633
+ * @export
8634
+ * @class TwingraphApi
8635
+ * @extends {BaseAPI}
8636
+ */
8637
+ var TwingraphApi = /** @class */ (function (_super) {
8638
+ __extends(TwingraphApi, _super);
8639
+ function TwingraphApi() {
8640
+ return _super !== null && _super.apply(this, arguments) || this;
8641
+ }
8642
+ /**
8643
+ * Launch a mass delete job
8644
+ * @param {string} organizationId the Organization identifier
8645
+ * @param {string} graphId the Graph Identifier
8646
+ * @param {*} [options] Override http request option.
8647
+ * @throws {RequiredError}
8648
+ * @memberof TwingraphApi
8649
+ */
8650
+ TwingraphApi.prototype._delete = function (organizationId, graphId, options) {
8651
+ var _this = this;
8652
+ return exports.TwingraphApiFp(this.configuration)._delete(organizationId, graphId, options).then(function (request) { return request(_this.axios, _this.basePath); });
8653
+ };
8654
+ /**
8655
+ * Return the list of all graphs stored in the organization
8656
+ * @param {string} organizationId the Organization identifier
8657
+ * @param {*} [options] Override http request option.
8658
+ * @throws {RequiredError}
8659
+ * @memberof TwingraphApi
8660
+ */
8661
+ TwingraphApi.prototype.findAllTwingraphs = function (organizationId, options) {
8662
+ var _this = this;
8663
+ return exports.TwingraphApiFp(this.configuration).findAllTwingraphs(organizationId, options).then(function (request) { return request(_this.axios, _this.basePath); });
8664
+ };
8665
+ /**
8666
+ * Return the metaData of the specified graph
8667
+ * @param {string} organizationId the Organization identifier
8668
+ * @param {string} graphId the Graph Identifier
8669
+ * @param {*} [options] Override http request option.
8670
+ * @throws {RequiredError}
8671
+ * @memberof TwingraphApi
8672
+ */
8673
+ TwingraphApi.prototype.getGraphMetaData = function (organizationId, graphId, options) {
8674
+ var _this = this;
8675
+ return exports.TwingraphApiFp(this.configuration).getGraphMetaData(organizationId, graphId, options).then(function (request) { return request(_this.axios, _this.basePath); });
8676
+ };
8677
+ /**
8678
+ * Import a new version of a twin graph
8679
+ * @param {string} organizationId the Organization identifier
8680
+ * @param {TwinGraphImport} twinGraphImport the graph to import
8681
+ * @param {*} [options] Override http request option.
8682
+ * @throws {RequiredError}
8683
+ * @memberof TwingraphApi
8684
+ */
8685
+ TwingraphApi.prototype.importGraph = function (organizationId, twinGraphImport, options) {
8686
+ var _this = this;
8687
+ return exports.TwingraphApiFp(this.configuration).importGraph(organizationId, twinGraphImport, options).then(function (request) { return request(_this.axios, _this.basePath); });
8688
+ };
8689
+ /**
8690
+ * Get the status of a job
8691
+ * @param {string} organizationId the Organization identifier
8692
+ * @param {string} jobId the job identifier
8693
+ * @param {*} [options] Override http request option.
8694
+ * @throws {RequiredError}
8695
+ * @memberof TwingraphApi
8696
+ */
8697
+ TwingraphApi.prototype.jobStatus = function (organizationId, jobId, options) {
8698
+ var _this = this;
8699
+ return exports.TwingraphApiFp(this.configuration).jobStatus(organizationId, jobId, options).then(function (request) { return request(_this.axios, _this.basePath); });
8700
+ };
8701
+ /**
8702
+ * Run a query on a graph instance
8703
+ * @param {string} organizationId the Organization identifier
8704
+ * @param {string} graphId the Graph Identifier
8705
+ * @param {TwinGraphQuery} twinGraphQuery the query to run
8706
+ * @param {*} [options] Override http request option.
8707
+ * @throws {RequiredError}
8708
+ * @memberof TwingraphApi
8709
+ */
8710
+ TwingraphApi.prototype.query = function (organizationId, graphId, twinGraphQuery, options) {
8711
+ var _this = this;
8712
+ return exports.TwingraphApiFp(this.configuration).query(organizationId, graphId, twinGraphQuery, options).then(function (request) { return request(_this.axios, _this.basePath); });
8713
+ };
8714
+ return TwingraphApi;
8715
+ }(base_1.BaseAPI));
8716
+ exports.TwingraphApi = TwingraphApi;
8717
+ /**
8718
+ * UserApi - axios parameter creator
8719
+ * @export
8720
+ */
8721
+ exports.UserApiAxiosParamCreator = function (configuration) {
8722
+ var _this = this;
8723
+ return {
8724
+ /**
8725
+ *
8726
+ * @summary Authorize an User with OAuth2. Delegated to configured OAuth2 service
8727
+ * @param {*} [options] Override http request option.
8728
+ * @throws {RequiredError}
8729
+ */
8730
+ authorizeUser: function (options) {
8731
+ if (options === void 0) { options = {}; }
8732
+ return __awaiter(_this, void 0, void 0, function () {
8733
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8734
+ return __generator(this, function (_a) {
8735
+ switch (_a.label) {
8736
+ case 0:
8737
+ localVarPath = "/oauth2/authorize";
8738
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8739
+ if (configuration) {
8740
+ baseOptions = configuration.baseOptions;
8741
+ }
8742
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8743
+ localVarHeaderParameter = {};
8744
+ localVarQueryParameter = {};
8745
+ // authentication oAuth2AuthCode required
8746
+ // oauth required
8747
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8748
+ case 1:
8749
+ // authentication oAuth2AuthCode required
8750
+ // oauth required
8751
+ _a.sent();
8752
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8753
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8754
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8755
+ return [2 /*return*/, {
8756
+ url: common_1.toPathString(localVarUrlObj),
8757
+ options: localVarRequestOptions,
8758
+ }];
8759
+ }
8760
+ });
8761
+ });
8762
+ },
8763
+ /**
8764
+ *
8765
+ * @summary List all Users
8766
+ * @param {*} [options] Override http request option.
8767
+ * @throws {RequiredError}
8768
+ */
8769
+ findAllUsers: function (options) {
8770
+ if (options === void 0) { options = {}; }
8771
+ return __awaiter(_this, void 0, void 0, function () {
8772
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8773
+ return __generator(this, function (_a) {
8774
+ switch (_a.label) {
8775
+ case 0:
8776
+ localVarPath = "/users";
8777
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8778
+ if (configuration) {
8779
+ baseOptions = configuration.baseOptions;
8780
+ }
8781
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8782
+ localVarHeaderParameter = {};
8783
+ localVarQueryParameter = {};
8784
+ // authentication oAuth2AuthCode required
8785
+ // oauth required
8786
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8787
+ case 1:
8788
+ // authentication oAuth2AuthCode required
8789
+ // oauth required
8790
+ _a.sent();
8791
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8792
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8793
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8794
+ return [2 /*return*/, {
8795
+ url: common_1.toPathString(localVarUrlObj),
8796
+ options: localVarRequestOptions,
8797
+ }];
8798
+ }
8799
+ });
8800
+ });
8801
+ },
8802
+ /**
8803
+ *
8804
+ * @summary Get the details of an user
8805
+ * @param {string} userId the User identifier
8806
+ * @param {*} [options] Override http request option.
8807
+ * @throws {RequiredError}
8808
+ */
8809
+ findUserById: function (userId, options) {
8810
+ if (options === void 0) { options = {}; }
8811
+ return __awaiter(_this, void 0, void 0, function () {
8812
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8813
+ return __generator(this, function (_a) {
8814
+ switch (_a.label) {
8815
+ case 0:
8816
+ // verify required parameter 'userId' is not null or undefined
8817
+ common_1.assertParamExists('findUserById', 'userId', userId);
8818
+ localVarPath = "/users/{user_id}"
8819
+ .replace("{" + "user_id" + "}", encodeURIComponent(String(userId)));
8820
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8821
+ if (configuration) {
8822
+ baseOptions = configuration.baseOptions;
8823
+ }
8824
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8825
+ localVarHeaderParameter = {};
8826
+ localVarQueryParameter = {};
8827
+ // authentication oAuth2AuthCode required
8828
+ // oauth required
8829
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8830
+ case 1:
8831
+ // authentication oAuth2AuthCode required
8832
+ // oauth required
8833
+ _a.sent();
8834
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8835
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8836
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8837
+ return [2 /*return*/, {
8838
+ url: common_1.toPathString(localVarUrlObj),
8839
+ options: localVarRequestOptions,
8840
+ }];
8841
+ }
8842
+ });
8843
+ });
8844
+ },
8845
+ /**
8846
+ *
8847
+ * @summary Get the details of the logged-in User
8848
+ * @param {*} [options] Override http request option.
8849
+ * @throws {RequiredError}
8850
+ */
8851
+ getCurrentUser: function (options) {
8852
+ if (options === void 0) { options = {}; }
8853
+ return __awaiter(_this, void 0, void 0, function () {
8854
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8855
+ return __generator(this, function (_a) {
8856
+ switch (_a.label) {
8857
+ case 0:
8858
+ localVarPath = "/users/me";
8859
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8860
+ if (configuration) {
8861
+ baseOptions = configuration.baseOptions;
8862
+ }
8863
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8864
+ localVarHeaderParameter = {};
8865
+ localVarQueryParameter = {};
8866
+ // authentication oAuth2AuthCode required
8867
+ // oauth required
8868
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8869
+ case 1:
8870
+ // authentication oAuth2AuthCode required
8871
+ // oauth required
8872
+ _a.sent();
8873
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8874
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8875
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8876
+ return [2 /*return*/, {
8877
+ url: common_1.toPathString(localVarUrlObj),
8878
+ options: localVarRequestOptions,
8879
+ }];
8880
+ }
8881
+ });
8882
+ });
8883
+ },
8884
+ /**
8885
+ *
8886
+ * @summary Get the details of a logged-in User with roles for an Organization
8887
+ * @param {string} organizationId the Organization identifier
8888
+ * @param {*} [options] Override http request option.
8889
+ * @throws {RequiredError}
8890
+ */
8891
+ getOrganizationCurrentUser: function (organizationId, options) {
8892
+ if (options === void 0) { options = {}; }
8893
+ return __awaiter(_this, void 0, void 0, function () {
8894
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8895
+ return __generator(this, function (_a) {
8896
+ switch (_a.label) {
8897
+ case 0:
8898
+ // verify required parameter 'organizationId' is not null or undefined
8899
+ common_1.assertParamExists('getOrganizationCurrentUser', 'organizationId', organizationId);
8900
+ localVarPath = "/organizations/{organization_id}/me"
8901
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)));
8902
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8903
+ if (configuration) {
8904
+ baseOptions = configuration.baseOptions;
8905
+ }
8906
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8907
+ localVarHeaderParameter = {};
8908
+ localVarQueryParameter = {};
8909
+ // authentication oAuth2AuthCode required
8910
+ // oauth required
8911
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8912
+ case 1:
8913
+ // authentication oAuth2AuthCode required
8914
+ // oauth required
8915
+ _a.sent();
8916
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8917
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8918
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8919
+ return [2 /*return*/, {
8920
+ url: common_1.toPathString(localVarUrlObj),
8921
+ options: localVarRequestOptions,
8922
+ }];
8923
+ }
8924
+ });
8925
+ });
8926
+ },
8927
+ /**
8928
+ *
8929
+ * @summary Get the details of the logged-in user with roles for a Workspace
8930
+ * @param {string} organizationId the Organization identifier
8931
+ * @param {string} workspaceId the Workspace identifier
8932
+ * @param {*} [options] Override http request option.
8933
+ * @throws {RequiredError}
8934
+ */
8935
+ getWorkspaceCurrentUser: function (organizationId, workspaceId, options) {
8936
+ if (options === void 0) { options = {}; }
8937
+ return __awaiter(_this, void 0, void 0, function () {
8938
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8939
+ return __generator(this, function (_a) {
8940
+ switch (_a.label) {
8941
+ case 0:
8942
+ // verify required parameter 'organizationId' is not null or undefined
8943
+ common_1.assertParamExists('getWorkspaceCurrentUser', 'organizationId', organizationId);
8944
+ // verify required parameter 'workspaceId' is not null or undefined
8945
+ common_1.assertParamExists('getWorkspaceCurrentUser', 'workspaceId', workspaceId);
8946
+ localVarPath = "/organizations/{organization_id}/workspaces/{workspace_id}/me"
8947
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
8948
+ .replace("{" + "workspace_id" + "}", encodeURIComponent(String(workspaceId)));
8949
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8950
+ if (configuration) {
8951
+ baseOptions = configuration.baseOptions;
8952
+ }
8953
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
8954
+ localVarHeaderParameter = {};
8955
+ localVarQueryParameter = {};
8956
+ // authentication oAuth2AuthCode required
8957
+ // oauth required
8958
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
8959
+ case 1:
8960
+ // authentication oAuth2AuthCode required
8961
+ // oauth required
8962
+ _a.sent();
8963
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
8964
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
8965
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
8966
+ return [2 /*return*/, {
8967
+ url: common_1.toPathString(localVarUrlObj),
8968
+ options: localVarRequestOptions,
8969
+ }];
8970
+ }
8971
+ });
8972
+ });
8973
+ },
8974
+ /**
8975
+ *
8976
+ * @summary Register a new user
8977
+ * @param {User} user the User to register
8978
+ * @param {*} [options] Override http request option.
8979
+ * @throws {RequiredError}
8980
+ */
8981
+ registerUser: function (user, options) {
8982
+ if (options === void 0) { options = {}; }
8983
+ return __awaiter(_this, void 0, void 0, function () {
8984
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
8985
+ return __generator(this, function (_a) {
8986
+ switch (_a.label) {
8987
+ case 0:
8988
+ // verify required parameter 'user' is not null or undefined
8989
+ common_1.assertParamExists('registerUser', 'user', user);
8990
+ localVarPath = "/users";
8991
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
8992
+ if (configuration) {
8993
+ baseOptions = configuration.baseOptions;
8994
+ }
8995
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
8996
+ localVarHeaderParameter = {};
8997
+ localVarQueryParameter = {};
8998
+ // authentication oAuth2AuthCode required
8999
+ // oauth required
9000
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
9001
+ case 1:
9002
+ // authentication oAuth2AuthCode required
9003
+ // oauth required
9004
+ _a.sent();
9005
+ localVarHeaderParameter['Content-Type'] = 'application/json';
9006
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
9007
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
9008
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
9009
+ localVarRequestOptions.data = common_1.serializeDataIfNeeded(user, localVarRequestOptions, configuration);
9010
+ return [2 /*return*/, {
9011
+ url: common_1.toPathString(localVarUrlObj),
9012
+ options: localVarRequestOptions,
9013
+ }];
9014
+ }
9015
+ });
9016
+ });
9017
+ },
9018
+ /**
9019
+ *
9020
+ * @summary test platform API call
9021
+ * @param {*} [options] Override http request option.
9022
+ * @throws {RequiredError}
9023
+ */
9024
+ testPlatform: function (options) {
9025
+ if (options === void 0) { options = {}; }
9026
+ return __awaiter(_this, void 0, void 0, function () {
9027
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
9028
+ return __generator(this, function (_a) {
9029
+ switch (_a.label) {
9030
+ case 0:
9031
+ localVarPath = "/test";
9032
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
9033
+ if (configuration) {
9034
+ baseOptions = configuration.baseOptions;
9035
+ }
9036
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
9037
+ localVarHeaderParameter = {};
9038
+ localVarQueryParameter = {};
9039
+ // authentication oAuth2AuthCode required
9040
+ // oauth required
9041
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
9042
+ case 1:
9043
+ // authentication oAuth2AuthCode required
9044
+ // oauth required
9045
+ _a.sent();
9046
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
9047
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
9048
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
9049
+ return [2 /*return*/, {
9050
+ url: common_1.toPathString(localVarUrlObj),
9051
+ options: localVarRequestOptions,
9052
+ }];
9053
+ }
9054
+ });
9055
+ });
9056
+ },
9057
+ /**
9058
+ *
9059
+ * @summary Unregister an user
9060
+ * @param {string} userId the User identifier
9061
+ * @param {*} [options] Override http request option.
9062
+ * @throws {RequiredError}
9063
+ */
9064
+ unregisterUser: function (userId, options) {
9065
+ if (options === void 0) { options = {}; }
9066
+ return __awaiter(_this, void 0, void 0, function () {
9067
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
9068
+ return __generator(this, function (_a) {
9069
+ switch (_a.label) {
9070
+ case 0:
9071
+ // verify required parameter 'userId' is not null or undefined
9072
+ common_1.assertParamExists('unregisterUser', 'userId', userId);
9073
+ localVarPath = "/users/{user_id}"
9074
+ .replace("{" + "user_id" + "}", encodeURIComponent(String(userId)));
9075
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
9076
+ if (configuration) {
9077
+ baseOptions = configuration.baseOptions;
9078
+ }
9079
+ localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
9080
+ localVarHeaderParameter = {};
9081
+ localVarQueryParameter = {};
9082
+ // authentication oAuth2AuthCode required
9083
+ // oauth required
9084
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
9085
+ case 1:
9086
+ // authentication oAuth2AuthCode required
9087
+ // oauth required
9088
+ _a.sent();
9089
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
9090
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
9091
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
9092
+ return [2 /*return*/, {
9093
+ url: common_1.toPathString(localVarUrlObj),
9094
+ options: localVarRequestOptions,
9095
+ }];
9096
+ }
9097
+ });
9098
+ });
9099
+ },
9100
+ /**
9101
+ *
9102
+ * @summary Update a User
9103
+ * @param {string} userId the User identifier
9104
+ * @param {User} user the new User details. Organization membership is handled via the /organizations endpoint.
9105
+ * @param {*} [options] Override http request option.
9106
+ * @throws {RequiredError}
9107
+ */
9108
+ updateUser: function (userId, user, options) {
9109
+ if (options === void 0) { options = {}; }
9110
+ return __awaiter(_this, void 0, void 0, function () {
9111
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
9112
+ return __generator(this, function (_a) {
9113
+ switch (_a.label) {
9114
+ case 0:
9115
+ // verify required parameter 'userId' is not null or undefined
9116
+ common_1.assertParamExists('updateUser', 'userId', userId);
9117
+ // verify required parameter 'user' is not null or undefined
9118
+ common_1.assertParamExists('updateUser', 'user', user);
9119
+ localVarPath = "/users/{user_id}"
9120
+ .replace("{" + "user_id" + "}", encodeURIComponent(String(userId)));
9121
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
9122
+ if (configuration) {
9123
+ baseOptions = configuration.baseOptions;
9124
+ }
9125
+ localVarRequestOptions = __assign(__assign({ method: 'PATCH' }, baseOptions), options);
9126
+ localVarHeaderParameter = {};
9127
+ localVarQueryParameter = {};
9128
+ // authentication oAuth2AuthCode required
9129
+ // oauth required
9130
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
9131
+ case 1:
9132
+ // authentication oAuth2AuthCode required
9133
+ // oauth required
9134
+ _a.sent();
9135
+ localVarHeaderParameter['Content-Type'] = 'application/json';
9136
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
9137
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
9138
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
9139
+ localVarRequestOptions.data = common_1.serializeDataIfNeeded(user, localVarRequestOptions, configuration);
9140
+ return [2 /*return*/, {
9141
+ url: common_1.toPathString(localVarUrlObj),
9142
+ options: localVarRequestOptions,
9143
+ }];
9144
+ }
9145
+ });
9146
+ });
9147
+ },
9148
+ };
9149
+ };
9150
+ /**
9151
+ * UserApi - functional programming interface
9152
+ * @export
9153
+ */
8558
9154
  exports.UserApiFp = function (configuration) {
8559
9155
  var localVarAxiosParamCreator = exports.UserApiAxiosParamCreator(configuration);
8560
9156
  return {
@@ -9949,6 +10545,58 @@ exports.WorkspaceApiAxiosParamCreator = function (configuration) {
9949
10545
  });
9950
10546
  });
9951
10547
  },
10548
+ /**
10549
+ *
10550
+ * @summary Create a secret for the Workspace
10551
+ * @param {string} organizationId the Organization identifier
10552
+ * @param {string} workspaceId the Workspace identifier
10553
+ * @param {WorkspaceSecret} workspaceSecret the definition of the secret
10554
+ * @param {*} [options] Override http request option.
10555
+ * @throws {RequiredError}
10556
+ */
10557
+ createSecret: function (organizationId, workspaceId, workspaceSecret, options) {
10558
+ if (options === void 0) { options = {}; }
10559
+ return __awaiter(_this, void 0, void 0, function () {
10560
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
10561
+ return __generator(this, function (_a) {
10562
+ switch (_a.label) {
10563
+ case 0:
10564
+ // verify required parameter 'organizationId' is not null or undefined
10565
+ common_1.assertParamExists('createSecret', 'organizationId', organizationId);
10566
+ // verify required parameter 'workspaceId' is not null or undefined
10567
+ common_1.assertParamExists('createSecret', 'workspaceId', workspaceId);
10568
+ // verify required parameter 'workspaceSecret' is not null or undefined
10569
+ common_1.assertParamExists('createSecret', 'workspaceSecret', workspaceSecret);
10570
+ localVarPath = "/organizations/{organization_id}/workspaces/{workspace_id}/secret"
10571
+ .replace("{" + "organization_id" + "}", encodeURIComponent(String(organizationId)))
10572
+ .replace("{" + "workspace_id" + "}", encodeURIComponent(String(workspaceId)));
10573
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
10574
+ if (configuration) {
10575
+ baseOptions = configuration.baseOptions;
10576
+ }
10577
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
10578
+ localVarHeaderParameter = {};
10579
+ localVarQueryParameter = {};
10580
+ // authentication oAuth2AuthCode required
10581
+ // oauth required
10582
+ return [4 /*yield*/, common_1.setOAuthToObject(localVarHeaderParameter, "oAuth2AuthCode", [], configuration)];
10583
+ case 1:
10584
+ // authentication oAuth2AuthCode required
10585
+ // oauth required
10586
+ _a.sent();
10587
+ localVarHeaderParameter['Content-Type'] = 'application/json';
10588
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
10589
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
10590
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
10591
+ localVarRequestOptions.data = common_1.serializeDataIfNeeded(workspaceSecret, localVarRequestOptions, configuration);
10592
+ return [2 /*return*/, {
10593
+ url: common_1.toPathString(localVarUrlObj),
10594
+ options: localVarRequestOptions,
10595
+ }];
10596
+ }
10597
+ });
10598
+ });
10599
+ },
9952
10600
  /**
9953
10601
  *
9954
10602
  * @summary Create a new workspace
@@ -10836,6 +11484,28 @@ exports.WorkspaceApiFp = function (configuration) {
10836
11484
  });
10837
11485
  });
10838
11486
  },
11487
+ /**
11488
+ *
11489
+ * @summary Create a secret for the Workspace
11490
+ * @param {string} organizationId the Organization identifier
11491
+ * @param {string} workspaceId the Workspace identifier
11492
+ * @param {WorkspaceSecret} workspaceSecret the definition of the secret
11493
+ * @param {*} [options] Override http request option.
11494
+ * @throws {RequiredError}
11495
+ */
11496
+ createSecret: function (organizationId, workspaceId, workspaceSecret, options) {
11497
+ return __awaiter(this, void 0, void 0, function () {
11498
+ var localVarAxiosArgs;
11499
+ return __generator(this, function (_a) {
11500
+ switch (_a.label) {
11501
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.createSecret(organizationId, workspaceId, workspaceSecret, options)];
11502
+ case 1:
11503
+ localVarAxiosArgs = _a.sent();
11504
+ return [2 /*return*/, common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
11505
+ }
11506
+ });
11507
+ });
11508
+ },
10839
11509
  /**
10840
11510
  *
10841
11511
  * @summary Create a new workspace
@@ -11225,6 +11895,18 @@ exports.WorkspaceApiFactory = function (configuration, basePath, axios) {
11225
11895
  addWorkspaceAccessControl: function (organizationId, workspaceId, workspaceAccessControl, options) {
11226
11896
  return localVarFp.addWorkspaceAccessControl(organizationId, workspaceId, workspaceAccessControl, options).then(function (request) { return request(axios, basePath); });
11227
11897
  },
11898
+ /**
11899
+ *
11900
+ * @summary Create a secret for the Workspace
11901
+ * @param {string} organizationId the Organization identifier
11902
+ * @param {string} workspaceId the Workspace identifier
11903
+ * @param {WorkspaceSecret} workspaceSecret the definition of the secret
11904
+ * @param {*} [options] Override http request option.
11905
+ * @throws {RequiredError}
11906
+ */
11907
+ createSecret: function (organizationId, workspaceId, workspaceSecret, options) {
11908
+ return localVarFp.createSecret(organizationId, workspaceId, workspaceSecret, options).then(function (request) { return request(axios, basePath); });
11909
+ },
11228
11910
  /**
11229
11911
  *
11230
11912
  * @summary Create a new workspace
@@ -11450,6 +12132,20 @@ var WorkspaceApi = /** @class */ (function (_super) {
11450
12132
  var _this = this;
11451
12133
  return exports.WorkspaceApiFp(this.configuration).addWorkspaceAccessControl(organizationId, workspaceId, workspaceAccessControl, options).then(function (request) { return request(_this.axios, _this.basePath); });
11452
12134
  };
12135
+ /**
12136
+ *
12137
+ * @summary Create a secret for the Workspace
12138
+ * @param {string} organizationId the Organization identifier
12139
+ * @param {string} workspaceId the Workspace identifier
12140
+ * @param {WorkspaceSecret} workspaceSecret the definition of the secret
12141
+ * @param {*} [options] Override http request option.
12142
+ * @throws {RequiredError}
12143
+ * @memberof WorkspaceApi
12144
+ */
12145
+ WorkspaceApi.prototype.createSecret = function (organizationId, workspaceId, workspaceSecret, options) {
12146
+ var _this = this;
12147
+ return exports.WorkspaceApiFp(this.configuration).createSecret(organizationId, workspaceId, workspaceSecret, options).then(function (request) { return request(_this.axios, _this.basePath); });
12148
+ };
11453
12149
  /**
11454
12150
  *
11455
12151
  * @summary Create a new workspace