@openshift-migration-advisor/agent-sdk 0.8.0 → 0.12.0-1f1dc16fb9e5
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 +46 -2
- package/.openapi-generator/VERSION +1 -1
- package/README.md +52 -17
- package/dist/apis/DefaultApi.d.ts +632 -126
- package/dist/apis/DefaultApi.js +710 -160
- package/dist/esm/apis/DefaultApi.d.ts +632 -126
- package/dist/esm/apis/DefaultApi.js +724 -174
- package/dist/esm/models/BenchmarkRun.d.ts +104 -0
- package/dist/esm/models/BenchmarkRun.js +85 -0
- package/dist/esm/models/DatastoreDetail.d.ts +90 -0
- package/dist/esm/models/DatastoreDetail.js +74 -0
- package/dist/esm/models/DatastorePair.d.ts +50 -0
- package/dist/esm/models/DatastorePair.js +53 -0
- package/dist/esm/models/EstimateRange.d.ts +44 -0
- package/dist/esm/models/EstimateRange.js +45 -0
- package/dist/esm/models/ForecastStats.d.ts +87 -0
- package/dist/esm/models/ForecastStats.js +64 -0
- package/dist/esm/models/ForecasterDatastoresRequest.d.ts +33 -0
- package/dist/esm/models/ForecasterDatastoresRequest.js +42 -0
- package/dist/esm/models/ForecasterPairStatus.d.ts +98 -0
- package/dist/esm/models/ForecasterPairStatus.js +82 -0
- package/dist/esm/models/ForecasterStartRequest.d.ts +58 -0
- package/dist/esm/models/ForecasterStartRequest.js +53 -0
- package/dist/esm/models/ForecasterStatus.d.ts +47 -0
- package/dist/esm/models/ForecasterStatus.js +53 -0
- package/dist/esm/models/InspectorStatus.d.ts +20 -7
- package/dist/esm/models/InspectorStatus.js +12 -7
- package/dist/esm/models/PairCapability.d.ts +60 -0
- package/dist/esm/models/PairCapability.js +64 -0
- package/dist/esm/models/PairCapabilityRequest.d.ts +40 -0
- package/dist/esm/models/PairCapabilityRequest.js +47 -0
- package/dist/esm/models/PutForecasterCredentials403Response.d.ts +38 -0
- package/dist/esm/models/PutForecasterCredentials403Response.js +43 -0
- package/dist/esm/models/RightsizingCollectRequest.d.ts +70 -0
- package/dist/esm/models/RightsizingCollectRequest.js +56 -0
- package/dist/esm/models/RightsizingMetricStats.d.ts +62 -0
- package/dist/esm/models/RightsizingMetricStats.js +63 -0
- package/dist/esm/models/RightsizingReport.d.ts +81 -0
- package/dist/esm/models/RightsizingReport.js +76 -0
- package/dist/esm/models/RightsizingReportListResponse.d.ts +39 -0
- package/dist/esm/models/RightsizingReportListResponse.js +48 -0
- package/dist/esm/models/RightsizingReportSummary.d.ts +74 -0
- package/dist/esm/models/RightsizingReportSummary.js +71 -0
- package/dist/esm/models/RightsizingVMReport.d.ts +53 -0
- package/dist/esm/models/RightsizingVMReport.js +57 -0
- package/dist/esm/models/StartInspectionRequest.d.ts +32 -0
- package/dist/esm/models/StartInspectionRequest.js +43 -0
- package/dist/esm/models/StopForecasterPair202Response.d.ts +45 -0
- package/dist/esm/models/StopForecasterPair202Response.js +49 -0
- package/dist/esm/models/VMs.d.ts +18 -0
- package/dist/esm/models/VMs.js +4 -0
- package/dist/esm/models/VirtualMachine.d.ts +31 -1
- package/dist/esm/models/VirtualMachine.js +12 -4
- package/dist/esm/models/VirtualMachineDetail.d.ts +3 -3
- package/dist/esm/models/VirtualMachineDetail.js +3 -3
- package/dist/esm/models/VmInspectionConcern.d.ts +44 -0
- package/dist/esm/models/VmInspectionConcern.js +51 -0
- package/dist/esm/models/VmInspectionResults.d.ts +33 -0
- package/dist/esm/models/VmInspectionResults.js +42 -0
- package/dist/esm/models/VmInspectionStatus.d.ts +0 -1
- package/dist/esm/models/VmInspectionStatus.js +1 -2
- package/dist/esm/models/VmUtilizationDetails.d.ts +98 -0
- package/dist/esm/models/VmUtilizationDetails.js +87 -0
- package/dist/esm/models/index.d.ts +23 -1
- package/dist/esm/models/index.js +23 -1
- package/dist/esm/runtime.js +1 -1
- package/dist/models/BenchmarkRun.d.ts +104 -0
- package/dist/models/BenchmarkRun.js +92 -0
- package/dist/models/DatastoreDetail.d.ts +90 -0
- package/dist/models/DatastoreDetail.js +82 -0
- package/dist/models/DatastorePair.d.ts +50 -0
- package/dist/models/DatastorePair.js +60 -0
- package/dist/models/EstimateRange.d.ts +44 -0
- package/dist/models/EstimateRange.js +52 -0
- package/dist/models/ForecastStats.d.ts +87 -0
- package/dist/models/ForecastStats.js +71 -0
- package/dist/models/ForecasterDatastoresRequest.d.ts +33 -0
- package/dist/models/ForecasterDatastoresRequest.js +49 -0
- package/dist/models/ForecasterPairStatus.d.ts +98 -0
- package/dist/models/ForecasterPairStatus.js +90 -0
- package/dist/models/ForecasterStartRequest.d.ts +58 -0
- package/dist/models/ForecasterStartRequest.js +60 -0
- package/dist/models/ForecasterStatus.d.ts +47 -0
- package/dist/models/ForecasterStatus.js +61 -0
- package/dist/models/InspectorStatus.d.ts +20 -7
- package/dist/models/InspectorStatus.js +12 -7
- package/dist/models/PairCapability.d.ts +60 -0
- package/dist/models/PairCapability.js +72 -0
- package/dist/models/PairCapabilityRequest.d.ts +40 -0
- package/dist/models/PairCapabilityRequest.js +54 -0
- package/dist/models/PutForecasterCredentials403Response.d.ts +38 -0
- package/dist/models/PutForecasterCredentials403Response.js +50 -0
- package/dist/models/RightsizingCollectRequest.d.ts +70 -0
- package/dist/models/RightsizingCollectRequest.js +63 -0
- package/dist/models/RightsizingMetricStats.d.ts +62 -0
- package/dist/models/RightsizingMetricStats.js +70 -0
- package/dist/models/RightsizingReport.d.ts +81 -0
- package/dist/models/RightsizingReport.js +83 -0
- package/dist/models/RightsizingReportListResponse.d.ts +39 -0
- package/dist/models/RightsizingReportListResponse.js +55 -0
- package/dist/models/RightsizingReportSummary.d.ts +74 -0
- package/dist/models/RightsizingReportSummary.js +78 -0
- package/dist/models/RightsizingVMReport.d.ts +53 -0
- package/dist/models/RightsizingVMReport.js +64 -0
- package/dist/models/StartInspectionRequest.d.ts +32 -0
- package/dist/models/StartInspectionRequest.js +50 -0
- package/dist/models/StopForecasterPair202Response.d.ts +45 -0
- package/dist/models/StopForecasterPair202Response.js +57 -0
- package/dist/models/VMs.d.ts +18 -0
- package/dist/models/VMs.js +4 -0
- package/dist/models/VirtualMachine.d.ts +31 -1
- package/dist/models/VirtualMachine.js +12 -4
- package/dist/models/VirtualMachineDetail.d.ts +3 -3
- package/dist/models/VirtualMachineDetail.js +3 -3
- package/dist/models/VmInspectionConcern.d.ts +44 -0
- package/dist/models/VmInspectionConcern.js +58 -0
- package/dist/models/VmInspectionResults.d.ts +33 -0
- package/dist/models/VmInspectionResults.js +49 -0
- package/dist/models/VmInspectionStatus.d.ts +0 -1
- package/dist/models/VmInspectionStatus.js +1 -2
- package/dist/models/VmUtilizationDetails.d.ts +98 -0
- package/dist/models/VmUtilizationDetails.js +94 -0
- package/dist/models/index.d.ts +23 -1
- package/dist/models/index.js +23 -1
- package/dist/runtime.js +1 -1
- package/docs/BenchmarkRun.md +58 -0
- package/docs/DatastoreDetail.md +50 -0
- package/docs/DatastorePair.md +40 -0
- package/docs/DefaultApi.md +1123 -237
- package/docs/EstimateRange.md +39 -0
- package/docs/ForecastStats.md +52 -0
- package/docs/ForecasterDatastoresRequest.md +34 -0
- package/docs/ForecasterPairStatus.md +52 -0
- package/docs/ForecasterStartRequest.md +42 -0
- package/docs/ForecasterStatus.md +36 -0
- package/docs/InspectorStatus.md +4 -0
- package/docs/PairCapability.md +40 -0
- package/docs/PairCapabilityRequest.md +36 -0
- package/docs/PutForecasterCredentials403Response.md +36 -0
- package/docs/RightsizingCollectRequest.md +46 -0
- package/docs/RightsizingMetricStats.md +44 -0
- package/docs/RightsizingReport.md +50 -0
- package/docs/RightsizingReportListResponse.md +36 -0
- package/docs/RightsizingReportSummary.md +49 -0
- package/docs/RightsizingVMReport.md +40 -0
- package/docs/{InspectorStartRequest.md → StartInspectionRequest.md} +5 -6
- package/docs/StopForecasterPair202Response.md +36 -0
- package/docs/VMs.md +4 -0
- package/docs/VirtualMachine.md +12 -2
- package/docs/VirtualMachineDetail.md +1 -1
- package/docs/VmInspectionConcern.md +39 -0
- package/docs/VmInspectionResults.md +35 -0
- package/docs/VmUtilizationDetails.md +56 -0
- package/package.json +1 -1
- package/src/apis/DefaultApi.ts +1396 -350
- package/src/models/BenchmarkRun.ts +171 -0
- package/src/models/DatastoreDetail.ts +146 -0
- package/src/models/DatastorePair.ts +92 -0
- package/src/models/EstimateRange.ts +81 -0
- package/src/models/ForecastStats.ts +147 -0
- package/src/models/ForecasterDatastoresRequest.ts +73 -0
- package/src/models/ForecasterPairStatus.ts +158 -0
- package/src/models/ForecasterStartRequest.ts +113 -0
- package/src/models/ForecasterStatus.ts +93 -0
- package/src/models/InspectorStatus.ts +37 -7
- package/src/models/PairCapability.ts +106 -0
- package/src/models/PairCapabilityRequest.ts +89 -0
- package/src/models/PutForecasterCredentials403Response.ts +73 -0
- package/src/models/RightsizingCollectRequest.ts +123 -0
- package/src/models/RightsizingMetricStats.ts +111 -0
- package/src/models/RightsizingReport.ts +146 -0
- package/src/models/RightsizingReportListResponse.ts +83 -0
- package/src/models/RightsizingReportSummary.ts +129 -0
- package/src/models/RightsizingVMReport.ts +101 -0
- package/src/models/StartInspectionRequest.ts +66 -0
- package/src/models/StopForecasterPair202Response.ts +83 -0
- package/src/models/VMs.ts +18 -0
- package/src/models/VirtualMachine.ts +43 -4
- package/src/models/VirtualMachineDetail.ts +11 -11
- package/src/models/VmInspectionConcern.ts +84 -0
- package/src/models/VmInspectionResults.ts +73 -0
- package/src/models/VmInspectionStatus.ts +1 -2
- package/src/models/VmUtilizationDetails.ts +165 -0
- package/src/models/index.ts +23 -1
- package/src/runtime.ts +1 -2
- package/dist/esm/models/InspectorStartRequest.d.ts +0 -39
- package/dist/esm/models/InspectorStartRequest.js +0 -48
- package/dist/models/InspectorStartRequest.d.ts +0 -39
- package/dist/models/InspectorStartRequest.js +0 -55
- package/src/models/InspectorStartRequest.ts +0 -83
package/docs/DefaultApi.md
CHANGED
|
@@ -4,36 +4,49 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v1*
|
|
|
4
4
|
|
|
5
5
|
| Method | HTTP request | Description |
|
|
6
6
|
|------------- | ------------- | -------------|
|
|
7
|
-
| [**addVMsToInspection**](DefaultApi.md#addvmstoinspection) | **PATCH** /vms/inspector | Add more VMs to inspection queue |
|
|
8
7
|
| [**createGroup**](DefaultApi.md#creategroupoperation) | **POST** /groups | Create a new group |
|
|
8
|
+
| [**deleteForecasterRun**](DefaultApi.md#deleteforecasterrun) | **DELETE** /forecaster/runs/{id} | Delete a benchmark run |
|
|
9
9
|
| [**deleteGroup**](DefaultApi.md#deletegroup) | **DELETE** /groups/{id} | Delete group |
|
|
10
10
|
| [**getAgentStatus**](DefaultApi.md#getagentstatus) | **GET** /agent | Get agent status |
|
|
11
11
|
| [**getCollectorStatus**](DefaultApi.md#getcollectorstatus) | **GET** /collector | Get collector status |
|
|
12
|
+
| [**getForecasterDatastores**](DefaultApi.md#getforecasterdatastores) | **POST** /forecaster/datastores | List available datastores |
|
|
13
|
+
| [**getForecasterRuns**](DefaultApi.md#getforecasterruns) | **GET** /forecaster/runs | List benchmark runs |
|
|
14
|
+
| [**getForecasterStats**](DefaultApi.md#getforecasterstats) | **GET** /forecaster/stats | Get throughput statistics |
|
|
15
|
+
| [**getForecasterStatus**](DefaultApi.md#getforecasterstatus) | **GET** /forecaster | Poll forecaster status |
|
|
12
16
|
| [**getGroup**](DefaultApi.md#getgroup) | **GET** /groups/{id} | Get group by ID with its VMs |
|
|
13
|
-
| [**getInspectorStatus**](DefaultApi.md#getinspectorstatus) | **GET** /
|
|
17
|
+
| [**getInspectorStatus**](DefaultApi.md#getinspectorstatus) | **GET** /inspector | Get inspector status |
|
|
18
|
+
| [**getInspectorVddkStatus**](DefaultApi.md#getinspectorvddkstatus) | **GET** /inspector/vddk | Get VDDK status |
|
|
14
19
|
| [**getInventory**](DefaultApi.md#getinventory) | **GET** /inventory | Get collected inventory |
|
|
20
|
+
| [**getRightsizingReport**](DefaultApi.md#getrightsizingreport) | **GET** /rightsizing/{id} | Get a specific rightsizing report with full VM metrics |
|
|
15
21
|
| [**getVM**](DefaultApi.md#getvm) | **GET** /vms/{id} | Get details about a vm |
|
|
16
|
-
| [**
|
|
22
|
+
| [**getVMUtilization**](DefaultApi.md#getvmutilization) | **GET** /vms/{id}/utilization | Get utilization breakdown for a specific VM |
|
|
17
23
|
| [**getVMs**](DefaultApi.md#getvms) | **GET** /vms | Get list of VMs with filtering and pagination |
|
|
18
|
-
| [**getVddkStatus**](DefaultApi.md#getvddkstatus) | **GET** /vddk | Get VDDK status |
|
|
19
24
|
| [**getVersion**](DefaultApi.md#getversion) | **GET** /version | Get agent version information |
|
|
20
25
|
| [**listGroups**](DefaultApi.md#listgroups) | **GET** /groups | List all groups |
|
|
21
|
-
| [**
|
|
26
|
+
| [**listRightsizingReports**](DefaultApi.md#listrightsizingreports) | **GET** /rightsizing | List all rightsizing reports |
|
|
27
|
+
| [**postForecasterPairCapabilities**](DefaultApi.md#postforecasterpaircapabilities) | **POST** /forecaster/capabilities | Compute pair capabilities |
|
|
28
|
+
| [**putForecasterCredentials**](DefaultApi.md#putforecastercredentials) | **PUT** /forecaster/credentials | Verify vCenter credentials and permissions |
|
|
29
|
+
| [**putInspectorCredentials**](DefaultApi.md#putinspectorcredentials) | **PUT** /inspector/credentials | Set or replace inspector credentials |
|
|
30
|
+
| [**putInspectorVddk**](DefaultApi.md#putinspectorvddk) | **PUT** /inspector/vddk | Upload VDDK tarball |
|
|
31
|
+
| [**removeVMFromInspection**](DefaultApi.md#removevmfrominspection) | **DELETE** /vms/{id}/inspection | Remove VirtualMachine from inspection queue |
|
|
22
32
|
| [**setAgentMode**](DefaultApi.md#setagentmode) | **POST** /agent | Change agent mode |
|
|
23
33
|
| [**startCollector**](DefaultApi.md#startcollector) | **POST** /collector | Start inventory collection |
|
|
24
|
-
| [**
|
|
34
|
+
| [**startForecaster**](DefaultApi.md#startforecaster) | **POST** /forecaster | Start benchmark |
|
|
35
|
+
| [**startInspection**](DefaultApi.md#startinspectionoperation) | **POST** /inspector | Start inspection for VMs |
|
|
25
36
|
| [**stopCollector**](DefaultApi.md#stopcollector) | **DELETE** /collector | Stop collection |
|
|
26
|
-
| [**
|
|
37
|
+
| [**stopForecaster**](DefaultApi.md#stopforecaster) | **DELETE** /forecaster | Cancel benchmark |
|
|
38
|
+
| [**stopForecasterPair**](DefaultApi.md#stopforecasterpair) | **DELETE** /forecaster/pairs/{name} | Cancel a single pair |
|
|
39
|
+
| [**stopInspection**](DefaultApi.md#stopinspection) | **DELETE** /inspector | Stop inspector entirely |
|
|
40
|
+
| [**triggerRightsizingCollection**](DefaultApi.md#triggerrightsizingcollection) | **POST** /rightsizing | Trigger rightsizing metrics collection |
|
|
27
41
|
| [**updateGroup**](DefaultApi.md#updategroupoperation) | **PATCH** /groups/{id} | Update group |
|
|
28
|
-
| [**vddkPost**](DefaultApi.md#vddkpost) | **POST** /vddk | Upload VDDK tarball |
|
|
29
42
|
|
|
30
43
|
|
|
31
44
|
|
|
32
|
-
##
|
|
45
|
+
## createGroup
|
|
33
46
|
|
|
34
|
-
>
|
|
47
|
+
> Group createGroup(createGroupRequest)
|
|
35
48
|
|
|
36
|
-
|
|
49
|
+
Create a new group
|
|
37
50
|
|
|
38
51
|
### Example
|
|
39
52
|
|
|
@@ -42,19 +55,19 @@ import {
|
|
|
42
55
|
Configuration,
|
|
43
56
|
DefaultApi,
|
|
44
57
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
45
|
-
import type {
|
|
58
|
+
import type { CreateGroupOperationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
46
59
|
|
|
47
60
|
async function example() {
|
|
48
61
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
49
62
|
const api = new DefaultApi();
|
|
50
63
|
|
|
51
64
|
const body = {
|
|
52
|
-
//
|
|
53
|
-
|
|
54
|
-
} satisfies
|
|
65
|
+
// CreateGroupRequest
|
|
66
|
+
createGroupRequest: ...,
|
|
67
|
+
} satisfies CreateGroupOperationRequest;
|
|
55
68
|
|
|
56
69
|
try {
|
|
57
|
-
const data = await api.
|
|
70
|
+
const data = await api.createGroup(body);
|
|
58
71
|
console.log(data);
|
|
59
72
|
} catch (error) {
|
|
60
73
|
console.error(error);
|
|
@@ -70,11 +83,11 @@ example().catch(console.error);
|
|
|
70
83
|
|
|
71
84
|
| Name | Type | Description | Notes |
|
|
72
85
|
|------------- | ------------- | ------------- | -------------|
|
|
73
|
-
| **
|
|
86
|
+
| **createGroupRequest** | [CreateGroupRequest](CreateGroupRequest.md) | | |
|
|
74
87
|
|
|
75
88
|
### Return type
|
|
76
89
|
|
|
77
|
-
[**
|
|
90
|
+
[**Group**](Group.md)
|
|
78
91
|
|
|
79
92
|
### Authorization
|
|
80
93
|
|
|
@@ -89,19 +102,18 @@ No authorization required
|
|
|
89
102
|
### HTTP response details
|
|
90
103
|
| Status code | Description | Response headers |
|
|
91
104
|
|-------------|-------------|------------------|
|
|
92
|
-
| **
|
|
93
|
-
| **400** | Invalid request | - |
|
|
94
|
-
| **404** | Inspector not running | - |
|
|
105
|
+
| **201** | Group created | - |
|
|
106
|
+
| **400** | Invalid request (e.g., invalid filter syntax) | - |
|
|
95
107
|
| **500** | Internal server error | - |
|
|
96
108
|
|
|
97
109
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
98
110
|
|
|
99
111
|
|
|
100
|
-
##
|
|
112
|
+
## deleteForecasterRun
|
|
101
113
|
|
|
102
|
-
>
|
|
114
|
+
> deleteForecasterRun(id)
|
|
103
115
|
|
|
104
|
-
|
|
116
|
+
Delete a benchmark run
|
|
105
117
|
|
|
106
118
|
### Example
|
|
107
119
|
|
|
@@ -110,19 +122,19 @@ import {
|
|
|
110
122
|
Configuration,
|
|
111
123
|
DefaultApi,
|
|
112
124
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
113
|
-
import type {
|
|
125
|
+
import type { DeleteForecasterRunRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
114
126
|
|
|
115
127
|
async function example() {
|
|
116
128
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
117
129
|
const api = new DefaultApi();
|
|
118
130
|
|
|
119
131
|
const body = {
|
|
120
|
-
//
|
|
121
|
-
|
|
122
|
-
} satisfies
|
|
132
|
+
// number | Run ID
|
|
133
|
+
id: 789,
|
|
134
|
+
} satisfies DeleteForecasterRunRequest;
|
|
123
135
|
|
|
124
136
|
try {
|
|
125
|
-
const data = await api.
|
|
137
|
+
const data = await api.deleteForecasterRun(body);
|
|
126
138
|
console.log(data);
|
|
127
139
|
} catch (error) {
|
|
128
140
|
console.error(error);
|
|
@@ -138,11 +150,11 @@ example().catch(console.error);
|
|
|
138
150
|
|
|
139
151
|
| Name | Type | Description | Notes |
|
|
140
152
|
|------------- | ------------- | ------------- | -------------|
|
|
141
|
-
| **
|
|
153
|
+
| **id** | `number` | Run ID | [Defaults to `undefined`] |
|
|
142
154
|
|
|
143
155
|
### Return type
|
|
144
156
|
|
|
145
|
-
|
|
157
|
+
`void` (Empty response body)
|
|
146
158
|
|
|
147
159
|
### Authorization
|
|
148
160
|
|
|
@@ -150,15 +162,16 @@ No authorization required
|
|
|
150
162
|
|
|
151
163
|
### HTTP request headers
|
|
152
164
|
|
|
153
|
-
- **Content-Type**:
|
|
154
|
-
- **Accept**:
|
|
165
|
+
- **Content-Type**: Not defined
|
|
166
|
+
- **Accept**: Not defined
|
|
155
167
|
|
|
156
168
|
|
|
157
169
|
### HTTP response details
|
|
158
170
|
| Status code | Description | Response headers |
|
|
159
171
|
|-------------|-------------|------------------|
|
|
160
|
-
| **
|
|
161
|
-
| **400** | Invalid
|
|
172
|
+
| **204** | Run deleted | - |
|
|
173
|
+
| **400** | Invalid run ID | - |
|
|
174
|
+
| **404** | Run not found | - |
|
|
162
175
|
| **500** | Internal server error | - |
|
|
163
176
|
|
|
164
177
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
@@ -346,11 +359,13 @@ No authorization required
|
|
|
346
359
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
347
360
|
|
|
348
361
|
|
|
349
|
-
##
|
|
362
|
+
## getForecasterDatastores
|
|
350
363
|
|
|
351
|
-
>
|
|
364
|
+
> Array<DatastoreDetail> getForecasterDatastores(forecasterDatastoresRequest)
|
|
352
365
|
|
|
353
|
-
|
|
366
|
+
List available datastores
|
|
367
|
+
|
|
368
|
+
Returns datastores from the forklift-collected inventory with storage vendor and capability information derived from NAA device identifiers. No vSphere credentials are required.
|
|
354
369
|
|
|
355
370
|
### Example
|
|
356
371
|
|
|
@@ -359,25 +374,19 @@ import {
|
|
|
359
374
|
Configuration,
|
|
360
375
|
DefaultApi,
|
|
361
376
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
362
|
-
import type {
|
|
377
|
+
import type { GetForecasterDatastoresRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
363
378
|
|
|
364
379
|
async function example() {
|
|
365
380
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
366
381
|
const api = new DefaultApi();
|
|
367
382
|
|
|
368
383
|
const body = {
|
|
369
|
-
//
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
sort: ["cluster:asc","name:desc"],
|
|
373
|
-
// number | Page number for pagination (optional)
|
|
374
|
-
page: 56,
|
|
375
|
-
// number | Number of items per page (optional)
|
|
376
|
-
pageSize: 56,
|
|
377
|
-
} satisfies GetGroupRequest;
|
|
384
|
+
// ForecasterDatastoresRequest (optional)
|
|
385
|
+
forecasterDatastoresRequest: ...,
|
|
386
|
+
} satisfies GetForecasterDatastoresRequest;
|
|
378
387
|
|
|
379
388
|
try {
|
|
380
|
-
const data = await api.
|
|
389
|
+
const data = await api.getForecasterDatastores(body);
|
|
381
390
|
console.log(data);
|
|
382
391
|
} catch (error) {
|
|
383
392
|
console.error(error);
|
|
@@ -393,14 +402,11 @@ example().catch(console.error);
|
|
|
393
402
|
|
|
394
403
|
| Name | Type | Description | Notes |
|
|
395
404
|
|------------- | ------------- | ------------- | -------------|
|
|
396
|
-
| **
|
|
397
|
-
| **sort** | `Array<string>` | Sort fields with direction (e.g., \"name:asc\" or \"cluster:desc,name:asc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues. | [Optional] |
|
|
398
|
-
| **page** | `number` | Page number for pagination | [Optional] [Defaults to `1`] |
|
|
399
|
-
| **pageSize** | `number` | Number of items per page | [Optional] [Defaults to `undefined`] |
|
|
405
|
+
| **forecasterDatastoresRequest** | [ForecasterDatastoresRequest](ForecasterDatastoresRequest.md) | | [Optional] |
|
|
400
406
|
|
|
401
407
|
### Return type
|
|
402
408
|
|
|
403
|
-
[**
|
|
409
|
+
[**Array<DatastoreDetail>**](DatastoreDetail.md)
|
|
404
410
|
|
|
405
411
|
### Authorization
|
|
406
412
|
|
|
@@ -408,25 +414,26 @@ No authorization required
|
|
|
408
414
|
|
|
409
415
|
### HTTP request headers
|
|
410
416
|
|
|
411
|
-
- **Content-Type**:
|
|
417
|
+
- **Content-Type**: `application/json`
|
|
412
418
|
- **Accept**: `application/json`
|
|
413
419
|
|
|
414
420
|
|
|
415
421
|
### HTTP response details
|
|
416
422
|
| Status code | Description | Response headers |
|
|
417
423
|
|-------------|-------------|------------------|
|
|
418
|
-
| **200** |
|
|
419
|
-
| **404** | Group not found | - |
|
|
424
|
+
| **200** | List of datastores | - |
|
|
420
425
|
| **500** | Internal server error | - |
|
|
421
426
|
|
|
422
427
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
423
428
|
|
|
424
429
|
|
|
425
|
-
##
|
|
430
|
+
## getForecasterRuns
|
|
426
431
|
|
|
427
|
-
>
|
|
432
|
+
> Array<BenchmarkRun> getForecasterRuns(pairName)
|
|
428
433
|
|
|
429
|
-
|
|
434
|
+
List benchmark runs
|
|
435
|
+
|
|
436
|
+
Returns individual benchmark iterations. Optionally filtered by pair name.
|
|
430
437
|
|
|
431
438
|
### Example
|
|
432
439
|
|
|
@@ -435,14 +442,19 @@ import {
|
|
|
435
442
|
Configuration,
|
|
436
443
|
DefaultApi,
|
|
437
444
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
438
|
-
import type {
|
|
445
|
+
import type { GetForecasterRunsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
439
446
|
|
|
440
447
|
async function example() {
|
|
441
448
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
442
449
|
const api = new DefaultApi();
|
|
443
450
|
|
|
451
|
+
const body = {
|
|
452
|
+
// string | Filter runs by pair name (optional)
|
|
453
|
+
pairName: pairName_example,
|
|
454
|
+
} satisfies GetForecasterRunsRequest;
|
|
455
|
+
|
|
444
456
|
try {
|
|
445
|
-
const data = await api.
|
|
457
|
+
const data = await api.getForecasterRuns(body);
|
|
446
458
|
console.log(data);
|
|
447
459
|
} catch (error) {
|
|
448
460
|
console.error(error);
|
|
@@ -455,11 +467,14 @@ example().catch(console.error);
|
|
|
455
467
|
|
|
456
468
|
### Parameters
|
|
457
469
|
|
|
458
|
-
|
|
470
|
+
|
|
471
|
+
| Name | Type | Description | Notes |
|
|
472
|
+
|------------- | ------------- | ------------- | -------------|
|
|
473
|
+
| **pairName** | `string` | Filter runs by pair name | [Optional] [Defaults to `undefined`] |
|
|
459
474
|
|
|
460
475
|
### Return type
|
|
461
476
|
|
|
462
|
-
[**
|
|
477
|
+
[**Array<BenchmarkRun>**](BenchmarkRun.md)
|
|
463
478
|
|
|
464
479
|
### Authorization
|
|
465
480
|
|
|
@@ -474,17 +489,19 @@ No authorization required
|
|
|
474
489
|
### HTTP response details
|
|
475
490
|
| Status code | Description | Response headers |
|
|
476
491
|
|-------------|-------------|------------------|
|
|
477
|
-
| **200** |
|
|
492
|
+
| **200** | List of benchmark runs | - |
|
|
478
493
|
| **500** | Internal server error | - |
|
|
479
494
|
|
|
480
495
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
481
496
|
|
|
482
497
|
|
|
483
|
-
##
|
|
498
|
+
## getForecasterStats
|
|
484
499
|
|
|
485
|
-
>
|
|
500
|
+
> ForecastStats getForecasterStats(pairName)
|
|
486
501
|
|
|
487
|
-
Get
|
|
502
|
+
Get throughput statistics
|
|
503
|
+
|
|
504
|
+
Returns computed statistics for a datastore pair\'s benchmark results. Primary endpoint for the UI to display migration time estimates.
|
|
488
505
|
|
|
489
506
|
### Example
|
|
490
507
|
|
|
@@ -493,21 +510,19 @@ import {
|
|
|
493
510
|
Configuration,
|
|
494
511
|
DefaultApi,
|
|
495
512
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
496
|
-
import type {
|
|
513
|
+
import type { GetForecasterStatsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
497
514
|
|
|
498
515
|
async function example() {
|
|
499
516
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
500
517
|
const api = new DefaultApi();
|
|
501
518
|
|
|
502
519
|
const body = {
|
|
503
|
-
//
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
groupId: groupId_example,
|
|
507
|
-
} satisfies GetInventoryRequest;
|
|
520
|
+
// string | Pair name to get statistics for
|
|
521
|
+
pairName: pairName_example,
|
|
522
|
+
} satisfies GetForecasterStatsRequest;
|
|
508
523
|
|
|
509
524
|
try {
|
|
510
|
-
const data = await api.
|
|
525
|
+
const data = await api.getForecasterStats(body);
|
|
511
526
|
console.log(data);
|
|
512
527
|
} catch (error) {
|
|
513
528
|
console.error(error);
|
|
@@ -523,12 +538,11 @@ example().catch(console.error);
|
|
|
523
538
|
|
|
524
539
|
| Name | Type | Description | Notes |
|
|
525
540
|
|------------- | ------------- | ------------- | -------------|
|
|
526
|
-
| **
|
|
527
|
-
| **groupId** | `string` | Filter inventory to VMs matching this group\'s filter expression | [Optional] [Defaults to `undefined`] |
|
|
541
|
+
| **pairName** | `string` | Pair name to get statistics for | [Defaults to `undefined`] |
|
|
528
542
|
|
|
529
543
|
### Return type
|
|
530
544
|
|
|
531
|
-
[**
|
|
545
|
+
[**ForecastStats**](ForecastStats.md)
|
|
532
546
|
|
|
533
547
|
### Authorization
|
|
534
548
|
|
|
@@ -543,18 +557,20 @@ No authorization required
|
|
|
543
557
|
### HTTP response details
|
|
544
558
|
| Status code | Description | Response headers |
|
|
545
559
|
|-------------|-------------|------------------|
|
|
546
|
-
| **200** |
|
|
547
|
-
| **
|
|
560
|
+
| **200** | Throughput statistics | - |
|
|
561
|
+
| **400** | Missing pairName parameter | - |
|
|
548
562
|
| **500** | Internal server error | - |
|
|
549
563
|
|
|
550
564
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
551
565
|
|
|
552
566
|
|
|
553
|
-
##
|
|
567
|
+
## getForecasterStatus
|
|
554
568
|
|
|
555
|
-
>
|
|
569
|
+
> ForecasterStatus getForecasterStatus()
|
|
556
570
|
|
|
557
|
-
|
|
571
|
+
Poll forecaster status
|
|
572
|
+
|
|
573
|
+
Returns current service state with per-pair progress details.
|
|
558
574
|
|
|
559
575
|
### Example
|
|
560
576
|
|
|
@@ -563,19 +579,14 @@ import {
|
|
|
563
579
|
Configuration,
|
|
564
580
|
DefaultApi,
|
|
565
581
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
566
|
-
import type {
|
|
582
|
+
import type { GetForecasterStatusRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
567
583
|
|
|
568
584
|
async function example() {
|
|
569
585
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
570
586
|
const api = new DefaultApi();
|
|
571
587
|
|
|
572
|
-
const body = {
|
|
573
|
-
// string | VirtualMachine id
|
|
574
|
-
id: id_example,
|
|
575
|
-
} satisfies GetVMRequest;
|
|
576
|
-
|
|
577
588
|
try {
|
|
578
|
-
const data = await api.
|
|
589
|
+
const data = await api.getForecasterStatus();
|
|
579
590
|
console.log(data);
|
|
580
591
|
} catch (error) {
|
|
581
592
|
console.error(error);
|
|
@@ -588,14 +599,11 @@ example().catch(console.error);
|
|
|
588
599
|
|
|
589
600
|
### Parameters
|
|
590
601
|
|
|
591
|
-
|
|
592
|
-
| Name | Type | Description | Notes |
|
|
593
|
-
|------------- | ------------- | ------------- | -------------|
|
|
594
|
-
| **id** | `string` | VirtualMachine id | [Defaults to `undefined`] |
|
|
602
|
+
This endpoint does not need any parameter.
|
|
595
603
|
|
|
596
604
|
### Return type
|
|
597
605
|
|
|
598
|
-
[**
|
|
606
|
+
[**ForecasterStatus**](ForecasterStatus.md)
|
|
599
607
|
|
|
600
608
|
### Authorization
|
|
601
609
|
|
|
@@ -610,18 +618,16 @@ No authorization required
|
|
|
610
618
|
### HTTP response details
|
|
611
619
|
| Status code | Description | Response headers |
|
|
612
620
|
|-------------|-------------|------------------|
|
|
613
|
-
| **200** |
|
|
614
|
-
| **404** | VirtualMachine not found | - |
|
|
615
|
-
| **500** | Internal server error | - |
|
|
621
|
+
| **200** | Current forecaster status | - |
|
|
616
622
|
|
|
617
623
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
618
624
|
|
|
619
625
|
|
|
620
|
-
##
|
|
626
|
+
## getGroup
|
|
621
627
|
|
|
622
|
-
>
|
|
628
|
+
> GroupResponse getGroup(id, sort, page, pageSize)
|
|
623
629
|
|
|
624
|
-
Get
|
|
630
|
+
Get group by ID with its VMs
|
|
625
631
|
|
|
626
632
|
### Example
|
|
627
633
|
|
|
@@ -630,19 +636,25 @@ import {
|
|
|
630
636
|
Configuration,
|
|
631
637
|
DefaultApi,
|
|
632
638
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
633
|
-
import type {
|
|
639
|
+
import type { GetGroupRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
634
640
|
|
|
635
641
|
async function example() {
|
|
636
642
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
637
643
|
const api = new DefaultApi();
|
|
638
644
|
|
|
639
645
|
const body = {
|
|
640
|
-
// string |
|
|
646
|
+
// string | Group ID
|
|
641
647
|
id: id_example,
|
|
642
|
-
|
|
648
|
+
// Array<string> | Sort fields with direction (e.g., \"name:asc\" or \"cluster:desc,name:asc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues. (optional)
|
|
649
|
+
sort: ["cluster:asc","name:desc"],
|
|
650
|
+
// number | Page number for pagination (optional)
|
|
651
|
+
page: 56,
|
|
652
|
+
// number | Number of items per page (optional)
|
|
653
|
+
pageSize: 56,
|
|
654
|
+
} satisfies GetGroupRequest;
|
|
643
655
|
|
|
644
656
|
try {
|
|
645
|
-
const data = await api.
|
|
657
|
+
const data = await api.getGroup(body);
|
|
646
658
|
console.log(data);
|
|
647
659
|
} catch (error) {
|
|
648
660
|
console.error(error);
|
|
@@ -658,11 +670,14 @@ example().catch(console.error);
|
|
|
658
670
|
|
|
659
671
|
| Name | Type | Description | Notes |
|
|
660
672
|
|------------- | ------------- | ------------- | -------------|
|
|
661
|
-
| **id** | `string` |
|
|
673
|
+
| **id** | `string` | Group ID | [Defaults to `undefined`] |
|
|
674
|
+
| **sort** | `Array<string>` | Sort fields with direction (e.g., \"name:asc\" or \"cluster:desc,name:asc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues. | [Optional] |
|
|
675
|
+
| **page** | `number` | Page number for pagination | [Optional] [Defaults to `1`] |
|
|
676
|
+
| **pageSize** | `number` | Number of items per page | [Optional] [Defaults to `undefined`] |
|
|
662
677
|
|
|
663
678
|
### Return type
|
|
664
679
|
|
|
665
|
-
[**
|
|
680
|
+
[**GroupResponse**](GroupResponse.md)
|
|
666
681
|
|
|
667
682
|
### Authorization
|
|
668
683
|
|
|
@@ -677,18 +692,18 @@ No authorization required
|
|
|
677
692
|
### HTTP response details
|
|
678
693
|
| Status code | Description | Response headers |
|
|
679
694
|
|-------------|-------------|------------------|
|
|
680
|
-
| **200** |
|
|
681
|
-
| **404** |
|
|
695
|
+
| **200** | Group details with VMs | - |
|
|
696
|
+
| **404** | Group not found | - |
|
|
682
697
|
| **500** | Internal server error | - |
|
|
683
698
|
|
|
684
699
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
685
700
|
|
|
686
701
|
|
|
687
|
-
##
|
|
702
|
+
## getInspectorStatus
|
|
688
703
|
|
|
689
|
-
>
|
|
704
|
+
> InspectorStatus getInspectorStatus(includeVddk, includeCredentials)
|
|
690
705
|
|
|
691
|
-
Get
|
|
706
|
+
Get inspector status
|
|
692
707
|
|
|
693
708
|
### Example
|
|
694
709
|
|
|
@@ -697,25 +712,21 @@ import {
|
|
|
697
712
|
Configuration,
|
|
698
713
|
DefaultApi,
|
|
699
714
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
700
|
-
import type {
|
|
715
|
+
import type { GetInspectorStatusRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
701
716
|
|
|
702
717
|
async function example() {
|
|
703
718
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
704
719
|
const api = new DefaultApi();
|
|
705
720
|
|
|
706
721
|
const body = {
|
|
707
|
-
//
|
|
708
|
-
|
|
709
|
-
//
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
page: 56,
|
|
713
|
-
// number | Number of items per page (optional)
|
|
714
|
-
pageSize: 56,
|
|
715
|
-
} satisfies GetVMsRequest;
|
|
722
|
+
// boolean | If true, include uploaded VDDK metadata (`version`, `md5`) when present. omitted if VDDK was never uploaded. (optional)
|
|
723
|
+
includeVddk: true,
|
|
724
|
+
// boolean | If true, include configured vCenter URL and username (password is never returned). omitted if was never set. (optional)
|
|
725
|
+
includeCredentials: true,
|
|
726
|
+
} satisfies GetInspectorStatusRequest;
|
|
716
727
|
|
|
717
728
|
try {
|
|
718
|
-
const data = await api.
|
|
729
|
+
const data = await api.getInspectorStatus(body);
|
|
719
730
|
console.log(data);
|
|
720
731
|
} catch (error) {
|
|
721
732
|
console.error(error);
|
|
@@ -731,14 +742,12 @@ example().catch(console.error);
|
|
|
731
742
|
|
|
732
743
|
| Name | Type | Description | Notes |
|
|
733
744
|
|------------- | ------------- | ------------- | -------------|
|
|
734
|
-
| **
|
|
735
|
-
| **
|
|
736
|
-
| **page** | `number` | Page number for pagination | [Optional] [Defaults to `1`] |
|
|
737
|
-
| **pageSize** | `number` | Number of items per page | [Optional] [Defaults to `undefined`] |
|
|
745
|
+
| **includeVddk** | `boolean` | If true, include uploaded VDDK metadata (`version`, `md5`) when present. omitted if VDDK was never uploaded. | [Optional] [Defaults to `false`] |
|
|
746
|
+
| **includeCredentials** | `boolean` | If true, include configured vCenter URL and username (password is never returned). omitted if was never set. | [Optional] [Defaults to `false`] |
|
|
738
747
|
|
|
739
748
|
### Return type
|
|
740
749
|
|
|
741
|
-
[**
|
|
750
|
+
[**InspectorStatus**](InspectorStatus.md)
|
|
742
751
|
|
|
743
752
|
### Authorization
|
|
744
753
|
|
|
@@ -753,16 +762,15 @@ No authorization required
|
|
|
753
762
|
### HTTP response details
|
|
754
763
|
| Status code | Description | Response headers |
|
|
755
764
|
|-------------|-------------|------------------|
|
|
756
|
-
| **200** |
|
|
757
|
-
| **400** | Invalid request parameters | - |
|
|
765
|
+
| **200** | Inspector status | - |
|
|
758
766
|
| **500** | Internal server error | - |
|
|
759
767
|
|
|
760
768
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
761
769
|
|
|
762
770
|
|
|
763
|
-
##
|
|
771
|
+
## getInspectorVddkStatus
|
|
764
772
|
|
|
765
|
-
> VddkProperties
|
|
773
|
+
> VddkProperties getInspectorVddkStatus()
|
|
766
774
|
|
|
767
775
|
Get VDDK status
|
|
768
776
|
|
|
@@ -773,14 +781,14 @@ import {
|
|
|
773
781
|
Configuration,
|
|
774
782
|
DefaultApi,
|
|
775
783
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
776
|
-
import type {
|
|
784
|
+
import type { GetInspectorVddkStatusRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
777
785
|
|
|
778
786
|
async function example() {
|
|
779
787
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
780
788
|
const api = new DefaultApi();
|
|
781
789
|
|
|
782
790
|
try {
|
|
783
|
-
const data = await api.
|
|
791
|
+
const data = await api.getInspectorVddkStatus();
|
|
784
792
|
console.log(data);
|
|
785
793
|
} catch (error) {
|
|
786
794
|
console.error(error);
|
|
@@ -812,18 +820,18 @@ No authorization required
|
|
|
812
820
|
### HTTP response details
|
|
813
821
|
| Status code | Description | Response headers |
|
|
814
822
|
|-------------|-------------|------------------|
|
|
815
|
-
| **200** | Returns the current properties of the uploaded VMware VDDK tar.
|
|
823
|
+
| **200** | Returns the current properties of the uploaded VMware VDDK tar. If the VDDK package has not been uploaded, a 404 response is returned. | - |
|
|
816
824
|
| **404** | Vddk not found | - |
|
|
817
825
|
| **500** | Internal server error | - |
|
|
818
826
|
|
|
819
827
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
820
828
|
|
|
821
829
|
|
|
822
|
-
##
|
|
830
|
+
## getInventory
|
|
823
831
|
|
|
824
|
-
>
|
|
832
|
+
> GetInventory200Response getInventory(withAgentId, groupId)
|
|
825
833
|
|
|
826
|
-
Get
|
|
834
|
+
Get collected inventory
|
|
827
835
|
|
|
828
836
|
### Example
|
|
829
837
|
|
|
@@ -832,14 +840,21 @@ import {
|
|
|
832
840
|
Configuration,
|
|
833
841
|
DefaultApi,
|
|
834
842
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
835
|
-
import type {
|
|
843
|
+
import type { GetInventoryRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
836
844
|
|
|
837
845
|
async function example() {
|
|
838
846
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
839
847
|
const api = new DefaultApi();
|
|
840
848
|
|
|
849
|
+
const body = {
|
|
850
|
+
// boolean | If true, include the agentId in the response (Compatible with manual inventory upload). (optional)
|
|
851
|
+
withAgentId: true,
|
|
852
|
+
// string | Filter inventory to VMs matching this group\'s filter expression (optional)
|
|
853
|
+
groupId: groupId_example,
|
|
854
|
+
} satisfies GetInventoryRequest;
|
|
855
|
+
|
|
841
856
|
try {
|
|
842
|
-
const data = await api.
|
|
857
|
+
const data = await api.getInventory(body);
|
|
843
858
|
console.log(data);
|
|
844
859
|
} catch (error) {
|
|
845
860
|
console.error(error);
|
|
@@ -852,11 +867,15 @@ example().catch(console.error);
|
|
|
852
867
|
|
|
853
868
|
### Parameters
|
|
854
869
|
|
|
855
|
-
|
|
870
|
+
|
|
871
|
+
| Name | Type | Description | Notes |
|
|
872
|
+
|------------- | ------------- | ------------- | -------------|
|
|
873
|
+
| **withAgentId** | `boolean` | If true, include the agentId in the response (Compatible with manual inventory upload). | [Optional] [Defaults to `false`] |
|
|
874
|
+
| **groupId** | `string` | Filter inventory to VMs matching this group\'s filter expression | [Optional] [Defaults to `undefined`] |
|
|
856
875
|
|
|
857
876
|
### Return type
|
|
858
877
|
|
|
859
|
-
[**
|
|
878
|
+
[**GetInventory200Response**](GetInventory200Response.md)
|
|
860
879
|
|
|
861
880
|
### Authorization
|
|
862
881
|
|
|
@@ -871,16 +890,18 @@ No authorization required
|
|
|
871
890
|
### HTTP response details
|
|
872
891
|
| Status code | Description | Response headers |
|
|
873
892
|
|-------------|-------------|------------------|
|
|
874
|
-
| **200** |
|
|
893
|
+
| **200** | Collected inventory | - |
|
|
894
|
+
| **404** | Inventory not available | - |
|
|
895
|
+
| **500** | Internal server error | - |
|
|
875
896
|
|
|
876
897
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
877
898
|
|
|
878
899
|
|
|
879
|
-
##
|
|
900
|
+
## getRightsizingReport
|
|
880
901
|
|
|
881
|
-
>
|
|
902
|
+
> RightsizingReport getRightsizingReport(id)
|
|
882
903
|
|
|
883
|
-
|
|
904
|
+
Get a specific rightsizing report with full VM metrics
|
|
884
905
|
|
|
885
906
|
### Example
|
|
886
907
|
|
|
@@ -889,23 +910,19 @@ import {
|
|
|
889
910
|
Configuration,
|
|
890
911
|
DefaultApi,
|
|
891
912
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
892
|
-
import type {
|
|
913
|
+
import type { GetRightsizingReportRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
893
914
|
|
|
894
915
|
async function example() {
|
|
895
916
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
896
917
|
const api = new DefaultApi();
|
|
897
918
|
|
|
898
919
|
const body = {
|
|
899
|
-
// string |
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
page: 56,
|
|
903
|
-
// number | Number of groups per page (optional)
|
|
904
|
-
pageSize: 56,
|
|
905
|
-
} satisfies ListGroupsRequest;
|
|
920
|
+
// string | Report UUID
|
|
921
|
+
id: id_example,
|
|
922
|
+
} satisfies GetRightsizingReportRequest;
|
|
906
923
|
|
|
907
924
|
try {
|
|
908
|
-
const data = await api.
|
|
925
|
+
const data = await api.getRightsizingReport(body);
|
|
909
926
|
console.log(data);
|
|
910
927
|
} catch (error) {
|
|
911
928
|
console.error(error);
|
|
@@ -921,13 +938,11 @@ example().catch(console.error);
|
|
|
921
938
|
|
|
922
939
|
| Name | Type | Description | Notes |
|
|
923
940
|
|------------- | ------------- | ------------- | -------------|
|
|
924
|
-
| **
|
|
925
|
-
| **page** | `number` | Page number (1-indexed) | [Optional] [Defaults to `1`] |
|
|
926
|
-
| **pageSize** | `number` | Number of groups per page | [Optional] [Defaults to `20`] |
|
|
941
|
+
| **id** | `string` | Report UUID | [Defaults to `undefined`] |
|
|
927
942
|
|
|
928
943
|
### Return type
|
|
929
944
|
|
|
930
|
-
[**
|
|
945
|
+
[**RightsizingReport**](RightsizingReport.md)
|
|
931
946
|
|
|
932
947
|
### Authorization
|
|
933
948
|
|
|
@@ -942,18 +957,18 @@ No authorization required
|
|
|
942
957
|
### HTTP response details
|
|
943
958
|
| Status code | Description | Response headers |
|
|
944
959
|
|-------------|-------------|------------------|
|
|
945
|
-
| **200** |
|
|
946
|
-
| **
|
|
960
|
+
| **200** | Rightsizing report | - |
|
|
961
|
+
| **404** | Report not found | - |
|
|
947
962
|
| **500** | Internal server error | - |
|
|
948
963
|
|
|
949
964
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
950
965
|
|
|
951
966
|
|
|
952
|
-
##
|
|
967
|
+
## getVM
|
|
953
968
|
|
|
954
|
-
>
|
|
969
|
+
> VirtualMachineDetail getVM(id)
|
|
955
970
|
|
|
956
|
-
|
|
971
|
+
Get details about a vm
|
|
957
972
|
|
|
958
973
|
### Example
|
|
959
974
|
|
|
@@ -962,19 +977,19 @@ import {
|
|
|
962
977
|
Configuration,
|
|
963
978
|
DefaultApi,
|
|
964
979
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
965
|
-
import type {
|
|
980
|
+
import type { GetVMRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
966
981
|
|
|
967
982
|
async function example() {
|
|
968
983
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
969
984
|
const api = new DefaultApi();
|
|
970
985
|
|
|
971
986
|
const body = {
|
|
972
|
-
// string
|
|
987
|
+
// string | VirtualMachine id
|
|
973
988
|
id: id_example,
|
|
974
|
-
} satisfies
|
|
989
|
+
} satisfies GetVMRequest;
|
|
975
990
|
|
|
976
991
|
try {
|
|
977
|
-
const data = await api.
|
|
992
|
+
const data = await api.getVM(body);
|
|
978
993
|
console.log(data);
|
|
979
994
|
} catch (error) {
|
|
980
995
|
console.error(error);
|
|
@@ -990,11 +1005,11 @@ example().catch(console.error);
|
|
|
990
1005
|
|
|
991
1006
|
| Name | Type | Description | Notes |
|
|
992
1007
|
|------------- | ------------- | ------------- | -------------|
|
|
993
|
-
| **id** | `string` |
|
|
1008
|
+
| **id** | `string` | VirtualMachine id | [Defaults to `undefined`] |
|
|
994
1009
|
|
|
995
1010
|
### Return type
|
|
996
1011
|
|
|
997
|
-
[**
|
|
1012
|
+
[**VirtualMachineDetail**](VirtualMachineDetail.md)
|
|
998
1013
|
|
|
999
1014
|
### Authorization
|
|
1000
1015
|
|
|
@@ -1009,19 +1024,18 @@ No authorization required
|
|
|
1009
1024
|
### HTTP response details
|
|
1010
1025
|
| Status code | Description | Response headers |
|
|
1011
1026
|
|-------------|-------------|------------------|
|
|
1012
|
-
| **200** |
|
|
1013
|
-
| **
|
|
1014
|
-
| **404** | Inspector not running | - |
|
|
1027
|
+
| **200** | VirtualMachine details | - |
|
|
1028
|
+
| **404** | VirtualMachine not found | - |
|
|
1015
1029
|
| **500** | Internal server error | - |
|
|
1016
1030
|
|
|
1017
1031
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1018
1032
|
|
|
1019
1033
|
|
|
1020
|
-
##
|
|
1034
|
+
## getVMUtilization
|
|
1021
1035
|
|
|
1022
|
-
>
|
|
1036
|
+
> VmUtilizationDetails getVMUtilization(id)
|
|
1023
1037
|
|
|
1024
|
-
|
|
1038
|
+
Get utilization breakdown for a specific VM
|
|
1025
1039
|
|
|
1026
1040
|
### Example
|
|
1027
1041
|
|
|
@@ -1030,19 +1044,19 @@ import {
|
|
|
1030
1044
|
Configuration,
|
|
1031
1045
|
DefaultApi,
|
|
1032
1046
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1033
|
-
import type {
|
|
1047
|
+
import type { GetVMUtilizationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1034
1048
|
|
|
1035
1049
|
async function example() {
|
|
1036
1050
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1037
1051
|
const api = new DefaultApi();
|
|
1038
1052
|
|
|
1039
1053
|
const body = {
|
|
1040
|
-
//
|
|
1041
|
-
|
|
1042
|
-
} satisfies
|
|
1054
|
+
// string | VirtualMachine MoRef ID
|
|
1055
|
+
id: id_example,
|
|
1056
|
+
} satisfies GetVMUtilizationRequest;
|
|
1043
1057
|
|
|
1044
1058
|
try {
|
|
1045
|
-
const data = await api.
|
|
1059
|
+
const data = await api.getVMUtilization(body);
|
|
1046
1060
|
console.log(data);
|
|
1047
1061
|
} catch (error) {
|
|
1048
1062
|
console.error(error);
|
|
@@ -1058,11 +1072,11 @@ example().catch(console.error);
|
|
|
1058
1072
|
|
|
1059
1073
|
| Name | Type | Description | Notes |
|
|
1060
1074
|
|------------- | ------------- | ------------- | -------------|
|
|
1061
|
-
| **
|
|
1075
|
+
| **id** | `string` | VirtualMachine MoRef ID | [Defaults to `undefined`] |
|
|
1062
1076
|
|
|
1063
1077
|
### Return type
|
|
1064
1078
|
|
|
1065
|
-
[**
|
|
1079
|
+
[**VmUtilizationDetails**](VmUtilizationDetails.md)
|
|
1066
1080
|
|
|
1067
1081
|
### Authorization
|
|
1068
1082
|
|
|
@@ -1070,26 +1084,25 @@ No authorization required
|
|
|
1070
1084
|
|
|
1071
1085
|
### HTTP request headers
|
|
1072
1086
|
|
|
1073
|
-
- **Content-Type**:
|
|
1087
|
+
- **Content-Type**: Not defined
|
|
1074
1088
|
- **Accept**: `application/json`
|
|
1075
1089
|
|
|
1076
1090
|
|
|
1077
1091
|
### HTTP response details
|
|
1078
1092
|
| Status code | Description | Response headers |
|
|
1079
1093
|
|-------------|-------------|------------------|
|
|
1080
|
-
| **200** |
|
|
1081
|
-
| **
|
|
1082
|
-
| **409** | Conflict | - |
|
|
1094
|
+
| **200** | VM utilization details | - |
|
|
1095
|
+
| **404** | No utilization data found for this VM | - |
|
|
1083
1096
|
| **500** | Internal server error | - |
|
|
1084
1097
|
|
|
1085
1098
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1086
1099
|
|
|
1087
1100
|
|
|
1088
|
-
##
|
|
1101
|
+
## getVMs
|
|
1089
1102
|
|
|
1090
|
-
>
|
|
1103
|
+
> VirtualMachineListResponse getVMs(byExpression, sort, page, pageSize)
|
|
1091
1104
|
|
|
1092
|
-
|
|
1105
|
+
Get list of VMs with filtering and pagination
|
|
1093
1106
|
|
|
1094
1107
|
### Example
|
|
1095
1108
|
|
|
@@ -1098,22 +1111,697 @@ import {
|
|
|
1098
1111
|
Configuration,
|
|
1099
1112
|
DefaultApi,
|
|
1100
1113
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1101
|
-
import type {
|
|
1114
|
+
import type { GetVMsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1102
1115
|
|
|
1103
1116
|
async function example() {
|
|
1104
1117
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1105
1118
|
const api = new DefaultApi();
|
|
1106
1119
|
|
|
1107
1120
|
const body = {
|
|
1108
|
-
//
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1121
|
+
// string | Filter by expression (matches VMs with the provided expression) (optional)
|
|
1122
|
+
byExpression: exp1,
|
|
1123
|
+
// Array<string> | Sort fields with direction (e.g., \"name:asc\" or \"cluster:desc,name:asc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues. (optional)
|
|
1124
|
+
sort: ["cluster:asc","name:desc"],
|
|
1125
|
+
// number | Page number for pagination (optional)
|
|
1126
|
+
page: 56,
|
|
1127
|
+
// number | Number of items per page (optional)
|
|
1128
|
+
pageSize: 56,
|
|
1129
|
+
} satisfies GetVMsRequest;
|
|
1130
|
+
|
|
1131
|
+
try {
|
|
1132
|
+
const data = await api.getVMs(body);
|
|
1133
|
+
console.log(data);
|
|
1134
|
+
} catch (error) {
|
|
1135
|
+
console.error(error);
|
|
1136
|
+
}
|
|
1137
|
+
}
|
|
1138
|
+
|
|
1139
|
+
// Run the test
|
|
1140
|
+
example().catch(console.error);
|
|
1141
|
+
```
|
|
1142
|
+
|
|
1143
|
+
### Parameters
|
|
1144
|
+
|
|
1145
|
+
|
|
1146
|
+
| Name | Type | Description | Notes |
|
|
1147
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1148
|
+
| **byExpression** | `string` | Filter by expression (matches VMs with the provided expression) | [Optional] [Defaults to `undefined`] |
|
|
1149
|
+
| **sort** | `Array<string>` | Sort fields with direction (e.g., \"name:asc\" or \"cluster:desc,name:asc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues. | [Optional] |
|
|
1150
|
+
| **page** | `number` | Page number for pagination | [Optional] [Defaults to `1`] |
|
|
1151
|
+
| **pageSize** | `number` | Number of items per page | [Optional] [Defaults to `undefined`] |
|
|
1152
|
+
|
|
1153
|
+
### Return type
|
|
1154
|
+
|
|
1155
|
+
[**VirtualMachineListResponse**](VirtualMachineListResponse.md)
|
|
1156
|
+
|
|
1157
|
+
### Authorization
|
|
1158
|
+
|
|
1159
|
+
No authorization required
|
|
1160
|
+
|
|
1161
|
+
### HTTP request headers
|
|
1162
|
+
|
|
1163
|
+
- **Content-Type**: Not defined
|
|
1164
|
+
- **Accept**: `application/json`
|
|
1165
|
+
|
|
1166
|
+
|
|
1167
|
+
### HTTP response details
|
|
1168
|
+
| Status code | Description | Response headers |
|
|
1169
|
+
|-------------|-------------|------------------|
|
|
1170
|
+
| **200** | List of VMs | - |
|
|
1171
|
+
| **400** | Invalid request parameters | - |
|
|
1172
|
+
| **500** | Internal server error | - |
|
|
1173
|
+
|
|
1174
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1175
|
+
|
|
1176
|
+
|
|
1177
|
+
## getVersion
|
|
1178
|
+
|
|
1179
|
+
> VersionInfo getVersion()
|
|
1180
|
+
|
|
1181
|
+
Get agent version information
|
|
1182
|
+
|
|
1183
|
+
### Example
|
|
1184
|
+
|
|
1185
|
+
```ts
|
|
1186
|
+
import {
|
|
1187
|
+
Configuration,
|
|
1188
|
+
DefaultApi,
|
|
1189
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1190
|
+
import type { GetVersionRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1191
|
+
|
|
1192
|
+
async function example() {
|
|
1193
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1194
|
+
const api = new DefaultApi();
|
|
1195
|
+
|
|
1196
|
+
try {
|
|
1197
|
+
const data = await api.getVersion();
|
|
1198
|
+
console.log(data);
|
|
1199
|
+
} catch (error) {
|
|
1200
|
+
console.error(error);
|
|
1201
|
+
}
|
|
1202
|
+
}
|
|
1203
|
+
|
|
1204
|
+
// Run the test
|
|
1205
|
+
example().catch(console.error);
|
|
1206
|
+
```
|
|
1207
|
+
|
|
1208
|
+
### Parameters
|
|
1209
|
+
|
|
1210
|
+
This endpoint does not need any parameter.
|
|
1211
|
+
|
|
1212
|
+
### Return type
|
|
1213
|
+
|
|
1214
|
+
[**VersionInfo**](VersionInfo.md)
|
|
1215
|
+
|
|
1216
|
+
### Authorization
|
|
1217
|
+
|
|
1218
|
+
No authorization required
|
|
1219
|
+
|
|
1220
|
+
### HTTP request headers
|
|
1221
|
+
|
|
1222
|
+
- **Content-Type**: Not defined
|
|
1223
|
+
- **Accept**: `application/json`
|
|
1224
|
+
|
|
1225
|
+
|
|
1226
|
+
### HTTP response details
|
|
1227
|
+
| Status code | Description | Response headers |
|
|
1228
|
+
|-------------|-------------|------------------|
|
|
1229
|
+
| **200** | Version information | - |
|
|
1230
|
+
|
|
1231
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1232
|
+
|
|
1233
|
+
|
|
1234
|
+
## listGroups
|
|
1235
|
+
|
|
1236
|
+
> GroupListResponse listGroups(byName, page, pageSize)
|
|
1237
|
+
|
|
1238
|
+
List all groups
|
|
1239
|
+
|
|
1240
|
+
### Example
|
|
1241
|
+
|
|
1242
|
+
```ts
|
|
1243
|
+
import {
|
|
1244
|
+
Configuration,
|
|
1245
|
+
DefaultApi,
|
|
1246
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1247
|
+
import type { ListGroupsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1248
|
+
|
|
1249
|
+
async function example() {
|
|
1250
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1251
|
+
const api = new DefaultApi();
|
|
1252
|
+
|
|
1253
|
+
const body = {
|
|
1254
|
+
// string | Filter groups by name (case-insensitive substring match) (optional)
|
|
1255
|
+
byName: byName_example,
|
|
1256
|
+
// number | Page number (1-indexed) (optional)
|
|
1257
|
+
page: 56,
|
|
1258
|
+
// number | Number of groups per page (optional)
|
|
1259
|
+
pageSize: 56,
|
|
1260
|
+
} satisfies ListGroupsRequest;
|
|
1261
|
+
|
|
1262
|
+
try {
|
|
1263
|
+
const data = await api.listGroups(body);
|
|
1264
|
+
console.log(data);
|
|
1265
|
+
} catch (error) {
|
|
1266
|
+
console.error(error);
|
|
1267
|
+
}
|
|
1268
|
+
}
|
|
1269
|
+
|
|
1270
|
+
// Run the test
|
|
1271
|
+
example().catch(console.error);
|
|
1272
|
+
```
|
|
1273
|
+
|
|
1274
|
+
### Parameters
|
|
1275
|
+
|
|
1276
|
+
|
|
1277
|
+
| Name | Type | Description | Notes |
|
|
1278
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1279
|
+
| **byName** | `string` | Filter groups by name (case-insensitive substring match) | [Optional] [Defaults to `undefined`] |
|
|
1280
|
+
| **page** | `number` | Page number (1-indexed) | [Optional] [Defaults to `1`] |
|
|
1281
|
+
| **pageSize** | `number` | Number of groups per page | [Optional] [Defaults to `20`] |
|
|
1282
|
+
|
|
1283
|
+
### Return type
|
|
1284
|
+
|
|
1285
|
+
[**GroupListResponse**](GroupListResponse.md)
|
|
1286
|
+
|
|
1287
|
+
### Authorization
|
|
1288
|
+
|
|
1289
|
+
No authorization required
|
|
1290
|
+
|
|
1291
|
+
### HTTP request headers
|
|
1292
|
+
|
|
1293
|
+
- **Content-Type**: Not defined
|
|
1294
|
+
- **Accept**: `application/json`
|
|
1295
|
+
|
|
1296
|
+
|
|
1297
|
+
### HTTP response details
|
|
1298
|
+
| Status code | Description | Response headers |
|
|
1299
|
+
|-------------|-------------|------------------|
|
|
1300
|
+
| **200** | List of groups | - |
|
|
1301
|
+
| **400** | Invalid filter expression | - |
|
|
1302
|
+
| **500** | Internal server error | - |
|
|
1303
|
+
|
|
1304
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1305
|
+
|
|
1306
|
+
|
|
1307
|
+
## listRightsizingReports
|
|
1308
|
+
|
|
1309
|
+
> RightsizingReportListResponse listRightsizingReports()
|
|
1310
|
+
|
|
1311
|
+
List all rightsizing reports
|
|
1312
|
+
|
|
1313
|
+
### Example
|
|
1314
|
+
|
|
1315
|
+
```ts
|
|
1316
|
+
import {
|
|
1317
|
+
Configuration,
|
|
1318
|
+
DefaultApi,
|
|
1319
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1320
|
+
import type { ListRightsizingReportsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1321
|
+
|
|
1322
|
+
async function example() {
|
|
1323
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1324
|
+
const api = new DefaultApi();
|
|
1325
|
+
|
|
1326
|
+
try {
|
|
1327
|
+
const data = await api.listRightsizingReports();
|
|
1328
|
+
console.log(data);
|
|
1329
|
+
} catch (error) {
|
|
1330
|
+
console.error(error);
|
|
1331
|
+
}
|
|
1332
|
+
}
|
|
1333
|
+
|
|
1334
|
+
// Run the test
|
|
1335
|
+
example().catch(console.error);
|
|
1336
|
+
```
|
|
1337
|
+
|
|
1338
|
+
### Parameters
|
|
1339
|
+
|
|
1340
|
+
This endpoint does not need any parameter.
|
|
1341
|
+
|
|
1342
|
+
### Return type
|
|
1343
|
+
|
|
1344
|
+
[**RightsizingReportListResponse**](RightsizingReportListResponse.md)
|
|
1345
|
+
|
|
1346
|
+
### Authorization
|
|
1347
|
+
|
|
1348
|
+
No authorization required
|
|
1349
|
+
|
|
1350
|
+
### HTTP request headers
|
|
1351
|
+
|
|
1352
|
+
- **Content-Type**: Not defined
|
|
1353
|
+
- **Accept**: `application/json`
|
|
1354
|
+
|
|
1355
|
+
|
|
1356
|
+
### HTTP response details
|
|
1357
|
+
| Status code | Description | Response headers |
|
|
1358
|
+
|-------------|-------------|------------------|
|
|
1359
|
+
| **200** | List of rightsizing reports | - |
|
|
1360
|
+
| **500** | Internal server error | - |
|
|
1361
|
+
|
|
1362
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1363
|
+
|
|
1364
|
+
|
|
1365
|
+
## postForecasterPairCapabilities
|
|
1366
|
+
|
|
1367
|
+
> Array<PairCapability> postForecasterPairCapabilities(pairCapabilityRequest)
|
|
1368
|
+
|
|
1369
|
+
Compute pair capabilities
|
|
1370
|
+
|
|
1371
|
+
Computes which offload methods are feasible for specific source-target datastore pairs based on vendor support and storage array topology derived from the forklift-collected inventory. No vSphere credentials are required.
|
|
1372
|
+
|
|
1373
|
+
### Example
|
|
1374
|
+
|
|
1375
|
+
```ts
|
|
1376
|
+
import {
|
|
1377
|
+
Configuration,
|
|
1378
|
+
DefaultApi,
|
|
1379
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1380
|
+
import type { PostForecasterPairCapabilitiesRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1381
|
+
|
|
1382
|
+
async function example() {
|
|
1383
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1384
|
+
const api = new DefaultApi();
|
|
1385
|
+
|
|
1386
|
+
const body = {
|
|
1387
|
+
// PairCapabilityRequest
|
|
1388
|
+
pairCapabilityRequest: ...,
|
|
1389
|
+
} satisfies PostForecasterPairCapabilitiesRequest;
|
|
1390
|
+
|
|
1391
|
+
try {
|
|
1392
|
+
const data = await api.postForecasterPairCapabilities(body);
|
|
1393
|
+
console.log(data);
|
|
1394
|
+
} catch (error) {
|
|
1395
|
+
console.error(error);
|
|
1396
|
+
}
|
|
1397
|
+
}
|
|
1398
|
+
|
|
1399
|
+
// Run the test
|
|
1400
|
+
example().catch(console.error);
|
|
1401
|
+
```
|
|
1402
|
+
|
|
1403
|
+
### Parameters
|
|
1404
|
+
|
|
1405
|
+
|
|
1406
|
+
| Name | Type | Description | Notes |
|
|
1407
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1408
|
+
| **pairCapabilityRequest** | [PairCapabilityRequest](PairCapabilityRequest.md) | | |
|
|
1409
|
+
|
|
1410
|
+
### Return type
|
|
1411
|
+
|
|
1412
|
+
[**Array<PairCapability>**](PairCapability.md)
|
|
1413
|
+
|
|
1414
|
+
### Authorization
|
|
1415
|
+
|
|
1416
|
+
No authorization required
|
|
1417
|
+
|
|
1418
|
+
### HTTP request headers
|
|
1419
|
+
|
|
1420
|
+
- **Content-Type**: `application/json`
|
|
1421
|
+
- **Accept**: `application/json`
|
|
1422
|
+
|
|
1423
|
+
|
|
1424
|
+
### HTTP response details
|
|
1425
|
+
| Status code | Description | Response headers |
|
|
1426
|
+
|-------------|-------------|------------------|
|
|
1427
|
+
| **200** | Capabilities per pair | - |
|
|
1428
|
+
| **400** | Datastore not found | - |
|
|
1429
|
+
| **500** | Internal server error | - |
|
|
1430
|
+
|
|
1431
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1432
|
+
|
|
1433
|
+
|
|
1434
|
+
## putForecasterCredentials
|
|
1435
|
+
|
|
1436
|
+
> putForecasterCredentials(vcenterCredentials)
|
|
1437
|
+
|
|
1438
|
+
Verify vCenter credentials and permissions
|
|
1439
|
+
|
|
1440
|
+
Validates vCenter connectivity and verifies the user has the required vSphere privileges for forecaster operations (datastore file management, VM provisioning, disk cloning). Verification only — credentials are not saved.
|
|
1441
|
+
|
|
1442
|
+
### Example
|
|
1443
|
+
|
|
1444
|
+
```ts
|
|
1445
|
+
import {
|
|
1446
|
+
Configuration,
|
|
1447
|
+
DefaultApi,
|
|
1448
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1449
|
+
import type { PutForecasterCredentialsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1450
|
+
|
|
1451
|
+
async function example() {
|
|
1452
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1453
|
+
const api = new DefaultApi();
|
|
1454
|
+
|
|
1455
|
+
const body = {
|
|
1456
|
+
// VcenterCredentials
|
|
1457
|
+
vcenterCredentials: ...,
|
|
1458
|
+
} satisfies PutForecasterCredentialsRequest;
|
|
1459
|
+
|
|
1460
|
+
try {
|
|
1461
|
+
const data = await api.putForecasterCredentials(body);
|
|
1462
|
+
console.log(data);
|
|
1463
|
+
} catch (error) {
|
|
1464
|
+
console.error(error);
|
|
1465
|
+
}
|
|
1466
|
+
}
|
|
1467
|
+
|
|
1468
|
+
// Run the test
|
|
1469
|
+
example().catch(console.error);
|
|
1470
|
+
```
|
|
1471
|
+
|
|
1472
|
+
### Parameters
|
|
1473
|
+
|
|
1474
|
+
|
|
1475
|
+
| Name | Type | Description | Notes |
|
|
1476
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1477
|
+
| **vcenterCredentials** | [VcenterCredentials](VcenterCredentials.md) | | |
|
|
1478
|
+
|
|
1479
|
+
### Return type
|
|
1480
|
+
|
|
1481
|
+
`void` (Empty response body)
|
|
1482
|
+
|
|
1483
|
+
### Authorization
|
|
1484
|
+
|
|
1485
|
+
No authorization required
|
|
1486
|
+
|
|
1487
|
+
### HTTP request headers
|
|
1488
|
+
|
|
1489
|
+
- **Content-Type**: `application/json`
|
|
1490
|
+
- **Accept**: `application/json`
|
|
1491
|
+
|
|
1492
|
+
|
|
1493
|
+
### HTTP response details
|
|
1494
|
+
| Status code | Description | Response headers |
|
|
1495
|
+
|-------------|-------------|------------------|
|
|
1496
|
+
| **200** | Credentials valid and all required privileges are granted | - |
|
|
1497
|
+
| **400** | Invalid credentials or unreachable vCenter | - |
|
|
1498
|
+
| **403** | Authentication succeeded but user lacks required privileges | - |
|
|
1499
|
+
| **500** | Internal server error | - |
|
|
1500
|
+
|
|
1501
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1502
|
+
|
|
1503
|
+
|
|
1504
|
+
## putInspectorCredentials
|
|
1505
|
+
|
|
1506
|
+
> putInspectorCredentials(vcenterCredentials)
|
|
1507
|
+
|
|
1508
|
+
Set or replace inspector credentials
|
|
1509
|
+
|
|
1510
|
+
### Example
|
|
1511
|
+
|
|
1512
|
+
```ts
|
|
1513
|
+
import {
|
|
1514
|
+
Configuration,
|
|
1515
|
+
DefaultApi,
|
|
1516
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1517
|
+
import type { PutInspectorCredentialsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1518
|
+
|
|
1519
|
+
async function example() {
|
|
1520
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1521
|
+
const api = new DefaultApi();
|
|
1522
|
+
|
|
1523
|
+
const body = {
|
|
1524
|
+
// VcenterCredentials
|
|
1525
|
+
vcenterCredentials: ...,
|
|
1526
|
+
} satisfies PutInspectorCredentialsRequest;
|
|
1527
|
+
|
|
1528
|
+
try {
|
|
1529
|
+
const data = await api.putInspectorCredentials(body);
|
|
1530
|
+
console.log(data);
|
|
1531
|
+
} catch (error) {
|
|
1532
|
+
console.error(error);
|
|
1533
|
+
}
|
|
1534
|
+
}
|
|
1535
|
+
|
|
1536
|
+
// Run the test
|
|
1537
|
+
example().catch(console.error);
|
|
1538
|
+
```
|
|
1539
|
+
|
|
1540
|
+
### Parameters
|
|
1541
|
+
|
|
1542
|
+
|
|
1543
|
+
| Name | Type | Description | Notes |
|
|
1544
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1545
|
+
| **vcenterCredentials** | [VcenterCredentials](VcenterCredentials.md) | | |
|
|
1546
|
+
|
|
1547
|
+
### Return type
|
|
1548
|
+
|
|
1549
|
+
`void` (Empty response body)
|
|
1550
|
+
|
|
1551
|
+
### Authorization
|
|
1552
|
+
|
|
1553
|
+
No authorization required
|
|
1554
|
+
|
|
1555
|
+
### HTTP request headers
|
|
1556
|
+
|
|
1557
|
+
- **Content-Type**: `application/json`
|
|
1558
|
+
- **Accept**: Not defined
|
|
1559
|
+
|
|
1560
|
+
|
|
1561
|
+
### HTTP response details
|
|
1562
|
+
| Status code | Description | Response headers |
|
|
1563
|
+
|-------------|-------------|------------------|
|
|
1564
|
+
| **200** | Credentials updated successfully | - |
|
|
1565
|
+
| **400** | Bad Credentials | - |
|
|
1566
|
+
| **500** | Internal server error | - |
|
|
1567
|
+
|
|
1568
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1569
|
+
|
|
1570
|
+
|
|
1571
|
+
## putInspectorVddk
|
|
1572
|
+
|
|
1573
|
+
> VddkProperties putInspectorVddk(file)
|
|
1574
|
+
|
|
1575
|
+
Upload VDDK tarball
|
|
1576
|
+
|
|
1577
|
+
### Example
|
|
1578
|
+
|
|
1579
|
+
```ts
|
|
1580
|
+
import {
|
|
1581
|
+
Configuration,
|
|
1582
|
+
DefaultApi,
|
|
1583
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1584
|
+
import type { PutInspectorVddkRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1585
|
+
|
|
1586
|
+
async function example() {
|
|
1587
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1588
|
+
const api = new DefaultApi();
|
|
1589
|
+
|
|
1590
|
+
const body = {
|
|
1591
|
+
// Blob | VDDK tarball
|
|
1592
|
+
file: BINARY_DATA_HERE,
|
|
1593
|
+
} satisfies PutInspectorVddkRequest;
|
|
1594
|
+
|
|
1595
|
+
try {
|
|
1596
|
+
const data = await api.putInspectorVddk(body);
|
|
1597
|
+
console.log(data);
|
|
1598
|
+
} catch (error) {
|
|
1599
|
+
console.error(error);
|
|
1600
|
+
}
|
|
1601
|
+
}
|
|
1602
|
+
|
|
1603
|
+
// Run the test
|
|
1604
|
+
example().catch(console.error);
|
|
1605
|
+
```
|
|
1606
|
+
|
|
1607
|
+
### Parameters
|
|
1608
|
+
|
|
1609
|
+
|
|
1610
|
+
| Name | Type | Description | Notes |
|
|
1611
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1612
|
+
| **file** | `Blob` | VDDK tarball | [Defaults to `undefined`] |
|
|
1613
|
+
|
|
1614
|
+
### Return type
|
|
1615
|
+
|
|
1616
|
+
[**VddkProperties**](VddkProperties.md)
|
|
1617
|
+
|
|
1618
|
+
### Authorization
|
|
1619
|
+
|
|
1620
|
+
No authorization required
|
|
1621
|
+
|
|
1622
|
+
### HTTP request headers
|
|
1623
|
+
|
|
1624
|
+
- **Content-Type**: `multipart/form-data`
|
|
1625
|
+
- **Accept**: `application/json`
|
|
1626
|
+
|
|
1627
|
+
|
|
1628
|
+
### HTTP response details
|
|
1629
|
+
| Status code | Description | Response headers |
|
|
1630
|
+
|-------------|-------------|------------------|
|
|
1631
|
+
| **200** | Upload successful | - |
|
|
1632
|
+
| **409** | Conflict | - |
|
|
1633
|
+
| **413** | File exceeds 64MB limit | - |
|
|
1634
|
+
| **400** | Bad request | - |
|
|
1635
|
+
| **500** | Internal server error | - |
|
|
1636
|
+
|
|
1637
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1638
|
+
|
|
1639
|
+
|
|
1640
|
+
## removeVMFromInspection
|
|
1641
|
+
|
|
1642
|
+
> VmInspectionStatus removeVMFromInspection(id)
|
|
1643
|
+
|
|
1644
|
+
Remove VirtualMachine from inspection queue
|
|
1645
|
+
|
|
1646
|
+
### Example
|
|
1647
|
+
|
|
1648
|
+
```ts
|
|
1649
|
+
import {
|
|
1650
|
+
Configuration,
|
|
1651
|
+
DefaultApi,
|
|
1652
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1653
|
+
import type { RemoveVMFromInspectionRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1654
|
+
|
|
1655
|
+
async function example() {
|
|
1656
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1657
|
+
const api = new DefaultApi();
|
|
1658
|
+
|
|
1659
|
+
const body = {
|
|
1660
|
+
// string
|
|
1661
|
+
id: id_example,
|
|
1662
|
+
} satisfies RemoveVMFromInspectionRequest;
|
|
1663
|
+
|
|
1664
|
+
try {
|
|
1665
|
+
const data = await api.removeVMFromInspection(body);
|
|
1666
|
+
console.log(data);
|
|
1667
|
+
} catch (error) {
|
|
1668
|
+
console.error(error);
|
|
1669
|
+
}
|
|
1670
|
+
}
|
|
1671
|
+
|
|
1672
|
+
// Run the test
|
|
1673
|
+
example().catch(console.error);
|
|
1674
|
+
```
|
|
1675
|
+
|
|
1676
|
+
### Parameters
|
|
1677
|
+
|
|
1678
|
+
|
|
1679
|
+
| Name | Type | Description | Notes |
|
|
1680
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1681
|
+
| **id** | `string` | | [Defaults to `undefined`] |
|
|
1682
|
+
|
|
1683
|
+
### Return type
|
|
1684
|
+
|
|
1685
|
+
[**VmInspectionStatus**](VmInspectionStatus.md)
|
|
1686
|
+
|
|
1687
|
+
### Authorization
|
|
1688
|
+
|
|
1689
|
+
No authorization required
|
|
1690
|
+
|
|
1691
|
+
### HTTP request headers
|
|
1692
|
+
|
|
1693
|
+
- **Content-Type**: Not defined
|
|
1694
|
+
- **Accept**: `application/json`
|
|
1695
|
+
|
|
1696
|
+
|
|
1697
|
+
### HTTP response details
|
|
1698
|
+
| Status code | Description | Response headers |
|
|
1699
|
+
|-------------|-------------|------------------|
|
|
1700
|
+
| **200** | VMs removed from queue | - |
|
|
1701
|
+
| **400** | Inspector not running or VirtualMachine cannot be canceled | - |
|
|
1702
|
+
| **404** | VirtualMachine not found or not in the queue | - |
|
|
1703
|
+
| **500** | Internal server error | - |
|
|
1704
|
+
|
|
1705
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1706
|
+
|
|
1707
|
+
|
|
1708
|
+
## setAgentMode
|
|
1709
|
+
|
|
1710
|
+
> AgentStatus setAgentMode(agentModeRequest)
|
|
1711
|
+
|
|
1712
|
+
Change agent mode
|
|
1713
|
+
|
|
1714
|
+
### Example
|
|
1715
|
+
|
|
1716
|
+
```ts
|
|
1717
|
+
import {
|
|
1718
|
+
Configuration,
|
|
1719
|
+
DefaultApi,
|
|
1720
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1721
|
+
import type { SetAgentModeRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1722
|
+
|
|
1723
|
+
async function example() {
|
|
1724
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1725
|
+
const api = new DefaultApi();
|
|
1726
|
+
|
|
1727
|
+
const body = {
|
|
1728
|
+
// AgentModeRequest
|
|
1729
|
+
agentModeRequest: ...,
|
|
1730
|
+
} satisfies SetAgentModeRequest;
|
|
1731
|
+
|
|
1732
|
+
try {
|
|
1733
|
+
const data = await api.setAgentMode(body);
|
|
1734
|
+
console.log(data);
|
|
1735
|
+
} catch (error) {
|
|
1736
|
+
console.error(error);
|
|
1737
|
+
}
|
|
1738
|
+
}
|
|
1739
|
+
|
|
1740
|
+
// Run the test
|
|
1741
|
+
example().catch(console.error);
|
|
1742
|
+
```
|
|
1743
|
+
|
|
1744
|
+
### Parameters
|
|
1745
|
+
|
|
1746
|
+
|
|
1747
|
+
| Name | Type | Description | Notes |
|
|
1748
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1749
|
+
| **agentModeRequest** | [AgentModeRequest](AgentModeRequest.md) | | |
|
|
1750
|
+
|
|
1751
|
+
### Return type
|
|
1752
|
+
|
|
1753
|
+
[**AgentStatus**](AgentStatus.md)
|
|
1754
|
+
|
|
1755
|
+
### Authorization
|
|
1756
|
+
|
|
1757
|
+
No authorization required
|
|
1758
|
+
|
|
1759
|
+
### HTTP request headers
|
|
1760
|
+
|
|
1761
|
+
- **Content-Type**: `application/json`
|
|
1762
|
+
- **Accept**: `application/json`
|
|
1763
|
+
|
|
1764
|
+
|
|
1765
|
+
### HTTP response details
|
|
1766
|
+
| Status code | Description | Response headers |
|
|
1767
|
+
|-------------|-------------|------------------|
|
|
1768
|
+
| **200** | Mode changed | - |
|
|
1769
|
+
| **400** | Invalid request | - |
|
|
1770
|
+
| **409** | Conflict | - |
|
|
1771
|
+
| **500** | Internal server error | - |
|
|
1772
|
+
|
|
1773
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1774
|
+
|
|
1775
|
+
|
|
1776
|
+
## startCollector
|
|
1777
|
+
|
|
1778
|
+
> CollectorStatus startCollector(collectorStartRequest)
|
|
1779
|
+
|
|
1780
|
+
Start inventory collection
|
|
1781
|
+
|
|
1782
|
+
### Example
|
|
1783
|
+
|
|
1784
|
+
```ts
|
|
1785
|
+
import {
|
|
1786
|
+
Configuration,
|
|
1787
|
+
DefaultApi,
|
|
1788
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1789
|
+
import type { StartCollectorRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1790
|
+
|
|
1791
|
+
async function example() {
|
|
1792
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1793
|
+
const api = new DefaultApi();
|
|
1794
|
+
|
|
1795
|
+
const body = {
|
|
1796
|
+
// CollectorStartRequest
|
|
1797
|
+
collectorStartRequest: ...,
|
|
1798
|
+
} satisfies StartCollectorRequest;
|
|
1799
|
+
|
|
1800
|
+
try {
|
|
1801
|
+
const data = await api.startCollector(body);
|
|
1802
|
+
console.log(data);
|
|
1803
|
+
} catch (error) {
|
|
1804
|
+
console.error(error);
|
|
1117
1805
|
}
|
|
1118
1806
|
}
|
|
1119
1807
|
|
|
@@ -1153,9 +1841,79 @@ No authorization required
|
|
|
1153
1841
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1154
1842
|
|
|
1155
1843
|
|
|
1844
|
+
## startForecaster
|
|
1845
|
+
|
|
1846
|
+
> ForecasterStatus startForecaster(forecasterStartRequest)
|
|
1847
|
+
|
|
1848
|
+
Start benchmark
|
|
1849
|
+
|
|
1850
|
+
Starts async benchmarking for one or more datastore pairs. Credentials can be passed inline or omitted if previously provided in an earlier request.
|
|
1851
|
+
|
|
1852
|
+
### Example
|
|
1853
|
+
|
|
1854
|
+
```ts
|
|
1855
|
+
import {
|
|
1856
|
+
Configuration,
|
|
1857
|
+
DefaultApi,
|
|
1858
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1859
|
+
import type { StartForecasterRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1860
|
+
|
|
1861
|
+
async function example() {
|
|
1862
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1863
|
+
const api = new DefaultApi();
|
|
1864
|
+
|
|
1865
|
+
const body = {
|
|
1866
|
+
// ForecasterStartRequest
|
|
1867
|
+
forecasterStartRequest: ...,
|
|
1868
|
+
} satisfies StartForecasterRequest;
|
|
1869
|
+
|
|
1870
|
+
try {
|
|
1871
|
+
const data = await api.startForecaster(body);
|
|
1872
|
+
console.log(data);
|
|
1873
|
+
} catch (error) {
|
|
1874
|
+
console.error(error);
|
|
1875
|
+
}
|
|
1876
|
+
}
|
|
1877
|
+
|
|
1878
|
+
// Run the test
|
|
1879
|
+
example().catch(console.error);
|
|
1880
|
+
```
|
|
1881
|
+
|
|
1882
|
+
### Parameters
|
|
1883
|
+
|
|
1884
|
+
|
|
1885
|
+
| Name | Type | Description | Notes |
|
|
1886
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1887
|
+
| **forecasterStartRequest** | [ForecasterStartRequest](ForecasterStartRequest.md) | | |
|
|
1888
|
+
|
|
1889
|
+
### Return type
|
|
1890
|
+
|
|
1891
|
+
[**ForecasterStatus**](ForecasterStatus.md)
|
|
1892
|
+
|
|
1893
|
+
### Authorization
|
|
1894
|
+
|
|
1895
|
+
No authorization required
|
|
1896
|
+
|
|
1897
|
+
### HTTP request headers
|
|
1898
|
+
|
|
1899
|
+
- **Content-Type**: `application/json`
|
|
1900
|
+
- **Accept**: `application/json`
|
|
1901
|
+
|
|
1902
|
+
|
|
1903
|
+
### HTTP response details
|
|
1904
|
+
| Status code | Description | Response headers |
|
|
1905
|
+
|-------------|-------------|------------------|
|
|
1906
|
+
| **202** | Benchmark started | - |
|
|
1907
|
+
| **400** | Invalid credentials, validation error, or pair limit exceeded | - |
|
|
1908
|
+
| **409** | Another benchmark is already running | - |
|
|
1909
|
+
| **500** | Internal server error | - |
|
|
1910
|
+
|
|
1911
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1912
|
+
|
|
1913
|
+
|
|
1156
1914
|
## startInspection
|
|
1157
1915
|
|
|
1158
|
-
> InspectorStatus startInspection(
|
|
1916
|
+
> InspectorStatus startInspection(startInspectionRequest)
|
|
1159
1917
|
|
|
1160
1918
|
Start inspection for VMs
|
|
1161
1919
|
|
|
@@ -1166,16 +1924,16 @@ import {
|
|
|
1166
1924
|
Configuration,
|
|
1167
1925
|
DefaultApi,
|
|
1168
1926
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1169
|
-
import type {
|
|
1927
|
+
import type { StartInspectionOperationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1170
1928
|
|
|
1171
1929
|
async function example() {
|
|
1172
1930
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1173
1931
|
const api = new DefaultApi();
|
|
1174
1932
|
|
|
1175
1933
|
const body = {
|
|
1176
|
-
//
|
|
1177
|
-
|
|
1178
|
-
} satisfies
|
|
1934
|
+
// StartInspectionRequest
|
|
1935
|
+
startInspectionRequest: ...,
|
|
1936
|
+
} satisfies StartInspectionOperationRequest;
|
|
1179
1937
|
|
|
1180
1938
|
try {
|
|
1181
1939
|
const data = await api.startInspection(body);
|
|
@@ -1194,7 +1952,7 @@ example().catch(console.error);
|
|
|
1194
1952
|
|
|
1195
1953
|
| Name | Type | Description | Notes |
|
|
1196
1954
|
|------------- | ------------- | ------------- | -------------|
|
|
1197
|
-
| **
|
|
1955
|
+
| **startInspectionRequest** | [StartInspectionRequest](StartInspectionRequest.md) | | |
|
|
1198
1956
|
|
|
1199
1957
|
### Return type
|
|
1200
1958
|
|
|
@@ -1279,6 +2037,136 @@ No authorization required
|
|
|
1279
2037
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1280
2038
|
|
|
1281
2039
|
|
|
2040
|
+
## stopForecaster
|
|
2041
|
+
|
|
2042
|
+
> ForecasterStatus stopForecaster()
|
|
2043
|
+
|
|
2044
|
+
Cancel benchmark
|
|
2045
|
+
|
|
2046
|
+
Stops the running benchmark. Already-completed runs are preserved in the database.
|
|
2047
|
+
|
|
2048
|
+
### Example
|
|
2049
|
+
|
|
2050
|
+
```ts
|
|
2051
|
+
import {
|
|
2052
|
+
Configuration,
|
|
2053
|
+
DefaultApi,
|
|
2054
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
2055
|
+
import type { StopForecasterRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
2056
|
+
|
|
2057
|
+
async function example() {
|
|
2058
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
2059
|
+
const api = new DefaultApi();
|
|
2060
|
+
|
|
2061
|
+
try {
|
|
2062
|
+
const data = await api.stopForecaster();
|
|
2063
|
+
console.log(data);
|
|
2064
|
+
} catch (error) {
|
|
2065
|
+
console.error(error);
|
|
2066
|
+
}
|
|
2067
|
+
}
|
|
2068
|
+
|
|
2069
|
+
// Run the test
|
|
2070
|
+
example().catch(console.error);
|
|
2071
|
+
```
|
|
2072
|
+
|
|
2073
|
+
### Parameters
|
|
2074
|
+
|
|
2075
|
+
This endpoint does not need any parameter.
|
|
2076
|
+
|
|
2077
|
+
### Return type
|
|
2078
|
+
|
|
2079
|
+
[**ForecasterStatus**](ForecasterStatus.md)
|
|
2080
|
+
|
|
2081
|
+
### Authorization
|
|
2082
|
+
|
|
2083
|
+
No authorization required
|
|
2084
|
+
|
|
2085
|
+
### HTTP request headers
|
|
2086
|
+
|
|
2087
|
+
- **Content-Type**: Not defined
|
|
2088
|
+
- **Accept**: `application/json`
|
|
2089
|
+
|
|
2090
|
+
|
|
2091
|
+
### HTTP response details
|
|
2092
|
+
| Status code | Description | Response headers |
|
|
2093
|
+
|-------------|-------------|------------------|
|
|
2094
|
+
| **202** | Benchmark canceled, service returned to ready | - |
|
|
2095
|
+
| **404** | No benchmark is running | - |
|
|
2096
|
+
| **500** | Internal server error | - |
|
|
2097
|
+
|
|
2098
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
2099
|
+
|
|
2100
|
+
|
|
2101
|
+
## stopForecasterPair
|
|
2102
|
+
|
|
2103
|
+
> StopForecasterPair202Response stopForecasterPair(name)
|
|
2104
|
+
|
|
2105
|
+
Cancel a single pair
|
|
2106
|
+
|
|
2107
|
+
Cancels the benchmark for a specific pair by name. The forecaster continues running if other pairs are still active.
|
|
2108
|
+
|
|
2109
|
+
### Example
|
|
2110
|
+
|
|
2111
|
+
```ts
|
|
2112
|
+
import {
|
|
2113
|
+
Configuration,
|
|
2114
|
+
DefaultApi,
|
|
2115
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
2116
|
+
import type { StopForecasterPairRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
2117
|
+
|
|
2118
|
+
async function example() {
|
|
2119
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
2120
|
+
const api = new DefaultApi();
|
|
2121
|
+
|
|
2122
|
+
const body = {
|
|
2123
|
+
// string | Pair name as specified in the start request
|
|
2124
|
+
name: name_example,
|
|
2125
|
+
} satisfies StopForecasterPairRequest;
|
|
2126
|
+
|
|
2127
|
+
try {
|
|
2128
|
+
const data = await api.stopForecasterPair(body);
|
|
2129
|
+
console.log(data);
|
|
2130
|
+
} catch (error) {
|
|
2131
|
+
console.error(error);
|
|
2132
|
+
}
|
|
2133
|
+
}
|
|
2134
|
+
|
|
2135
|
+
// Run the test
|
|
2136
|
+
example().catch(console.error);
|
|
2137
|
+
```
|
|
2138
|
+
|
|
2139
|
+
### Parameters
|
|
2140
|
+
|
|
2141
|
+
|
|
2142
|
+
| Name | Type | Description | Notes |
|
|
2143
|
+
|------------- | ------------- | ------------- | -------------|
|
|
2144
|
+
| **name** | `string` | Pair name as specified in the start request | [Defaults to `undefined`] |
|
|
2145
|
+
|
|
2146
|
+
### Return type
|
|
2147
|
+
|
|
2148
|
+
[**StopForecasterPair202Response**](StopForecasterPair202Response.md)
|
|
2149
|
+
|
|
2150
|
+
### Authorization
|
|
2151
|
+
|
|
2152
|
+
No authorization required
|
|
2153
|
+
|
|
2154
|
+
### HTTP request headers
|
|
2155
|
+
|
|
2156
|
+
- **Content-Type**: Not defined
|
|
2157
|
+
- **Accept**: `application/json`
|
|
2158
|
+
|
|
2159
|
+
|
|
2160
|
+
### HTTP response details
|
|
2161
|
+
| Status code | Description | Response headers |
|
|
2162
|
+
|-------------|-------------|------------------|
|
|
2163
|
+
| **202** | Pair canceled | - |
|
|
2164
|
+
| **404** | No benchmark running, or pair not found / already finished | - |
|
|
2165
|
+
| **500** | Internal server error | - |
|
|
2166
|
+
|
|
2167
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
2168
|
+
|
|
2169
|
+
|
|
1282
2170
|
## stopInspection
|
|
1283
2171
|
|
|
1284
2172
|
> InspectorStatus stopInspection()
|
|
@@ -1339,11 +2227,11 @@ No authorization required
|
|
|
1339
2227
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1340
2228
|
|
|
1341
2229
|
|
|
1342
|
-
##
|
|
2230
|
+
## triggerRightsizingCollection
|
|
1343
2231
|
|
|
1344
|
-
>
|
|
2232
|
+
> RightsizingReportSummary triggerRightsizingCollection(rightsizingCollectRequest)
|
|
1345
2233
|
|
|
1346
|
-
|
|
2234
|
+
Trigger rightsizing metrics collection
|
|
1347
2235
|
|
|
1348
2236
|
### Example
|
|
1349
2237
|
|
|
@@ -1352,21 +2240,19 @@ import {
|
|
|
1352
2240
|
Configuration,
|
|
1353
2241
|
DefaultApi,
|
|
1354
2242
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1355
|
-
import type {
|
|
2243
|
+
import type { TriggerRightsizingCollectionRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1356
2244
|
|
|
1357
2245
|
async function example() {
|
|
1358
2246
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1359
2247
|
const api = new DefaultApi();
|
|
1360
2248
|
|
|
1361
2249
|
const body = {
|
|
1362
|
-
//
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
updateGroupRequest: ...,
|
|
1366
|
-
} satisfies UpdateGroupOperationRequest;
|
|
2250
|
+
// RightsizingCollectRequest
|
|
2251
|
+
rightsizingCollectRequest: ...,
|
|
2252
|
+
} satisfies TriggerRightsizingCollectionRequest;
|
|
1367
2253
|
|
|
1368
2254
|
try {
|
|
1369
|
-
const data = await api.
|
|
2255
|
+
const data = await api.triggerRightsizingCollection(body);
|
|
1370
2256
|
console.log(data);
|
|
1371
2257
|
} catch (error) {
|
|
1372
2258
|
console.error(error);
|
|
@@ -1382,12 +2268,11 @@ example().catch(console.error);
|
|
|
1382
2268
|
|
|
1383
2269
|
| Name | Type | Description | Notes |
|
|
1384
2270
|
|------------- | ------------- | ------------- | -------------|
|
|
1385
|
-
| **
|
|
1386
|
-
| **updateGroupRequest** | [UpdateGroupRequest](UpdateGroupRequest.md) | | |
|
|
2271
|
+
| **rightsizingCollectRequest** | [RightsizingCollectRequest](RightsizingCollectRequest.md) | | |
|
|
1387
2272
|
|
|
1388
2273
|
### Return type
|
|
1389
2274
|
|
|
1390
|
-
[**
|
|
2275
|
+
[**RightsizingReportSummary**](RightsizingReportSummary.md)
|
|
1391
2276
|
|
|
1392
2277
|
### Authorization
|
|
1393
2278
|
|
|
@@ -1402,19 +2287,18 @@ No authorization required
|
|
|
1402
2287
|
### HTTP response details
|
|
1403
2288
|
| Status code | Description | Response headers |
|
|
1404
2289
|
|-------------|-------------|------------------|
|
|
1405
|
-
| **
|
|
1406
|
-
| **400** | Invalid request
|
|
1407
|
-
| **404** | Group not found | - |
|
|
2290
|
+
| **202** | Collection triggered; returns report | - |
|
|
2291
|
+
| **400** | Invalid request | - |
|
|
1408
2292
|
| **500** | Internal server error | - |
|
|
1409
2293
|
|
|
1410
2294
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1411
2295
|
|
|
1412
2296
|
|
|
1413
|
-
##
|
|
2297
|
+
## updateGroup
|
|
1414
2298
|
|
|
1415
|
-
>
|
|
2299
|
+
> Group updateGroup(id, updateGroupRequest)
|
|
1416
2300
|
|
|
1417
|
-
|
|
2301
|
+
Update group
|
|
1418
2302
|
|
|
1419
2303
|
### Example
|
|
1420
2304
|
|
|
@@ -1423,19 +2307,21 @@ import {
|
|
|
1423
2307
|
Configuration,
|
|
1424
2308
|
DefaultApi,
|
|
1425
2309
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1426
|
-
import type {
|
|
2310
|
+
import type { UpdateGroupOperationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1427
2311
|
|
|
1428
2312
|
async function example() {
|
|
1429
2313
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1430
2314
|
const api = new DefaultApi();
|
|
1431
2315
|
|
|
1432
2316
|
const body = {
|
|
1433
|
-
//
|
|
1434
|
-
|
|
1435
|
-
|
|
2317
|
+
// string | Group ID
|
|
2318
|
+
id: id_example,
|
|
2319
|
+
// UpdateGroupRequest
|
|
2320
|
+
updateGroupRequest: ...,
|
|
2321
|
+
} satisfies UpdateGroupOperationRequest;
|
|
1436
2322
|
|
|
1437
2323
|
try {
|
|
1438
|
-
const data = await api.
|
|
2324
|
+
const data = await api.updateGroup(body);
|
|
1439
2325
|
console.log(data);
|
|
1440
2326
|
} catch (error) {
|
|
1441
2327
|
console.error(error);
|
|
@@ -1451,11 +2337,12 @@ example().catch(console.error);
|
|
|
1451
2337
|
|
|
1452
2338
|
| Name | Type | Description | Notes |
|
|
1453
2339
|
|------------- | ------------- | ------------- | -------------|
|
|
1454
|
-
| **
|
|
2340
|
+
| **id** | `string` | Group ID | [Defaults to `undefined`] |
|
|
2341
|
+
| **updateGroupRequest** | [UpdateGroupRequest](UpdateGroupRequest.md) | | |
|
|
1455
2342
|
|
|
1456
2343
|
### Return type
|
|
1457
2344
|
|
|
1458
|
-
[**
|
|
2345
|
+
[**Group**](Group.md)
|
|
1459
2346
|
|
|
1460
2347
|
### Authorization
|
|
1461
2348
|
|
|
@@ -1463,17 +2350,16 @@ No authorization required
|
|
|
1463
2350
|
|
|
1464
2351
|
### HTTP request headers
|
|
1465
2352
|
|
|
1466
|
-
- **Content-Type**: `
|
|
2353
|
+
- **Content-Type**: `application/json`
|
|
1467
2354
|
- **Accept**: `application/json`
|
|
1468
2355
|
|
|
1469
2356
|
|
|
1470
2357
|
### HTTP response details
|
|
1471
2358
|
| Status code | Description | Response headers |
|
|
1472
2359
|
|-------------|-------------|------------------|
|
|
1473
|
-
| **200** |
|
|
1474
|
-
| **
|
|
1475
|
-
| **
|
|
1476
|
-
| **400** | Bad request | - |
|
|
2360
|
+
| **200** | Group updated | - |
|
|
2361
|
+
| **400** | Invalid request (e.g., invalid filter syntax) | - |
|
|
2362
|
+
| **404** | Group not found | - |
|
|
1477
2363
|
| **500** | Internal server error | - |
|
|
1478
2364
|
|
|
1479
2365
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|