@openshift-migration-advisor/agent-sdk 0.8.0 → 0.12.0-d4bdc4301890
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 +20 -2
- package/.openapi-generator/VERSION +1 -1
- package/README.md +29 -17
- package/dist/apis/DefaultApi.d.ts +260 -130
- package/dist/apis/DefaultApi.js +313 -172
- package/dist/esm/apis/DefaultApi.d.ts +260 -130
- package/dist/esm/apis/DefaultApi.js +295 -154
- package/dist/esm/models/InspectorStatus.d.ts +20 -7
- package/dist/esm/models/InspectorStatus.js +12 -7
- 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/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 +10 -1
- package/dist/esm/models/index.js +10 -1
- package/dist/esm/runtime.js +1 -1
- package/dist/models/InspectorStatus.d.ts +20 -7
- package/dist/models/InspectorStatus.js +12 -7
- 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/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 +10 -1
- package/dist/models/index.js +10 -1
- package/dist/runtime.js +1 -1
- package/docs/DefaultApi.md +368 -163
- package/docs/InspectorStatus.md +4 -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/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 +564 -285
- package/src/models/InspectorStatus.ts +37 -7
- 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/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 +10 -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,99 +4,34 @@ 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 |
|
|
9
8
|
| [**deleteGroup**](DefaultApi.md#deletegroup) | **DELETE** /groups/{id} | Delete group |
|
|
10
9
|
| [**getAgentStatus**](DefaultApi.md#getagentstatus) | **GET** /agent | Get agent status |
|
|
11
10
|
| [**getCollectorStatus**](DefaultApi.md#getcollectorstatus) | **GET** /collector | Get collector status |
|
|
12
11
|
| [**getGroup**](DefaultApi.md#getgroup) | **GET** /groups/{id} | Get group by ID with its VMs |
|
|
13
|
-
| [**getInspectorStatus**](DefaultApi.md#getinspectorstatus) | **GET** /
|
|
12
|
+
| [**getInspectorStatus**](DefaultApi.md#getinspectorstatus) | **GET** /inspector | Get inspector status |
|
|
13
|
+
| [**getInspectorVddkStatus**](DefaultApi.md#getinspectorvddkstatus) | **GET** /inspector/vddk | Get VDDK status |
|
|
14
14
|
| [**getInventory**](DefaultApi.md#getinventory) | **GET** /inventory | Get collected inventory |
|
|
15
|
+
| [**getRightsizingReport**](DefaultApi.md#getrightsizingreport) | **GET** /rightsizing/{id} | Get a specific rightsizing report with full VM metrics |
|
|
15
16
|
| [**getVM**](DefaultApi.md#getvm) | **GET** /vms/{id} | Get details about a vm |
|
|
16
|
-
| [**
|
|
17
|
+
| [**getVMUtilization**](DefaultApi.md#getvmutilization) | **GET** /vms/{id}/utilization | Get utilization breakdown for a specific VM |
|
|
17
18
|
| [**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
19
|
| [**getVersion**](DefaultApi.md#getversion) | **GET** /version | Get agent version information |
|
|
20
20
|
| [**listGroups**](DefaultApi.md#listgroups) | **GET** /groups | List all groups |
|
|
21
|
-
| [**
|
|
21
|
+
| [**listRightsizingReports**](DefaultApi.md#listrightsizingreports) | **GET** /rightsizing | List all rightsizing reports |
|
|
22
|
+
| [**putInspectorCredentials**](DefaultApi.md#putinspectorcredentials) | **PUT** /inspector/credentials | Set or replace inspector credentials |
|
|
23
|
+
| [**putInspectorVddk**](DefaultApi.md#putinspectorvddk) | **PUT** /inspector/vddk | Upload VDDK tarball |
|
|
24
|
+
| [**removeVMFromInspection**](DefaultApi.md#removevmfrominspection) | **DELETE** /vms/{id}/inspection | Remove VirtualMachine from inspection queue |
|
|
22
25
|
| [**setAgentMode**](DefaultApi.md#setagentmode) | **POST** /agent | Change agent mode |
|
|
23
26
|
| [**startCollector**](DefaultApi.md#startcollector) | **POST** /collector | Start inventory collection |
|
|
24
|
-
| [**startInspection**](DefaultApi.md#
|
|
27
|
+
| [**startInspection**](DefaultApi.md#startinspectionoperation) | **POST** /inspector | Start inspection for VMs |
|
|
25
28
|
| [**stopCollector**](DefaultApi.md#stopcollector) | **DELETE** /collector | Stop collection |
|
|
26
|
-
| [**stopInspection**](DefaultApi.md#stopinspection) | **DELETE** /
|
|
29
|
+
| [**stopInspection**](DefaultApi.md#stopinspection) | **DELETE** /inspector | Stop inspector entirely |
|
|
30
|
+
| [**triggerRightsizingCollection**](DefaultApi.md#triggerrightsizingcollection) | **POST** /rightsizing | Trigger rightsizing metrics collection |
|
|
27
31
|
| [**updateGroup**](DefaultApi.md#updategroupoperation) | **PATCH** /groups/{id} | Update group |
|
|
28
|
-
| [**vddkPost**](DefaultApi.md#vddkpost) | **POST** /vddk | Upload VDDK tarball |
|
|
29
32
|
|
|
30
33
|
|
|
31
34
|
|
|
32
|
-
## addVMsToInspection
|
|
33
|
-
|
|
34
|
-
> InspectorStatus addVMsToInspection(requestBody)
|
|
35
|
-
|
|
36
|
-
Add more VMs to inspection queue
|
|
37
|
-
|
|
38
|
-
### Example
|
|
39
|
-
|
|
40
|
-
```ts
|
|
41
|
-
import {
|
|
42
|
-
Configuration,
|
|
43
|
-
DefaultApi,
|
|
44
|
-
} from '@openshift-migration-advisor/agent-sdk';
|
|
45
|
-
import type { AddVMsToInspectionRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
46
|
-
|
|
47
|
-
async function example() {
|
|
48
|
-
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
49
|
-
const api = new DefaultApi();
|
|
50
|
-
|
|
51
|
-
const body = {
|
|
52
|
-
// Array<string>
|
|
53
|
-
requestBody: ["vm-1236","vm-1237"],
|
|
54
|
-
} satisfies AddVMsToInspectionRequest;
|
|
55
|
-
|
|
56
|
-
try {
|
|
57
|
-
const data = await api.addVMsToInspection(body);
|
|
58
|
-
console.log(data);
|
|
59
|
-
} catch (error) {
|
|
60
|
-
console.error(error);
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
// Run the test
|
|
65
|
-
example().catch(console.error);
|
|
66
|
-
```
|
|
67
|
-
|
|
68
|
-
### Parameters
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
| Name | Type | Description | Notes |
|
|
72
|
-
|------------- | ------------- | ------------- | -------------|
|
|
73
|
-
| **requestBody** | `Array<string>` | | |
|
|
74
|
-
|
|
75
|
-
### Return type
|
|
76
|
-
|
|
77
|
-
[**InspectorStatus**](InspectorStatus.md)
|
|
78
|
-
|
|
79
|
-
### Authorization
|
|
80
|
-
|
|
81
|
-
No authorization required
|
|
82
|
-
|
|
83
|
-
### HTTP request headers
|
|
84
|
-
|
|
85
|
-
- **Content-Type**: `application/json`
|
|
86
|
-
- **Accept**: `application/json`
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
### HTTP response details
|
|
90
|
-
| Status code | Description | Response headers |
|
|
91
|
-
|-------------|-------------|------------------|
|
|
92
|
-
| **202** | VMs added to inspection queue | - |
|
|
93
|
-
| **400** | Invalid request | - |
|
|
94
|
-
| **404** | Inspector not running | - |
|
|
95
|
-
| **500** | Internal server error | - |
|
|
96
|
-
|
|
97
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
98
|
-
|
|
99
|
-
|
|
100
35
|
## createGroup
|
|
101
36
|
|
|
102
37
|
> Group createGroup(createGroupRequest)
|
|
@@ -424,7 +359,7 @@ No authorization required
|
|
|
424
359
|
|
|
425
360
|
## getInspectorStatus
|
|
426
361
|
|
|
427
|
-
> InspectorStatus getInspectorStatus()
|
|
362
|
+
> InspectorStatus getInspectorStatus(includeVddk, includeCredentials)
|
|
428
363
|
|
|
429
364
|
Get inspector status
|
|
430
365
|
|
|
@@ -441,8 +376,15 @@ async function example() {
|
|
|
441
376
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
442
377
|
const api = new DefaultApi();
|
|
443
378
|
|
|
379
|
+
const body = {
|
|
380
|
+
// boolean | If true, include uploaded VDDK metadata (`version`, `md5`) when present. omitted if VDDK was never uploaded. (optional)
|
|
381
|
+
includeVddk: true,
|
|
382
|
+
// boolean | If true, include configured vCenter URL and username (password is never returned). omitted if was never set. (optional)
|
|
383
|
+
includeCredentials: true,
|
|
384
|
+
} satisfies GetInspectorStatusRequest;
|
|
385
|
+
|
|
444
386
|
try {
|
|
445
|
-
const data = await api.getInspectorStatus();
|
|
387
|
+
const data = await api.getInspectorStatus(body);
|
|
446
388
|
console.log(data);
|
|
447
389
|
} catch (error) {
|
|
448
390
|
console.error(error);
|
|
@@ -455,7 +397,11 @@ example().catch(console.error);
|
|
|
455
397
|
|
|
456
398
|
### Parameters
|
|
457
399
|
|
|
458
|
-
|
|
400
|
+
|
|
401
|
+
| Name | Type | Description | Notes |
|
|
402
|
+
|------------- | ------------- | ------------- | -------------|
|
|
403
|
+
| **includeVddk** | `boolean` | If true, include uploaded VDDK metadata (`version`, `md5`) when present. omitted if VDDK was never uploaded. | [Optional] [Defaults to `false`] |
|
|
404
|
+
| **includeCredentials** | `boolean` | If true, include configured vCenter URL and username (password is never returned). omitted if was never set. | [Optional] [Defaults to `false`] |
|
|
459
405
|
|
|
460
406
|
### Return type
|
|
461
407
|
|
|
@@ -480,6 +426,65 @@ No authorization required
|
|
|
480
426
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
481
427
|
|
|
482
428
|
|
|
429
|
+
## getInspectorVddkStatus
|
|
430
|
+
|
|
431
|
+
> VddkProperties getInspectorVddkStatus()
|
|
432
|
+
|
|
433
|
+
Get VDDK status
|
|
434
|
+
|
|
435
|
+
### Example
|
|
436
|
+
|
|
437
|
+
```ts
|
|
438
|
+
import {
|
|
439
|
+
Configuration,
|
|
440
|
+
DefaultApi,
|
|
441
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
442
|
+
import type { GetInspectorVddkStatusRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
443
|
+
|
|
444
|
+
async function example() {
|
|
445
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
446
|
+
const api = new DefaultApi();
|
|
447
|
+
|
|
448
|
+
try {
|
|
449
|
+
const data = await api.getInspectorVddkStatus();
|
|
450
|
+
console.log(data);
|
|
451
|
+
} catch (error) {
|
|
452
|
+
console.error(error);
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
// Run the test
|
|
457
|
+
example().catch(console.error);
|
|
458
|
+
```
|
|
459
|
+
|
|
460
|
+
### Parameters
|
|
461
|
+
|
|
462
|
+
This endpoint does not need any parameter.
|
|
463
|
+
|
|
464
|
+
### Return type
|
|
465
|
+
|
|
466
|
+
[**VddkProperties**](VddkProperties.md)
|
|
467
|
+
|
|
468
|
+
### Authorization
|
|
469
|
+
|
|
470
|
+
No authorization required
|
|
471
|
+
|
|
472
|
+
### HTTP request headers
|
|
473
|
+
|
|
474
|
+
- **Content-Type**: Not defined
|
|
475
|
+
- **Accept**: `application/json`
|
|
476
|
+
|
|
477
|
+
|
|
478
|
+
### HTTP response details
|
|
479
|
+
| Status code | Description | Response headers |
|
|
480
|
+
|-------------|-------------|------------------|
|
|
481
|
+
| **200** | Returns the current properties of the uploaded VMware VDDK tar. If the VDDK package has not been uploaded, a 404 response is returned. | - |
|
|
482
|
+
| **404** | Vddk not found | - |
|
|
483
|
+
| **500** | Internal server error | - |
|
|
484
|
+
|
|
485
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
486
|
+
|
|
487
|
+
|
|
483
488
|
## getInventory
|
|
484
489
|
|
|
485
490
|
> GetInventory200Response getInventory(withAgentId, groupId)
|
|
@@ -550,6 +555,73 @@ No authorization required
|
|
|
550
555
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
551
556
|
|
|
552
557
|
|
|
558
|
+
## getRightsizingReport
|
|
559
|
+
|
|
560
|
+
> RightsizingReport getRightsizingReport(id)
|
|
561
|
+
|
|
562
|
+
Get a specific rightsizing report with full VM metrics
|
|
563
|
+
|
|
564
|
+
### Example
|
|
565
|
+
|
|
566
|
+
```ts
|
|
567
|
+
import {
|
|
568
|
+
Configuration,
|
|
569
|
+
DefaultApi,
|
|
570
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
571
|
+
import type { GetRightsizingReportRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
572
|
+
|
|
573
|
+
async function example() {
|
|
574
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
575
|
+
const api = new DefaultApi();
|
|
576
|
+
|
|
577
|
+
const body = {
|
|
578
|
+
// string | Report UUID
|
|
579
|
+
id: id_example,
|
|
580
|
+
} satisfies GetRightsizingReportRequest;
|
|
581
|
+
|
|
582
|
+
try {
|
|
583
|
+
const data = await api.getRightsizingReport(body);
|
|
584
|
+
console.log(data);
|
|
585
|
+
} catch (error) {
|
|
586
|
+
console.error(error);
|
|
587
|
+
}
|
|
588
|
+
}
|
|
589
|
+
|
|
590
|
+
// Run the test
|
|
591
|
+
example().catch(console.error);
|
|
592
|
+
```
|
|
593
|
+
|
|
594
|
+
### Parameters
|
|
595
|
+
|
|
596
|
+
|
|
597
|
+
| Name | Type | Description | Notes |
|
|
598
|
+
|------------- | ------------- | ------------- | -------------|
|
|
599
|
+
| **id** | `string` | Report UUID | [Defaults to `undefined`] |
|
|
600
|
+
|
|
601
|
+
### Return type
|
|
602
|
+
|
|
603
|
+
[**RightsizingReport**](RightsizingReport.md)
|
|
604
|
+
|
|
605
|
+
### Authorization
|
|
606
|
+
|
|
607
|
+
No authorization required
|
|
608
|
+
|
|
609
|
+
### HTTP request headers
|
|
610
|
+
|
|
611
|
+
- **Content-Type**: Not defined
|
|
612
|
+
- **Accept**: `application/json`
|
|
613
|
+
|
|
614
|
+
|
|
615
|
+
### HTTP response details
|
|
616
|
+
| Status code | Description | Response headers |
|
|
617
|
+
|-------------|-------------|------------------|
|
|
618
|
+
| **200** | Rightsizing report | - |
|
|
619
|
+
| **404** | Report not found | - |
|
|
620
|
+
| **500** | Internal server error | - |
|
|
621
|
+
|
|
622
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
623
|
+
|
|
624
|
+
|
|
553
625
|
## getVM
|
|
554
626
|
|
|
555
627
|
> VirtualMachineDetail getVM(id)
|
|
@@ -617,11 +689,11 @@ No authorization required
|
|
|
617
689
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
618
690
|
|
|
619
691
|
|
|
620
|
-
##
|
|
692
|
+
## getVMUtilization
|
|
621
693
|
|
|
622
|
-
>
|
|
694
|
+
> VmUtilizationDetails getVMUtilization(id)
|
|
623
695
|
|
|
624
|
-
Get
|
|
696
|
+
Get utilization breakdown for a specific VM
|
|
625
697
|
|
|
626
698
|
### Example
|
|
627
699
|
|
|
@@ -630,19 +702,19 @@ import {
|
|
|
630
702
|
Configuration,
|
|
631
703
|
DefaultApi,
|
|
632
704
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
633
|
-
import type {
|
|
705
|
+
import type { GetVMUtilizationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
634
706
|
|
|
635
707
|
async function example() {
|
|
636
708
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
637
709
|
const api = new DefaultApi();
|
|
638
710
|
|
|
639
711
|
const body = {
|
|
640
|
-
// string | VirtualMachine ID
|
|
712
|
+
// string | VirtualMachine MoRef ID
|
|
641
713
|
id: id_example,
|
|
642
|
-
} satisfies
|
|
714
|
+
} satisfies GetVMUtilizationRequest;
|
|
643
715
|
|
|
644
716
|
try {
|
|
645
|
-
const data = await api.
|
|
717
|
+
const data = await api.getVMUtilization(body);
|
|
646
718
|
console.log(data);
|
|
647
719
|
} catch (error) {
|
|
648
720
|
console.error(error);
|
|
@@ -658,11 +730,11 @@ example().catch(console.error);
|
|
|
658
730
|
|
|
659
731
|
| Name | Type | Description | Notes |
|
|
660
732
|
|------------- | ------------- | ------------- | -------------|
|
|
661
|
-
| **id** | `string` | VirtualMachine ID | [Defaults to `undefined`] |
|
|
733
|
+
| **id** | `string` | VirtualMachine MoRef ID | [Defaults to `undefined`] |
|
|
662
734
|
|
|
663
735
|
### Return type
|
|
664
736
|
|
|
665
|
-
[**
|
|
737
|
+
[**VmUtilizationDetails**](VmUtilizationDetails.md)
|
|
666
738
|
|
|
667
739
|
### Authorization
|
|
668
740
|
|
|
@@ -677,8 +749,8 @@ No authorization required
|
|
|
677
749
|
### HTTP response details
|
|
678
750
|
| Status code | Description | Response headers |
|
|
679
751
|
|-------------|-------------|------------------|
|
|
680
|
-
| **200** |
|
|
681
|
-
| **404** |
|
|
752
|
+
| **200** | VM utilization details | - |
|
|
753
|
+
| **404** | No utilization data found for this VM | - |
|
|
682
754
|
| **500** | Internal server error | - |
|
|
683
755
|
|
|
684
756
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
@@ -760,11 +832,11 @@ No authorization required
|
|
|
760
832
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
761
833
|
|
|
762
834
|
|
|
763
|
-
##
|
|
835
|
+
## getVersion
|
|
764
836
|
|
|
765
|
-
>
|
|
837
|
+
> VersionInfo getVersion()
|
|
766
838
|
|
|
767
|
-
Get
|
|
839
|
+
Get agent version information
|
|
768
840
|
|
|
769
841
|
### Example
|
|
770
842
|
|
|
@@ -773,14 +845,14 @@ import {
|
|
|
773
845
|
Configuration,
|
|
774
846
|
DefaultApi,
|
|
775
847
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
776
|
-
import type {
|
|
848
|
+
import type { GetVersionRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
777
849
|
|
|
778
850
|
async function example() {
|
|
779
851
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
780
852
|
const api = new DefaultApi();
|
|
781
853
|
|
|
782
854
|
try {
|
|
783
|
-
const data = await api.
|
|
855
|
+
const data = await api.getVersion();
|
|
784
856
|
console.log(data);
|
|
785
857
|
} catch (error) {
|
|
786
858
|
console.error(error);
|
|
@@ -797,7 +869,7 @@ This endpoint does not need any parameter.
|
|
|
797
869
|
|
|
798
870
|
### Return type
|
|
799
871
|
|
|
800
|
-
[**
|
|
872
|
+
[**VersionInfo**](VersionInfo.md)
|
|
801
873
|
|
|
802
874
|
### Authorization
|
|
803
875
|
|
|
@@ -812,18 +884,89 @@ No authorization required
|
|
|
812
884
|
### HTTP response details
|
|
813
885
|
| Status code | Description | Response headers |
|
|
814
886
|
|-------------|-------------|------------------|
|
|
815
|
-
| **200** |
|
|
816
|
-
|
|
887
|
+
| **200** | Version information | - |
|
|
888
|
+
|
|
889
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
890
|
+
|
|
891
|
+
|
|
892
|
+
## listGroups
|
|
893
|
+
|
|
894
|
+
> GroupListResponse listGroups(byName, page, pageSize)
|
|
895
|
+
|
|
896
|
+
List all groups
|
|
897
|
+
|
|
898
|
+
### Example
|
|
899
|
+
|
|
900
|
+
```ts
|
|
901
|
+
import {
|
|
902
|
+
Configuration,
|
|
903
|
+
DefaultApi,
|
|
904
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
905
|
+
import type { ListGroupsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
906
|
+
|
|
907
|
+
async function example() {
|
|
908
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
909
|
+
const api = new DefaultApi();
|
|
910
|
+
|
|
911
|
+
const body = {
|
|
912
|
+
// string | Filter groups by name (case-insensitive substring match) (optional)
|
|
913
|
+
byName: byName_example,
|
|
914
|
+
// number | Page number (1-indexed) (optional)
|
|
915
|
+
page: 56,
|
|
916
|
+
// number | Number of groups per page (optional)
|
|
917
|
+
pageSize: 56,
|
|
918
|
+
} satisfies ListGroupsRequest;
|
|
919
|
+
|
|
920
|
+
try {
|
|
921
|
+
const data = await api.listGroups(body);
|
|
922
|
+
console.log(data);
|
|
923
|
+
} catch (error) {
|
|
924
|
+
console.error(error);
|
|
925
|
+
}
|
|
926
|
+
}
|
|
927
|
+
|
|
928
|
+
// Run the test
|
|
929
|
+
example().catch(console.error);
|
|
930
|
+
```
|
|
931
|
+
|
|
932
|
+
### Parameters
|
|
933
|
+
|
|
934
|
+
|
|
935
|
+
| Name | Type | Description | Notes |
|
|
936
|
+
|------------- | ------------- | ------------- | -------------|
|
|
937
|
+
| **byName** | `string` | Filter groups by name (case-insensitive substring match) | [Optional] [Defaults to `undefined`] |
|
|
938
|
+
| **page** | `number` | Page number (1-indexed) | [Optional] [Defaults to `1`] |
|
|
939
|
+
| **pageSize** | `number` | Number of groups per page | [Optional] [Defaults to `20`] |
|
|
940
|
+
|
|
941
|
+
### Return type
|
|
942
|
+
|
|
943
|
+
[**GroupListResponse**](GroupListResponse.md)
|
|
944
|
+
|
|
945
|
+
### Authorization
|
|
946
|
+
|
|
947
|
+
No authorization required
|
|
948
|
+
|
|
949
|
+
### HTTP request headers
|
|
950
|
+
|
|
951
|
+
- **Content-Type**: Not defined
|
|
952
|
+
- **Accept**: `application/json`
|
|
953
|
+
|
|
954
|
+
|
|
955
|
+
### HTTP response details
|
|
956
|
+
| Status code | Description | Response headers |
|
|
957
|
+
|-------------|-------------|------------------|
|
|
958
|
+
| **200** | List of groups | - |
|
|
959
|
+
| **400** | Invalid filter expression | - |
|
|
817
960
|
| **500** | Internal server error | - |
|
|
818
961
|
|
|
819
962
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
820
963
|
|
|
821
964
|
|
|
822
|
-
##
|
|
965
|
+
## listRightsizingReports
|
|
823
966
|
|
|
824
|
-
>
|
|
967
|
+
> RightsizingReportListResponse listRightsizingReports()
|
|
825
968
|
|
|
826
|
-
|
|
969
|
+
List all rightsizing reports
|
|
827
970
|
|
|
828
971
|
### Example
|
|
829
972
|
|
|
@@ -832,14 +975,14 @@ import {
|
|
|
832
975
|
Configuration,
|
|
833
976
|
DefaultApi,
|
|
834
977
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
835
|
-
import type {
|
|
978
|
+
import type { ListRightsizingReportsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
836
979
|
|
|
837
980
|
async function example() {
|
|
838
981
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
839
982
|
const api = new DefaultApi();
|
|
840
983
|
|
|
841
984
|
try {
|
|
842
|
-
const data = await api.
|
|
985
|
+
const data = await api.listRightsizingReports();
|
|
843
986
|
console.log(data);
|
|
844
987
|
} catch (error) {
|
|
845
988
|
console.error(error);
|
|
@@ -856,7 +999,7 @@ This endpoint does not need any parameter.
|
|
|
856
999
|
|
|
857
1000
|
### Return type
|
|
858
1001
|
|
|
859
|
-
[**
|
|
1002
|
+
[**RightsizingReportListResponse**](RightsizingReportListResponse.md)
|
|
860
1003
|
|
|
861
1004
|
### Authorization
|
|
862
1005
|
|
|
@@ -871,16 +1014,17 @@ No authorization required
|
|
|
871
1014
|
### HTTP response details
|
|
872
1015
|
| Status code | Description | Response headers |
|
|
873
1016
|
|-------------|-------------|------------------|
|
|
874
|
-
| **200** |
|
|
1017
|
+
| **200** | List of rightsizing reports | - |
|
|
1018
|
+
| **500** | Internal server error | - |
|
|
875
1019
|
|
|
876
1020
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
877
1021
|
|
|
878
1022
|
|
|
879
|
-
##
|
|
1023
|
+
## putInspectorCredentials
|
|
880
1024
|
|
|
881
|
-
>
|
|
1025
|
+
> putInspectorCredentials(vcenterCredentials)
|
|
882
1026
|
|
|
883
|
-
|
|
1027
|
+
Set or replace inspector credentials
|
|
884
1028
|
|
|
885
1029
|
### Example
|
|
886
1030
|
|
|
@@ -889,23 +1033,19 @@ import {
|
|
|
889
1033
|
Configuration,
|
|
890
1034
|
DefaultApi,
|
|
891
1035
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
892
|
-
import type {
|
|
1036
|
+
import type { PutInspectorCredentialsRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
893
1037
|
|
|
894
1038
|
async function example() {
|
|
895
1039
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
896
1040
|
const api = new DefaultApi();
|
|
897
1041
|
|
|
898
1042
|
const body = {
|
|
899
|
-
//
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
page: 56,
|
|
903
|
-
// number | Number of groups per page (optional)
|
|
904
|
-
pageSize: 56,
|
|
905
|
-
} satisfies ListGroupsRequest;
|
|
1043
|
+
// VcenterCredentials
|
|
1044
|
+
vcenterCredentials: ...,
|
|
1045
|
+
} satisfies PutInspectorCredentialsRequest;
|
|
906
1046
|
|
|
907
1047
|
try {
|
|
908
|
-
const data = await api.
|
|
1048
|
+
const data = await api.putInspectorCredentials(body);
|
|
909
1049
|
console.log(data);
|
|
910
1050
|
} catch (error) {
|
|
911
1051
|
console.error(error);
|
|
@@ -921,13 +1061,11 @@ example().catch(console.error);
|
|
|
921
1061
|
|
|
922
1062
|
| Name | Type | Description | Notes |
|
|
923
1063
|
|------------- | ------------- | ------------- | -------------|
|
|
924
|
-
| **
|
|
925
|
-
| **page** | `number` | Page number (1-indexed) | [Optional] [Defaults to `1`] |
|
|
926
|
-
| **pageSize** | `number` | Number of groups per page | [Optional] [Defaults to `20`] |
|
|
1064
|
+
| **vcenterCredentials** | [VcenterCredentials](VcenterCredentials.md) | | |
|
|
927
1065
|
|
|
928
1066
|
### Return type
|
|
929
1067
|
|
|
930
|
-
|
|
1068
|
+
`void` (Empty response body)
|
|
931
1069
|
|
|
932
1070
|
### Authorization
|
|
933
1071
|
|
|
@@ -935,15 +1073,84 @@ No authorization required
|
|
|
935
1073
|
|
|
936
1074
|
### HTTP request headers
|
|
937
1075
|
|
|
938
|
-
- **Content-Type**:
|
|
1076
|
+
- **Content-Type**: `application/json`
|
|
1077
|
+
- **Accept**: Not defined
|
|
1078
|
+
|
|
1079
|
+
|
|
1080
|
+
### HTTP response details
|
|
1081
|
+
| Status code | Description | Response headers |
|
|
1082
|
+
|-------------|-------------|------------------|
|
|
1083
|
+
| **200** | Credentials updated successfully | - |
|
|
1084
|
+
| **400** | Bad Credentials | - |
|
|
1085
|
+
| **500** | Internal server error | - |
|
|
1086
|
+
|
|
1087
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1088
|
+
|
|
1089
|
+
|
|
1090
|
+
## putInspectorVddk
|
|
1091
|
+
|
|
1092
|
+
> VddkProperties putInspectorVddk(file)
|
|
1093
|
+
|
|
1094
|
+
Upload VDDK tarball
|
|
1095
|
+
|
|
1096
|
+
### Example
|
|
1097
|
+
|
|
1098
|
+
```ts
|
|
1099
|
+
import {
|
|
1100
|
+
Configuration,
|
|
1101
|
+
DefaultApi,
|
|
1102
|
+
} from '@openshift-migration-advisor/agent-sdk';
|
|
1103
|
+
import type { PutInspectorVddkRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1104
|
+
|
|
1105
|
+
async function example() {
|
|
1106
|
+
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1107
|
+
const api = new DefaultApi();
|
|
1108
|
+
|
|
1109
|
+
const body = {
|
|
1110
|
+
// Blob | VDDK tarball
|
|
1111
|
+
file: BINARY_DATA_HERE,
|
|
1112
|
+
} satisfies PutInspectorVddkRequest;
|
|
1113
|
+
|
|
1114
|
+
try {
|
|
1115
|
+
const data = await api.putInspectorVddk(body);
|
|
1116
|
+
console.log(data);
|
|
1117
|
+
} catch (error) {
|
|
1118
|
+
console.error(error);
|
|
1119
|
+
}
|
|
1120
|
+
}
|
|
1121
|
+
|
|
1122
|
+
// Run the test
|
|
1123
|
+
example().catch(console.error);
|
|
1124
|
+
```
|
|
1125
|
+
|
|
1126
|
+
### Parameters
|
|
1127
|
+
|
|
1128
|
+
|
|
1129
|
+
| Name | Type | Description | Notes |
|
|
1130
|
+
|------------- | ------------- | ------------- | -------------|
|
|
1131
|
+
| **file** | `Blob` | VDDK tarball | [Defaults to `undefined`] |
|
|
1132
|
+
|
|
1133
|
+
### Return type
|
|
1134
|
+
|
|
1135
|
+
[**VddkProperties**](VddkProperties.md)
|
|
1136
|
+
|
|
1137
|
+
### Authorization
|
|
1138
|
+
|
|
1139
|
+
No authorization required
|
|
1140
|
+
|
|
1141
|
+
### HTTP request headers
|
|
1142
|
+
|
|
1143
|
+
- **Content-Type**: `multipart/form-data`
|
|
939
1144
|
- **Accept**: `application/json`
|
|
940
1145
|
|
|
941
1146
|
|
|
942
1147
|
### HTTP response details
|
|
943
1148
|
| Status code | Description | Response headers |
|
|
944
1149
|
|-------------|-------------|------------------|
|
|
945
|
-
| **200** |
|
|
946
|
-
| **
|
|
1150
|
+
| **200** | Upload successful | - |
|
|
1151
|
+
| **409** | Conflict | - |
|
|
1152
|
+
| **413** | File exceeds 64MB limit | - |
|
|
1153
|
+
| **400** | Bad request | - |
|
|
947
1154
|
| **500** | Internal server error | - |
|
|
948
1155
|
|
|
949
1156
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
@@ -1010,8 +1217,8 @@ No authorization required
|
|
|
1010
1217
|
| Status code | Description | Response headers |
|
|
1011
1218
|
|-------------|-------------|------------------|
|
|
1012
1219
|
| **200** | VMs removed from queue | - |
|
|
1013
|
-
| **400** |
|
|
1014
|
-
| **404** |
|
|
1220
|
+
| **400** | Inspector not running or VirtualMachine cannot be canceled | - |
|
|
1221
|
+
| **404** | VirtualMachine not found or not in the queue | - |
|
|
1015
1222
|
| **500** | Internal server error | - |
|
|
1016
1223
|
|
|
1017
1224
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
@@ -1155,7 +1362,7 @@ No authorization required
|
|
|
1155
1362
|
|
|
1156
1363
|
## startInspection
|
|
1157
1364
|
|
|
1158
|
-
> InspectorStatus startInspection(
|
|
1365
|
+
> InspectorStatus startInspection(startInspectionRequest)
|
|
1159
1366
|
|
|
1160
1367
|
Start inspection for VMs
|
|
1161
1368
|
|
|
@@ -1166,16 +1373,16 @@ import {
|
|
|
1166
1373
|
Configuration,
|
|
1167
1374
|
DefaultApi,
|
|
1168
1375
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1169
|
-
import type {
|
|
1376
|
+
import type { StartInspectionOperationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1170
1377
|
|
|
1171
1378
|
async function example() {
|
|
1172
1379
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1173
1380
|
const api = new DefaultApi();
|
|
1174
1381
|
|
|
1175
1382
|
const body = {
|
|
1176
|
-
//
|
|
1177
|
-
|
|
1178
|
-
} satisfies
|
|
1383
|
+
// StartInspectionRequest
|
|
1384
|
+
startInspectionRequest: ...,
|
|
1385
|
+
} satisfies StartInspectionOperationRequest;
|
|
1179
1386
|
|
|
1180
1387
|
try {
|
|
1181
1388
|
const data = await api.startInspection(body);
|
|
@@ -1194,7 +1401,7 @@ example().catch(console.error);
|
|
|
1194
1401
|
|
|
1195
1402
|
| Name | Type | Description | Notes |
|
|
1196
1403
|
|------------- | ------------- | ------------- | -------------|
|
|
1197
|
-
| **
|
|
1404
|
+
| **startInspectionRequest** | [StartInspectionRequest](StartInspectionRequest.md) | | |
|
|
1198
1405
|
|
|
1199
1406
|
### Return type
|
|
1200
1407
|
|
|
@@ -1339,11 +1546,11 @@ No authorization required
|
|
|
1339
1546
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1340
1547
|
|
|
1341
1548
|
|
|
1342
|
-
##
|
|
1549
|
+
## triggerRightsizingCollection
|
|
1343
1550
|
|
|
1344
|
-
>
|
|
1551
|
+
> RightsizingReportSummary triggerRightsizingCollection(rightsizingCollectRequest)
|
|
1345
1552
|
|
|
1346
|
-
|
|
1553
|
+
Trigger rightsizing metrics collection
|
|
1347
1554
|
|
|
1348
1555
|
### Example
|
|
1349
1556
|
|
|
@@ -1352,21 +1559,19 @@ import {
|
|
|
1352
1559
|
Configuration,
|
|
1353
1560
|
DefaultApi,
|
|
1354
1561
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1355
|
-
import type {
|
|
1562
|
+
import type { TriggerRightsizingCollectionRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1356
1563
|
|
|
1357
1564
|
async function example() {
|
|
1358
1565
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1359
1566
|
const api = new DefaultApi();
|
|
1360
1567
|
|
|
1361
1568
|
const body = {
|
|
1362
|
-
//
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
updateGroupRequest: ...,
|
|
1366
|
-
} satisfies UpdateGroupOperationRequest;
|
|
1569
|
+
// RightsizingCollectRequest
|
|
1570
|
+
rightsizingCollectRequest: ...,
|
|
1571
|
+
} satisfies TriggerRightsizingCollectionRequest;
|
|
1367
1572
|
|
|
1368
1573
|
try {
|
|
1369
|
-
const data = await api.
|
|
1574
|
+
const data = await api.triggerRightsizingCollection(body);
|
|
1370
1575
|
console.log(data);
|
|
1371
1576
|
} catch (error) {
|
|
1372
1577
|
console.error(error);
|
|
@@ -1382,12 +1587,11 @@ example().catch(console.error);
|
|
|
1382
1587
|
|
|
1383
1588
|
| Name | Type | Description | Notes |
|
|
1384
1589
|
|------------- | ------------- | ------------- | -------------|
|
|
1385
|
-
| **
|
|
1386
|
-
| **updateGroupRequest** | [UpdateGroupRequest](UpdateGroupRequest.md) | | |
|
|
1590
|
+
| **rightsizingCollectRequest** | [RightsizingCollectRequest](RightsizingCollectRequest.md) | | |
|
|
1387
1591
|
|
|
1388
1592
|
### Return type
|
|
1389
1593
|
|
|
1390
|
-
[**
|
|
1594
|
+
[**RightsizingReportSummary**](RightsizingReportSummary.md)
|
|
1391
1595
|
|
|
1392
1596
|
### Authorization
|
|
1393
1597
|
|
|
@@ -1402,19 +1606,18 @@ No authorization required
|
|
|
1402
1606
|
### HTTP response details
|
|
1403
1607
|
| Status code | Description | Response headers |
|
|
1404
1608
|
|-------------|-------------|------------------|
|
|
1405
|
-
| **
|
|
1406
|
-
| **400** | Invalid request
|
|
1407
|
-
| **404** | Group not found | - |
|
|
1609
|
+
| **202** | Collection triggered; returns report | - |
|
|
1610
|
+
| **400** | Invalid request | - |
|
|
1408
1611
|
| **500** | Internal server error | - |
|
|
1409
1612
|
|
|
1410
1613
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
1411
1614
|
|
|
1412
1615
|
|
|
1413
|
-
##
|
|
1616
|
+
## updateGroup
|
|
1414
1617
|
|
|
1415
|
-
>
|
|
1618
|
+
> Group updateGroup(id, updateGroupRequest)
|
|
1416
1619
|
|
|
1417
|
-
|
|
1620
|
+
Update group
|
|
1418
1621
|
|
|
1419
1622
|
### Example
|
|
1420
1623
|
|
|
@@ -1423,19 +1626,21 @@ import {
|
|
|
1423
1626
|
Configuration,
|
|
1424
1627
|
DefaultApi,
|
|
1425
1628
|
} from '@openshift-migration-advisor/agent-sdk';
|
|
1426
|
-
import type {
|
|
1629
|
+
import type { UpdateGroupOperationRequest } from '@openshift-migration-advisor/agent-sdk';
|
|
1427
1630
|
|
|
1428
1631
|
async function example() {
|
|
1429
1632
|
console.log("🚀 Testing @openshift-migration-advisor/agent-sdk SDK...");
|
|
1430
1633
|
const api = new DefaultApi();
|
|
1431
1634
|
|
|
1432
1635
|
const body = {
|
|
1433
|
-
//
|
|
1434
|
-
|
|
1435
|
-
|
|
1636
|
+
// string | Group ID
|
|
1637
|
+
id: id_example,
|
|
1638
|
+
// UpdateGroupRequest
|
|
1639
|
+
updateGroupRequest: ...,
|
|
1640
|
+
} satisfies UpdateGroupOperationRequest;
|
|
1436
1641
|
|
|
1437
1642
|
try {
|
|
1438
|
-
const data = await api.
|
|
1643
|
+
const data = await api.updateGroup(body);
|
|
1439
1644
|
console.log(data);
|
|
1440
1645
|
} catch (error) {
|
|
1441
1646
|
console.error(error);
|
|
@@ -1451,11 +1656,12 @@ example().catch(console.error);
|
|
|
1451
1656
|
|
|
1452
1657
|
| Name | Type | Description | Notes |
|
|
1453
1658
|
|------------- | ------------- | ------------- | -------------|
|
|
1454
|
-
| **
|
|
1659
|
+
| **id** | `string` | Group ID | [Defaults to `undefined`] |
|
|
1660
|
+
| **updateGroupRequest** | [UpdateGroupRequest](UpdateGroupRequest.md) | | |
|
|
1455
1661
|
|
|
1456
1662
|
### Return type
|
|
1457
1663
|
|
|
1458
|
-
[**
|
|
1664
|
+
[**Group**](Group.md)
|
|
1459
1665
|
|
|
1460
1666
|
### Authorization
|
|
1461
1667
|
|
|
@@ -1463,17 +1669,16 @@ No authorization required
|
|
|
1463
1669
|
|
|
1464
1670
|
### HTTP request headers
|
|
1465
1671
|
|
|
1466
|
-
- **Content-Type**: `
|
|
1672
|
+
- **Content-Type**: `application/json`
|
|
1467
1673
|
- **Accept**: `application/json`
|
|
1468
1674
|
|
|
1469
1675
|
|
|
1470
1676
|
### HTTP response details
|
|
1471
1677
|
| Status code | Description | Response headers |
|
|
1472
1678
|
|-------------|-------------|------------------|
|
|
1473
|
-
| **200** |
|
|
1474
|
-
| **
|
|
1475
|
-
| **
|
|
1476
|
-
| **400** | Bad request | - |
|
|
1679
|
+
| **200** | Group updated | - |
|
|
1680
|
+
| **400** | Invalid request (e.g., invalid filter syntax) | - |
|
|
1681
|
+
| **404** | Group not found | - |
|
|
1477
1682
|
| **500** | Internal server error | - |
|
|
1478
1683
|
|
|
1479
1684
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|