@openshift-migration-advisor/agent-sdk 0.33.0 → 0.33.1-693656015cf9

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 (136) hide show
  1. package/.openapi-generator/FILES +26 -0
  2. package/.openapi-generator/VERSION +1 -1
  3. package/README.md +21 -3
  4. package/dist/apis/AppliancesApi.d.ts +194 -0
  5. package/dist/apis/AppliancesApi.js +201 -0
  6. package/dist/apis/GroupsApi.d.ts +6 -6
  7. package/dist/apis/ImageUpgradeApi.d.ts +66 -0
  8. package/dist/apis/ImageUpgradeApi.js +90 -0
  9. package/dist/apis/VirtualMachinesApi.d.ts +6 -6
  10. package/dist/apis/index.d.ts +1 -0
  11. package/dist/apis/index.js +1 -0
  12. package/dist/esm/apis/AppliancesApi.d.ts +194 -0
  13. package/dist/esm/apis/AppliancesApi.js +201 -0
  14. package/dist/esm/apis/GroupsApi.d.ts +6 -6
  15. package/dist/esm/apis/ImageUpgradeApi.d.ts +66 -0
  16. package/dist/esm/apis/ImageUpgradeApi.js +86 -0
  17. package/dist/esm/apis/VirtualMachinesApi.d.ts +6 -6
  18. package/dist/esm/apis/index.d.ts +1 -0
  19. package/dist/esm/apis/index.js +1 -0
  20. package/dist/esm/models/AgentStatus.d.ts +5 -0
  21. package/dist/esm/models/AgentStatus.js +5 -0
  22. package/dist/esm/models/ApplianceRule.d.ts +90 -0
  23. package/dist/esm/models/ApplianceRule.js +98 -0
  24. package/dist/esm/models/ApplianceRuleCondition.d.ts +42 -0
  25. package/dist/esm/models/ApplianceRuleCondition.js +48 -0
  26. package/dist/esm/models/ApplianceRuleFunction.d.ts +37 -0
  27. package/dist/esm/models/ApplianceRuleFunction.js +46 -0
  28. package/dist/esm/models/ApplianceRuleListResponse.d.ts +31 -0
  29. package/dist/esm/models/ApplianceRuleListResponse.js +44 -0
  30. package/dist/esm/models/ApplianceRuleRequest.d.ts +74 -0
  31. package/dist/esm/models/ApplianceRuleRequest.js +85 -0
  32. package/dist/esm/models/DiskGeometryCondition.d.ts +47 -0
  33. package/dist/esm/models/DiskGeometryCondition.js +58 -0
  34. package/dist/esm/models/ImageUpgradeImage.d.ts +34 -0
  35. package/dist/esm/models/ImageUpgradeImage.js +47 -0
  36. package/dist/esm/models/ImageUpgradeResult.d.ts +66 -0
  37. package/dist/esm/models/ImageUpgradeResult.js +71 -0
  38. package/dist/esm/models/ImageUpgradeStatus.d.ts +44 -0
  39. package/dist/esm/models/ImageUpgradeStatus.js +57 -0
  40. package/dist/esm/models/ImageUploadStatus.d.ts +44 -0
  41. package/dist/esm/models/ImageUploadStatus.js +56 -0
  42. package/dist/esm/models/RDMBacking.d.ts +26 -0
  43. package/dist/esm/models/RDMBacking.js +17 -0
  44. package/dist/esm/models/RDMHostLun.d.ts +42 -0
  45. package/dist/esm/models/RDMHostLun.js +49 -0
  46. package/dist/esm/models/SuccessfulImageUpgrade.d.ts +38 -0
  47. package/dist/esm/models/SuccessfulImageUpgrade.js +52 -0
  48. package/dist/esm/models/VMFilterOptionsResponse.d.ts +8 -0
  49. package/dist/esm/models/VMFilterOptionsResponse.js +8 -0
  50. package/dist/esm/models/VirtualMachine.d.ts +8 -0
  51. package/dist/esm/models/VirtualMachine.js +4 -0
  52. package/dist/esm/models/VirtualMachineDisk.d.ts +8 -0
  53. package/dist/esm/models/VirtualMachineDisk.js +4 -0
  54. package/dist/esm/models/index.d.ts +12 -0
  55. package/dist/esm/models/index.js +12 -0
  56. package/dist/models/AgentStatus.d.ts +5 -0
  57. package/dist/models/AgentStatus.js +5 -0
  58. package/dist/models/ApplianceRule.d.ts +90 -0
  59. package/dist/models/ApplianceRule.js +106 -0
  60. package/dist/models/ApplianceRuleCondition.d.ts +42 -0
  61. package/dist/models/ApplianceRuleCondition.js +55 -0
  62. package/dist/models/ApplianceRuleFunction.d.ts +37 -0
  63. package/dist/models/ApplianceRuleFunction.js +53 -0
  64. package/dist/models/ApplianceRuleListResponse.d.ts +31 -0
  65. package/dist/models/ApplianceRuleListResponse.js +51 -0
  66. package/dist/models/ApplianceRuleRequest.d.ts +74 -0
  67. package/dist/models/ApplianceRuleRequest.js +93 -0
  68. package/dist/models/DiskGeometryCondition.d.ts +47 -0
  69. package/dist/models/DiskGeometryCondition.js +66 -0
  70. package/dist/models/ImageUpgradeImage.d.ts +34 -0
  71. package/dist/models/ImageUpgradeImage.js +54 -0
  72. package/dist/models/ImageUpgradeResult.d.ts +66 -0
  73. package/dist/models/ImageUpgradeResult.js +79 -0
  74. package/dist/models/ImageUpgradeStatus.d.ts +44 -0
  75. package/dist/models/ImageUpgradeStatus.js +64 -0
  76. package/dist/models/ImageUploadStatus.d.ts +44 -0
  77. package/dist/models/ImageUploadStatus.js +64 -0
  78. package/dist/models/RDMBacking.d.ts +26 -0
  79. package/dist/models/RDMBacking.js +18 -0
  80. package/dist/models/RDMHostLun.d.ts +42 -0
  81. package/dist/models/RDMHostLun.js +56 -0
  82. package/dist/models/SuccessfulImageUpgrade.d.ts +38 -0
  83. package/dist/models/SuccessfulImageUpgrade.js +59 -0
  84. package/dist/models/VMFilterOptionsResponse.d.ts +8 -0
  85. package/dist/models/VMFilterOptionsResponse.js +8 -0
  86. package/dist/models/VirtualMachine.d.ts +8 -0
  87. package/dist/models/VirtualMachine.js +4 -0
  88. package/dist/models/VirtualMachineDisk.d.ts +8 -0
  89. package/dist/models/VirtualMachineDisk.js +4 -0
  90. package/dist/models/index.d.ts +12 -0
  91. package/dist/models/index.js +12 -0
  92. package/docs/AgentStatus.md +2 -0
  93. package/docs/ApplianceRule.md +50 -0
  94. package/docs/ApplianceRuleCondition.md +39 -0
  95. package/docs/ApplianceRuleFunction.md +37 -0
  96. package/docs/ApplianceRuleListResponse.md +34 -0
  97. package/docs/ApplianceRuleRequest.md +46 -0
  98. package/docs/AppliancesApi.md +338 -0
  99. package/docs/DiskGeometryCondition.md +38 -0
  100. package/docs/GroupsApi.md +4 -4
  101. package/docs/ImageUpgradeApi.md +82 -0
  102. package/docs/ImageUpgradeImage.md +36 -0
  103. package/docs/ImageUpgradeResult.md +46 -0
  104. package/docs/ImageUpgradeStatus.md +40 -0
  105. package/docs/ImageUploadStatus.md +36 -0
  106. package/docs/RDMBacking.md +8 -0
  107. package/docs/RDMHostLun.md +41 -0
  108. package/docs/SuccessfulImageUpgrade.md +38 -0
  109. package/docs/VMFilterOptionsResponse.md +4 -0
  110. package/docs/VirtualMachine.md +4 -0
  111. package/docs/VirtualMachineDisk.md +4 -0
  112. package/docs/VirtualMachinesApi.md +4 -4
  113. package/package.json +1 -1
  114. package/src/apis/AppliancesApi.ts +393 -0
  115. package/src/apis/GroupsApi.ts +6 -6
  116. package/src/apis/ImageUpgradeApi.ts +128 -0
  117. package/src/apis/VirtualMachinesApi.ts +6 -6
  118. package/src/apis/index.ts +1 -0
  119. package/src/models/AgentStatus.ts +14 -0
  120. package/src/models/ApplianceRule.ts +159 -0
  121. package/src/models/ApplianceRuleCondition.ts +87 -0
  122. package/src/models/ApplianceRuleFunction.ts +80 -0
  123. package/src/models/ApplianceRuleListResponse.ts +72 -0
  124. package/src/models/ApplianceRuleRequest.ts +137 -0
  125. package/src/models/DiskGeometryCondition.ts +90 -0
  126. package/src/models/ImageUpgradeImage.ts +71 -0
  127. package/src/models/ImageUpgradeResult.ts +130 -0
  128. package/src/models/ImageUpgradeStatus.ts +100 -0
  129. package/src/models/ImageUploadStatus.ts +84 -0
  130. package/src/models/RDMBacking.ts +44 -0
  131. package/src/models/RDMHostLun.ts +82 -0
  132. package/src/models/SuccessfulImageUpgrade.ts +78 -0
  133. package/src/models/VMFilterOptionsResponse.ts +14 -0
  134. package/src/models/VirtualMachine.ts +12 -0
  135. package/src/models/VirtualMachineDisk.ts +12 -0
  136. package/src/models/index.ts +12 -0
