@openshift-migration-advisor/agent-sdk 0.12.0-b2d61b72e086 → 0.12.0-b940fec9f503

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.
Files changed (208) hide show
  1. package/.openapi-generator/FILES +22 -0
  2. package/.openapi-generator/VERSION +1 -1
  3. package/README.md +25 -5
  4. package/dist/apis/DefaultApi.d.ts +369 -41
  5. package/dist/apis/DefaultApi.js +410 -46
  6. package/dist/esm/apis/DefaultApi.d.ts +369 -41
  7. package/dist/esm/apis/DefaultApi.js +410 -46
  8. package/dist/esm/models/AgentStatus.d.ts +1 -1
  9. package/dist/esm/models/AgentStatus.js +3 -3
  10. package/dist/esm/models/ApplicationListResponse.d.ts +33 -0
  11. package/dist/esm/models/ApplicationListResponse.js +44 -0
  12. package/dist/esm/models/ApplicationOverview.d.ts +51 -0
  13. package/dist/esm/models/ApplicationOverview.js +56 -0
  14. package/dist/esm/models/ApplicationVM.d.ts +38 -0
  15. package/dist/esm/models/ApplicationVM.js +47 -0
  16. package/dist/esm/models/ClusterFeatures.d.ts +54 -0
  17. package/dist/esm/models/ClusterFeatures.js +54 -0
  18. package/dist/esm/models/ClusterUtilization.d.ts +68 -0
  19. package/dist/esm/models/ClusterUtilization.js +67 -0
  20. package/dist/esm/models/CollectorStartRequest.d.ts +12 -0
  21. package/dist/esm/models/CollectorStartRequest.js +4 -0
  22. package/dist/esm/models/CreateGroupRequest.d.ts +0 -6
  23. package/dist/esm/models/CreateGroupRequest.js +0 -2
  24. package/dist/esm/models/DeleteLabelGloballyResponse.d.ts +38 -0
  25. package/dist/esm/models/DeleteLabelGloballyResponse.js +47 -0
  26. package/dist/esm/models/Group.d.ts +0 -6
  27. package/dist/esm/models/Group.js +0 -2
  28. package/dist/esm/models/GroupResponse.d.ts +7 -0
  29. package/dist/esm/models/GroupResponse.js +3 -0
  30. package/dist/esm/models/InspectorStatus.d.ts +0 -17
  31. package/dist/esm/models/InspectorStatus.js +1 -10
  32. package/dist/esm/models/Inventory.d.ts +7 -1
  33. package/dist/esm/models/Inventory.js +5 -3
  34. package/dist/esm/models/InventoryData.d.ts +14 -0
  35. package/dist/esm/models/InventoryData.js +6 -0
  36. package/dist/esm/models/RightsizingClusterListResponse.d.ts +1 -1
  37. package/dist/esm/models/RightsizingClusterListResponse.js +3 -3
  38. package/dist/esm/models/RightsizingClusterResponse.d.ts +39 -0
  39. package/dist/esm/models/RightsizingClusterResponse.js +48 -0
  40. package/dist/esm/models/RightsizingClusterUtilization.d.ts +12 -12
  41. package/dist/esm/models/RightsizingClusterUtilization.js +36 -36
  42. package/dist/esm/models/RightsizingCollectRequest.d.ts +6 -6
  43. package/dist/esm/models/RightsizingCollectRequest.js +12 -12
  44. package/dist/esm/models/RightsizingMetricStats.d.ts +1 -1
  45. package/dist/esm/models/RightsizingMetricStats.js +3 -3
  46. package/dist/esm/models/RightsizingReport.d.ts +6 -6
  47. package/dist/esm/models/RightsizingReport.js +18 -18
  48. package/dist/esm/models/RightsizingReportSummary.d.ts +6 -6
  49. package/dist/esm/models/RightsizingReportSummary.js +18 -18
  50. package/dist/esm/models/StartInspectionRequest.d.ts +8 -1
  51. package/dist/esm/models/StartInspectionRequest.js +5 -0
  52. package/dist/esm/models/UpdateGroupRequest.d.ts +0 -6
  53. package/dist/esm/models/UpdateGroupRequest.js +0 -2
  54. package/dist/esm/models/UpdateLabelVMsRequest.d.ts +38 -0
  55. package/dist/esm/models/UpdateLabelVMsRequest.js +43 -0
  56. package/dist/esm/models/VMFilterOptionsResponse.d.ts +56 -0
  57. package/dist/esm/models/VMFilterOptionsResponse.js +59 -0
  58. package/dist/esm/models/VMLabelsResponse.d.ts +38 -0
  59. package/dist/esm/models/VMLabelsResponse.js +47 -0
  60. package/dist/esm/models/VMNIC.d.ts +12 -0
  61. package/dist/esm/models/VMNIC.js +4 -0
  62. package/dist/esm/models/VcenterCredentials.d.ts +12 -0
  63. package/dist/esm/models/VcenterCredentials.js +4 -0
  64. package/dist/esm/models/VirtualMachine.d.ts +30 -6
  65. package/dist/esm/models/VirtualMachine.js +18 -10
  66. package/dist/esm/models/VirtualMachineDetail.d.ts +12 -0
  67. package/dist/esm/models/VirtualMachineDetail.js +4 -0
  68. package/dist/esm/models/VirtualMachineUpdateRequest.d.ts +38 -0
  69. package/dist/esm/models/VirtualMachineUpdateRequest.js +43 -0
  70. package/dist/esm/models/VmUtilizationDetails.d.ts +12 -12
  71. package/dist/esm/models/VmUtilizationDetails.js +36 -36
  72. package/dist/esm/models/index.d.ts +11 -0
  73. package/dist/esm/models/index.js +11 -0
  74. package/dist/models/AgentStatus.d.ts +1 -1
  75. package/dist/models/AgentStatus.js +3 -3
  76. package/dist/models/ApplicationListResponse.d.ts +33 -0
  77. package/dist/models/ApplicationListResponse.js +51 -0
  78. package/dist/models/ApplicationOverview.d.ts +51 -0
  79. package/dist/models/ApplicationOverview.js +63 -0
  80. package/dist/models/ApplicationVM.d.ts +38 -0
  81. package/dist/models/ApplicationVM.js +54 -0
  82. package/dist/models/ClusterFeatures.d.ts +54 -0
  83. package/dist/models/ClusterFeatures.js +62 -0
  84. package/dist/models/ClusterUtilization.d.ts +68 -0
  85. package/dist/models/ClusterUtilization.js +74 -0
  86. package/dist/models/CollectorStartRequest.d.ts +12 -0
  87. package/dist/models/CollectorStartRequest.js +4 -0
  88. package/dist/models/CreateGroupRequest.d.ts +0 -6
  89. package/dist/models/CreateGroupRequest.js +0 -2
  90. package/dist/models/DeleteLabelGloballyResponse.d.ts +38 -0
  91. package/dist/models/DeleteLabelGloballyResponse.js +54 -0
  92. package/dist/models/Group.d.ts +0 -6
  93. package/dist/models/Group.js +0 -2
  94. package/dist/models/GroupResponse.d.ts +7 -0
  95. package/dist/models/GroupResponse.js +3 -0
  96. package/dist/models/InspectorStatus.d.ts +0 -17
  97. package/dist/models/InspectorStatus.js +1 -10
  98. package/dist/models/Inventory.d.ts +7 -1
  99. package/dist/models/Inventory.js +5 -3
  100. package/dist/models/InventoryData.d.ts +14 -0
  101. package/dist/models/InventoryData.js +6 -0
  102. package/dist/models/RightsizingClusterListResponse.d.ts +1 -1
  103. package/dist/models/RightsizingClusterListResponse.js +3 -3
  104. package/dist/models/RightsizingClusterResponse.d.ts +39 -0
  105. package/dist/models/RightsizingClusterResponse.js +55 -0
  106. package/dist/models/RightsizingClusterUtilization.d.ts +12 -12
  107. package/dist/models/RightsizingClusterUtilization.js +36 -36
  108. package/dist/models/RightsizingCollectRequest.d.ts +6 -6
  109. package/dist/models/RightsizingCollectRequest.js +12 -12
  110. package/dist/models/RightsizingMetricStats.d.ts +1 -1
  111. package/dist/models/RightsizingMetricStats.js +3 -3
  112. package/dist/models/RightsizingReport.d.ts +6 -6
  113. package/dist/models/RightsizingReport.js +18 -18
  114. package/dist/models/RightsizingReportSummary.d.ts +6 -6
  115. package/dist/models/RightsizingReportSummary.js +18 -18
  116. package/dist/models/StartInspectionRequest.d.ts +8 -1
  117. package/dist/models/StartInspectionRequest.js +5 -0
  118. package/dist/models/UpdateGroupRequest.d.ts +0 -6
  119. package/dist/models/UpdateGroupRequest.js +0 -2
  120. package/dist/models/UpdateLabelVMsRequest.d.ts +38 -0
  121. package/dist/models/UpdateLabelVMsRequest.js +50 -0
  122. package/dist/models/VMFilterOptionsResponse.d.ts +56 -0
  123. package/dist/models/VMFilterOptionsResponse.js +66 -0
  124. package/dist/models/VMLabelsResponse.d.ts +38 -0
  125. package/dist/models/VMLabelsResponse.js +54 -0
  126. package/dist/models/VMNIC.d.ts +12 -0
  127. package/dist/models/VMNIC.js +4 -0
  128. package/dist/models/VcenterCredentials.d.ts +12 -0
  129. package/dist/models/VcenterCredentials.js +4 -0
  130. package/dist/models/VirtualMachine.d.ts +30 -6
  131. package/dist/models/VirtualMachine.js +18 -10
  132. package/dist/models/VirtualMachineDetail.d.ts +12 -0
  133. package/dist/models/VirtualMachineDetail.js +4 -0
  134. package/dist/models/VirtualMachineUpdateRequest.d.ts +38 -0
  135. package/dist/models/VirtualMachineUpdateRequest.js +50 -0
  136. package/dist/models/VmUtilizationDetails.d.ts +12 -12
  137. package/dist/models/VmUtilizationDetails.js +36 -36
  138. package/dist/models/index.d.ts +11 -0
  139. package/dist/models/index.js +11 -0
  140. package/docs/AgentStatus.md +2 -2
  141. package/docs/ApplicationListResponse.md +34 -0
  142. package/docs/ApplicationOverview.md +40 -0
  143. package/docs/ApplicationVM.md +36 -0
  144. package/docs/ClusterFeatures.md +38 -0
  145. package/docs/ClusterUtilization.md +46 -0
  146. package/docs/CollectorStartRequest.md +4 -0
  147. package/docs/CreateGroupRequest.md +0 -2
  148. package/docs/DefaultApi.md +680 -83
  149. package/docs/DeleteLabelGloballyResponse.md +36 -0
  150. package/docs/GetInventory200Response.md +4 -2
  151. package/docs/Group.md +0 -2
  152. package/docs/GroupResponse.md +2 -0
  153. package/docs/InspectorStatus.md +0 -4
  154. package/docs/Inventory.md +4 -2
  155. package/docs/InventoryData.md +4 -0
  156. package/docs/RightsizingClusterListResponse.md +2 -2
  157. package/docs/RightsizingClusterResponse.md +36 -0
  158. package/docs/RightsizingClusterUtilization.md +24 -24
  159. package/docs/RightsizingCollectRequest.md +12 -12
  160. package/docs/RightsizingMetricStats.md +2 -2
  161. package/docs/RightsizingReport.md +12 -12
  162. package/docs/RightsizingReportSummary.md +12 -12
  163. package/docs/StartInspectionRequest.md +3 -1
  164. package/docs/UpdateGroupRequest.md +0 -2
  165. package/docs/UpdateLabelVMsRequest.md +36 -0
  166. package/docs/VMFilterOptionsResponse.md +42 -0
  167. package/docs/VMLabelsResponse.md +36 -0
  168. package/docs/VMNIC.md +4 -0
  169. package/docs/VcenterCredentials.md +4 -0
  170. package/docs/VirtualMachine.md +18 -10
  171. package/docs/VirtualMachineDetail.md +4 -0
  172. package/docs/VirtualMachineUpdateRequest.md +36 -0
  173. package/docs/VmUtilizationDetails.md +24 -24
  174. package/package.json +1 -1
  175. package/src/apis/DefaultApi.ts +806 -118
  176. package/src/models/AgentStatus.ts +4 -4
  177. package/src/models/ApplicationListResponse.ts +74 -0
  178. package/src/models/ApplicationOverview.ts +101 -0
  179. package/src/models/ApplicationVM.ts +75 -0
  180. package/src/models/ClusterFeatures.ts +94 -0
  181. package/src/models/ClusterUtilization.ts +120 -0
  182. package/src/models/CollectorStartRequest.ts +16 -0
  183. package/src/models/CreateGroupRequest.ts +0 -8
  184. package/src/models/DeleteLabelGloballyResponse.ts +75 -0
  185. package/src/models/Group.ts +0 -8
  186. package/src/models/GroupResponse.ts +15 -0
  187. package/src/models/InspectorStatus.ts +1 -28
  188. package/src/models/Inventory.ts +12 -4
  189. package/src/models/InventoryData.ts +30 -0
  190. package/src/models/RightsizingClusterListResponse.ts +4 -4
  191. package/src/models/RightsizingClusterResponse.ts +83 -0
  192. package/src/models/RightsizingClusterUtilization.ts +48 -48
  193. package/src/models/RightsizingCollectRequest.ts +18 -18
  194. package/src/models/RightsizingMetricStats.ts +4 -4
  195. package/src/models/RightsizingReport.ts +24 -24
  196. package/src/models/RightsizingReportSummary.ts +24 -24
  197. package/src/models/StartInspectionRequest.ts +18 -1
  198. package/src/models/UpdateGroupRequest.ts +0 -8
  199. package/src/models/UpdateLabelVMsRequest.ts +73 -0
  200. package/src/models/VMFilterOptionsResponse.ts +102 -0
  201. package/src/models/VMLabelsResponse.ts +75 -0
  202. package/src/models/VMNIC.ts +16 -0
  203. package/src/models/VcenterCredentials.ts +16 -0
  204. package/src/models/VirtualMachine.ts +48 -16
  205. package/src/models/VirtualMachineDetail.ts +16 -0
  206. package/src/models/VirtualMachineUpdateRequest.ts +73 -0
  207. package/src/models/VmUtilizationDetails.ts +48 -48
  208. package/src/models/index.ts +11 -0
