@openshift-migration-advisor/agent-sdk 0.12.0-645d2fae3eee → 0.12.0-6a69e0e34d95
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/.openapi-generator/FILES +4 -0
- package/README.md +6 -2
- package/dist/apis/DefaultApi.d.ts +66 -0
- package/dist/apis/DefaultApi.js +75 -0
- package/dist/esm/apis/DefaultApi.d.ts +66 -0
- package/dist/esm/apis/DefaultApi.js +75 -0
- package/dist/esm/models/ClusterUtilization.d.ts +68 -0
- package/dist/esm/models/ClusterUtilization.js +67 -0
- package/dist/esm/models/CreateGroupRequest.d.ts +0 -6
- package/dist/esm/models/CreateGroupRequest.js +0 -2
- package/dist/esm/models/Group.d.ts +0 -6
- package/dist/esm/models/Group.js +0 -2
- package/dist/esm/models/GroupResponse.d.ts +7 -0
- package/dist/esm/models/GroupResponse.js +3 -0
- package/dist/esm/models/InventoryData.d.ts +7 -0
- package/dist/esm/models/InventoryData.js +3 -0
- package/dist/esm/models/UpdateGroupRequest.d.ts +0 -6
- package/dist/esm/models/UpdateGroupRequest.js +0 -2
- package/dist/esm/models/VMFilterOptionsResponse.d.ts +50 -0
- package/dist/esm/models/VMFilterOptionsResponse.js +55 -0
- package/dist/esm/models/VMNIC.d.ts +12 -0
- package/dist/esm/models/VMNIC.js +4 -0
- package/dist/esm/models/VirtualMachine.d.ts +14 -2
- package/dist/esm/models/VirtualMachine.js +6 -2
- package/dist/esm/models/index.d.ts +2 -0
- package/dist/esm/models/index.js +2 -0
- package/dist/models/ClusterUtilization.d.ts +68 -0
- package/dist/models/ClusterUtilization.js +74 -0
- package/dist/models/CreateGroupRequest.d.ts +0 -6
- package/dist/models/CreateGroupRequest.js +0 -2
- package/dist/models/Group.d.ts +0 -6
- package/dist/models/Group.js +0 -2
- package/dist/models/GroupResponse.d.ts +7 -0
- package/dist/models/GroupResponse.js +3 -0
- package/dist/models/InventoryData.d.ts +7 -0
- package/dist/models/InventoryData.js +3 -0
- package/dist/models/UpdateGroupRequest.d.ts +0 -6
- package/dist/models/UpdateGroupRequest.js +0 -2
- package/dist/models/VMFilterOptionsResponse.d.ts +50 -0
- package/dist/models/VMFilterOptionsResponse.js +62 -0
- package/dist/models/VMNIC.d.ts +12 -0
- package/dist/models/VMNIC.js +4 -0
- package/dist/models/VirtualMachine.d.ts +14 -2
- package/dist/models/VirtualMachine.js +6 -2
- package/dist/models/index.d.ts +2 -0
- package/dist/models/index.js +2 -0
- package/docs/ClusterUtilization.md +46 -0
- package/docs/CreateGroupRequest.md +0 -2
- package/docs/DefaultApi.md +128 -0
- package/docs/Group.md +0 -2
- package/docs/GroupResponse.md +2 -0
- package/docs/InventoryData.md +2 -0
- package/docs/UpdateGroupRequest.md +0 -2
- package/docs/VMFilterOptionsResponse.md +40 -0
- package/docs/VMNIC.md +4 -0
- package/docs/VirtualMachine.md +6 -2
- package/package.json +1 -1
- package/src/apis/DefaultApi.ts +135 -0
- package/src/models/ClusterUtilization.ts +120 -0
- package/src/models/CreateGroupRequest.ts +0 -8
- package/src/models/Group.ts +0 -8
- package/src/models/GroupResponse.ts +15 -0
- package/src/models/InventoryData.ts +15 -0
- package/src/models/UpdateGroupRequest.ts +0 -8
- package/src/models/VMFilterOptionsResponse.ts +93 -0
- package/src/models/VMNIC.ts +16 -0
- package/src/models/VirtualMachine.ts +20 -4
- package/src/models/index.ts +2 -0
|
@@ -20,6 +20,7 @@ exports.InventoryDataToJSON = InventoryDataToJSON;
|
|
|
20
20
|
exports.InventoryDataToJSONTyped = InventoryDataToJSONTyped;
|
|
21
21
|
const VCenter_js_1 = require("./VCenter.js");
|
|
22
22
|
const Infra_js_1 = require("./Infra.js");
|
|
23
|
+
const ClusterUtilization_js_1 = require("./ClusterUtilization.js");
|
|
23
24
|
const VMs_js_1 = require("./VMs.js");
|
|
24
25
|
const ClusterFeatures_js_1 = require("./ClusterFeatures.js");
|
|
25
26
|
/**
|
|
@@ -42,6 +43,7 @@ function InventoryDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
42
43
|
return {
|
|
43
44
|
'vcenter': json['vcenter'] == null ? undefined : (0, VCenter_js_1.VCenterFromJSON)(json['vcenter']),
|
|
44
45
|
'clusterFeatures': json['clusterFeatures'] == null ? undefined : (0, ClusterFeatures_js_1.ClusterFeaturesFromJSON)(json['clusterFeatures']),
|
|
46
|
+
'clusterUtilization': json['clusterUtilization'] == null ? undefined : (0, ClusterUtilization_js_1.ClusterUtilizationFromJSON)(json['clusterUtilization']),
|
|
45
47
|
'vms': (0, VMs_js_1.VMsFromJSON)(json['vms']),
|
|
46
48
|
'infra': (0, Infra_js_1.InfraFromJSON)(json['infra']),
|
|
47
49
|
};
|
|
@@ -56,6 +58,7 @@ function InventoryDataToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
56
58
|
return {
|
|
57
59
|
'vcenter': (0, VCenter_js_1.VCenterToJSON)(value['vcenter']),
|
|
58
60
|
'clusterFeatures': (0, ClusterFeatures_js_1.ClusterFeaturesToJSON)(value['clusterFeatures']),
|
|
61
|
+
'clusterUtilization': (0, ClusterUtilization_js_1.ClusterUtilizationToJSON)(value['clusterUtilization']),
|
|
59
62
|
'vms': (0, VMs_js_1.VMsToJSON)(value['vms']),
|
|
60
63
|
'infra': (0, Infra_js_1.InfraToJSON)(value['infra']),
|
|
61
64
|
};
|
|
@@ -33,12 +33,6 @@ export interface UpdateGroupRequest {
|
|
|
33
33
|
* @memberof UpdateGroupRequest
|
|
34
34
|
*/
|
|
35
35
|
filter?: string;
|
|
36
|
-
/**
|
|
37
|
-
* Tags to apply to matching VMs (only alphanumeric, underscore, and dot allowed)
|
|
38
|
-
* @type {Array<string>}
|
|
39
|
-
* @memberof UpdateGroupRequest
|
|
40
|
-
*/
|
|
41
|
-
tags?: Array<string>;
|
|
42
36
|
}
|
|
43
37
|
/**
|
|
44
38
|
* Check if a given object implements the UpdateGroupRequest interface.
|
|
@@ -35,7 +35,6 @@ function UpdateGroupRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
35
35
|
'name': json['name'] == null ? undefined : json['name'],
|
|
36
36
|
'description': json['description'] == null ? undefined : json['description'],
|
|
37
37
|
'filter': json['filter'] == null ? undefined : json['filter'],
|
|
38
|
-
'tags': json['tags'] == null ? undefined : json['tags'],
|
|
39
38
|
};
|
|
40
39
|
}
|
|
41
40
|
function UpdateGroupRequestToJSON(json) {
|
|
@@ -49,6 +48,5 @@ function UpdateGroupRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
49
48
|
'name': value['name'],
|
|
50
49
|
'description': value['description'],
|
|
51
50
|
'filter': value['filter'],
|
|
52
|
-
'tags': value['tags'],
|
|
53
51
|
};
|
|
54
52
|
}
|
|
@@ -0,0 +1,50 @@
|
|
|
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: v1
|
|
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
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface VMFilterOptionsResponse
|
|
16
|
+
*/
|
|
17
|
+
export interface VMFilterOptionsResponse {
|
|
18
|
+
/**
|
|
19
|
+
* Distinct cluster names
|
|
20
|
+
* @type {Array<string>}
|
|
21
|
+
* @memberof VMFilterOptionsResponse
|
|
22
|
+
*/
|
|
23
|
+
clusters: Array<string>;
|
|
24
|
+
/**
|
|
25
|
+
* Distinct datacenter names
|
|
26
|
+
* @type {Array<string>}
|
|
27
|
+
* @memberof VMFilterOptionsResponse
|
|
28
|
+
*/
|
|
29
|
+
datacenters: Array<string>;
|
|
30
|
+
/**
|
|
31
|
+
* Distinct concern labels
|
|
32
|
+
* @type {Array<string>}
|
|
33
|
+
* @memberof VMFilterOptionsResponse
|
|
34
|
+
*/
|
|
35
|
+
concernLabels: Array<string>;
|
|
36
|
+
/**
|
|
37
|
+
* Distinct concern categories
|
|
38
|
+
* @type {Array<string>}
|
|
39
|
+
* @memberof VMFilterOptionsResponse
|
|
40
|
+
*/
|
|
41
|
+
concernCategories: Array<string>;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Check if a given object implements the VMFilterOptionsResponse interface.
|
|
45
|
+
*/
|
|
46
|
+
export declare function instanceOfVMFilterOptionsResponse(value: object): value is VMFilterOptionsResponse;
|
|
47
|
+
export declare function VMFilterOptionsResponseFromJSON(json: any): VMFilterOptionsResponse;
|
|
48
|
+
export declare function VMFilterOptionsResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): VMFilterOptionsResponse;
|
|
49
|
+
export declare function VMFilterOptionsResponseToJSON(json: any): VMFilterOptionsResponse;
|
|
50
|
+
export declare function VMFilterOptionsResponseToJSONTyped(value?: VMFilterOptionsResponse | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Assisted Migration Agent API
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: v1
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfVMFilterOptionsResponse = instanceOfVMFilterOptionsResponse;
|
|
17
|
+
exports.VMFilterOptionsResponseFromJSON = VMFilterOptionsResponseFromJSON;
|
|
18
|
+
exports.VMFilterOptionsResponseFromJSONTyped = VMFilterOptionsResponseFromJSONTyped;
|
|
19
|
+
exports.VMFilterOptionsResponseToJSON = VMFilterOptionsResponseToJSON;
|
|
20
|
+
exports.VMFilterOptionsResponseToJSONTyped = VMFilterOptionsResponseToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the VMFilterOptionsResponse interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfVMFilterOptionsResponse(value) {
|
|
25
|
+
if (!('clusters' in value) || value['clusters'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('datacenters' in value) || value['datacenters'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('concernLabels' in value) || value['concernLabels'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
if (!('concernCategories' in value) || value['concernCategories'] === undefined)
|
|
32
|
+
return false;
|
|
33
|
+
return true;
|
|
34
|
+
}
|
|
35
|
+
function VMFilterOptionsResponseFromJSON(json) {
|
|
36
|
+
return VMFilterOptionsResponseFromJSONTyped(json, false);
|
|
37
|
+
}
|
|
38
|
+
function VMFilterOptionsResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
39
|
+
if (json == null) {
|
|
40
|
+
return json;
|
|
41
|
+
}
|
|
42
|
+
return {
|
|
43
|
+
'clusters': json['clusters'],
|
|
44
|
+
'datacenters': json['datacenters'],
|
|
45
|
+
'concernLabels': json['concernLabels'],
|
|
46
|
+
'concernCategories': json['concernCategories'],
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
function VMFilterOptionsResponseToJSON(json) {
|
|
50
|
+
return VMFilterOptionsResponseToJSONTyped(json, false);
|
|
51
|
+
}
|
|
52
|
+
function VMFilterOptionsResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
53
|
+
if (value == null) {
|
|
54
|
+
return value;
|
|
55
|
+
}
|
|
56
|
+
return {
|
|
57
|
+
'clusters': value['clusters'],
|
|
58
|
+
'datacenters': value['datacenters'],
|
|
59
|
+
'concernLabels': value['concernLabels'],
|
|
60
|
+
'concernCategories': value['concernCategories'],
|
|
61
|
+
};
|
|
62
|
+
}
|
package/dist/models/VMNIC.d.ts
CHANGED
|
@@ -33,6 +33,18 @@ export interface VMNIC {
|
|
|
33
33
|
* @memberof VMNIC
|
|
34
34
|
*/
|
|
35
35
|
index?: number;
|
|
36
|
+
/**
|
|
37
|
+
* IPv4 address of this NIC as reported by VMware Tools
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof VMNIC
|
|
40
|
+
*/
|
|
41
|
+
ipv4Address?: string;
|
|
42
|
+
/**
|
|
43
|
+
* IPv6 address of this NIC as reported by VMware Tools
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof VMNIC
|
|
46
|
+
*/
|
|
47
|
+
ipv6Address?: string;
|
|
36
48
|
}
|
|
37
49
|
/**
|
|
38
50
|
* Check if a given object implements the VMNIC interface.
|
package/dist/models/VMNIC.js
CHANGED
|
@@ -35,6 +35,8 @@ function VMNICFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
35
35
|
'mac': json['mac'] == null ? undefined : json['mac'],
|
|
36
36
|
'network': json['network'] == null ? undefined : json['network'],
|
|
37
37
|
'index': json['index'] == null ? undefined : json['index'],
|
|
38
|
+
'ipv4Address': json['ipv4Address'] == null ? undefined : json['ipv4Address'],
|
|
39
|
+
'ipv6Address': json['ipv6Address'] == null ? undefined : json['ipv6Address'],
|
|
38
40
|
};
|
|
39
41
|
}
|
|
40
42
|
function VMNICToJSON(json) {
|
|
@@ -48,5 +50,7 @@ function VMNICToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
48
50
|
'mac': value['mac'],
|
|
49
51
|
'network': value['network'],
|
|
50
52
|
'index': value['index'],
|
|
53
|
+
'ipv4Address': value['ipv4Address'],
|
|
54
|
+
'ipv6Address': value['ipv6Address'],
|
|
51
55
|
};
|
|
52
56
|
}
|
|
@@ -95,11 +95,11 @@ export interface VirtualMachine {
|
|
|
95
95
|
*/
|
|
96
96
|
inspectionConcernCount?: number;
|
|
97
97
|
/**
|
|
98
|
-
*
|
|
98
|
+
* Names of groups this VM matches
|
|
99
99
|
* @type {Array<string>}
|
|
100
100
|
* @memberof VirtualMachine
|
|
101
101
|
*/
|
|
102
|
-
|
|
102
|
+
groups?: Array<string>;
|
|
103
103
|
/**
|
|
104
104
|
* User-defined labels for this VM
|
|
105
105
|
* @type {Array<string>}
|
|
@@ -118,6 +118,18 @@ export interface VirtualMachine {
|
|
|
118
118
|
* @memberof VirtualMachine
|
|
119
119
|
*/
|
|
120
120
|
utilization_mem_p95?: number;
|
|
121
|
+
/**
|
|
122
|
+
* CPU utilization at max (%); absent when no utilization data
|
|
123
|
+
* @type {number}
|
|
124
|
+
* @memberof VirtualMachine
|
|
125
|
+
*/
|
|
126
|
+
utilization_cpu_max?: number;
|
|
127
|
+
/**
|
|
128
|
+
* Memory utilization at max (%); absent when no utilization data
|
|
129
|
+
* @type {number}
|
|
130
|
+
* @memberof VirtualMachine
|
|
131
|
+
*/
|
|
132
|
+
utilization_mem_max?: number;
|
|
121
133
|
/**
|
|
122
134
|
* Disk utilization (%); absent when no utilization data
|
|
123
135
|
* @type {number}
|
|
@@ -62,10 +62,12 @@ function VirtualMachineFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
62
62
|
'migrationExcluded': json['migrationExcluded'] == null ? undefined : json['migrationExcluded'],
|
|
63
63
|
'inspectionStatus': json['inspectionStatus'] == null ? undefined : (0, VmInspectionStatus_js_1.VmInspectionStatusFromJSON)(json['inspectionStatus']),
|
|
64
64
|
'inspectionConcernCount': json['inspectionConcernCount'] == null ? undefined : json['inspectionConcernCount'],
|
|
65
|
-
'
|
|
65
|
+
'groups': json['groups'] == null ? undefined : json['groups'],
|
|
66
66
|
'labels': json['labels'] == null ? undefined : json['labels'],
|
|
67
67
|
'utilization_cpu_p95': json['utilization_cpu_p95'] == null ? undefined : json['utilization_cpu_p95'],
|
|
68
68
|
'utilization_mem_p95': json['utilization_mem_p95'] == null ? undefined : json['utilization_mem_p95'],
|
|
69
|
+
'utilization_cpu_max': json['utilization_cpu_max'] == null ? undefined : json['utilization_cpu_max'],
|
|
70
|
+
'utilization_mem_max': json['utilization_mem_max'] == null ? undefined : json['utilization_mem_max'],
|
|
69
71
|
'utilization_disk': json['utilization_disk'] == null ? undefined : json['utilization_disk'],
|
|
70
72
|
'utilization_confidence': json['utilization_confidence'] == null ? undefined : json['utilization_confidence'],
|
|
71
73
|
};
|
|
@@ -91,10 +93,12 @@ function VirtualMachineToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
91
93
|
'migrationExcluded': value['migrationExcluded'],
|
|
92
94
|
'inspectionStatus': (0, VmInspectionStatus_js_1.VmInspectionStatusToJSON)(value['inspectionStatus']),
|
|
93
95
|
'inspectionConcernCount': value['inspectionConcernCount'],
|
|
94
|
-
'
|
|
96
|
+
'groups': value['groups'],
|
|
95
97
|
'labels': value['labels'],
|
|
96
98
|
'utilization_cpu_p95': value['utilization_cpu_p95'],
|
|
97
99
|
'utilization_mem_p95': value['utilization_mem_p95'],
|
|
100
|
+
'utilization_cpu_max': value['utilization_cpu_max'],
|
|
101
|
+
'utilization_mem_max': value['utilization_mem_max'],
|
|
98
102
|
'utilization_disk': value['utilization_disk'],
|
|
99
103
|
'utilization_confidence': value['utilization_confidence'],
|
|
100
104
|
};
|
package/dist/models/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ export * from './AgentModeRequest.js';
|
|
|
2
2
|
export * from './AgentStatus.js';
|
|
3
3
|
export * from './BenchmarkRun.js';
|
|
4
4
|
export * from './ClusterFeatures.js';
|
|
5
|
+
export * from './ClusterUtilization.js';
|
|
5
6
|
export * from './CollectorStartRequest.js';
|
|
6
7
|
export * from './CollectorStatus.js';
|
|
7
8
|
export * from './CreateGroupRequest.js';
|
|
@@ -51,6 +52,7 @@ export * from './UpdateLabelVMsRequest.js';
|
|
|
51
52
|
export * from './VCenter.js';
|
|
52
53
|
export * from './VMDevice.js';
|
|
53
54
|
export * from './VMDisk.js';
|
|
55
|
+
export * from './VMFilterOptionsResponse.js';
|
|
54
56
|
export * from './VMIssue.js';
|
|
55
57
|
export * from './VMLabelsResponse.js';
|
|
56
58
|
export * from './VMNIC.js';
|
package/dist/models/index.js
CHANGED
|
@@ -20,6 +20,7 @@ __exportStar(require("./AgentModeRequest.js"), exports);
|
|
|
20
20
|
__exportStar(require("./AgentStatus.js"), exports);
|
|
21
21
|
__exportStar(require("./BenchmarkRun.js"), exports);
|
|
22
22
|
__exportStar(require("./ClusterFeatures.js"), exports);
|
|
23
|
+
__exportStar(require("./ClusterUtilization.js"), exports);
|
|
23
24
|
__exportStar(require("./CollectorStartRequest.js"), exports);
|
|
24
25
|
__exportStar(require("./CollectorStatus.js"), exports);
|
|
25
26
|
__exportStar(require("./CreateGroupRequest.js"), exports);
|
|
@@ -69,6 +70,7 @@ __exportStar(require("./UpdateLabelVMsRequest.js"), exports);
|
|
|
69
70
|
__exportStar(require("./VCenter.js"), exports);
|
|
70
71
|
__exportStar(require("./VMDevice.js"), exports);
|
|
71
72
|
__exportStar(require("./VMDisk.js"), exports);
|
|
73
|
+
__exportStar(require("./VMFilterOptionsResponse.js"), exports);
|
|
72
74
|
__exportStar(require("./VMIssue.js"), exports);
|
|
73
75
|
__exportStar(require("./VMLabelsResponse.js"), exports);
|
|
74
76
|
__exportStar(require("./VMNIC.js"), exports);
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
|
|
2
|
+
# ClusterUtilization
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type
|
|
8
|
+
------------ | -------------
|
|
9
|
+
`cpu_avg` | number
|
|
10
|
+
`cpu_p95` | number
|
|
11
|
+
`cpu_max` | number
|
|
12
|
+
`mem_avg` | number
|
|
13
|
+
`mem_p95` | number
|
|
14
|
+
`mem_max` | number
|
|
15
|
+
`confidence` | number
|
|
16
|
+
|
|
17
|
+
## Example
|
|
18
|
+
|
|
19
|
+
```typescript
|
|
20
|
+
import type { ClusterUtilization } from '@openshift-migration-advisor/agent-sdk'
|
|
21
|
+
|
|
22
|
+
// TODO: Update the object below with actual values
|
|
23
|
+
const example = {
|
|
24
|
+
"cpu_avg": null,
|
|
25
|
+
"cpu_p95": null,
|
|
26
|
+
"cpu_max": null,
|
|
27
|
+
"mem_avg": null,
|
|
28
|
+
"mem_p95": null,
|
|
29
|
+
"mem_max": null,
|
|
30
|
+
"confidence": null,
|
|
31
|
+
} satisfies ClusterUtilization
|
|
32
|
+
|
|
33
|
+
console.log(example)
|
|
34
|
+
|
|
35
|
+
// Convert the instance to a JSON string
|
|
36
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
37
|
+
console.log(exampleJSON)
|
|
38
|
+
|
|
39
|
+
// Parse the JSON string back to an object
|
|
40
|
+
const exampleParsed = JSON.parse(exampleJSON) as ClusterUtilization
|
|
41
|
+
console.log(exampleParsed)
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
45
|
+
|
|
46
|
+
|
|
@@ -9,7 +9,6 @@ Name | Type
|
|
|
9
9
|
`name` | string
|
|
10
10
|
`description` | string
|
|
11
11
|
`filter` | string
|
|
12
|
-
`tags` | Array<string>
|
|
13
12
|
|
|
14
13
|
## Example
|
|
15
14
|
|
|
@@ -21,7 +20,6 @@ const example = {
|
|
|
21
20
|
"name": null,
|
|
22
21
|
"description": null,
|
|
23
22
|
"filter": null,
|
|
24
|
-
"tags": null,
|
|
25
23
|
} satisfies CreateGroupRequest
|
|
26
24
|
|
|
27
25
|
console.log(example)
|
package/docs/DefaultApi.md
CHANGED
|
@@ -9,6 +9,7 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v1*
|
|
|
9
9
|
| [**deleteGroup**](DefaultApi.md#deletegroup) | **DELETE** /groups/{id} | Delete group |
|
|
10
10
|
| [**deleteLabelGlobally**](DefaultApi.md#deletelabelglobally) | **DELETE** /vms/labels/{label} | Delete label from all VMs |
|
|
11
11
|
| [**getAgentStatus**](DefaultApi.md#getagentstatus) | **GET** /agent | Get agent status |
|
|
12
|
+
| [**getClusterUtilization**](DefaultApi.md#getclusterutilization) | **GET** /clusters/{cluster_id}/utilization | Get latest cluster utilization by cluster ID |
|
|
12
13
|
| [**getCollectorStatus**](DefaultApi.md#getcollectorstatus) | **GET** /collector | Get collector status |
|
|
13
14
|
| [**getForecasterDatastores**](DefaultApi.md#getforecasterdatastores) | **POST** /forecaster/datastores | List available datastores |
|
|
14
15
|
| [**getForecasterRuns**](DefaultApi.md#getforecasterruns) | **GET** /forecaster/runs | List benchmark runs |
|
|
@@ -26,6 +27,7 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v1*
|
|
|
26
27
|
| [**getVMLabels**](DefaultApi.md#getvmlabels) | **GET** /vms/labels | Get all distinct labels in use across VMs |
|
|
27
28
|
| [**getVMUtilization**](DefaultApi.md#getvmutilization) | **GET** /vms/{id}/utilization | Get utilization breakdown for a specific VM |
|
|
28
29
|
| [**getVMs**](DefaultApi.md#getvms) | **GET** /vms | Get list of VMs with filtering and pagination |
|
|
30
|
+
| [**getVMsFilterOptions**](DefaultApi.md#getvmsfilteroptions) | **GET** /vms/filter-options | Get distinct filter option values for VMs |
|
|
29
31
|
| [**getVersion**](DefaultApi.md#getversion) | **GET** /version | Get agent version information |
|
|
30
32
|
| [**listGroups**](DefaultApi.md#listgroups) | **GET** /groups | List all groups |
|
|
31
33
|
| [**listRightsizingReportClusters**](DefaultApi.md#listrightsizingreportclusters) | **GET** /rightsizing/{report_id}/clusters | Get cluster-level utilization aggregates for a specific report |
|
|
@@ -376,6 +378,74 @@ No authorization required
|
|
|
376
378
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
377
379
|
|
|
378
380
|
|
|
381
|
+
## getClusterUtilization
|
|
382
|
+
|
|
383
|
+
> RightsizingClusterResponse getClusterUtilization(clusterId)
|
|
384
|
+
|
|
385
|
+
Get latest cluster utilization by cluster ID
|
|
386
|
+
|
|
387
|
+
### Example
|
|
388
|
+
|
|
389
|
+
```ts
|
|
390
|
+
import {
|
|
391
|
+
Configuration,
|
|
392
|
+
DefaultApi,
|
|
393
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
394
|
+
import type { GetClusterUtilizationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
395
|
+
|
|
396
|
+
async function example() {
|
|
397
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
398
|
+
const api = new DefaultApi();
|
|
399
|
+
|
|
400
|
+
const body = {
|
|
401
|
+
// string | vSphere MoRef (e.g. \"domain-c123\") or generated cluster ID (e.g. \"cluster-a3f7b2c1d4e89012\")
|
|
402
|
+
clusterId: clusterId_example,
|
|
403
|
+
} satisfies GetClusterUtilizationRequest;
|
|
404
|
+
|
|
405
|
+
try {
|
|
406
|
+
const data = await api.getClusterUtilization(body);
|
|
407
|
+
console.log(data);
|
|
408
|
+
} catch (error) {
|
|
409
|
+
console.error(error);
|
|
410
|
+
}
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
// Run the test
|
|
414
|
+
example().catch(console.error);
|
|
415
|
+
```
|
|
416
|
+
|
|
417
|
+
### Parameters
|
|
418
|
+
|
|
419
|
+
|
|
420
|
+
| Name | Type | Description | Notes |
|
|
421
|
+
|------------- | ------------- | ------------- | -------------|
|
|
422
|
+
| **clusterId** | `string` | vSphere MoRef (e.g. \"domain-c123\") or generated cluster ID (e.g. \"cluster-a3f7b2c1d4e89012\") | [Defaults to `undefined`] |
|
|
423
|
+
|
|
424
|
+
### Return type
|
|
425
|
+
|
|
426
|
+
[**RightsizingClusterResponse**](RightsizingClusterResponse.md)
|
|
427
|
+
|
|
428
|
+
### Authorization
|
|
429
|
+
|
|
430
|
+
No authorization required
|
|
431
|
+
|
|
432
|
+
### HTTP request headers
|
|
433
|
+
|
|
434
|
+
- **Content-Type**: Not defined
|
|
435
|
+
- **Accept**: `application/json`
|
|
436
|
+
|
|
437
|
+
|
|
438
|
+
### HTTP response details
|
|
439
|
+
| Status code | Description | Response headers |
|
|
440
|
+
|-------------|-------------|------------------|
|
|
441
|
+
| **200** | Cluster utilization data from the latest completed rightsizing report | - |
|
|
442
|
+
| **400** | Invalid cluster_id format | - |
|
|
443
|
+
| **404** | No completed rightsizing report found, or cluster not found in report | - |
|
|
444
|
+
| **500** | Internal server error | - |
|
|
445
|
+
|
|
446
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
447
|
+
|
|
448
|
+
|
|
379
449
|
## getCollectorStatus
|
|
380
450
|
|
|
381
451
|
> CollectorStatus getCollectorStatus()
|
|
@@ -1511,6 +1581,64 @@ No authorization required
|
|
|
1511
1581
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1512
1582
|
|
|
1513
1583
|
|
|
1584
|
+
## getVMsFilterOptions
|
|
1585
|
+
|
|
1586
|
+
> VMFilterOptionsResponse getVMsFilterOptions()
|
|
1587
|
+
|
|
1588
|
+
Get distinct filter option values for VMs
|
|
1589
|
+
|
|
1590
|
+
### Example
|
|
1591
|
+
|
|
1592
|
+
```ts
|
|
1593
|
+
import {
|
|
1594
|
+
Configuration,
|
|
1595
|
+
DefaultApi,
|
|
1596
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1597
|
+
import type { GetVMsFilterOptionsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1598
|
+
|
|
1599
|
+
async function example() {
|
|
1600
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1601
|
+
const api = new DefaultApi();
|
|
1602
|
+
|
|
1603
|
+
try {
|
|
1604
|
+
const data = await api.getVMsFilterOptions();
|
|
1605
|
+
console.log(data);
|
|
1606
|
+
} catch (error) {
|
|
1607
|
+
console.error(error);
|
|
1608
|
+
}
|
|
1609
|
+
}
|
|
1610
|
+
|
|
1611
|
+
// Run the test
|
|
1612
|
+
example().catch(console.error);
|
|
1613
|
+
```
|
|
1614
|
+
|
|
1615
|
+
### Parameters
|
|
1616
|
+
|
|
1617
|
+
This endpoint does not need any parameter.
|
|
1618
|
+
|
|
1619
|
+
### Return type
|
|
1620
|
+
|
|
1621
|
+
[**VMFilterOptionsResponse**](VMFilterOptionsResponse.md)
|
|
1622
|
+
|
|
1623
|
+
### Authorization
|
|
1624
|
+
|
|
1625
|
+
No authorization required
|
|
1626
|
+
|
|
1627
|
+
### HTTP request headers
|
|
1628
|
+
|
|
1629
|
+
- **Content-Type**: Not defined
|
|
1630
|
+
- **Accept**: `application/json`
|
|
1631
|
+
|
|
1632
|
+
|
|
1633
|
+
### HTTP response details
|
|
1634
|
+
| Status code | Description | Response headers |
|
|
1635
|
+
|-------------|-------------|------------------|
|
|
1636
|
+
| **200** | Filter options | - |
|
|
1637
|
+
| **500** | Internal server error | - |
|
|
1638
|
+
|
|
1639
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1640
|
+
|
|
1641
|
+
|
|
1514
1642
|
## getVersion
|
|
1515
1643
|
|
|
1516
1644
|
> VersionInfo getVersion()
|
package/docs/Group.md
CHANGED
|
@@ -10,7 +10,6 @@ Name | Type
|
|
|
10
10
|
`name` | string
|
|
11
11
|
`description` | string
|
|
12
12
|
`filter` | string
|
|
13
|
-
`tags` | Array<string>
|
|
14
13
|
`createdAt` | Date
|
|
15
14
|
`updatedAt` | Date
|
|
16
15
|
|
|
@@ -25,7 +24,6 @@ const example = {
|
|
|
25
24
|
"name": null,
|
|
26
25
|
"description": null,
|
|
27
26
|
"filter": memory >= 8GB and cluster = 'prod',
|
|
28
|
-
"tags": ["production","critical"],
|
|
29
27
|
"createdAt": null,
|
|
30
28
|
"updatedAt": null,
|
|
31
29
|
} satisfies Group
|
package/docs/GroupResponse.md
CHANGED
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
Name | Type
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`group` | [Group](Group.md)
|
|
10
|
+
`inventory` | [Inventory](Inventory.md)
|
|
10
11
|
`vms` | [Array<VirtualMachine>](VirtualMachine.md)
|
|
11
12
|
`total` | number
|
|
12
13
|
`page` | number
|
|
@@ -20,6 +21,7 @@ import type { GroupResponse } from '@openshift-migration-advisor/agent-sdk'
|
|
|
20
21
|
// TODO: Update the object below with actual values
|
|
21
22
|
const example = {
|
|
22
23
|
"group": null,
|
|
24
|
+
"inventory": null,
|
|
23
25
|
"vms": null,
|
|
24
26
|
"total": null,
|
|
25
27
|
"page": null,
|
package/docs/InventoryData.md
CHANGED
|
@@ -8,6 +8,7 @@ Name | Type
|
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`vcenter` | [VCenter](VCenter.md)
|
|
10
10
|
`clusterFeatures` | [ClusterFeatures](ClusterFeatures.md)
|
|
11
|
+
`clusterUtilization` | [ClusterUtilization](ClusterUtilization.md)
|
|
11
12
|
`vms` | [VMs](VMs.md)
|
|
12
13
|
`infra` | [Infra](Infra.md)
|
|
13
14
|
|
|
@@ -20,6 +21,7 @@ import type { InventoryData } from '@openshift-migration-advisor/agent-sdk'
|
|
|
20
21
|
const example = {
|
|
21
22
|
"vcenter": null,
|
|
22
23
|
"clusterFeatures": null,
|
|
24
|
+
"clusterUtilization": null,
|
|
23
25
|
"vms": null,
|
|
24
26
|
"infra": null,
|
|
25
27
|
} satisfies InventoryData
|
|
@@ -9,7 +9,6 @@ Name | Type
|
|
|
9
9
|
`name` | string
|
|
10
10
|
`description` | string
|
|
11
11
|
`filter` | string
|
|
12
|
-
`tags` | Array<string>
|
|
13
12
|
|
|
14
13
|
## Example
|
|
15
14
|
|
|
@@ -21,7 +20,6 @@ const example = {
|
|
|
21
20
|
"name": null,
|
|
22
21
|
"description": null,
|
|
23
22
|
"filter": null,
|
|
24
|
-
"tags": null,
|
|
25
23
|
} satisfies UpdateGroupRequest
|
|
26
24
|
|
|
27
25
|
console.log(example)
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
|
|
2
|
+
# VMFilterOptionsResponse
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type
|
|
8
|
+
------------ | -------------
|
|
9
|
+
`clusters` | Array<string>
|
|
10
|
+
`datacenters` | Array<string>
|
|
11
|
+
`concernLabels` | Array<string>
|
|
12
|
+
`concernCategories` | Array<string>
|
|
13
|
+
|
|
14
|
+
## Example
|
|
15
|
+
|
|
16
|
+
```typescript
|
|
17
|
+
import type { VMFilterOptionsResponse } from '@openshift-migration-advisor/agent-sdk'
|
|
18
|
+
|
|
19
|
+
// TODO: Update the object below with actual values
|
|
20
|
+
const example = {
|
|
21
|
+
"clusters": null,
|
|
22
|
+
"datacenters": null,
|
|
23
|
+
"concernLabels": null,
|
|
24
|
+
"concernCategories": null,
|
|
25
|
+
} satisfies VMFilterOptionsResponse
|
|
26
|
+
|
|
27
|
+
console.log(example)
|
|
28
|
+
|
|
29
|
+
// Convert the instance to a JSON string
|
|
30
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
31
|
+
console.log(exampleJSON)
|
|
32
|
+
|
|
33
|
+
// Parse the JSON string back to an object
|
|
34
|
+
const exampleParsed = JSON.parse(exampleJSON) as VMFilterOptionsResponse
|
|
35
|
+
console.log(exampleParsed)
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
39
|
+
|
|
40
|
+
|
package/docs/VMNIC.md
CHANGED
|
@@ -9,6 +9,8 @@ Name | Type
|
|
|
9
9
|
`mac` | string
|
|
10
10
|
`network` | string
|
|
11
11
|
`index` | number
|
|
12
|
+
`ipv4Address` | string
|
|
13
|
+
`ipv6Address` | string
|
|
12
14
|
|
|
13
15
|
## Example
|
|
14
16
|
|
|
@@ -20,6 +22,8 @@ const example = {
|
|
|
20
22
|
"mac": null,
|
|
21
23
|
"network": null,
|
|
22
24
|
"index": null,
|
|
25
|
+
"ipv4Address": null,
|
|
26
|
+
"ipv6Address": null,
|
|
23
27
|
} satisfies VMNIC
|
|
24
28
|
|
|
25
29
|
console.log(example)
|
package/docs/VirtualMachine.md
CHANGED
|
@@ -19,10 +19,12 @@ Name | Type
|
|
|
19
19
|
`migrationExcluded` | boolean
|
|
20
20
|
`inspectionStatus` | [VmInspectionStatus](VmInspectionStatus.md)
|
|
21
21
|
`inspectionConcernCount` | number
|
|
22
|
-
`
|
|
22
|
+
`groups` | Array<string>
|
|
23
23
|
`labels` | Array<string>
|
|
24
24
|
`utilization_cpu_p95` | number
|
|
25
25
|
`utilization_mem_p95` | number
|
|
26
|
+
`utilization_cpu_max` | number
|
|
27
|
+
`utilization_mem_max` | number
|
|
26
28
|
`utilization_disk` | number
|
|
27
29
|
`utilization_confidence` | number
|
|
28
30
|
|
|
@@ -46,10 +48,12 @@ const example = {
|
|
|
46
48
|
"migrationExcluded": null,
|
|
47
49
|
"inspectionStatus": null,
|
|
48
50
|
"inspectionConcernCount": null,
|
|
49
|
-
"
|
|
51
|
+
"groups": null,
|
|
50
52
|
"labels": null,
|
|
51
53
|
"utilization_cpu_p95": null,
|
|
52
54
|
"utilization_mem_p95": null,
|
|
55
|
+
"utilization_cpu_max": null,
|
|
56
|
+
"utilization_mem_max": null,
|
|
53
57
|
"utilization_disk": null,
|
|
54
58
|
"utilization_confidence": null,
|
|
55
59
|
} satisfies VirtualMachine
|