@@ -22,10 +22,165 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
22
22
  };
23
23
  import * as runtime from '../runtime.js';
24
24
  import { ApplianceListResponseFromJSON, } from '../models/ApplianceListResponse.js';
25
+ import { ApplianceRuleFromJSON, } from '../models/ApplianceRule.js';
26
+ import { ApplianceRuleListResponseFromJSON, } from '../models/ApplianceRuleListResponse.js';
27
+ import { ApplianceRuleRequestToJSON, } from '../models/ApplianceRuleRequest.js';
25
28
  /**
26
29
  *
27
30
  */
28
31
  export class AppliancesApi extends runtime.BaseAPI {
32
+ /**
33
+ * Creates request options for createApplianceRule without sending the request
34
+ */
35
+ createApplianceRuleRequestOpts(requestParameters) {
36
+ return __awaiter(this, void 0, void 0, function* () {
37
+ if (requestParameters['applianceRuleRequest'] == null) {
38
+ throw new runtime.RequiredError('applianceRuleRequest', 'Required parameter "applianceRuleRequest" was null or undefined when calling createApplianceRule().');
39
+ }
40
+ const queryParameters = {};
41
+ const headerParameters = {};
42
+ headerParameters['Content-Type'] = 'application/json';
43
+ let urlPath = `/appliances/rules`;
44
+ return {
45
+ path: urlPath,
46
+ method: 'POST',
47
+ headers: headerParameters,
48
+ query: queryParameters,
49
+ body: ApplianceRuleRequestToJSON(requestParameters['applianceRuleRequest']),
50
+ };
51
+ });
52
+ }
53
+ /**
54
+ * Create an appliance rule
55
+ */
56
+ createApplianceRuleRaw(requestParameters, initOverrides) {
57
+ return __awaiter(this, void 0, void 0, function* () {
58
+ const requestOptions = yield this.createApplianceRuleRequestOpts(requestParameters);
59
+ const response = yield this.request(requestOptions, initOverrides);
60
+ return new runtime.JSONApiResponse(response, (jsonValue) => ApplianceRuleFromJSON(jsonValue));
61
+ });
62
+ }
63
+ /**
64
+ * Create an appliance rule
65
+ */
66
+ createApplianceRule(requestParameters, initOverrides) {
67
+ return __awaiter(this, void 0, void 0, function* () {
68
+ const response = yield this.createApplianceRuleRaw(requestParameters, initOverrides);
69
+ return yield response.value();
70
+ });
71
+ }
72
+ /**
73
+ * Creates request options for deleteApplianceRule without sending the request
74
+ */
75
+ deleteApplianceRuleRequestOpts(requestParameters) {
76
+ return __awaiter(this, void 0, void 0, function* () {
77
+ if (requestParameters['ruleId'] == null) {
78
+ throw new runtime.RequiredError('ruleId', 'Required parameter "ruleId" was null or undefined when calling deleteApplianceRule().');
79
+ }
80
+ const queryParameters = {};
81
+ const headerParameters = {};
82
+ let urlPath = `/appliances/rules/{ruleId}`;
83
+ urlPath = urlPath.replace('{ruleId}', encodeURIComponent(String(requestParameters['ruleId'])));
84
+ return {
85
+ path: urlPath,
86
+ method: 'DELETE',
87
+ headers: headerParameters,
88
+ query: queryParameters,
89
+ };
90
+ });
91
+ }
92
+ /**
93
+ * Delete an appliance rule
94
+ */
95
+ deleteApplianceRuleRaw(requestParameters, initOverrides) {
96
+ return __awaiter(this, void 0, void 0, function* () {
97
+ const requestOptions = yield this.deleteApplianceRuleRequestOpts(requestParameters);
98
+ const response = yield this.request(requestOptions, initOverrides);
99
+ return new runtime.VoidApiResponse(response);
100
+ });
101
+ }
102
+ /**
103
+ * Delete an appliance rule
104
+ */
105
+ deleteApplianceRule(requestParameters, initOverrides) {
106
+ return __awaiter(this, void 0, void 0, function* () {
107
+ yield this.deleteApplianceRuleRaw(requestParameters, initOverrides);
108
+ });
109
+ }
110
+ /**
111
+ * Creates request options for getApplianceRule without sending the request
112
+ */
113
+ getApplianceRuleRequestOpts(requestParameters) {
114
+ return __awaiter(this, void 0, void 0, function* () {
115
+ if (requestParameters['ruleId'] == null) {
116
+ throw new runtime.RequiredError('ruleId', 'Required parameter "ruleId" was null or undefined when calling getApplianceRule().');
117
+ }
118
+ const queryParameters = {};
119
+ const headerParameters = {};
120
+ let urlPath = `/appliances/rules/{ruleId}`;
121
+ urlPath = urlPath.replace('{ruleId}', encodeURIComponent(String(requestParameters['ruleId'])));
122
+ return {
123
+ path: urlPath,
124
+ method: 'GET',
125
+ headers: headerParameters,
126
+ query: queryParameters,
127
+ };
128
+ });
129
+ }
130
+ /**
131
+ * Get an appliance rule
132
+ */
133
+ getApplianceRuleRaw(requestParameters, initOverrides) {
134
+ return __awaiter(this, void 0, void 0, function* () {
135
+ const requestOptions = yield this.getApplianceRuleRequestOpts(requestParameters);
136
+ const response = yield this.request(requestOptions, initOverrides);
137
+ return new runtime.JSONApiResponse(response, (jsonValue) => ApplianceRuleFromJSON(jsonValue));
138
+ });
139
+ }
140
+ /**
141
+ * Get an appliance rule
142
+ */
143
+ getApplianceRule(requestParameters, initOverrides) {
144
+ return __awaiter(this, void 0, void 0, function* () {
145
+ const response = yield this.getApplianceRuleRaw(requestParameters, initOverrides);
146
+ return yield response.value();
147
+ });
148
+ }
149
+ /**
150
+ * Creates request options for listApplianceRules without sending the request
151
+ */
152
+ listApplianceRulesRequestOpts() {
153
+ return __awaiter(this, void 0, void 0, function* () {
154
+ const queryParameters = {};
155
+ const headerParameters = {};
156
+ let urlPath = `/appliances/rules`;
157
+ return {
158
+ path: urlPath,
159
+ method: 'GET',
160
+ headers: headerParameters,
161
+ query: queryParameters,
162
+ };
163
+ });
164
+ }
165
+ /**
166
+ * List appliance rules
167
+ */
168
+ listApplianceRulesRaw(initOverrides) {
169
+ return __awaiter(this, void 0, void 0, function* () {
170
+ const requestOptions = yield this.listApplianceRulesRequestOpts();
171
+ const response = yield this.request(requestOptions, initOverrides);
172
+ return new runtime.JSONApiResponse(response, (jsonValue) => ApplianceRuleListResponseFromJSON(jsonValue));
173
+ });
174
+ }
175
+ /**
176
+ * List appliance rules
177
+ */
178
+ listApplianceRules(initOverrides) {
179
+ return __awaiter(this, void 0, void 0, function* () {
180
+ const response = yield this.listApplianceRulesRaw(initOverrides);
181
+ return yield response.value();
182
+ });
183
+ }
29
184
  /**
30
185
  * Creates request options for listAppliances without sending the request
31
186
  */
@@ -65,4 +220,50 @@ export class AppliancesApi extends runtime.BaseAPI {
65
220
  return yield response.value();
66
221
  });