@@ -26,11 +26,13 @@ exports.DefaultApi = void 0;
26
26
  const runtime = require("../runtime.js");
27
27
  const AgentModeRequest_js_1 = require("../models/AgentModeRequest.js");
28
28
  const AgentStatus_js_1 = require("../models/AgentStatus.js");
29
+ const ApplicationListResponse_js_1 = require("../models/ApplicationListResponse.js");
29
30
  const BenchmarkRun_js_1 = require("../models/BenchmarkRun.js");
30
31
  const CollectorStartRequest_js_1 = require("../models/CollectorStartRequest.js");
31
32
  const CollectorStatus_js_1 = require("../models/CollectorStatus.js");
32
33
  const CreateGroupRequest_js_1 = require("../models/CreateGroupRequest.js");
33
34
  const DatastoreDetail_js_1 = require("../models/DatastoreDetail.js");
35
+ const DeleteLabelGloballyResponse_js_1 = require("../models/DeleteLabelGloballyResponse.js");
34
36
  const ForecastStats_js_1 = require("../models/ForecastStats.js");
35
37
  const ForecasterDatastoresRequest_js_1 = require("../models/ForecasterDatastoresRequest.js");
36
38
  const ForecasterStartRequest_js_1 = require("../models/ForecasterStartRequest.js");
