@openshift-migration-advisor/agent-sdk 0.20.1-bf086d122d0f → 0.20.2-01f58bf215ef

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/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # @openshift-migration-advisor/agent-sdk@0.20.1-bf086d122d0f
1
+ # @openshift-migration-advisor/agent-sdk@0.20.2-01f58bf215ef
2
2
 
3
3
  A TypeScript SDK client for the raw.githubusercontent.com API.
4
4
 
@@ -54,6 +54,7 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v2*
54
54
  *CollectionsApi* | [**listCollections**](docs/CollectionsApi.md#listcollections) | **GET** /collections | List all collections
55
55
  *CollectorApi* | [**getCollectorStatus**](docs/CollectorApi.md#getcollectorstatus) | **GET** /collector | Get collector status
56
56
  *CollectorApi* | [**startCollector**](docs/CollectorApi.md#startcollector) | **POST** /collector | Start a collection
57
+ *CollectorApi* | [**startRvtoolsCollector**](docs/CollectorApi.md#startrvtoolscollector) | **POST** /collector/rvtools | Start a collection from RVTools files
57
58
  *CollectorApi* | [**stopCollector**](docs/CollectorApi.md#stopcollector) | **DELETE** /collector | Stop collector
58
59
  *CredentialsApi* | [**deleteCredentials**](docs/CredentialsApi.md#deletecredentials) | **DELETE** /credentials | Delete stored credentials
59
60
  *CredentialsApi* | [**getCredentialCapabilities**](docs/CredentialsApi.md#getcredentialcapabilities) | **GET** /credentials/capabilities | Check vSphere operation capabilities
@@ -196,7 +197,7 @@ and is automatically generated by the
196
197
  [OpenAPI Generator](https://openapi-generator.tech) project:
197
198
 
198
199
  - API version: `v2`
199
- - Package version: `0.20.1-bf086d122d0f`
200
+ - Package version: `0.20.2-01f58bf215ef`
200
201
  - Generator version: `7.25.0-SNAPSHOT`
201
202
  - Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
202
203
 
@@ -11,6 +11,12 @@
11
11
  */
12
12
  import * as runtime from '../runtime.js';
13
13
  import { type CollectorStatus } from '../models/CollectorStatus.js';
14
+ export interface StartRvtoolsCollectorRequest {
15
+ /**
16
+ *
17
+ */
18
+ files: Array<Blob>;
19
+ }
14
20
  /**
15
21
  * CollectorApi - interface
16
22
  *
@@ -54,6 +60,26 @@ export interface CollectorApiInterface {
54
60
  * Start a collection
55
61
  */
56
62
  startCollector(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
63
+ /**
64
+ * Creates request options for startRvtoolsCollector without sending the request
65
+ * @param {Array<Blob>} files
66
+ * @throws {RequiredError}
67
+ * @memberof CollectorApiInterface
68
+ */
69
+ startRvtoolsCollectorRequestOpts(requestParameters: StartRvtoolsCollectorRequest): Promise<runtime.RequestOpts>;
70
+ /**
71
+ *
72
+ * @summary Start a collection from RVTools files
73
+ * @param {Array<Blob>} files
74
+ * @param {*} [options] Override http request option.
75
+ * @throws {RequiredError}
76
+ * @memberof CollectorApiInterface
77
+ */
78
+ startRvtoolsCollectorRaw(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CollectorStatus>>;
79
+ /**
80
+ * Start a collection from RVTools files
81
+ */
82
+ startRvtoolsCollector(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
57
83
  /**
58
84
  * Creates request options for stopCollector without sending the request
59
85
  * @throws {RequiredError}
@@ -101,6 +127,18 @@ export declare class CollectorApi extends runtime.BaseAPI implements CollectorAp
101
127
  * Start a collection
102
128
  */
103
129
  startCollector(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
130
+ /**
131
+ * Creates request options for startRvtoolsCollector without sending the request
132
+ */
133
+ startRvtoolsCollectorRequestOpts(requestParameters: StartRvtoolsCollectorRequest): Promise<runtime.RequestOpts>;
134
+ /**
135
+ * Start a collection from RVTools files
136
+ */
137
+ startRvtoolsCollectorRaw(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CollectorStatus>>;
138
+ /**
139
+ * Start a collection from RVTools files
140
+ */
141
+ startRvtoolsCollector(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
104
142
  /**
105
143
  * Creates request options for stopCollector without sending the request
106
144
  */
@@ -99,6 +99,65 @@ class CollectorApi extends runtime.BaseAPI {
99
99
  return yield response.value();
100
100
  });
101
101
  }
102
+ /**
103
+ * Creates request options for startRvtoolsCollector without sending the request
104
+ */
105
+ startRvtoolsCollectorRequestOpts(requestParameters) {
106
+ return __awaiter(this, void 0, void 0, function* () {
107
+ if (requestParameters['files'] == null) {
108
+ throw new runtime.RequiredError('files', 'Required parameter "files" was null or undefined when calling startRvtoolsCollector().');
109
+ }
110
+ const queryParameters = {};
111
+ const headerParameters = {};
112
+ const consumes = [
113
+ { contentType: 'multipart/form-data' },
114
+ ];
115
+ // @ts-ignore: canConsumeForm may be unused
116
+ const canConsumeForm = runtime.canConsumeForm(consumes);
117
+ let formParams;
118
+ let useForm = false;
119
+ // use FormData to transmit files using content-type "multipart/form-data"
120
+ useForm = canConsumeForm;
121
+ if (useForm) {
122
+ formParams = new FormData();
123
+ }
124
+ else {
125
+ formParams = new URLSearchParams();
126
+ }
127
+ if (requestParameters['files'] != null) {
128
+ requestParameters['files'].forEach((element) => {
129
+ formParams.append('files', element);
130
+ });
131
+ }
132
+ let urlPath = `/collector/rvtools`;
133
+ return {
134
+ path: urlPath,
135
+ method: 'POST',
136
+ headers: headerParameters,
137
+ query: queryParameters,
138
+ body: formParams,
139
+ };
140
+ });
141
+ }
142
+ /**
143
+ * Start a collection from RVTools files
144
+ */
145
+ startRvtoolsCollectorRaw(requestParameters, initOverrides) {
146
+ return __awaiter(this, void 0, void 0, function* () {
147
+ const requestOptions = yield this.startRvtoolsCollectorRequestOpts(requestParameters);
148
+ const response = yield this.request(requestOptions, initOverrides);
149
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, CollectorStatus_js_1.CollectorStatusFromJSON)(jsonValue));
150
+ });
151
+ }
152
+ /**
153
+ * Start a collection from RVTools files
154
+ */
155
+ startRvtoolsCollector(requestParameters, initOverrides) {
156
+ return __awaiter(this, void 0, void 0, function* () {
157
+ const response = yield this.startRvtoolsCollectorRaw(requestParameters, initOverrides);
158
+ return yield response.value();
159
+ });
160
+ }
102
161
  /**
103
162
  * Creates request options for stopCollector without sending the request
104
163
  */
@@ -11,6 +11,12 @@
11
11
  */
12
12
  import * as runtime from '../runtime.js';
13
13
  import { type CollectorStatus } from '../models/CollectorStatus.js';
14
+ export interface StartRvtoolsCollectorRequest {
15
+ /**
16
+ *
17
+ */
18
+ files: Array<Blob>;
19
+ }
14
20
  /**
15
21
  * CollectorApi - interface
16
22
  *
@@ -54,6 +60,26 @@ export interface CollectorApiInterface {
54
60
  * Start a collection
55
61
  */
56
62
  startCollector(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
63
+ /**
64
+ * Creates request options for startRvtoolsCollector without sending the request
65
+ * @param {Array<Blob>} files
66
+ * @throws {RequiredError}
67
+ * @memberof CollectorApiInterface
68
+ */
69
+ startRvtoolsCollectorRequestOpts(requestParameters: StartRvtoolsCollectorRequest): Promise<runtime.RequestOpts>;
70
+ /**
71
+ *
72
+ * @summary Start a collection from RVTools files
73
+ * @param {Array<Blob>} files
74
+ * @param {*} [options] Override http request option.
75
+ * @throws {RequiredError}
76
+ * @memberof CollectorApiInterface
77
+ */
78
+ startRvtoolsCollectorRaw(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CollectorStatus>>;
79
+ /**
80
+ * Start a collection from RVTools files
81
+ */
82
+ startRvtoolsCollector(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
57
83
  /**
58
84
  * Creates request options for stopCollector without sending the request
59
85
  * @throws {RequiredError}
@@ -101,6 +127,18 @@ export declare class CollectorApi extends runtime.BaseAPI implements CollectorAp
101
127
  * Start a collection
102
128
  */
103
129
  startCollector(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
130
+ /**
131
+ * Creates request options for startRvtoolsCollector without sending the request
132
+ */
133
+ startRvtoolsCollectorRequestOpts(requestParameters: StartRvtoolsCollectorRequest): Promise<runtime.RequestOpts>;
134
+ /**
135
+ * Start a collection from RVTools files
136
+ */
137
+ startRvtoolsCollectorRaw(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CollectorStatus>>;
138
+ /**
139
+ * Start a collection from RVTools files
140
+ */
141
+ startRvtoolsCollector(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
104
142
  /**
105
143
  * Creates request options for stopCollector without sending the request
106
144
  */
@@ -96,6 +96,65 @@ export class CollectorApi extends runtime.BaseAPI {
96
96
  return yield response.value();
97
97
  });
98
98
  }
99
+ /**
100
+ * Creates request options for startRvtoolsCollector without sending the request
101
+ */
102
+ startRvtoolsCollectorRequestOpts(requestParameters) {
103
+ return __awaiter(this, void 0, void 0, function* () {
104
+ if (requestParameters['files'] == null) {
105
+ throw new runtime.RequiredError('files', 'Required parameter "files" was null or undefined when calling startRvtoolsCollector().');
106
+ }
107
+ const queryParameters = {};
108
+ const headerParameters = {};
109
+ const consumes = [
110
+ { contentType: 'multipart/form-data' },
111
+ ];
112
+ // @ts-ignore: canConsumeForm may be unused
113
+ const canConsumeForm = runtime.canConsumeForm(consumes);
114
+ let formParams;
115
+ let useForm = false;
116
+ // use FormData to transmit files using content-type "multipart/form-data"
117
+ useForm = canConsumeForm;
118
+ if (useForm) {
119
+ formParams = new FormData();
120
+ }
121
+ else {
122
+ formParams = new URLSearchParams();
123
+ }
124
+ if (requestParameters['files'] != null) {
125
+ requestParameters['files'].forEach((element) => {
126
+ formParams.append('files', element);
127
+ });
128
+ }
129
+ let urlPath = `/collector/rvtools`;
130
+ return {
131
+ path: urlPath,
132
+ method: 'POST',
133
+ headers: headerParameters,
134
+ query: queryParameters,
135
+ body: formParams,
136
+ };
137
+ });
138
+ }
139
+ /**
140
+ * Start a collection from RVTools files
141
+ */
142
+ startRvtoolsCollectorRaw(requestParameters, initOverrides) {
143
+ return __awaiter(this, void 0, void 0, function* () {
144
+ const requestOptions = yield this.startRvtoolsCollectorRequestOpts(requestParameters);
145
+ const response = yield this.request(requestOptions, initOverrides);
146
+ return new runtime.JSONApiResponse(response, (jsonValue) => CollectorStatusFromJSON(jsonValue));
147
+ });
148
+ }
149
+ /**
150
+ * Start a collection from RVTools files
151
+ */
152
+ startRvtoolsCollector(requestParameters, initOverrides) {
153
+ return __awaiter(this, void 0, void 0, function* () {
154
+ const response = yield this.startRvtoolsCollectorRaw(requestParameters, initOverrides);
155
+ return yield response.value();
156
+ });
157
+ }
99
158
  /**
100
159
  * Creates request options for stopCollector without sending the request
101
160
  */
@@ -24,6 +24,10 @@ export interface AgentStatus {
24
24
  *
25
25
  */
26
26
  consoleConnection: AgentStatusConsoleConnection;
27
+ /**
28
+ * RVTool mode enabled
29
+ */
30
+ rvtoolsModeEnabled?: boolean;
27
31
  }
28
32
  /**
29
33
  * @export
@@ -39,6 +39,7 @@ export function AgentStatusFromJSONTyped(json, ignoreDiscriminator) {
39
39
  return {
40
40
  'mode': json['mode'],
41
41
  'consoleConnection': AgentStatusConsoleConnectionFromJSON(json['consoleConnection']),
42
+ 'rvtoolsModeEnabled': json['rvtoolsModeEnabled'] == null ? undefined : json['rvtoolsModeEnabled'],
42
43
  };
43
44
  }
44
45
  export function AgentStatusToJSON(json) {
@@ -51,5 +52,6 @@ export function AgentStatusToJSONTyped(value, ignoreDiscriminator = false) {
51
52
  return {
52
53
  'mode': value['mode'],
53
54
  'consoleConnection': AgentStatusConsoleConnectionToJSON(value['consoleConnection']),
55
+ 'rvtoolsModeEnabled': value['rvtoolsModeEnabled'],
54
56
  };
55
57
  }
@@ -39,6 +39,14 @@ export interface Host {
39
39
  * Host memory in MB
40
40
  */
41
41
  memoryMB?: number | null;
42
+ /**
43
+ * Whether vMotion is supported on this host (HostSystem.capability.vmotionSupported)
44
+ */
45
+ vmotionSupported?: boolean;
46
+ /**
47
+ * Whether Storage vMotion is supported on this host (HostSystem.capability.storageVMotionSupported)
48
+ */
49
+ storageVmotionSupported?: boolean;
42
50
  }
43
51
  /**
44
52
  * Check if a given object implements the Host interface.
@@ -35,6 +35,8 @@ export function HostFromJSONTyped(json, ignoreDiscriminator) {
35
35
  'cpuCores': json['cpuCores'] === undefined ? undefined : json['cpuCores'] === null ? null : json['cpuCores'],
36
36
  'cpuSockets': json['cpuSockets'] === undefined ? undefined : json['cpuSockets'] === null ? null : json['cpuSockets'],
37
37
  'memoryMB': json['memoryMB'] === undefined ? undefined : json['memoryMB'] === null ? null : json['memoryMB'],
38
+ 'vmotionSupported': json['vmotionSupported'] == null ? undefined : json['vmotionSupported'],
39
+ 'storageVmotionSupported': json['storageVmotionSupported'] == null ? undefined : json['storageVmotionSupported'],
38
40
  };
39
41
  }
40
42
  export function HostToJSON(json) {
@@ -51,5 +53,7 @@ export function HostToJSONTyped(value, ignoreDiscriminator = false) {
51
53
  'cpuCores': value['cpuCores'],
52
54
  'cpuSockets': value['cpuSockets'],
53
55
  'memoryMB': value['memoryMB'],
56
+ 'vmotionSupported': value['vmotionSupported'],
57
+ 'storageVmotionSupported': value['storageVmotionSupported'],
54
58
  };
55
59
  }
@@ -19,6 +19,10 @@ export interface InspectionStatus {
19
19
  * Current inspection state
20
20
  */
21
21
  state: InspectionStatusStateEnum;
22
+ /**
23
+ * Human-readable details about the current inspection state
24
+ */
25
+ details?: string;
22
26
  /**
23
27
  * Error message when state is error
24
28
  */
@@ -38,6 +38,7 @@ export function InspectionStatusFromJSONTyped(json, ignoreDiscriminator) {
38
38
  }
39
39
  return {
40
40
  'state': json['state'],
41
+ 'details': json['details'] == null ? undefined : json['details'],
41
42
  'error': json['error'] == null ? undefined : json['error'],
42
43
  };
43
44
  }
@@ -50,6 +51,7 @@ export function InspectionStatusToJSONTyped(value, ignoreDiscriminator = false)
50
51
  }
51
52
  return {
52
53
  'state': value['state'],
54
+ 'details': value['details'],
53
55
  'error': value['error'],
54
56
  };
55
57
  }
@@ -10,6 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import type { VirtualMachineInspectionResults } from './VirtualMachineInspectionResults.js';
13
+ import type { InspectionStatus } from './InspectionStatus.js';
13
14
  import type { GuestNetwork } from './GuestNetwork.js';
14
15
  import type { VirtualMachineIssue } from './VirtualMachineIssue.js';
15
16
  import type { VirtualMachineDevice } from './VirtualMachineDevice.js';
@@ -115,6 +116,10 @@ export interface VirtualMachineDetail {
115
116
  * Whether this VM is excluded from migration
116
117
  */
117
118
  migrationExcluded?: boolean;
119
+ /**
120
+ *
121
+ */
122
+ inspectionStatus?: InspectionStatus;
118
123
  /**
119
124
  * User-defined labels for this VM
120
125
  */
@@ -12,6 +12,7 @@
12
12
  * Do not edit the class manually.
13
13
  */
14
14
  import { VirtualMachineInspectionResultsFromJSON, VirtualMachineInspectionResultsToJSON, } from './VirtualMachineInspectionResults.js';
15
+ import { InspectionStatusFromJSON, InspectionStatusToJSON, } from './InspectionStatus.js';
15
16
  import { GuestNetworkFromJSON, GuestNetworkToJSON, } from './GuestNetwork.js';
16
17
  import { VirtualMachineIssueFromJSON, VirtualMachineIssueToJSON, } from './VirtualMachineIssue.js';
17
18
  import { VirtualMachineDeviceFromJSON, VirtualMachineDeviceToJSON, } from './VirtualMachineDevice.js';
@@ -76,6 +77,7 @@ export function VirtualMachineDetailFromJSONTyped(json, ignoreDiscriminator) {
76
77
  'template': json['template'] == null ? undefined : json['template'],
77
78
  'migratable': json['migratable'] == null ? undefined : json['migratable'],
78
79
  'migrationExcluded': json['migrationExcluded'] == null ? undefined : json['migrationExcluded'],
80
+ 'inspectionStatus': json['inspectionStatus'] == null ? undefined : InspectionStatusFromJSON(json['inspectionStatus']),
79
81
  'labels': json['labels'] == null ? undefined : json['labels'],
80
82
  'faultToleranceEnabled': json['faultToleranceEnabled'] == null ? undefined : json['faultToleranceEnabled'],
81
83
  'nestedHVEnabled': json['nestedHVEnabled'] == null ? undefined : json['nestedHVEnabled'],
@@ -122,6 +124,7 @@ export function VirtualMachineDetailToJSONTyped(value, ignoreDiscriminator = fal
122
124
  'template': value['template'],
123
125
  'migratable': value['migratable'],
124
126
  'migrationExcluded': value['migrationExcluded'],
127
+ 'inspectionStatus': InspectionStatusToJSON(value['inspectionStatus']),
125
128
  'labels': value['labels'],
126
129
  'faultToleranceEnabled': value['faultToleranceEnabled'],
127
130
  'nestedHVEnabled': value['nestedHVEnabled'],
@@ -24,6 +24,10 @@ export interface AgentStatus {
24
24
  *
25
25
  */
26
26
  consoleConnection: AgentStatusConsoleConnection;
27
+ /**
28
+ * RVTool mode enabled
29
+ */
30
+ rvtoolsModeEnabled?: boolean;
27
31
  }
28
32
  /**
29
33
  * @export
@@ -47,6 +47,7 @@ function AgentStatusFromJSONTyped(json, ignoreDiscriminator) {
47
47
  return {
48
48
  'mode': json['mode'],
49
49
  'consoleConnection': (0, AgentStatusConsoleConnection_js_1.AgentStatusConsoleConnectionFromJSON)(json['consoleConnection']),
50
+ 'rvtoolsModeEnabled': json['rvtoolsModeEnabled'] == null ? undefined : json['rvtoolsModeEnabled'],
50
51
  };
51
52
  }
52
53
  function AgentStatusToJSON(json) {
@@ -59,5 +60,6 @@ function AgentStatusToJSONTyped(value, ignoreDiscriminator = false) {
59
60
  return {
60
61
  'mode': value['mode'],
61
62
  'consoleConnection': (0, AgentStatusConsoleConnection_js_1.AgentStatusConsoleConnectionToJSON)(value['consoleConnection']),
63
+ 'rvtoolsModeEnabled': value['rvtoolsModeEnabled'],
62
64
  };
63
65
  }
@@ -39,6 +39,14 @@ export interface Host {
39
39
  * Host memory in MB
40
40
  */
41
41
  memoryMB?: number | null;
42
+ /**
43
+ * Whether vMotion is supported on this host (HostSystem.capability.vmotionSupported)
44
+ */
45
+ vmotionSupported?: boolean;
46
+ /**
47
+ * Whether Storage vMotion is supported on this host (HostSystem.capability.storageVMotionSupported)
48
+ */
49
+ storageVmotionSupported?: boolean;
42
50
  }
43
51
  /**
44
52
  * Check if a given object implements the Host interface.
@@ -42,6 +42,8 @@ function HostFromJSONTyped(json, ignoreDiscriminator) {
42
42
  'cpuCores': json['cpuCores'] === undefined ? undefined : json['cpuCores'] === null ? null : json['cpuCores'],
43
43
  'cpuSockets': json['cpuSockets'] === undefined ? undefined : json['cpuSockets'] === null ? null : json['cpuSockets'],
44
44
  'memoryMB': json['memoryMB'] === undefined ? undefined : json['memoryMB'] === null ? null : json['memoryMB'],
45
+ 'vmotionSupported': json['vmotionSupported'] == null ? undefined : json['vmotionSupported'],
46
+ 'storageVmotionSupported': json['storageVmotionSupported'] == null ? undefined : json['storageVmotionSupported'],
45
47
  };
46
48
  }
47
49
  function HostToJSON(json) {
@@ -58,5 +60,7 @@ function HostToJSONTyped(value, ignoreDiscriminator = false) {
58
60
  'cpuCores': value['cpuCores'],
59
61
  'cpuSockets': value['cpuSockets'],
60
62
  'memoryMB': value['memoryMB'],
63
+ 'vmotionSupported': value['vmotionSupported'],
64
+ 'storageVmotionSupported': value['storageVmotionSupported'],
61
65
  };
62
66
  }
@@ -19,6 +19,10 @@ export interface InspectionStatus {
19
19
  * Current inspection state
20
20
  */
21
21
  state: InspectionStatusStateEnum;
22
+ /**
23
+ * Human-readable details about the current inspection state
24
+ */
25
+ details?: string;
22
26
  /**
23
27
  * Error message when state is error
24
28
  */
@@ -46,6 +46,7 @@ function InspectionStatusFromJSONTyped(json, ignoreDiscriminator) {
46
46
  }
47
47
  return {
48
48
  'state': json['state'],
49
+ 'details': json['details'] == null ? undefined : json['details'],
49
50
  'error': json['error'] == null ? undefined : json['error'],
50
51
  };
51
52
  }
@@ -58,6 +59,7 @@ function InspectionStatusToJSONTyped(value, ignoreDiscriminator = false) {
58
59
  }
59
60
  return {
60
61
  'state': value['state'],
62
+ 'details': value['details'],
61
63
  'error': value['error'],
62
64
  };
63
65
  }
@@ -10,6 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import type { VirtualMachineInspectionResults } from './VirtualMachineInspectionResults.js';
13
+ import type { InspectionStatus } from './InspectionStatus.js';
13
14
  import type { GuestNetwork } from './GuestNetwork.js';
14
15
  import type { VirtualMachineIssue } from './VirtualMachineIssue.js';
15
16
  import type { VirtualMachineDevice } from './VirtualMachineDevice.js';
@@ -115,6 +116,10 @@ export interface VirtualMachineDetail {
115
116
  * Whether this VM is excluded from migration
116
117
  */
117
118
  migrationExcluded?: boolean;
119
+ /**
120
+ *
121
+ */
122
+ inspectionStatus?: InspectionStatus;
118
123
  /**
119
124
  * User-defined labels for this VM
120
125
  */
@@ -19,6 +19,7 @@ exports.VirtualMachineDetailFromJSONTyped = VirtualMachineDetailFromJSONTyped;
19
19
  exports.VirtualMachineDetailToJSON = VirtualMachineDetailToJSON;
20
20
  exports.VirtualMachineDetailToJSONTyped = VirtualMachineDetailToJSONTyped;
21
21
  const VirtualMachineInspectionResults_js_1 = require("./VirtualMachineInspectionResults.js");
22
+ const InspectionStatus_js_1 = require("./InspectionStatus.js");
22
23
  const GuestNetwork_js_1 = require("./GuestNetwork.js");
23
24
  const VirtualMachineIssue_js_1 = require("./VirtualMachineIssue.js");
24
25
  const VirtualMachineDevice_js_1 = require("./VirtualMachineDevice.js");
@@ -83,6 +84,7 @@ function VirtualMachineDetailFromJSONTyped(json, ignoreDiscriminator) {
83
84
  'template': json['template'] == null ? undefined : json['template'],
84
85
  'migratable': json['migratable'] == null ? undefined : json['migratable'],
85
86
  'migrationExcluded': json['migrationExcluded'] == null ? undefined : json['migrationExcluded'],
87
+ 'inspectionStatus': json['inspectionStatus'] == null ? undefined : (0, InspectionStatus_js_1.InspectionStatusFromJSON)(json['inspectionStatus']),
86
88
  'labels': json['labels'] == null ? undefined : json['labels'],
87
89
  'faultToleranceEnabled': json['faultToleranceEnabled'] == null ? undefined : json['faultToleranceEnabled'],
88
90
  'nestedHVEnabled': json['nestedHVEnabled'] == null ? undefined : json['nestedHVEnabled'],
@@ -129,6 +131,7 @@ function VirtualMachineDetailToJSONTyped(value, ignoreDiscriminator = false) {
129
131
  'template': value['template'],
130
132
  'migratable': value['migratable'],
131
133
  'migrationExcluded': value['migrationExcluded'],
134
+ 'inspectionStatus': (0, InspectionStatus_js_1.InspectionStatusToJSON)(value['inspectionStatus']),
132
135
  'labels': value['labels'],
133
136
  'faultToleranceEnabled': value['faultToleranceEnabled'],
134
137
  'nestedHVEnabled': value['nestedHVEnabled'],
@@ -8,6 +8,7 @@ Name | Type
8
8
  ------------ | -------------
9
9
  `mode` | string
10
10
  `consoleConnection` | [AgentStatusConsoleConnection](AgentStatusConsoleConnection.md)
11
+ `rvtoolsModeEnabled` | boolean
11
12
 
12
13
  ## Example
13
14
 
@@ -18,6 +19,7 @@ import type { AgentStatus } from '@openshift-migration-advisor/agent-sdk'
18
19
  const example = {
19
20
  "mode": null,
20
21
  "consoleConnection": null,
22
+ "rvtoolsModeEnabled": null,
21
23
  } satisfies AgentStatus
22
24
 
23
25
  console.log(example)
@@ -6,6 +6,7 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v2*
6
6
  |------------- | ------------- | -------------|
7
7
  | [**getCollectorStatus**](CollectorApi.md#getcollectorstatus) | **GET** /collector | Get collector status |
8
8
  | [**startCollector**](CollectorApi.md#startcollector) | **POST** /collector | Start a collection |
9
+ | [**startRvtoolsCollector**](CollectorApi.md#startrvtoolscollector) | **POST** /collector/rvtools | Start a collection from RVTools files |
9
10
  | [**stopCollector**](CollectorApi.md#stopcollector) | **DELETE** /collector | Stop collector |
10
11
 
11
12
 
@@ -128,6 +129,75 @@ No authorization required
128
129
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
129
130
 
130
131
 
132
+ ## startRvtoolsCollector
133
+
134
+ > CollectorStatus startRvtoolsCollector(files)
135
+
136
+ Start a collection from RVTools files
137
+
138
+ ### Example
139
+
140
+ ```ts
141
+ import {
142
+ Configuration,
143
+ CollectorApi,
144
+ } from '@openshift-migration-advisor/agent-sdk';
145
+ import type { StartRvtoolsCollectorRequest } from '@openshift-migration-advisor/agent-sdk';
146
+
147
+ async function example() {
148
+ console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
149
+ const api = new CollectorApi();
150
+
151
+ const body = {
152
+ // Array<Blob>
153
+ files: [new Blob(['example file content'], { type: 'application/octet-stream' })],
154
+ } satisfies StartRvtoolsCollectorRequest;
155
+
156
+ try {
157
+ const data = await api.startRvtoolsCollector(body);
158
+ console.log(data);
159
+ } catch (error) {
160
+ console.error(error);
161
+ }
162
+ }
163
+
164
+ // Run the test
165
+ example().catch(console.error);
166
+ ```
167
+
168
+ ### Parameters
169
+
170
+
171
+ | Name | Type | Description | Notes |
172
+ |------------- | ------------- | ------------- | -------------|
173
+ | **files** | `Array<Blob>` | | |
174
+
175
+ ### Return type
176
+
177
+ [**CollectorStatus**](CollectorStatus.md)
178
+
179
+ ### Authorization
180
+
181
+ No authorization required
182
+
183
+ ### HTTP request headers
184
+
185
+ - **Content-Type**: `multipart/form-data`
186
+ - **Accept**: `application/json`
187
+
188
+
189
+ ### HTTP response details
190
+ | Status code | Description | Response headers |
191
+ |-------------|-------------|------------------|
192
+ | **202** | Collection started | - |
193
+ | **400** | No files provided | - |
194
+ | **409** | Collection already in progress | - |
195
+ | **500** | Internal server error | - |
196
+ | **501** | RVTools mode is not enabled | - |
197
+
198
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
199
+
200
+
131
201
  ## stopCollector
132
202
 
133
203
  > stopCollector()
package/docs/Host.md CHANGED
@@ -12,6 +12,8 @@ Name | Type
12
12
  `cpuCores` | number
13
13
  `cpuSockets` | number
14
14
  `memoryMB` | number
15
+ `vmotionSupported` | boolean
16
+ `storageVmotionSupported` | boolean
15
17
 
16
18
  ## Example
17
19
 
@@ -26,6 +28,8 @@ const example = {
26
28
  "cpuCores": null,
27
29
  "cpuSockets": null,
28
30
  "memoryMB": null,
31
+ "vmotionSupported": null,
32
+ "storageVmotionSupported": null,
29
33
  } satisfies Host
30
34
 
31
35
  console.log(example)
@@ -7,6 +7,7 @@
7
7
  Name | Type
8
8
  ------------ | -------------
9
9
  `state` | string
10
+ `details` | string
10
11
  `error` | string
11
12
 
12
13
  ## Example
@@ -17,6 +18,7 @@ import type { InspectionStatus } from '@openshift-migration-advisor/agent-sdk'
17
18
  // TODO: Update the object below with actual values
18
19
  const example = {
19
20
  "state": null,
21
+ "details": null,
20
22
  "error": null,
21
23
  } satisfies InspectionStatus
22
24
 
@@ -29,6 +29,7 @@ Name | Type
29
29
  `template` | boolean
30
30
  `migratable` | boolean
31
31
  `migrationExcluded` | boolean
32
+ `inspectionStatus` | [InspectionStatus](InspectionStatus.md)
32
33
  `labels` | Array&lt;string&gt;
33
34
  `faultToleranceEnabled` | boolean
34
35
  `nestedHVEnabled` | boolean
@@ -73,6 +74,7 @@ const example = {
73
74
  "template": null,
74
75
  "migratable": null,
75
76
  "migrationExcluded": null,
77
+ "inspectionStatus": null,
76
78
  "labels": null,
77
79
  "faultToleranceEnabled": null,
78
80
  "nestedHVEnabled": null,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openshift-migration-advisor/agent-sdk",
3
- "version": "0.20.1-bf086d122d0f",
3
+ "version": "0.20.2-01f58bf215ef",
4
4
  "description": "OpenAPI client for @openshift-migration-advisor/agent-sdk",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -19,6 +19,13 @@ import {
19
19
  CollectorStatusToJSON,
20
20
  } from '../models/CollectorStatus.js';
21
21
 
22
+ export interface StartRvtoolsCollectorRequest {
23
+ /**
24
+ *
25
+ */
26
+ files: Array<Blob>;
27
+ }
28
+
22
29
  /**
23
30
  * CollectorApi - interface
24
31
  *
@@ -68,6 +75,29 @@ export interface CollectorApiInterface {
68
75
  */
69
76
  startCollector(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
70
77
 
78
+ /**
79
+ * Creates request options for startRvtoolsCollector without sending the request
80
+ * @param {Array<Blob>} files
81
+ * @throws {RequiredError}
82
+ * @memberof CollectorApiInterface
83
+ */
84
+ startRvtoolsCollectorRequestOpts(requestParameters: StartRvtoolsCollectorRequest): Promise<runtime.RequestOpts>;
85
+
86
+ /**
87
+ *
88
+ * @summary Start a collection from RVTools files
89
+ * @param {Array<Blob>} files
90
+ * @param {*} [options] Override http request option.
91
+ * @throws {RequiredError}
92
+ * @memberof CollectorApiInterface
93
+ */
94
+ startRvtoolsCollectorRaw(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CollectorStatus>>;
95
+
96
+ /**
97
+ * Start a collection from RVTools files
98
+ */
99
+ startRvtoolsCollector(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus>;
100
+
71
101
  /**
72
102
  * Creates request options for stopCollector without sending the request
73
103
  * @throws {RequiredError}
@@ -170,6 +200,73 @@ export class CollectorApi extends runtime.BaseAPI implements CollectorApiInterfa
170
200
  return await response.value();
171
201
  }
172
202
 
203
+ /**
204
+ * Creates request options for startRvtoolsCollector without sending the request
205
+ */
206
+ async startRvtoolsCollectorRequestOpts(requestParameters: StartRvtoolsCollectorRequest): Promise<runtime.RequestOpts> {
207
+ if (requestParameters['files'] == null) {
208
+ throw new runtime.RequiredError(
209
+ 'files',
210
+ 'Required parameter "files" was null or undefined when calling startRvtoolsCollector().'
211
+ );
212
+ }
213
+
214
+ const queryParameters: any = {};
215
+
216
+ const headerParameters: runtime.HTTPHeaders = {};
217
+
218
+ const consumes: runtime.Consume[] = [
219
+ { contentType: 'multipart/form-data' },
220
+ ];
221
+ // @ts-ignore: canConsumeForm may be unused
222
+ const canConsumeForm = runtime.canConsumeForm(consumes);
223
+
224
+ let formParams: { append(param: string, value: any): any };
225
+ let useForm = false;
226
+ // use FormData to transmit files using content-type "multipart/form-data"
227
+ useForm = canConsumeForm;
228
+ if (useForm) {
229
+ formParams = new FormData();
230
+ } else {
231
+ formParams = new URLSearchParams();
232
+ }
233
+
234
+ if (requestParameters['files'] != null) {
235
+ requestParameters['files'].forEach((element) => {
236
+ formParams.append('files', element as any);
237
+ })
238
+ }
239
+
240
+
241
+ let urlPath = `/collector/rvtools`;
242
+
243
+ return {
244
+ path: urlPath,
245
+ method: 'POST',
246
+ headers: headerParameters,
247
+ query: queryParameters,
248
+ body: formParams,
249
+ };
250
+ }
251
+
252
+ /**
253
+ * Start a collection from RVTools files
254
+ */
255
+ async startRvtoolsCollectorRaw(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CollectorStatus>> {
256
+ const requestOptions = await this.startRvtoolsCollectorRequestOpts(requestParameters);
257
+ const response = await this.request(requestOptions, initOverrides);
258
+
259
+ return new runtime.JSONApiResponse(response, (jsonValue) => CollectorStatusFromJSON(jsonValue));
260
+ }
261
+
262
+ /**
263
+ * Start a collection from RVTools files
264
+ */
265
+ async startRvtoolsCollector(requestParameters: StartRvtoolsCollectorRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CollectorStatus> {
266
+ const response = await this.startRvtoolsCollectorRaw(requestParameters, initOverrides);
267
+ return await response.value();
268
+ }
269
+
173
270
  /**
174
271
  * Creates request options for stopCollector without sending the request
175
272
  */
@@ -35,6 +35,10 @@ export interface AgentStatus {
35
35
  *
36
36
  */
37
37
  consoleConnection: AgentStatusConsoleConnection;
38
+ /**
39
+ * RVTool mode enabled
40
+ */
41
+ rvtoolsModeEnabled?: boolean;
38
42
  }
39
43
 
40
44
 
@@ -69,6 +73,7 @@ export function AgentStatusFromJSONTyped(json: any, ignoreDiscriminator: boolean
69
73
 
70
74
  'mode': json['mode'],
71
75
  'consoleConnection': AgentStatusConsoleConnectionFromJSON(json['consoleConnection']),
76
+ 'rvtoolsModeEnabled': json['rvtoolsModeEnabled'] == null ? undefined : json['rvtoolsModeEnabled'],
72
77
  };
73
78
  }
74
79
 
@@ -85,6 +90,7 @@ export function AgentStatusToJSONTyped(value?: AgentStatus | null, ignoreDiscrim
85
90
 
86
91
  'mode': value['mode'],
87
92
  'consoleConnection': AgentStatusConsoleConnectionToJSON(value['consoleConnection']),
93
+ 'rvtoolsModeEnabled': value['rvtoolsModeEnabled'],
88
94
  };
89
95
  }
90
96
 
@@ -43,6 +43,14 @@ export interface Host {
43
43
  * Host memory in MB
44
44
  */
45
45
  memoryMB?: number | null;
46
+ /**
47
+ * Whether vMotion is supported on this host (HostSystem.capability.vmotionSupported)
48
+ */
49
+ vmotionSupported?: boolean;
50
+ /**
51
+ * Whether Storage vMotion is supported on this host (HostSystem.capability.storageVMotionSupported)
52
+ */
53
+ storageVmotionSupported?: boolean;
46
54
  }
47
55
 
48
56
  /**
@@ -70,6 +78,8 @@ export function HostFromJSONTyped(json: any, ignoreDiscriminator: boolean): Host
70
78
  'cpuCores': json['cpuCores'] === undefined ? undefined : json['cpuCores'] === null ? null : json['cpuCores'],
71
79
  'cpuSockets': json['cpuSockets'] === undefined ? undefined : json['cpuSockets'] === null ? null : json['cpuSockets'],
72
80
  'memoryMB': json['memoryMB'] === undefined ? undefined : json['memoryMB'] === null ? null : json['memoryMB'],
81
+ 'vmotionSupported': json['vmotionSupported'] == null ? undefined : json['vmotionSupported'],
82
+ 'storageVmotionSupported': json['storageVmotionSupported'] == null ? undefined : json['storageVmotionSupported'],
73
83
  };
74
84
  }
75
85
 
@@ -90,6 +100,8 @@ export function HostToJSONTyped(value?: Host | null, ignoreDiscriminator: boolea
90
100
  'cpuCores': value['cpuCores'],
91
101
  'cpuSockets': value['cpuSockets'],
92
102
  'memoryMB': value['memoryMB'],
103
+ 'vmotionSupported': value['vmotionSupported'],
104
+ 'storageVmotionSupported': value['storageVmotionSupported'],
93
105
  };
94
106
  }
95
107
 
@@ -23,6 +23,10 @@ export interface InspectionStatus {
23
23
  * Current inspection state
24
24
  */
25
25
  state: InspectionStatusStateEnum;
26
+ /**
27
+ * Human-readable details about the current inspection state
28
+ */
29
+ details?: string;
26
30
  /**
27
31
  * Error message when state is error
28
32
  */
@@ -62,6 +66,7 @@ export function InspectionStatusFromJSONTyped(json: any, ignoreDiscriminator: bo
62
66
  return {
63
67
 
64
68
  'state': json['state'],
69
+ 'details': json['details'] == null ? undefined : json['details'],
65
70
  'error': json['error'] == null ? undefined : json['error'],
66
71
  };
67
72
  }
@@ -78,6 +83,7 @@ export function InspectionStatusToJSONTyped(value?: InspectionStatus | null, ign
78
83
  return {
79
84
 
80
85
  'state': value['state'],
86
+ 'details': value['details'],
81
87
  'error': value['error'],
82
88
  };
83
89
  }
@@ -20,6 +20,13 @@ import {
20
20
  VirtualMachineInspectionResultsToJSON,
21
21
  VirtualMachineInspectionResultsToJSONTyped,
22
22
  } from './VirtualMachineInspectionResults.js';
23
+ import type { InspectionStatus } from './InspectionStatus.js';
24
+ import {
25
+ InspectionStatusFromJSON,
26
+ InspectionStatusFromJSONTyped,
27
+ InspectionStatusToJSON,
28
+ InspectionStatusToJSONTyped,
29
+ } from './InspectionStatus.js';
23
30
  import type { GuestNetwork } from './GuestNetwork.js';
24
31
  import {
25
32
  GuestNetworkFromJSON,
@@ -168,6 +175,10 @@ export interface VirtualMachineDetail {
168
175
  * Whether this VM is excluded from migration
169
176
  */
170
177
  migrationExcluded?: boolean;
178
+ /**
179
+ *
180
+ */
181
+ inspectionStatus?: InspectionStatus;
171
182
  /**
172
183
  * User-defined labels for this VM
173
184
  */
@@ -272,6 +283,7 @@ export function VirtualMachineDetailFromJSONTyped(json: any, ignoreDiscriminator
272
283
  'template': json['template'] == null ? undefined : json['template'],
273
284
  'migratable': json['migratable'] == null ? undefined : json['migratable'],
274
285
  'migrationExcluded': json['migrationExcluded'] == null ? undefined : json['migrationExcluded'],
286
+ 'inspectionStatus': json['inspectionStatus'] == null ? undefined : InspectionStatusFromJSON(json['inspectionStatus']),
275
287
  'labels': json['labels'] == null ? undefined : json['labels'],
276
288
  'faultToleranceEnabled': json['faultToleranceEnabled'] == null ? undefined : json['faultToleranceEnabled'],
277
289
  'nestedHVEnabled': json['nestedHVEnabled'] == null ? undefined : json['nestedHVEnabled'],
@@ -322,6 +334,7 @@ export function VirtualMachineDetailToJSONTyped(value?: VirtualMachineDetail | n
322
334
  'template': value['template'],
323
335
  'migratable': value['migratable'],
324
336
  'migrationExcluded': value['migrationExcluded'],
337
+ 'inspectionStatus': InspectionStatusToJSON(value['inspectionStatus']),
325
338
  'labels': value['labels'],
326
339
  'faultToleranceEnabled': value['faultToleranceEnabled'],
327
340
  'nestedHVEnabled': value['nestedHVEnabled'],