67
222
  }
223
+ /**
224
+ * Creates request options for updateApplianceRule without sending the request
225
+ */
226
+ updateApplianceRuleRequestOpts(requestParameters) {
227
+ return __awaiter(this, void 0, void 0, function* () {
228
+ if (requestParameters['ruleId'] == null) {
229
+ throw new runtime.RequiredError('ruleId', 'Required parameter "ruleId" was null or undefined when calling updateApplianceRule().');
230
+ }
231
+ if (requestParameters['applianceRuleRequest'] == null) {
232
+ throw new runtime.RequiredError('applianceRuleRequest', 'Required parameter "applianceRuleRequest" was null or undefined when calling updateApplianceRule().');
233
+ }
234
+ const queryParameters = {};
235
+ const headerParameters = {};
236
+ headerParameters['Content-Type'] = 'application/json';
237
+ let urlPath = `/appliances/rules/{ruleId}`;
238
+ urlPath = urlPath.replace('{ruleId}', encodeURIComponent(String(requestParameters['ruleId'])));
239
+ return {
240
+ path: urlPath,
241
+ method: 'PUT',
242
+ headers: headerParameters,
243
+ query: queryParameters,
244
+ body: ApplianceRuleRequestToJSON(requestParameters['applianceRuleRequest']),
245
+ };
246
+ });
247
+ }
248
+ /**
249
+ * Full replacement of the rule with this id, including its conditions. When no rule has this id a new rule is created and the response carries the server assigned id, which differs from the id in the path.
250
+ * Replace an appliance rule
251
+ */
252
+ updateApplianceRuleRaw(requestParameters, initOverrides) {
253
+ return __awaiter(this, void 0, void 0, function* () {
254
+ const requestOptions = yield this.updateApplianceRuleRequestOpts(requestParameters);
255
+ const response = yield this.request(requestOptions, initOverrides);
256
+ return new runtime.JSONApiResponse(response, (jsonValue) => ApplianceRuleFromJSON(jsonValue));
257
+ });
258
+ }
259
+ /**
260
+ * Full replacement of the rule with this id, including its conditions. When no rule has this id a new rule is created and the response carries the server assigned id, which differs from the id in the path.
261
+ * Replace an appliance rule
262
+ */
263
+ updateApplianceRule(requestParameters, initOverrides) {
264
+ return __awaiter(this, void 0, void 0, function* () {
265
+ const response = yield this.updateApplianceRuleRaw(requestParameters, initOverrides);
266
+ return yield response.value();
267
+ });
268
+ }
68
269
  }