@@ -43,6 +45,7 @@ const InspectorStatus_js_1 = require("../models/InspectorStatus.js");
43
45
  const PairCapability_js_1 = require("../models/PairCapability.js");
44
46
  const PairCapabilityRequest_js_1 = require("../models/PairCapabilityRequest.js");
45
47
  const RightsizingClusterListResponse_js_1 = require("../models/RightsizingClusterListResponse.js");
48
+ const RightsizingClusterResponse_js_1 = require("../models/RightsizingClusterResponse.js");
46
49
  const RightsizingCollectRequest_js_1 = require("../models/RightsizingCollectRequest.js");
47
50
  const RightsizingReport_js_1 = require("../models/RightsizingReport.js");
48
51
  const RightsizingReportListResponse_js_1 = require("../models/RightsizingReportListResponse.js");
@@ -50,11 +53,15 @@ const RightsizingReportSummary_js_1 = require("../models/RightsizingReportSummar
50
53
  const StartInspectionRequest_js_1 = require("../models/StartInspectionRequest.js");
51
54
  const StopForecasterPair202Response_js_1 = require("../models/StopForecasterPair202Response.js");
52
55
  const UpdateGroupRequest_js_1 = require("../models/UpdateGroupRequest.js");
56
+ const UpdateLabelVMsRequest_js_1 = require("../models/UpdateLabelVMsRequest.js");
57
+ const VMFilterOptionsResponse_js_1 = require("../models/VMFilterOptionsResponse.js");
58
+ const VMLabelsResponse_js_1 = require("../models/VMLabelsResponse.js");
53
59
  const VcenterCredentials_js_1 = require("../models/VcenterCredentials.js");
54
60
  const VddkProperties_js_1 = require("../models/VddkProperties.js");
55
61
  const VersionInfo_js_1 = require("../models/VersionInfo.js");
56
62
  const VirtualMachineDetail_js_1 = require("../models/VirtualMachineDetail.js");
57
63
  const VirtualMachineListResponse_js_1 = require("../models/VirtualMachineListResponse.js");
64
+ const VirtualMachineUpdateRequest_js_1 = require("../models/VirtualMachineUpdateRequest.js");
58
65
  const VmInspectionStatus_js_1 = require("../models/VmInspectionStatus.js");
59
66
  const VmUtilizationDetails_js_1 = require("../models/VmUtilizationDetails.js");
60
67
  /**
@@ -177,6 +184,45 @@ class DefaultApi extends runtime.BaseAPI {
177
184
  yield this.deleteGroupRaw(requestParameters, initOverrides);
178
185
  });
179
186
  }
187
+ /**
188
+ * Creates request options for deleteLabelGlobally without sending the request
189
+ */
190
+ deleteLabelGloballyRequestOpts(requestParameters) {
191
+ return __awaiter(this, void 0, void 0, function* () {
192
+ if (requestParameters['label'] == null) {
193
+ throw new runtime.RequiredError('label', 'Required parameter "label" was null or undefined when calling deleteLabelGlobally().');
194
+ }
195
+ const queryParameters = {};
196
+ const headerParameters = {};
197
+ let urlPath = `/vms/labels/{label}`;
198
+ urlPath = urlPath.replace('{label}', encodeURIComponent(String(requestParameters['label'])));
199
+ return {
200
+ path: urlPath,
201
+ method: 'DELETE',
202
+ headers: headerParameters,
203
+ query: queryParameters,
204
+ };
205
+ });
206
+ }
207
+ /**
208
+ * Delete label from all VMs
209
+ */
210
+ deleteLabelGloballyRaw(requestParameters, initOverrides) {
211
+ return __awaiter(this, void 0, void 0, function* () {
212
+ const requestOptions = yield this.deleteLabelGloballyRequestOpts(requestParameters);
213
+ const response = yield this.request(requestOptions, initOverrides);
214
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, DeleteLabelGloballyResponse_js_1.DeleteLabelGloballyResponseFromJSON)(jsonValue));
215
+ });
216
+ }
217
+ /**
218
+ * Delete label from all VMs
219
+ */
220
+ deleteLabelGlobally(requestParameters, initOverrides) {
221
+ return __awaiter(this, void 0, void 0, function* () {
222
+ const response = yield this.deleteLabelGloballyRaw(requestParameters, initOverrides);
223
+ return yield response.value();
224
+ });
225
+ }
180
226
  /**
181
227
  * Creates request options for getAgentStatus without sending the request
182
228
  */
