@openshift-migration-advisor/agent-sdk 0.33.0 → 0.33.1-d63d5073ca08
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 +14 -0
- package/.openapi-generator/VERSION +1 -1
- package/README.md +10 -3
- package/dist/apis/GroupsApi.d.ts +6 -6
- package/dist/apis/ImageUpgradeApi.d.ts +66 -0
- package/dist/apis/ImageUpgradeApi.js +90 -0
- package/dist/apis/VirtualMachinesApi.d.ts +6 -6
- package/dist/apis/index.d.ts +1 -0
- package/dist/apis/index.js +1 -0
- package/dist/esm/apis/GroupsApi.d.ts +6 -6
- package/dist/esm/apis/ImageUpgradeApi.d.ts +66 -0
- package/dist/esm/apis/ImageUpgradeApi.js +86 -0
- package/dist/esm/apis/VirtualMachinesApi.d.ts +6 -6
- package/dist/esm/apis/index.d.ts +1 -0
- package/dist/esm/apis/index.js +1 -0
- package/dist/esm/models/AgentStatus.d.ts +5 -0
- package/dist/esm/models/AgentStatus.js +5 -0
- package/dist/esm/models/ImageUpgradeImage.d.ts +34 -0
- package/dist/esm/models/ImageUpgradeImage.js +47 -0
- package/dist/esm/models/ImageUpgradeResult.d.ts +66 -0
- package/dist/esm/models/ImageUpgradeResult.js +71 -0
- package/dist/esm/models/ImageUpgradeStatus.d.ts +44 -0
- package/dist/esm/models/ImageUpgradeStatus.js +57 -0
- package/dist/esm/models/ImageUploadStatus.d.ts +44 -0
- package/dist/esm/models/ImageUploadStatus.js +56 -0
- package/dist/esm/models/RDMBacking.d.ts +26 -0
- package/dist/esm/models/RDMBacking.js +17 -0
- package/dist/esm/models/RDMHostLun.d.ts +42 -0
- package/dist/esm/models/RDMHostLun.js +49 -0
- package/dist/esm/models/SuccessfulImageUpgrade.d.ts +38 -0
- package/dist/esm/models/SuccessfulImageUpgrade.js +52 -0
- package/dist/esm/models/VMFilterOptionsResponse.d.ts +8 -0
- package/dist/esm/models/VMFilterOptionsResponse.js +8 -0
- package/dist/esm/models/VirtualMachine.d.ts +8 -0
- package/dist/esm/models/VirtualMachine.js +4 -0
- package/dist/esm/models/VirtualMachineDisk.d.ts +8 -0
- package/dist/esm/models/VirtualMachineDisk.js +4 -0
- package/dist/esm/models/index.d.ts +6 -0
- package/dist/esm/models/index.js +6 -0
- package/dist/models/AgentStatus.d.ts +5 -0
- package/dist/models/AgentStatus.js +5 -0
- package/dist/models/ImageUpgradeImage.d.ts +34 -0
- package/dist/models/ImageUpgradeImage.js +54 -0
- package/dist/models/ImageUpgradeResult.d.ts +66 -0
- package/dist/models/ImageUpgradeResult.js +79 -0
- package/dist/models/ImageUpgradeStatus.d.ts +44 -0
- package/dist/models/ImageUpgradeStatus.js +64 -0
- package/dist/models/ImageUploadStatus.d.ts +44 -0
- package/dist/models/ImageUploadStatus.js +64 -0
- package/dist/models/RDMBacking.d.ts +26 -0
- package/dist/models/RDMBacking.js +18 -0
- package/dist/models/RDMHostLun.d.ts +42 -0
- package/dist/models/RDMHostLun.js +56 -0
- package/dist/models/SuccessfulImageUpgrade.d.ts +38 -0
- package/dist/models/SuccessfulImageUpgrade.js +59 -0
- package/dist/models/VMFilterOptionsResponse.d.ts +8 -0
- package/dist/models/VMFilterOptionsResponse.js +8 -0
- package/dist/models/VirtualMachine.d.ts +8 -0
- package/dist/models/VirtualMachine.js +4 -0
- package/dist/models/VirtualMachineDisk.d.ts +8 -0
- package/dist/models/VirtualMachineDisk.js +4 -0
- package/dist/models/index.d.ts +6 -0
- package/dist/models/index.js +6 -0
- package/docs/AgentStatus.md +2 -0
- package/docs/GroupsApi.md +4 -4
- package/docs/ImageUpgradeApi.md +82 -0
- package/docs/ImageUpgradeImage.md +36 -0
- package/docs/ImageUpgradeResult.md +46 -0
- package/docs/ImageUpgradeStatus.md +40 -0
- package/docs/ImageUploadStatus.md +36 -0
- package/docs/RDMBacking.md +8 -0
- package/docs/RDMHostLun.md +41 -0
- package/docs/SuccessfulImageUpgrade.md +38 -0
- package/docs/VMFilterOptionsResponse.md +4 -0
- package/docs/VirtualMachine.md +4 -0
- package/docs/VirtualMachineDisk.md +4 -0
- package/docs/VirtualMachinesApi.md +4 -4
- package/package.json +1 -1
- package/src/apis/GroupsApi.ts +6 -6
- package/src/apis/ImageUpgradeApi.ts +128 -0
- package/src/apis/VirtualMachinesApi.ts +6 -6
- package/src/apis/index.ts +1 -0
- package/src/models/AgentStatus.ts +14 -0
- package/src/models/ImageUpgradeImage.ts +71 -0
- package/src/models/ImageUpgradeResult.ts +130 -0
- package/src/models/ImageUpgradeStatus.ts +100 -0
- package/src/models/ImageUploadStatus.ts +84 -0
- package/src/models/RDMBacking.ts +44 -0
- package/src/models/RDMHostLun.ts +82 -0
- package/src/models/SuccessfulImageUpgrade.ts +78 -0
- package/src/models/VMFilterOptionsResponse.ts +14 -0
- package/src/models/VirtualMachine.ts +12 -0
- package/src/models/VirtualMachineDisk.ts +12 -0
- package/src/models/index.ts +6 -0
package/.openapi-generator/FILES
CHANGED
|
@@ -55,6 +55,11 @@ docs/Host.md
|
|
|
55
55
|
docs/HostPhysicalNIC.md
|
|
56
56
|
docs/HostStorageAdapter.md
|
|
57
57
|
docs/HostStorageLun.md
|
|
58
|
+
docs/ImageUpgradeApi.md
|
|
59
|
+
docs/ImageUpgradeImage.md
|
|
60
|
+
docs/ImageUpgradeResult.md
|
|
61
|
+
docs/ImageUpgradeStatus.md
|
|
62
|
+
docs/ImageUploadStatus.md
|
|
58
63
|
docs/Infra.md
|
|
59
64
|
docs/InspectionStatus.md
|
|
60
65
|
docs/InspectorApi.md
|
|
@@ -72,6 +77,7 @@ docs/PairCapabilityRequest.md
|
|
|
72
77
|
docs/Process.md
|
|
73
78
|
docs/Product.md
|
|
74
79
|
docs/RDMBacking.md
|
|
80
|
+
docs/RDMHostLun.md
|
|
75
81
|
docs/RightsizingApi.md
|
|
76
82
|
docs/RightsizingClusterResponse.md
|
|
77
83
|
docs/RightsizingClusterUtilization.md
|
|
@@ -79,6 +85,7 @@ docs/StartForecasterRequest.md
|
|
|
79
85
|
docs/StartInspectionRequest.md
|
|
80
86
|
docs/StopForecasterPair202Response.md
|
|
81
87
|
docs/StorageIoConfiguration.md
|
|
88
|
+
docs/SuccessfulImageUpgrade.md
|
|
82
89
|
docs/UpdateGroupRequest.md
|
|
83
90
|
docs/UpdateInventory.md
|
|
84
91
|
docs/UpdateLabelVMsRequest.md
|
|
@@ -114,6 +121,7 @@ src/apis/CollectorApi.ts
|
|
|
114
121
|
src/apis/CredentialsApi.ts
|
|
115
122
|
src/apis/ForecasterApi.ts
|
|
116
123
|
src/apis/GroupsApi.ts
|
|
124
|
+
src/apis/ImageUpgradeApi.ts
|
|
117
125
|
src/apis/InspectorApi.ts
|
|
118
126
|
src/apis/InventoriesApi.ts
|
|
119
127
|
src/apis/RightsizingApi.ts
|
|
@@ -166,6 +174,10 @@ src/models/Host.ts
|
|
|
166
174
|
src/models/HostPhysicalNIC.ts
|
|
167
175
|
src/models/HostStorageAdapter.ts
|
|
168
176
|
src/models/HostStorageLun.ts
|
|
177
|
+
src/models/ImageUpgradeImage.ts
|
|
178
|
+
src/models/ImageUpgradeResult.ts
|
|
179
|
+
src/models/ImageUpgradeStatus.ts
|
|
180
|
+
src/models/ImageUploadStatus.ts
|
|
169
181
|
src/models/Infra.ts
|
|
170
182
|
src/models/InspectionStatus.ts
|
|
171
183
|
src/models/InspectorStatus.ts
|
|
@@ -181,12 +193,14 @@ src/models/PairCapabilityRequest.ts
|
|
|
181
193
|
src/models/Process.ts
|
|
182
194
|
src/models/Product.ts
|
|
183
195
|
src/models/RDMBacking.ts
|
|
196
|
+
src/models/RDMHostLun.ts
|
|
184
197
|
src/models/RightsizingClusterResponse.ts
|
|
185
198
|
src/models/RightsizingClusterUtilization.ts
|
|
186
199
|
src/models/StartForecasterRequest.ts
|
|
187
200
|
src/models/StartInspectionRequest.ts
|
|
188
201
|
src/models/StopForecasterPair202Response.ts
|
|
189
202
|
src/models/StorageIoConfiguration.ts
|
|
203
|
+
src/models/SuccessfulImageUpgrade.ts
|
|
190
204
|
src/models/UpdateGroupRequest.ts
|
|
191
205
|
src/models/UpdateInventory.ts
|
|
192
206
|
src/models/UpdateLabelVMsRequest.ts
|
|
@@ -1 +1 @@
|
|
|
1
|
-
7.
|
|
1
|
+
7.29.0-SNAPSHOT
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @openshift-migration-advisor/agent-sdk@0.33.
|
|
1
|
+
# @openshift-migration-advisor/agent-sdk@0.33.1-d63d5073ca08
|
|
2
2
|
|
|
3
3
|
A TypeScript SDK client for the raw.githubusercontent.com API.
|
|
4
4
|
|
|
@@ -79,6 +79,7 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v2*
|
|
|
79
79
|
*GroupsApi* | [**listGroups**](docs/GroupsApi.md#listgroups) | **GET** /collections/{id}/groups | List all groups in a collection
|
|
80
80
|
*GroupsApi* | [**listLatestGroups**](docs/GroupsApi.md#listlatestgroups) | **GET** /groups | List groups from the latest collection
|
|
81
81
|
*GroupsApi* | [**updateLatestGroup**](docs/GroupsApi.md#updatelatestgroup) | **PATCH** /groups/{groupId} | Update group in the latest collection
|
|
82
|
+
*ImageUpgradeApi* | [**postImageUpgrade**](docs/ImageUpgradeApi.md#postimageupgrade) | **POST** /image-upgrades | Upload an OCI image for a disconnected appliance image upgrade
|
|
82
83
|
*InspectorApi* | [**getInspectorStatus**](docs/InspectorApi.md#getinspectorstatus) | **GET** /inspector | Get inspector status
|
|
83
84
|
*InspectorApi* | [**getInspectorVddkStatus**](docs/InspectorApi.md#getinspectorvddkstatus) | **GET** /inspector/vddk | Get VDDK upload status
|
|
84
85
|
*InspectorApi* | [**putInspectorVddk**](docs/InspectorApi.md#putinspectorvddk) | **PUT** /inspector/vddk | Upload VDDK tarball
|
|
@@ -152,6 +153,10 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v2*
|
|
|
152
153
|
- [HostPhysicalNIC](docs/HostPhysicalNIC.md)
|
|
153
154
|
- [HostStorageAdapter](docs/HostStorageAdapter.md)
|
|
154
155
|
- [HostStorageLun](docs/HostStorageLun.md)
|
|
156
|
+
- [ImageUpgradeImage](docs/ImageUpgradeImage.md)
|
|
157
|
+
- [ImageUpgradeResult](docs/ImageUpgradeResult.md)
|
|
158
|
+
- [ImageUpgradeStatus](docs/ImageUpgradeStatus.md)
|
|
159
|
+
- [ImageUploadStatus](docs/ImageUploadStatus.md)
|
|
155
160
|
- [Infra](docs/Infra.md)
|
|
156
161
|
- [InspectionStatus](docs/InspectionStatus.md)
|
|
157
162
|
- [InspectorStatus](docs/InspectorStatus.md)
|
|
@@ -167,12 +172,14 @@ All URIs are relative to *https://raw.githubusercontent.com/api/v2*
|
|
|
167
172
|
- [Process](docs/Process.md)
|
|
168
173
|
- [Product](docs/Product.md)
|
|
169
174
|
- [RDMBacking](docs/RDMBacking.md)
|
|
175
|
+
- [RDMHostLun](docs/RDMHostLun.md)
|
|
170
176
|
- [RightsizingClusterResponse](docs/RightsizingClusterResponse.md)
|
|
171
177
|
- [RightsizingClusterUtilization](docs/RightsizingClusterUtilization.md)
|
|
172
178
|
- [StartForecasterRequest](docs/StartForecasterRequest.md)
|
|
173
179
|
- [StartInspectionRequest](docs/StartInspectionRequest.md)
|
|
174
180
|
- [StopForecasterPair202Response](docs/StopForecasterPair202Response.md)
|
|
175
181
|
- [StorageIoConfiguration](docs/StorageIoConfiguration.md)
|
|
182
|
+
- [SuccessfulImageUpgrade](docs/SuccessfulImageUpgrade.md)
|
|
176
183
|
- [UpdateGroupRequest](docs/UpdateGroupRequest.md)
|
|
177
184
|
- [UpdateInventory](docs/UpdateInventory.md)
|
|
178
185
|
- [UpdateLabelVMsRequest](docs/UpdateLabelVMsRequest.md)
|
|
@@ -210,8 +217,8 @@ and is automatically generated by the
|
|
|
210
217
|
[OpenAPI Generator](https://openapi-generator.tech) project:
|
|
211
218
|
|
|
212
219
|
- API version: `v2`
|
|
213
|
-
- Package version: `0.33.
|
|
214
|
-
- Generator version: `7.
|
|
220
|
+
- Package version: `0.33.1-d63d5073ca08`
|
|
221
|
+
- Generator version: `7.29.0-SNAPSHOT`
|
|
215
222
|
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
|
|
216
223
|
|
|
217
224
|
The generated npm module supports the following:
|
package/dist/apis/GroupsApi.d.ts
CHANGED
|
@@ -39,7 +39,7 @@ export interface GetGroupRequest {
|
|
|
39
39
|
*/
|
|
40
40
|
groupId: string;
|
|
41
41
|
/**
|
|
42
|
-
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
42
|
+
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
43
43
|
*/
|
|
44
44
|
sort?: Array<string>;
|
|
45
45
|
/**
|
|
@@ -57,7 +57,7 @@ export interface GetLatestGroupRequest {
|
|
|
57
57
|
*/
|
|
58
58
|
groupId: string;
|
|
59
59
|
/**
|
|
60
|
-
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
60
|
+
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
61
61
|
*/
|
|
62
62
|
sort?: Array<string>;
|
|
63
63
|
/**
|
|
@@ -174,7 +174,7 @@ export interface GroupsApiInterface {
|
|
|
174
174
|
* Creates request options for getGroup without sending the request
|
|
175
175
|
* @param {string} id Collection ID
|
|
176
176
|
* @param {string} groupId Group ID
|
|
177
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
177
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
178
178
|
* @param {number} [page] Page number for pagination
|
|
179
179
|
* @param {number} [pageSize] Number of items per page
|
|
180
180
|
* @throws {RequiredError}
|
|
@@ -186,7 +186,7 @@ export interface GroupsApiInterface {
|
|
|
186
186
|
* @summary Get group by ID with its VirtualMachines
|
|
187
187
|
* @param {string} id Collection ID
|
|
188
188
|
* @param {string} groupId Group ID
|
|
189
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
189
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
190
190
|
* @param {number} [page] Page number for pagination
|
|
191
191
|
* @param {number} [pageSize] Number of items per page
|
|
192
192
|
* @param {*} [options] Override http request option.
|
|
@@ -201,7 +201,7 @@ export interface GroupsApiInterface {
|
|
|
201
201
|
/**
|
|
202
202
|
* Creates request options for getLatestGroup without sending the request
|
|
203
203
|
* @param {string} groupId Group ID
|
|
204
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
204
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
205
205
|
* @param {number} [page] Page number for pagination
|
|
206
206
|
* @param {number} [pageSize] Number of items per page
|
|
207
207
|
* @throws {RequiredError}
|
|
@@ -212,7 +212,7 @@ export interface GroupsApiInterface {
|
|
|
212
212
|
*
|
|
213
213
|
* @summary Get group by ID from the latest collection
|
|
214
214
|
* @param {string} groupId Group ID
|
|
215
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
215
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
216
216
|
* @param {number} [page] Page number for pagination
|
|
217
217
|
* @param {number} [pageSize] Number of items per page
|
|
218
218
|
* @param {*} [options] Override http request option.
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Assisted Migration Agent API
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: v2
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import * as runtime from '../runtime.js';
|
|
13
|
+
export interface PostImageUpgradeRequest {
|
|
14
|
+
/**
|
|
15
|
+
* OCI archive; maximum file payload is 3 GiB
|
|
16
|
+
*/
|
|
17
|
+
file: Blob;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* ImageUpgradeApi - interface
|
|
21
|
+
*
|
|
22
|
+
* @export
|
|
23
|
+
* @interface ImageUpgradeApiInterface
|
|
24
|
+
*/
|
|
25
|
+
export interface ImageUpgradeApiInterface {
|
|
26
|
+
/**
|
|
27
|
+
* Creates request options for postImageUpgrade without sending the request
|
|
28
|
+
* @param {Blob} file OCI archive; maximum file payload is 3 GiB
|
|
29
|
+
* @throws {RequiredError}
|
|
30
|
+
* @memberof ImageUpgradeApiInterface
|
|
31
|
+
*/
|
|
32
|
+
postImageUpgradeRequestOpts(requestParameters: PostImageUpgradeRequest): Promise<runtime.RequestOpts>;
|
|
33
|
+
/**
|
|
34
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
35
|
+
* @summary Upload an OCI image for a disconnected appliance image upgrade
|
|
36
|
+
* @param {Blob} file OCI archive; maximum file payload is 3 GiB
|
|
37
|
+
* @param {*} [options] Override http request option.
|
|
38
|
+
* @throws {RequiredError}
|
|
39
|
+
* @memberof ImageUpgradeApiInterface
|
|
40
|
+
*/
|
|
41
|
+
postImageUpgradeRaw(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
42
|
+
/**
|
|
43
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
44
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
45
|
+
*/
|
|
46
|
+
postImageUpgrade(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
*/
|
|
51
|
+
export declare class ImageUpgradeApi extends runtime.BaseAPI implements ImageUpgradeApiInterface {
|
|
52
|
+
/**
|
|
53
|
+
* Creates request options for postImageUpgrade without sending the request
|
|
54
|
+
*/
|
|
55
|
+
postImageUpgradeRequestOpts(requestParameters: PostImageUpgradeRequest): Promise<runtime.RequestOpts>;
|
|
56
|
+
/**
|
|
57
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
58
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
59
|
+
*/
|
|
60
|
+
postImageUpgradeRaw(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
61
|
+
/**
|
|
62
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
63
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
64
|
+
*/
|
|
65
|
+
postImageUpgrade(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
66
|
+
}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Assisted Migration Agent API
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: v2
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
16
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
17
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
18
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
19
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
20
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
21
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
+
exports.ImageUpgradeApi = void 0;
|
|
26
|
+
const runtime = require("../runtime.js");
|
|
27
|
+
/**
|
|
28
|
+
*
|
|
29
|
+
*/
|
|
30
|
+
class ImageUpgradeApi extends runtime.BaseAPI {
|
|
31
|
+
/**
|
|
32
|
+
* Creates request options for postImageUpgrade without sending the request
|
|
33
|
+
*/
|
|
34
|
+
postImageUpgradeRequestOpts(requestParameters) {
|
|
35
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
36
|
+
if (requestParameters['file'] == null) {
|
|
37
|
+
throw new runtime.RequiredError('file', 'Required parameter "file" was null or undefined when calling postImageUpgrade().');
|
|
38
|
+
}
|
|
39
|
+
const queryParameters = {};
|
|
40
|
+
const headerParameters = {};
|
|
41
|
+
const consumes = [
|
|
42
|
+
{ contentType: 'multipart/form-data' },
|
|
43
|
+
];
|
|
44
|
+
// @ts-ignore: canConsumeForm may be unused
|
|
45
|
+
const canConsumeForm = runtime.canConsumeForm(consumes);
|
|
46
|
+
let formParams;
|
|
47
|
+
let useForm = false;
|
|
48
|
+
// use FormData to transmit files using content-type "multipart/form-data"
|
|
49
|
+
useForm = canConsumeForm;
|
|
50
|
+
if (useForm) {
|
|
51
|
+
formParams = new FormData();
|
|
52
|
+
}
|
|
53
|
+
else {
|
|
54
|
+
formParams = new URLSearchParams();
|
|
55
|
+
}
|
|
56
|
+
if (requestParameters['file'] != null) {
|
|
57
|
+
formParams.append('file', requestParameters['file']);
|
|
58
|
+
}
|
|
59
|
+
let urlPath = `/image-upgrades`;
|
|
60
|
+
return {
|
|
61
|
+
path: urlPath,
|
|
62
|
+
method: 'POST',
|
|
63
|
+
headers: headerParameters,
|
|
64
|
+
query: queryParameters,
|
|
65
|
+
body: formParams,
|
|
66
|
+
};
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
71
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
72
|
+
*/
|
|
73
|
+
postImageUpgradeRaw(requestParameters, initOverrides) {
|
|
74
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
75
|
+
const requestOptions = yield this.postImageUpgradeRequestOpts(requestParameters);
|
|
76
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
77
|
+
return new runtime.VoidApiResponse(response);
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
82
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
83
|
+
*/
|
|
84
|
+
postImageUpgrade(requestParameters, initOverrides) {
|
|
85
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
86
|
+
yield this.postImageUpgradeRaw(requestParameters, initOverrides);
|
|
87
|
+
});
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
exports.ImageUpgradeApi = ImageUpgradeApi;
|
|
@@ -81,7 +81,7 @@ export interface ListLatestVirtualMachinesRequest {
|
|
|
81
81
|
*/
|
|
82
82
|
byExpression?: string;
|
|
83
83
|
/**
|
|
84
|
-
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
84
|
+
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
85
85
|
*/
|
|
86
86
|
sort?: Array<string>;
|
|
87
87
|
/**
|
|
@@ -103,7 +103,7 @@ export interface ListVirtualMachinesRequest {
|
|
|
103
103
|
*/
|
|
104
104
|
byExpression?: string;
|
|
105
105
|
/**
|
|
106
|
-
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
106
|
+
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
107
107
|
*/
|
|
108
108
|
sort?: Array<string>;
|
|
109
109
|
/**
|
|
@@ -345,7 +345,7 @@ export interface VirtualMachinesApiInterface {
|
|
|
345
345
|
/**
|
|
346
346
|
* Creates request options for listLatestVirtualMachines without sending the request
|
|
347
347
|
* @param {string} [byExpression] Filter by expression
|
|
348
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
348
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
349
349
|
* @param {number} [page] Page number for pagination
|
|
350
350
|
* @param {number} [pageSize] Number of items per page
|
|
351
351
|
* @throws {RequiredError}
|
|
@@ -356,7 +356,7 @@ export interface VirtualMachinesApiInterface {
|
|
|
356
356
|
*
|
|
357
357
|
* @summary List VirtualMachines from the latest collection
|
|
358
358
|
* @param {string} [byExpression] Filter by expression
|
|
359
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
359
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
360
360
|
* @param {number} [page] Page number for pagination
|
|
361
361
|
* @param {number} [pageSize] Number of items per page
|
|
362
362
|
* @param {*} [options] Override http request option.
|
|
@@ -372,7 +372,7 @@ export interface VirtualMachinesApiInterface {
|
|
|
372
372
|
* Creates request options for listVirtualMachines without sending the request
|
|
373
373
|
* @param {string} id Collection ID
|
|
374
374
|
* @param {string} [byExpression] Filter by expression
|
|
375
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
375
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
376
376
|
* @param {number} [page] Page number for pagination
|
|
377
377
|
* @param {number} [pageSize] Number of items per page
|
|
378
378
|
* @throws {RequiredError}
|
|
@@ -384,7 +384,7 @@ export interface VirtualMachinesApiInterface {
|
|
|
384
384
|
* @summary List VirtualMachines in a collection
|
|
385
385
|
* @param {string} id Collection ID
|
|
386
386
|
* @param {string} [byExpression] Filter by expression
|
|
387
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
387
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
388
388
|
* @param {number} [page] Page number for pagination
|
|
389
389
|
* @param {number} [pageSize] Number of items per page
|
|
390
390
|
* @param {*} [options] Override http request option.
|
package/dist/apis/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export * from './CollectorApi.js';
|
|
|
6
6
|
export * from './CredentialsApi.js';
|
|
7
7
|
export * from './ForecasterApi.js';
|
|
8
8
|
export * from './GroupsApi.js';
|
|
9
|
+
export * from './ImageUpgradeApi.js';
|
|
9
10
|
export * from './InspectorApi.js';
|
|
10
11
|
export * from './InventoriesApi.js';
|
|
11
12
|
export * from './RightsizingApi.js';
|
package/dist/apis/index.js
CHANGED
|
@@ -24,6 +24,7 @@ __exportStar(require("./CollectorApi.js"), exports);
|
|
|
24
24
|
__exportStar(require("./CredentialsApi.js"), exports);
|
|
25
25
|
__exportStar(require("./ForecasterApi.js"), exports);
|
|
26
26
|
__exportStar(require("./GroupsApi.js"), exports);
|
|
27
|
+
__exportStar(require("./ImageUpgradeApi.js"), exports);
|
|
27
28
|
__exportStar(require("./InspectorApi.js"), exports);
|
|
28
29
|
__exportStar(require("./InventoriesApi.js"), exports);
|
|
29
30
|
__exportStar(require("./RightsizingApi.js"), exports);
|
|
@@ -39,7 +39,7 @@ export interface GetGroupRequest {
|
|
|
39
39
|
*/
|
|
40
40
|
groupId: string;
|
|
41
41
|
/**
|
|
42
|
-
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
42
|
+
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
43
43
|
*/
|
|
44
44
|
sort?: Array<string>;
|
|
45
45
|
/**
|
|
@@ -57,7 +57,7 @@ export interface GetLatestGroupRequest {
|
|
|
57
57
|
*/
|
|
58
58
|
groupId: string;
|
|
59
59
|
/**
|
|
60
|
-
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
60
|
+
* Sort fields with direction (e.g., "name:asc", "cluster:desc"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
61
61
|
*/
|
|
62
62
|
sort?: Array<string>;
|
|
63
63
|
/**
|
|
@@ -174,7 +174,7 @@ export interface GroupsApiInterface {
|
|
|
174
174
|
* Creates request options for getGroup without sending the request
|
|
175
175
|
* @param {string} id Collection ID
|
|
176
176
|
* @param {string} groupId Group ID
|
|
177
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
177
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
178
178
|
* @param {number} [page] Page number for pagination
|
|
179
179
|
* @param {number} [pageSize] Number of items per page
|
|
180
180
|
* @throws {RequiredError}
|
|
@@ -186,7 +186,7 @@ export interface GroupsApiInterface {
|
|
|
186
186
|
* @summary Get group by ID with its VirtualMachines
|
|
187
187
|
* @param {string} id Collection ID
|
|
188
188
|
* @param {string} groupId Group ID
|
|
189
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
189
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
190
190
|
* @param {number} [page] Page number for pagination
|
|
191
191
|
* @param {number} [pageSize] Number of items per page
|
|
192
192
|
* @param {*} [options] Override http request option.
|
|
@@ -201,7 +201,7 @@ export interface GroupsApiInterface {
|
|
|
201
201
|
/**
|
|
202
202
|
* Creates request options for getLatestGroup without sending the request
|
|
203
203
|
* @param {string} groupId Group ID
|
|
204
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
204
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
205
205
|
* @param {number} [page] Page number for pagination
|
|
206
206
|
* @param {number} [pageSize] Number of items per page
|
|
207
207
|
* @throws {RequiredError}
|
|
@@ -212,7 +212,7 @@ export interface GroupsApiInterface {
|
|
|
212
212
|
*
|
|
213
213
|
* @summary Get group by ID from the latest collection
|
|
214
214
|
* @param {string} groupId Group ID
|
|
215
|
-
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg.
|
|
215
|
+
* @param {Array<string>} [sort] Sort fields with direction (e.g., \"name:asc\", \"cluster:desc\"). Valid fields are name, vCenterState, cluster, diskSize, memory, issues, cpuUsage, diskUsage, ramUsage, cpuAvg, memAvg, guestOs.
|
|
216
216
|
* @param {number} [page] Page number for pagination
|
|
217
217
|
* @param {number} [pageSize] Number of items per page
|
|
218
218
|
* @param {*} [options] Override http request option.
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Assisted Migration Agent API
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: v2
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import * as runtime from '../runtime.js';
|
|
13
|
+
export interface PostImageUpgradeRequest {
|
|
14
|
+
/**
|
|
15
|
+
* OCI archive; maximum file payload is 3 GiB
|
|
16
|
+
*/
|
|
17
|
+
file: Blob;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* ImageUpgradeApi - interface
|
|
21
|
+
*
|
|
22
|
+
* @export
|
|
23
|
+
* @interface ImageUpgradeApiInterface
|
|
24
|
+
*/
|
|
25
|
+
export interface ImageUpgradeApiInterface {
|
|
26
|
+
/**
|
|
27
|
+
* Creates request options for postImageUpgrade without sending the request
|
|
28
|
+
* @param {Blob} file OCI archive; maximum file payload is 3 GiB
|
|
29
|
+
* @throws {RequiredError}
|
|
30
|
+
* @memberof ImageUpgradeApiInterface
|
|
31
|
+
*/
|
|
32
|
+
postImageUpgradeRequestOpts(requestParameters: PostImageUpgradeRequest): Promise<runtime.RequestOpts>;
|
|
33
|
+
/**
|
|
34
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
35
|
+
* @summary Upload an OCI image for a disconnected appliance image upgrade
|
|
36
|
+
* @param {Blob} file OCI archive; maximum file payload is 3 GiB
|
|
37
|
+
* @param {*} [options] Override http request option.
|
|
38
|
+
* @throws {RequiredError}
|
|
39
|
+
* @memberof ImageUpgradeApiInterface
|
|
40
|
+
*/
|
|
41
|
+
postImageUpgradeRaw(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
42
|
+
/**
|
|
43
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
44
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
45
|
+
*/
|
|
46
|
+
postImageUpgrade(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
*/
|
|
51
|
+
export declare class ImageUpgradeApi extends runtime.BaseAPI implements ImageUpgradeApiInterface {
|
|
52
|
+
/**
|
|
53
|
+
* Creates request options for postImageUpgrade without sending the request
|
|
54
|
+
*/
|
|
55
|
+
postImageUpgradeRequestOpts(requestParameters: PostImageUpgradeRequest): Promise<runtime.RequestOpts>;
|
|
56
|
+
/**
|
|
57
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
58
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
59
|
+
*/
|
|
60
|
+
postImageUpgradeRaw(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
61
|
+
/**
|
|
62
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
63
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
64
|
+
*/
|
|
65
|
+
postImageUpgrade(requestParameters: PostImageUpgradeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
66
|
+
}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Assisted Migration Agent API
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: v2
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
15
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
16
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
17
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
18
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
19
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
20
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
import * as runtime from '../runtime.js';
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
export class ImageUpgradeApi extends runtime.BaseAPI {
|
|
28
|
+
/**
|
|
29
|
+
* Creates request options for postImageUpgrade without sending the request
|
|
30
|
+
*/
|
|
31
|
+
postImageUpgradeRequestOpts(requestParameters) {
|
|
32
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
33
|
+
if (requestParameters['file'] == null) {
|
|
34
|
+
throw new runtime.RequiredError('file', 'Required parameter "file" was null or undefined when calling postImageUpgrade().');
|
|
35
|
+
}
|
|
36
|
+
const queryParameters = {};
|
|
37
|
+
const headerParameters = {};
|
|
38
|
+
const consumes = [
|
|
39
|
+
{ contentType: 'multipart/form-data' },
|
|
40
|
+
];
|
|
41
|
+
// @ts-ignore: canConsumeForm may be unused
|
|
42
|
+
const canConsumeForm = runtime.canConsumeForm(consumes);
|
|
43
|
+
let formParams;
|
|
44
|
+
let useForm = false;
|
|
45
|
+
// use FormData to transmit files using content-type "multipart/form-data"
|
|
46
|
+
useForm = canConsumeForm;
|
|
47
|
+
if (useForm) {
|
|
48
|
+
formParams = new FormData();
|
|
49
|
+
}
|
|
50
|
+
else {
|
|
51
|
+
formParams = new URLSearchParams();
|
|
52
|
+
}
|
|
53
|
+
if (requestParameters['file'] != null) {
|
|
54
|
+
formParams.append('file', requestParameters['file']);
|
|
55
|
+
}
|
|
56
|
+
let urlPath = `/image-upgrades`;
|
|
57
|
+
return {
|
|
58
|
+
path: urlPath,
|
|
59
|
+
method: 'POST',
|
|
60
|
+
headers: headerParameters,
|
|
61
|
+
query: queryParameters,
|
|
62
|
+
body: formParams,
|
|
63
|
+
};
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
68
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
69
|
+
*/
|
|
70
|
+
postImageUpgradeRaw(requestParameters, initOverrides) {
|
|
71
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
72
|
+
const requestOptions = yield this.postImageUpgradeRequestOpts(requestParameters);
|
|
73
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
74
|
+
return new runtime.VoidApiResponse(response);
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Validate the complete upload and atomically place the archive in the watched directory. The host owns upgrade execution. Read imageUpgradeStatus in GET /agent for upload activity and the last host result.
|
|
79
|
+
* Upload an OCI image for a disconnected appliance image upgrade
|
|
80
|
+
*/
|
|
81
|
+
postImageUpgrade(requestParameters, initOverrides) {
|
|
82
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
83
|
+
yield this.postImageUpgradeRaw(requestParameters, initOverrides);
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
}
|