@@ -39,7 +39,7 @@ export interface GetGroupRequest {
39
39
  */
40
40
  groupId: string;
41
41
  /**
42
- * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
42
+ * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
43
43
  */
44
44
  sort?: Array<string>;
45
45
  /**
@@ -57,7 +57,7 @@ export interface GetLatestGroupRequest {
57
57
  */
58
58
  groupId: string;
59
59
  /**
60
- * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
60
+ * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
61
61
  */
62
62
  sort?: Array<string>;
63
63
  /**
@@ -174,7 +174,7 @@ export interface GroupsApiInterface {
174
174
  * Creates request options for getGroup without sending the request
175
175
  * @param {string} id Collection ID
176
176
  * @param {string} groupId Group ID
177
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
177
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
178
178
  * @param {number} [page] Page number for pagination
179
179
  * @param {number} [pageSize] Number of items per page
180
180
  * @throws {RequiredError}
@@ -186,7 +186,7 @@ export interface GroupsApiInterface {
186
186
  * @summary Get group by ID with its VirtualMachines
187
187
  * @param {string} id Collection ID
188
188
  * @param {string} groupId Group ID
189
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
189
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
190
190
  * @param {number} [page] Page number for pagination
191
191
  * @param {number} [pageSize] Number of items per page
192
192
  * @param {*} [options] Override http request option.
@@ -201,7 +201,7 @@ export interface GroupsApiInterface {
201
201
  /**
202
202
  * Creates request options for getLatestGroup without sending the request
203
203
  * @param {string} groupId Group ID
204
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
204
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
205
205
  * @param {number} [page] Page number for pagination
206
206
  * @param {number} [pageSize] Number of items per page
207
207
  * @throws {RequiredError}
@@ -212,7 +212,7 @@ export interface GroupsApiInterface {
212
212
  *
213
213
  * @summary Get group by ID from the latest collection
214
214
  * @param {string} groupId Group ID
215
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
215
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
216
216
  * @param {number} [page] Page number for pagination
217
217
  * @param {number} [pageSize] Number of items per page
218
218
  * @param {*} [options] Override http request option.
@@ -0,0 +1,66 @@
1
+ /**
2
+ * Assisted Migration Agent API
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: v2
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import * as runtime from '../runtime.js';
13
+ export interface PostImageUpgradeRequest {
14
+ /**
15
+ * OCI archive; maximum file payload is 3 GiB
16
+ */
17
+ file: Blob;
18
+ }
19
+ /**
20
+ * ImageUpgradeApi - interface
21
+ *
22
+ * @export
23
+ * @interface ImageUpgradeApiInterface
24
+ */
25
+ export interface ImageUpgradeApiInterface {
26
+ /**
27
+ * Creates request options for postImageUpgrade without sending the request
28
+ * @param {Blob} file OCI archive; maximum file payload is 3 GiB
29
+ * @throws {RequiredError}
30
+ * @memberof ImageUpgradeApiInterface
31
+ */
32
+ postImageUpgradeRequestOpts(requestParameters: PostImageUpgradeRequest): Promise<runtime.RequestOpts>;
33
+ /**
34
+ * Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
35
+ * @summary Upload an OCI image for a disconnected appliance image upgrade
36
+ * @param {Blob} file OCI archive; maximum file payload is 3 GiB
37
+ * @param {*} [options] Override http request option.
38
+ * @throws {RequiredError}
39
+ * @memberof ImageUpgradeApiInterface
40
+ */
41
+ postImageUpgradeRaw(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
42
+ /**
43
+ * Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
44
+ * Upload an OCI image for a disconnected appliance image upgrade
45
+ */
46
+ postImageUpgrade(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
47
+ }
48
+ /**
49
+ *
50
+ */
51
+ export declare class ImageUpgradeApi extends runtime.BaseAPI implements ImageUpgradeApiInterface {
52
+ /**
53
+ * Creates request options for postImageUpgrade without sending the request
54
+ */
55
+ postImageUpgradeRequestOpts(requestParameters: PostImageUpgradeRequest): Promise<runtime.RequestOpts>;
56
+ /**
57
+ * Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
58
+ * Upload an OCI image for a disconnected appliance image upgrade
59
+ */
60
+ postImageUpgradeRaw(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
61
+ /**
62
+ * Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
63
+ * Upload an OCI image for a disconnected appliance image upgrade
64
+ */
65
+ postImageUpgrade(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
66
+ }
@@ -0,0 +1,86 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Assisted Migration Agent API
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: v2
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
15
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16
+ return new (P || (P = Promise))(function (resolve, reject) {
17
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
18
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
19
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
20
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
21
+ });
22
+ };
23
+ import * as runtime from '../runtime.js';
24
+ /**
25
+ *
26
+ */
27
+ export class ImageUpgradeApi extends runtime.BaseAPI {
28
+ /**
29
+ * Creates request options for postImageUpgrade without sending the request
30
+ */
31
+ postImageUpgradeRequestOpts(requestParameters) {
32
+ return __awaiter(this, void 0, void 0, function* () {
33
+ if (requestParameters['file'] == null) {
34
+ throw new runtime.RequiredError('file', 'Required parameter "file" was null or undefined when calling postImageUpgrade().');
35
+ }
36
+ const queryParameters = {};
37
+ const headerParameters = {};
38
+ const consumes = [
39
+ { contentType: 'multipart/form-data' },
40
+ ];
41
+ // @ts-ignore: canConsumeForm may be unused
42
+ const canConsumeForm = runtime.canConsumeForm(consumes);
43
+ let formParams;
44
+ let useForm = false;
45
+ // use FormData to transmit files using content-type "multipart/form-data"
46
+ useForm = canConsumeForm;
47
+ if (useForm) {
48
+ formParams = new FormData();
49
+ }
50
+ else {
51
+ formParams = new URLSearchParams();
52
+ }
53
+ if (requestParameters['file'] != null) {
54
+ formParams.append('file', requestParameters['file']);
55
+ }
56
+ let urlPath = `/image-upgrades`;
57
+ return {
58
+ path: urlPath,
59
+ method: 'POST',
60
+ headers: headerParameters,
61
+ query: queryParameters,
62
+ body: formParams,
63
+ };
64
+ });
65
+ }
66
+ /**
67
+ * Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
68
+ * Upload an OCI image for a disconnected appliance image upgrade
69
+ */
70
+ postImageUpgradeRaw(requestParameters, initOverrides) {
71
+ return __awaiter(this, void 0, void 0, function* () {
72
+ const requestOptions = yield this.postImageUpgradeRequestOpts(requestParameters);
73
+ const response = yield this.request(requestOptions, initOverrides);
74
+ return new runtime.VoidApiResponse(response);
75
+ });
76
+ }
77
+ /**
78
+ * Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
79
+ * Upload an OCI image for a disconnected appliance image upgrade
80
+ */
81
+ postImageUpgrade(requestParameters, initOverrides) {
82
+ return __awaiter(this, void 0, void 0, function* () {
83
+ yield this.postImageUpgradeRaw(requestParameters, initOverrides);
84
+ });
85
+ }
86
+ }
@@ -81,7 +81,7 @@ export interface ListLatestVirtualMachinesRequest {
81
81
  */
82
82
  byExpression?: string;
83
83
  /**
84
- * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
84
+ * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
85
85
  */
86
86
  sort?: Array<string>;
87
87
  /**
@@ -103,7 +103,7 @@ export interface ListVirtualMachinesRequest {
103
103
  */
104
104
  byExpression?: string;
105
105
  /**
106
- * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
106
+ * Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
107
107
  */
108
108
  sort?: Array<string>;
109
109
  /**
@@ -345,7 +345,7 @@ export interface VirtualMachinesApiInterface {
345
345
  /**
346
346
  * Creates request options for listLatestVirtualMachines without sending the request
347
347
  * @param {string} [byExpression] Filter by expression
348
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
348
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
349
349
  * @param {number} [page] Page number for pagination
350
350
  * @param {number} [pageSize] Number of items per page
351
351
  * @throws {RequiredError}
@@ -356,7 +356,7 @@ export interface VirtualMachinesApiInterface {
356
356
  *
357
357
  * @summary List VirtualMachines from the latest collection
358
358
  * @param {string} [byExpression] Filter by expression
359
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
359
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
360
360
  * @param {number} [page] Page number for pagination
361
361
  * @param {number} [pageSize] Number of items per page
362
362
  * @param {*} [options] Override http request option.
@@ -372,7 +372,7 @@ export interface VirtualMachinesApiInterface {
372
372
  * Creates request options for listVirtualMachines without sending the request
373
373
  * @param {string} id Collection ID
374
374
  * @param {string} [byExpression] Filter by expression
375
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
375
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
376
376
  * @param {number} [page] Page number for pagination
377
377
  * @param {number} [pageSize] Number of items per page
378
378
  * @throws {RequiredError}
@@ -384,7 +384,7 @@ export interface VirtualMachinesApiInterface {
384
384
  * @summary List VirtualMachines in a collection
385
385
  * @param {string} id Collection ID
386
386
  * @param {string} [byExpression] Filter by expression
387
- * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
387
+ * @param {Array<string>} [sort] Sort fields with direction (e.g., \&quot;name:asc\&quot;, \&quot;cluster:desc\&quot;). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
388
388
  * @param {number} [page] Page number for pagination
389
389
  * @param {number} [pageSize] Number of items per page
390
390
  * @param {*} [options] Override http request option.
@@ -6,6 +6,7 @@ export * from './CollectorApi.js';
6
6
  export * from './CredentialsApi.js';
7
7
  export * from './ForecasterApi.js';
8
8
  export * from './GroupsApi.js';
9
+ export * from './ImageUpgradeApi.js';
9
10
  export * from './InspectorApi.js';
10
11
  export * from './InventoriesApi.js';
11
12
  export * from './RightsizingApi.js';
@@ -8,6 +8,7 @@ export * from './CollectorApi.js';
8
8
  export * from './CredentialsApi.js';
9
9
  export * from './ForecasterApi.js';
10
10
  export * from './GroupsApi.js';
11
+ export * from './ImageUpgradeApi.js';
11
12
  export * from './InspectorApi.js';
12
13
  export * from './InventoriesApi.js';
13
14
  export * from './RightsizingApi.js';
@@ -9,6 +9,7 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
+ import type { ImageUpgradeStatus } from './ImageUpgradeStatus.js';
12
13
  import type { AgentStatusConsoleConnection } from './AgentStatusConsoleConnection.js';
13
14
  /**
14
15
  *
@@ -28,6 +29,10 @@ export interface AgentStatus {
28
29
  * RVTool mode enabled
29
30
  */
30
31
  rvtoolsModeEnabled?: boolean;
32
+ /**
33
+ * Always present in both connected and disconnected modes, including while the console is unreachable. Includes upload activity and the last host image upgrade result. Image upgrade status errors do not fail the agent-status response.
34
+ */
35
+ imageUpgradeStatus: ImageUpgradeStatus;
31
36
  }
32
37
  /**
33
38
  * @export
@@ -11,6 +11,7 @@
11
11
  * https://openapi-generator.tech
12
12
  * Do not edit the class manually.
13
13
  */
14
+ import { ImageUpgradeStatusFromJSON, ImageUpgradeStatusToJSON, } from './ImageUpgradeStatus.js';
14
15
  import { AgentStatusConsoleConnectionFromJSON, AgentStatusConsoleConnectionToJSON, } from './AgentStatusConsoleConnection.js';
15
16
  /**
16
17
  * @export
@@ -27,6 +28,8 @@ export function instanceOfAgentStatus(value) {
27
28
  return false;
28
29
  if (!('consoleConnection' in value) || value['consoleConnection'] === undefined)
29
30
  return false;
31
+ if (!('imageUpgradeStatus' in value) || value['imageUpgradeStatus'] === undefined)
32
+ return false;
30
33
  return true;
31
34
  }
32
35
  export function AgentStatusFromJSON(json) {
@@ -40,6 +43,7 @@ export function AgentStatusFromJSONTyped(json, ignoreDiscriminator) {
40
43
  'mode': json['mode'],
41
44
  'consoleConnection': AgentStatusConsoleConnectionFromJSON(json['consoleConnection']),
42
45
  'rvtoolsModeEnabled': json['rvtoolsModeEnabled'] == null ? undefined : json['rvtoolsModeEnabled'],
46
+ 'imageUpgradeStatus': ImageUpgradeStatusFromJSON(json['imageUpgradeStatus']),
43
47
  };
44
48
  }
45
49
  export function AgentStatusToJSON(json) {
@@ -53,5 +57,6 @@ export function AgentStatusToJSONTyped(value, ignoreDiscriminator = false) {
53
57
  'mode': value['mode'],
54
58
  'consoleConnection': AgentStatusConsoleConnectionToJSON(value['consoleConnection']),
55
59
  'rvtoolsModeEnabled': value['rvtoolsModeEnabled'],
60
+ 'imageUpgradeStatus': ImageUpgradeStatusToJSON(value['imageUpgradeStatus']),
56
61
  };
57
62
  }
@@ -0,0 +1,90 @@
1
+ /**
2
+ * Assisted Migration Agent API
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: v2
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { ApplianceRuleCondition } from './ApplianceRuleCondition.js';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface ApplianceRule
17
+ */
18
+ export interface ApplianceRule {
19
+ /**
20
+ * Rule ID
21
+ */
22
+ id?: string;
23
+ /**
24
+ * Appliance product name
25
+ */
26
+ name: string;
27
+ /**
28
+ * Appliance vendor
29
+ */
30
+ vendor: string;
31
+ /**
32
+ * Appliance category
33
+ */
34
+ category: string;
35
+ /**
36
+ * OSV migration verdict
37
+ */
38
+ osv_verdict: ApplianceRuleOsvVerdictEnum;
39
+ /**
40
+ * Confidence ceiling for this rule
41
+ */
42
+ max_confidence: ApplianceRuleMaxConfidenceEnum;
43
+ /**
44
+ * Kind of rules either default or custom
45
+ */
46
+ kind: ApplianceRuleKindEnum;
47
+ /**
48
+ * Number of conditions that must match before the rule fires
49
+ */
50
+ min_matched: number;
51
+ /**
52
+ *
53
+ */
54
+ conditions: Array<ApplianceRuleCondition>;
55
+ }
56
+ /**
57
+ * @export
58
+ */
59
+ export declare const ApplianceRuleOsvVerdictEnum: {
60
+ readonly Blocked: "blocked";
61
+ readonly Conditional: "conditional";
62
+ readonly Supported: "supported";
63
+ readonly Unknown: "unknown";
64
+ };
65
+ export type ApplianceRuleOsvVerdictEnum = typeof ApplianceRuleOsvVerdictEnum[keyof typeof ApplianceRuleOsvVerdictEnum];
66
+ /**
67
+ * @export
68
+ */
69
+ export declare const ApplianceRuleMaxConfidenceEnum: {
70
+ readonly High: "high";
71
+ readonly Medium: "medium";
72
+ readonly Low: "low";
73
+ };
74
+ export type ApplianceRuleMaxConfidenceEnum = typeof ApplianceRuleMaxConfidenceEnum[keyof typeof ApplianceRuleMaxConfidenceEnum];
75
+ /**
76
+ * @export
77
+ */
78
+ export declare const ApplianceRuleKindEnum: {
79
+ readonly Default: "default";
80
+ readonly Custom: "custom";
81
+ };
82
+ export type ApplianceRuleKindEnum = typeof ApplianceRuleKindEnum[keyof typeof ApplianceRuleKindEnum];
83
+ /**
84
+ * Check if a given object implements the ApplianceRule interface.
85
+ */
86
+ export declare function instanceOfApplianceRule(value: object): value is ApplianceRule;
87
+ export declare function ApplianceRuleFromJSON(json: any): ApplianceRule;
88
+ export declare function ApplianceRuleFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApplianceRule;
89
+ export declare function ApplianceRuleToJSON(json: any): ApplianceRule;
90
+ export declare function ApplianceRuleToJSONTyped(value?: ApplianceRule | null, ignoreDiscriminator?: boolean): any;