@@ -212,6 +258,80 @@ class DefaultApi extends runtime.BaseAPI {
212
258
  return yield response.value();
213
259
  });
214
260
  }
261
+ /**
262
+ * Creates request options for getApplications without sending the request
263
+ */
264
+ getApplicationsRequestOpts() {
265
+ return __awaiter(this, void 0, void 0, function* () {
266
+ const queryParameters = {};
267
+ const headerParameters = {};
268
+ let urlPath = `/applications`;
269
+ return {
270
+ path: urlPath,
271
+ method: 'GET',
272
+ headers: headerParameters,
273
+ query: queryParameters,
274
+ };
275
+ });
276
+ }
277
+ /**
278
+ * List detected applications running on VMs
279
+ */
280
+ getApplicationsRaw(initOverrides) {
281
+ return __awaiter(this, void 0, void 0, function* () {
282
+ const requestOptions = yield this.getApplicationsRequestOpts();
283
+ const response = yield this.request(requestOptions, initOverrides);
284
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, ApplicationListResponse_js_1.ApplicationListResponseFromJSON)(jsonValue));
285
+ });
286
+ }
287
+ /**
288
+ * List detected applications running on VMs
289
+ */
290
+ getApplications(initOverrides) {
291
+ return __awaiter(this, void 0, void 0, function* () {
292
+ const response = yield this.getApplicationsRaw(initOverrides);
293
+ return yield response.value();
294
+ });
295
+ }
296
+ /**
297
+ * Creates request options for getClusterUtilization without sending the request
298
+ */
299
+ getClusterUtilizationRequestOpts(requestParameters) {
300
+ return __awaiter(this, void 0, void 0, function* () {
301
+ if (requestParameters['clusterId'] == null) {
302
+ throw new runtime.RequiredError('clusterId', 'Required parameter "clusterId" was null or undefined when calling getClusterUtilization().');
303
+ }
304
+ const queryParameters = {};
305
+ const headerParameters = {};
306
+ let urlPath = `/clusters/{cluster_id}/utilization`;
307
+ urlPath = urlPath.replace('{cluster_id}', encodeURIComponent(String(requestParameters['clusterId'])));
308
+ return {
309
+ path: urlPath,
310
+ method: 'GET',
311
+ headers: headerParameters,
312
+ query: queryParameters,
313
+ };
314
+ });
315
+ }
316
+ /**
317
+ * Get latest cluster utilization by cluster ID
318
+ */
319
+ getClusterUtilizationRaw(requestParameters, initOverrides) {
320
+ return __awaiter(this, void 0, void 0, function* () {
321
+ const requestOptions = yield this.getClusterUtilizationRequestOpts(requestParameters);
322
+ const response = yield this.request(requestOptions, initOverrides);
323
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, RightsizingClusterResponse_js_1.RightsizingClusterResponseFromJSON)(jsonValue));
324
+ });
325
+ }
326
+ /**
327
+ * Get latest cluster utilization by cluster ID
328
+ */
329
+ getClusterUtilization(requestParameters, initOverrides) {
330
+ return __awaiter(this, void 0, void 0, function* () {
331
+ const response = yield this.getClusterUtilizationRaw(requestParameters, initOverrides);
332
+ return yield response.value();
333
+ });
334
+ }
215
335
  /**
216
336
  * Creates request options for getCollectorStatus without sending the request
217
337
  */
@@ -463,9 +583,6 @@ class DefaultApi extends runtime.BaseAPI {
463
583
  if (requestParameters['includeVddk'] != null) {
464
584
  queryParameters['includeVddk'] = requestParameters['includeVddk'];
465
585
  }
466
- if (requestParameters['includeCredentials'] != null) {
467
- queryParameters['includeCredentials'] = requestParameters['includeCredentials'];
468
- }
469
586
  const headerParameters = {};
470
587
  let urlPath = `/inspector`;
471
588
  return {
@@ -573,6 +690,7 @@ class DefaultApi extends runtime.BaseAPI {
573
690
  }
574
691
  /**
575
692
  * Creates request options for getLatestRightsizingClusters without sending the request
693
+ * @deprecated
576
694
  */
577
695
  getLatestRightsizingClustersRequestOpts(requestParameters) {
578
696
  return __awaiter(this, void 0, void 0, function* () {
@@ -592,6 +710,7 @@ class DefaultApi extends runtime.BaseAPI {
592
710
  }
593
711
  /**
594
712
  * Get cluster-level utilization aggregates for the latest completed report
713
+ * @deprecated
595
714
  */
596
715
  getLatestRightsizingClustersRaw(requestParameters, initOverrides) {
597
716
  return __awaiter(this, void 0, void 0, function* () {
@@ -602,6 +721,7 @@ class DefaultApi extends runtime.BaseAPI {
602
721
  }
603
722
  /**
604
723
  * Get cluster-level utilization aggregates for the latest completed report
724
+ * @deprecated
605
725
  */
606
726
  getLatestRightsizingClusters() {
607
727
  return __awaiter(this, arguments, void 0, function* (requestParameters = {}, initOverrides) {
@@ -614,13 +734,13 @@ class DefaultApi extends runtime.BaseAPI {
614
734
  */
615
735
  getRightsizingReportRequestOpts(requestParameters) {
616
736
  return __awaiter(this, void 0, void 0, function* () {
617
- if (requestParameters['id'] == null) {
618
- throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling getRightsizingReport().');
737
+ if (requestParameters['reportId'] == null) {
738
+ throw new runtime.RequiredError('reportId', 'Required parameter "reportId" was null or undefined when calling getRightsizingReport().');
619
739
  }
620
740
  const queryParameters = {};
621
741
  const headerParameters = {};
622
- let urlPath = `/rightsizing/{id}`;
623
- urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
742
+ let urlPath = `/rightsizing/{report_id}`;
743
+ urlPath = urlPath.replace('{report_id}', encodeURIComponent(String(requestParameters['reportId'])));
624
744
  return {
625
745
  path: urlPath,
626
746
  method: 'GET',
@@ -648,8 +768,52 @@ class DefaultApi extends runtime.BaseAPI {
648
768
  return yield response.value();
649
769
  });
650
770
  }
771
+ /**
772
+ * Creates request options for getRightsizingReportCluster without sending the request
773
+ */
774
+ getRightsizingReportClusterRequestOpts(requestParameters) {
775
+ return __awaiter(this, void 0, void 0, function* () {
776
+ if (requestParameters['reportId'] == null) {
777
+ throw new runtime.RequiredError('reportId', 'Required parameter "reportId" was null or undefined when calling getRightsizingReportCluster().');
778
+ }
779
+ if (requestParameters['clusterId'] == null) {
780
+ throw new runtime.RequiredError('clusterId', 'Required parameter "clusterId" was null or undefined when calling getRightsizingReportCluster().');
781
+ }
782
+ const queryParameters = {};
783
+ const headerParameters = {};
784
+ let urlPath = `/rightsizing/{report_id}/clusters/{cluster_id}`;
785
+ urlPath = urlPath.replace('{report_id}', encodeURIComponent(String(requestParameters['reportId'])));
786
+ urlPath = urlPath.replace('{cluster_id}', encodeURIComponent(String(requestParameters['clusterId'])));
787
+ return {
788
+ path: urlPath,
789
+ method: 'GET',
790
+ headers: headerParameters,
791
+ query: queryParameters,
792
+ };
793
+ });
794
+ }
795
+ /**
796
+ * Get utilization for a specific cluster from a specific report
797
+ */
798
+ getRightsizingReportClusterRaw(requestParameters, initOverrides) {
799
+ return __awaiter(this, void 0, void 0, function* () {
800
+ const requestOptions = yield this.getRightsizingReportClusterRequestOpts(requestParameters);
801
+ const response = yield this.request(requestOptions, initOverrides);
802
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, RightsizingClusterResponse_js_1.RightsizingClusterResponseFromJSON)(jsonValue));
803
+ });
804
+ }
805
+ /**
806
+ * Get utilization for a specific cluster from a specific report
807
+ */
808
+ getRightsizingReportCluster(requestParameters, initOverrides) {
809
+ return __awaiter(this, void 0, void 0, function* () {
810
+ const response = yield this.getRightsizingReportClusterRaw(requestParameters, initOverrides);
811
+ return yield response.value();
812
+ });
813
+ }
651
814
  /**
652
815
  * Creates request options for getRightsizingReportClusters without sending the request
816
+ * @deprecated
653
817
  */
654
818
  getRightsizingReportClustersRequestOpts(requestParameters) {
655
819
  return __awaiter(this, void 0, void 0, function* () {
@@ -673,6 +837,7 @@ class DefaultApi extends runtime.BaseAPI {
673
837
  }
674
838
  /**
675
839
  * Get cluster-level utilization aggregates for a specific report
840
+ * @deprecated
676
841
  */
677
842
  getRightsizingReportClustersRaw(requestParameters, initOverrides) {
678
843
  return __awaiter(this, void 0, void 0, function* () {
@@ -683,6 +848,7 @@ class DefaultApi extends runtime.BaseAPI {
683
848
  }
684
849
  /**
685
850
  * Get cluster-level utilization aggregates for a specific report
851
+ * @deprecated
686
852
  */
687
853
  getRightsizingReportClusters(requestParameters, initOverrides) {
688
854
  return __awaiter(this, void 0, void 0, function* () {
@@ -729,6 +895,41 @@ class DefaultApi extends runtime.BaseAPI {
729
895
  return yield response.value();
730
896
  });
731
897
  }
898
+ /**
899
+ * Creates request options for getVMLabels without sending the request
900
+ */
901
+ getVMLabelsRequestOpts() {
902
+ return __awaiter(this, void 0, void 0, function* () {
903
+ const queryParameters = {};
904
+ const headerParameters = {};
905
+ let urlPath = `/vms/labels`;
906
+ return {
907
+ path: urlPath,
908
+ method: 'GET',
909
+ headers: headerParameters,
910
+ query: queryParameters,
911
+ };
912
+ });
913
+ }
914
+ /**
915
+ * Get all distinct labels in use across VMs
916
+ */
917
+ getVMLabelsRaw(initOverrides) {
918
+ return __awaiter(this, void 0, void 0, function* () {
919
+ const requestOptions = yield this.getVMLabelsRequestOpts();
920
+ const response = yield this.request(requestOptions, initOverrides);
921
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, VMLabelsResponse_js_1.VMLabelsResponseFromJSON)(jsonValue));
922
+ });
923
+ }
924
+ /**
925
+ * Get all distinct labels in use across VMs
926
+ */
927
+ getVMLabels(initOverrides) {
928
+ return __awaiter(this, void 0, void 0, function* () {
929
+ const response = yield this.getVMLabelsRaw(initOverrides);
930
+ return yield response.value();
931
+ });
932
+ }
732
933
  /**
733
934
  * Creates request options for getVMUtilization without sending the request
734
935
  */
@@ -815,6 +1016,41 @@ class DefaultApi extends runtime.BaseAPI {
815
1016
  return yield response.value();
816
1017
  });
817
1018
  }
1019
+ /**
1020
+ * Creates request options for getVMsFilterOptions without sending the request
1021
+ */
1022
+ getVMsFilterOptionsRequestOpts() {
1023
+ return __awaiter(this, void 0, void 0, function* () {
1024
+ const queryParameters = {};
1025
+ const headerParameters = {};
1026
+ let urlPath = `/vms/filter-options`;
1027
+ return {
1028
+ path: urlPath,
1029
+ method: 'GET',
1030
+ headers: headerParameters,
1031
+ query: queryParameters,
1032
+ };
1033
+ });
1034
+ }
1035
+ /**
1036
+ * Get distinct filter option values for VMs
1037
+ */
1038
+ getVMsFilterOptionsRaw(initOverrides) {
1039
+ return __awaiter(this, void 0, void 0, function* () {
1040
+ const requestOptions = yield this.getVMsFilterOptionsRequestOpts();
1041
+ const response = yield this.request(requestOptions, initOverrides);
1042
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, VMFilterOptionsResponse_js_1.VMFilterOptionsResponseFromJSON)(jsonValue));
1043
+ });
1044
+ }
1045
+ /**
1046
+ * Get distinct filter option values for VMs
1047
+ */
1048
+ getVMsFilterOptions(initOverrides) {
1049
+ return __awaiter(this, void 0, void 0, function* () {
1050
+ const response = yield this.getVMsFilterOptionsRaw(initOverrides);
1051
+ return yield response.value();
1052
+ });
1053
+ }
818
1054
  /**
819
1055
  * Creates request options for getVersion without sending the request
820
1056
  */
@@ -894,6 +1130,48 @@ class DefaultApi extends runtime.BaseAPI {
894
1130
  return yield response.value();
895
1131
  });
896
1132
  }
1133
+ /**
1134
+ * Creates request options for listRightsizingReportClusters without sending the request
1135
+ */
1136
+ listRightsizingReportClustersRequestOpts(requestParameters) {
1137
+ return __awaiter(this, void 0, void 0, function* () {
1138
+ if (requestParameters['reportId'] == null) {
1139
+ throw new runtime.RequiredError('reportId', 'Required parameter "reportId" was null or undefined when calling listRightsizingReportClusters().');
1140
+ }
1141
+ const queryParameters = {};
1142
+ if (requestParameters['byExpression'] != null) {
1143
+ queryParameters['byExpression'] = requestParameters['byExpression'];
1144
+ }
1145
+ const headerParameters = {};
1146
+ let urlPath = `/rightsizing/{report_id}/clusters`;
1147
+ urlPath = urlPath.replace('{report_id}', encodeURIComponent(String(requestParameters['reportId'])));
1148
+ return {
1149
+ path: urlPath,
1150
+ method: 'GET',
1151
+ headers: headerParameters,
1152
+ query: queryParameters,
1153
+ };
1154
+ });
1155
+ }
1156
+ /**
1157
+ * Get cluster-level utilization aggregates for a specific report
1158
+ */
1159
+ listRightsizingReportClustersRaw(requestParameters, initOverrides) {
1160
+ return __awaiter(this, void 0, void 0, function* () {
1161
+ const requestOptions = yield this.listRightsizingReportClustersRequestOpts(requestParameters);
1162
+ const response = yield this.request(requestOptions, initOverrides);
1163
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, RightsizingClusterListResponse_js_1.RightsizingClusterListResponseFromJSON)(jsonValue));
1164
+ });
1165
+ }
1166
+ /**
1167
+ * Get cluster-level utilization aggregates for a specific report
1168
+ */
1169
+ listRightsizingReportClusters(requestParameters, initOverrides) {
1170
+ return __awaiter(this, void 0, void 0, function* () {
1171
+ const response = yield this.listRightsizingReportClustersRaw(requestParameters, initOverrides);
1172
+ return yield response.value();
1173
+ });
1174
+ }
897
1175
  /**
898
1176
  * Creates request options for listRightsizingReports without sending the request
899
1177
  */
@@ -1012,45 +1290,6 @@ class DefaultApi extends runtime.BaseAPI {
1012
1290
  yield this.putForecasterCredentialsRaw(requestParameters, initOverrides);
1013
1291
  });
1014
1292
  }
1015
- /**
1016
- * Creates request options for putInspectorCredentials without sending the request
1017
- */
1018
- putInspectorCredentialsRequestOpts(requestParameters) {
1019
- return __awaiter(this, void 0, void 0, function* () {
1020
- if (requestParameters['vcenterCredentials'] == null) {
1021
- throw new runtime.RequiredError('vcenterCredentials', 'Required parameter "vcenterCredentials" was null or undefined when calling putInspectorCredentials().');
1022
- }
1023
- const queryParameters = {};
1024
- const headerParameters = {};
1025
- headerParameters['Content-Type'] = 'application/json';
1026
- let urlPath = `/inspector/credentials`;
1027
- return {
1028
- path: urlPath,
1029
- method: 'PUT',
1030
- headers: headerParameters,
1031
- query: queryParameters,
1032
- body: (0, VcenterCredentials_js_1.VcenterCredentialsToJSON)(requestParameters['vcenterCredentials']),
1033
- };
1034
- });
1035
- }
1036
- /**
1037
- * Set or replace inspector credentials
1038
- */
1039
- putInspectorCredentialsRaw(requestParameters, initOverrides) {
1040
- return __awaiter(this, void 0, void 0, function* () {
1041
- const requestOptions = yield this.putInspectorCredentialsRequestOpts(requestParameters);
1042
- const response = yield this.request(requestOptions, initOverrides);
1043
- return new runtime.VoidApiResponse(response);
1044
- });
1045
- }
1046
- /**
1047
- * Set or replace inspector credentials
1048
- */
1049
- putInspectorCredentials(requestParameters, initOverrides) {
1050
- return __awaiter(this, void 0, void 0, function* () {
1051
- yield this.putInspectorCredentialsRaw(requestParameters, initOverrides);
1052
- });
1053
- }
1054
1293
  /**
1055
1294
  * Creates request options for putInspectorVddk without sending the request
1056
1295
  */
@@ -1540,5 +1779,130 @@ class DefaultApi extends runtime.BaseAPI {
1540
1779
  return yield response.value();
1541
1780
  });
1542
1781
  }
1782
+ /**
1783
+ * Creates request options for updateLabelVMs without sending the request
1784
+ */
1785
+ updateLabelVMsRequestOpts(requestParameters) {
1786
+ return __awaiter(this, void 0, void 0, function* () {
1787
+ if (requestParameters['label'] == null) {
1788
+ throw new runtime.RequiredError('label', 'Required parameter "label" was null or undefined when calling updateLabelVMs().');
1789
+ }
1790
+ if (requestParameters['updateLabelVMsRequest'] == null) {
1791
+ throw new runtime.RequiredError('updateLabelVMsRequest', 'Required parameter "updateLabelVMsRequest" was null or undefined when calling updateLabelVMs().');
1792
+ }
1793
+ const queryParameters = {};
1794
+ const headerParameters = {};
1795
+ headerParameters['Content-Type'] = 'application/json';
1796
+ let urlPath = `/vms/labels/{label}`;
1797
+ urlPath = urlPath.replace('{label}', encodeURIComponent(String(requestParameters['label'])));
1798
+ return {
1799
+ path: urlPath,
1800
+ method: 'PATCH',
1801
+ headers: headerParameters,
1802
+ query: queryParameters,
1803
+ body: (0, UpdateLabelVMsRequest_js_1.UpdateLabelVMsRequestToJSON)(requestParameters['updateLabelVMsRequest']),
1804
+ };
1805
+ });
1806
+ }
1807
+ /**
1808
+ * Modify label VM membership (add/remove label to/from VMs)
1809
+ */
1810
+ updateLabelVMsRaw(requestParameters, initOverrides) {
1811
+ return __awaiter(this, void 0, void 0, function* () {
1812
+ const requestOptions = yield this.updateLabelVMsRequestOpts(requestParameters);
1813
+ const response = yield this.request(requestOptions, initOverrides);
1814
+ return new runtime.VoidApiResponse(response);
1815
+ });
1816
+ }
1817
+ /**
1818
+ * Modify label VM membership (add/remove label to/from VMs)
1819
+ */
1820
+ updateLabelVMs(requestParameters, initOverrides) {
1821
+ return __awaiter(this, void 0, void 0, function* () {
1822
+ yield this.updateLabelVMsRaw(requestParameters, initOverrides);
1823
+ });
1824
+ }
1825
+ /**
1826
+ * Creates request options for updateVM without sending the request
1827
+ */
1828
+ updateVMRequestOpts(requestParameters) {
1829
+ return __awaiter(this, void 0, void 0, function* () {
1830
+ if (requestParameters['id'] == null) {
1831
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling updateVM().');
1832
+ }
1833
+ if (requestParameters['virtualMachineUpdateRequest'] == null) {
1834
+ throw new runtime.RequiredError('virtualMachineUpdateRequest', 'Required parameter "virtualMachineUpdateRequest" was null or undefined when calling updateVM().');
1835
+ }
1836
+ const queryParameters = {};
1837
+ const headerParameters = {};
1838
+ headerParameters['Content-Type'] = 'application/json';
1839
+ let urlPath = `/vms/{id}`;
1840
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
1841
+ return {
1842
+ path: urlPath,
1843
+ method: 'PATCH',
1844
+ headers: headerParameters,
1845
+ query: queryParameters,
1846
+ body: (0, VirtualMachineUpdateRequest_js_1.VirtualMachineUpdateRequestToJSON)(requestParameters['virtualMachineUpdateRequest']),
1847
+ };
1848
+ });
1849
+ }
1850
+ /**
1851
+ * Update VM properties
1852
+ */
1853
+ updateVMRaw(requestParameters, initOverrides) {
1854
+ return __awaiter(this, void 0, void 0, function* () {
1855
+ const requestOptions = yield this.updateVMRequestOpts(requestParameters);
1856
+ const response = yield this.request(requestOptions, initOverrides);
1857
+ return new runtime.VoidApiResponse(response);
1858
+ });
1859
+ }
1860
+ /**
1861
+ * Update VM properties
1862
+ */
1863
+ updateVM(requestParameters, initOverrides) {
1864
+ return __awaiter(this, void 0, void 0, function* () {
1865
+ yield this.updateVMRaw(requestParameters, initOverrides);
1866
+ });
1867
+ }
1868
+ /**
1869
+ * Creates request options for validateInspectorCredentials without sending the request
1870
+ */
1871
+ validateInspectorCredentialsRequestOpts(requestParameters) {
1872
+ return __awaiter(this, void 0, void 0, function* () {
1873
+ if (requestParameters['vcenterCredentials'] == null) {
1874
+ throw new runtime.RequiredError('vcenterCredentials', 'Required parameter "vcenterCredentials" was null or undefined when calling validateInspectorCredentials().');
1875
+ }
1876
+ const queryParameters = {};
1877
+ const headerParameters = {};
1878
+ headerParameters['Content-Type'] = 'application/json';
1879
+ let urlPath = `/inspector/credentials`;
1880
+ return {
1881
+ path: urlPath,
1882
+ method: 'POST',
1883
+ headers: headerParameters,
1884
+ query: queryParameters,
1885
+ body: (0, VcenterCredentials_js_1.VcenterCredentialsToJSON)(requestParameters['vcenterCredentials']),
1886
+ };
1887
+ });
1888
+ }
1889
+ /**
1890
+ * Validate vCenter credentials for inspector
1891
+ */
1892
+ validateInspectorCredentialsRaw(requestParameters, initOverrides) {
1893
+ return __awaiter(this, void 0, void 0, function* () {
1894
+ const requestOptions = yield this.validateInspectorCredentialsRequestOpts(requestParameters);
1895
+ const response = yield this.request(requestOptions, initOverrides);
1896
+ return new runtime.VoidApiResponse(response);
1897
+ });
1898
+ }
1899
+ /**
1900
+ * Validate vCenter credentials for inspector
1901
+ */
1902
+ validateInspectorCredentials(requestParameters, initOverrides) {
1903
+ return __awaiter(this, void 0, void 0, function* () {
1904
+ yield this.validateInspectorCredentialsRaw(requestParameters, initOverrides);
1905
+ });
1906
+ }
1543
1907
  }
1544
1908
  exports.DefaultApi = DefaultApi;