oci-visualbuilder 2.11.1
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/LICENSE.txt +89 -0
- package/NOTICE.txt +1 -0
- package/README.md +22 -0
- package/THIRD_PARTY_LICENSES.txt +1521 -0
- package/index.d.ts +24 -0
- package/index.js +47 -0
- package/index.js.map +1 -0
- package/lib/client.d.ts +196 -0
- package/lib/client.js +984 -0
- package/lib/client.js.map +1 -0
- package/lib/model/application-summary-collection.d.ts +28 -0
- package/lib/model/application-summary-collection.js +63 -0
- package/lib/model/application-summary-collection.js.map +1 -0
- package/lib/model/application-summary.d.ts +48 -0
- package/lib/model/application-summary.js +41 -0
- package/lib/model/application-summary.js.map +1 -0
- package/lib/model/change-vb-instance-compartment-details.d.ts +27 -0
- package/lib/model/change-vb-instance-compartment-details.js +31 -0
- package/lib/model/change-vb-instance-compartment-details.js.map +1 -0
- package/lib/model/create-custom-endpoint-details.d.ts +34 -0
- package/lib/model/create-custom-endpoint-details.js +31 -0
- package/lib/model/create-custom-endpoint-details.js.map +1 -0
- package/lib/model/create-vb-instance-details.d.ts +80 -0
- package/lib/model/create-vb-instance-details.js +75 -0
- package/lib/model/create-vb-instance-details.js.map +1 -0
- package/lib/model/custom-endpoint-details.d.ts +37 -0
- package/lib/model/custom-endpoint-details.js +31 -0
- package/lib/model/custom-endpoint-details.js.map +1 -0
- package/lib/model/index.d.ts +54 -0
- package/lib/model/index.js +77 -0
- package/lib/model/index.js.map +1 -0
- package/lib/model/request-summarized-applications-details.d.ts +27 -0
- package/lib/model/request-summarized-applications-details.js +31 -0
- package/lib/model/request-summarized-applications-details.js.map +1 -0
- package/lib/model/update-custom-endpoint-details.d.ts +34 -0
- package/lib/model/update-custom-endpoint-details.js +31 -0
- package/lib/model/update-custom-endpoint-details.js.map +1 -0
- package/lib/model/update-vb-instance-details.d.ts +67 -0
- package/lib/model/update-vb-instance-details.js +69 -0
- package/lib/model/update-vb-instance-details.js.map +1 -0
- package/lib/model/vb-instance-summary-collection.d.ts +28 -0
- package/lib/model/vb-instance-summary-collection.js +63 -0
- package/lib/model/vb-instance-summary-collection.js.map +1 -0
- package/lib/model/vb-instance-summary.d.ts +126 -0
- package/lib/model/vb-instance-summary.js +95 -0
- package/lib/model/vb-instance-summary.js.map +1 -0
- package/lib/model/vb-instance.d.ts +126 -0
- package/lib/model/vb-instance.js +95 -0
- package/lib/model/vb-instance.js.map +1 -0
- package/lib/model/work-request-error-collection.d.ts +28 -0
- package/lib/model/work-request-error-collection.js +63 -0
- package/lib/model/work-request-error-collection.js.map +1 -0
- package/lib/model/work-request-error.d.ts +35 -0
- package/lib/model/work-request-error.js +31 -0
- package/lib/model/work-request-error.js.map +1 -0
- package/lib/model/work-request-log-entry-collection.d.ts +28 -0
- package/lib/model/work-request-log-entry-collection.js +63 -0
- package/lib/model/work-request-log-entry-collection.js.map +1 -0
- package/lib/model/work-request-log-entry.d.ts +31 -0
- package/lib/model/work-request-log-entry.js +31 -0
- package/lib/model/work-request-log-entry.js.map +1 -0
- package/lib/model/work-request-resource.d.ts +57 -0
- package/lib/model/work-request-resource.js +45 -0
- package/lib/model/work-request-resource.js.map +1 -0
- package/lib/model/work-request-summary-collection.d.ts +28 -0
- package/lib/model/work-request-summary-collection.js +63 -0
- package/lib/model/work-request-summary-collection.js.map +1 -0
- package/lib/model/work-request-summary.d.ts +98 -0
- package/lib/model/work-request-summary.js +90 -0
- package/lib/model/work-request-summary.js.map +1 -0
- package/lib/model/work-request.d.ts +98 -0
- package/lib/model/work-request.js +90 -0
- package/lib/model/work-request.js.map +1 -0
- package/lib/request/change-vb-instance-compartment-request.d.ts +50 -0
- package/lib/request/change-vb-instance-compartment-request.js +15 -0
- package/lib/request/change-vb-instance-compartment-request.js.map +1 -0
- package/lib/request/create-vb-instance-request.d.ts +37 -0
- package/lib/request/create-vb-instance-request.js +15 -0
- package/lib/request/create-vb-instance-request.js.map +1 -0
- package/lib/request/delete-vb-instance-request.d.ts +35 -0
- package/lib/request/delete-vb-instance-request.js +15 -0
- package/lib/request/delete-vb-instance-request.js.map +1 -0
- package/lib/request/get-vb-instance-request.d.ts +26 -0
- package/lib/request/get-vb-instance-request.js +15 -0
- package/lib/request/get-vb-instance-request.js.map +1 -0
- package/lib/request/get-work-request-request.d.ts +26 -0
- package/lib/request/get-work-request-request.js +15 -0
- package/lib/request/get-work-request-request.js.map +1 -0
- package/lib/request/index.d.ts +40 -0
- package/lib/request/index.js +39 -0
- package/lib/request/index.js.map +1 -0
- package/lib/request/list-vb-instances-request.d.ts +75 -0
- package/lib/request/list-vb-instances-request.js +39 -0
- package/lib/request/list-vb-instances-request.js.map +1 -0
- package/lib/request/list-work-request-errors-request.d.ts +38 -0
- package/lib/request/list-work-request-errors-request.js +15 -0
- package/lib/request/list-work-request-errors-request.js.map +1 -0
- package/lib/request/list-work-request-logs-request.d.ts +38 -0
- package/lib/request/list-work-request-logs-request.js +15 -0
- package/lib/request/list-work-request-logs-request.js.map +1 -0
- package/lib/request/list-work-requests-request.d.ts +38 -0
- package/lib/request/list-work-requests-request.js +15 -0
- package/lib/request/list-work-requests-request.js.map +1 -0
- package/lib/request/request-summarized-applications-request.d.ts +50 -0
- package/lib/request/request-summarized-applications-request.js +15 -0
- package/lib/request/request-summarized-applications-request.js.map +1 -0
- package/lib/request/start-vb-instance-request.d.ts +45 -0
- package/lib/request/start-vb-instance-request.js +15 -0
- package/lib/request/start-vb-instance-request.js.map +1 -0
- package/lib/request/stop-vb-instance-request.d.ts +45 -0
- package/lib/request/stop-vb-instance-request.js +15 -0
- package/lib/request/stop-vb-instance-request.js.map +1 -0
- package/lib/request/update-vb-instance-request.d.ts +40 -0
- package/lib/request/update-vb-instance-request.js +15 -0
- package/lib/request/update-vb-instance-request.js.map +1 -0
- package/lib/response/change-vb-instance-compartment-response.d.ts +27 -0
- package/lib/response/change-vb-instance-compartment-response.js +15 -0
- package/lib/response/change-vb-instance-compartment-response.js.map +1 -0
- package/lib/response/create-vb-instance-response.d.ts +27 -0
- package/lib/response/create-vb-instance-response.js +15 -0
- package/lib/response/create-vb-instance-response.js.map +1 -0
- package/lib/response/delete-vb-instance-response.d.ts +27 -0
- package/lib/response/delete-vb-instance-response.js +15 -0
- package/lib/response/delete-vb-instance-response.js.map +1 -0
- package/lib/response/get-vb-instance-response.d.ts +30 -0
- package/lib/response/get-vb-instance-response.js +15 -0
- package/lib/response/get-vb-instance-response.js.map +1 -0
- package/lib/response/get-work-request-response.d.ts +34 -0
- package/lib/response/get-work-request-response.js +15 -0
- package/lib/response/get-work-request-response.js.map +1 -0
- package/lib/response/index.d.ts +40 -0
- package/lib/response/index.js +17 -0
- package/lib/response/index.js.map +1 -0
- package/lib/response/list-vb-instances-response.d.ts +36 -0
- package/lib/response/list-vb-instances-response.js +15 -0
- package/lib/response/list-vb-instances-response.js.map +1 -0
- package/lib/response/list-work-request-errors-response.d.ts +35 -0
- package/lib/response/list-work-request-errors-response.js +15 -0
- package/lib/response/list-work-request-errors-response.js.map +1 -0
- package/lib/response/list-work-request-logs-response.d.ts +35 -0
- package/lib/response/list-work-request-logs-response.js +15 -0
- package/lib/response/list-work-request-logs-response.js.map +1 -0
- package/lib/response/list-work-requests-response.d.ts +36 -0
- package/lib/response/list-work-requests-response.js +15 -0
- package/lib/response/list-work-requests-response.js.map +1 -0
- package/lib/response/request-summarized-applications-response.d.ts +30 -0
- package/lib/response/request-summarized-applications-response.js +15 -0
- package/lib/response/request-summarized-applications-response.js.map +1 -0
- package/lib/response/start-vb-instance-response.d.ts +27 -0
- package/lib/response/start-vb-instance-response.js +15 -0
- package/lib/response/start-vb-instance-response.js.map +1 -0
- package/lib/response/stop-vb-instance-response.d.ts +27 -0
- package/lib/response/stop-vb-instance-response.js +15 -0
- package/lib/response/stop-vb-instance-response.js.map +1 -0
- package/lib/response/update-vb-instance-response.d.ts +27 -0
- package/lib/response/update-vb-instance-response.js +15 -0
- package/lib/response/update-vb-instance-response.js.map +1 -0
- package/lib/vbinstance-waiter.d.ts +38 -0
- package/lib/vbinstance-waiter.js +78 -0
- package/lib/vbinstance-waiter.js.map +1 -0
- package/package.json +29 -0
package/lib/client.js
ADDED
|
@@ -0,0 +1,984 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Visual Builder API
|
|
4
|
+
* Oracle Visual Builder enables developers to quickly build web and mobile applications. With a visual development environment that makes it easy to connect to Oracle data and third-party REST services, developers can build modern, consumer-grade applications in a fraction of the time it would take in other tools.
|
|
5
|
+
The Visual Builder Instance Management API allows users to create and manage a Visual Builder instance.
|
|
6
|
+
|
|
7
|
+
* OpenAPI spec version: 20210601
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OracleSDKGenerator.
|
|
11
|
+
* Do not edit the class manually.
|
|
12
|
+
*
|
|
13
|
+
* Copyright (c) 2020, 2022, Oracle and/or its affiliates. All rights reserved.
|
|
14
|
+
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
|
15
|
+
*/
|
|
16
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
17
|
+
if (k2 === undefined) k2 = k;
|
|
18
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
19
|
+
}) : (function(o, m, k, k2) {
|
|
20
|
+
if (k2 === undefined) k2 = k;
|
|
21
|
+
o[k2] = m[k];
|
|
22
|
+
}));
|
|
23
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
24
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
25
|
+
}) : function(o, v) {
|
|
26
|
+
o["default"] = v;
|
|
27
|
+
});
|
|
28
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
36
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
37
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
38
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
39
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
40
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
41
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
42
|
+
});
|
|
43
|
+
};
|
|
44
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
45
|
+
exports.VbInstanceClient = exports.VbInstanceApiKeys = void 0;
|
|
46
|
+
const common = require("oci-common");
|
|
47
|
+
const model = __importStar(require("./model"));
|
|
48
|
+
const vbinstance_waiter_1 = require("./vbinstance-waiter");
|
|
49
|
+
const oci_common_1 = require("oci-common");
|
|
50
|
+
// ===============================================
|
|
51
|
+
// This file is autogenerated - Please do not edit
|
|
52
|
+
// ===============================================
|
|
53
|
+
var VbInstanceApiKeys;
|
|
54
|
+
(function (VbInstanceApiKeys) {
|
|
55
|
+
})(VbInstanceApiKeys = exports.VbInstanceApiKeys || (exports.VbInstanceApiKeys = {}));
|
|
56
|
+
/**
|
|
57
|
+
* This service client uses {@link common.CircuitBreaker.DefaultConfiguration} for all the operations by default if no circuit breaker configuration is defined by the user.
|
|
58
|
+
*/
|
|
59
|
+
class VbInstanceClient {
|
|
60
|
+
constructor(params, clientConfiguration) {
|
|
61
|
+
this["_endpoint"] = "";
|
|
62
|
+
this["_defaultHeaders"] = {};
|
|
63
|
+
this._circuitBreaker = null;
|
|
64
|
+
const requestSigner = params.authenticationDetailsProvider
|
|
65
|
+
? new common.DefaultRequestSigner(params.authenticationDetailsProvider)
|
|
66
|
+
: null;
|
|
67
|
+
if (clientConfiguration) {
|
|
68
|
+
this._clientConfiguration = clientConfiguration;
|
|
69
|
+
this._circuitBreaker = clientConfiguration.circuitBreaker
|
|
70
|
+
? clientConfiguration.circuitBreaker.circuit
|
|
71
|
+
: null;
|
|
72
|
+
}
|
|
73
|
+
// if circuit breaker is not created, check if circuit breaker system is enabled to use default circuit breaker
|
|
74
|
+
const specCircuitBreakerEnabled = true;
|
|
75
|
+
if (!this._circuitBreaker &&
|
|
76
|
+
common.utils.isCircuitBreakerSystemEnabled(clientConfiguration) &&
|
|
77
|
+
(specCircuitBreakerEnabled || common.CircuitBreaker.DefaultCircuitBreakerOverriden)) {
|
|
78
|
+
this._circuitBreaker = new common.CircuitBreaker().circuit;
|
|
79
|
+
}
|
|
80
|
+
this._httpClient =
|
|
81
|
+
params.httpClient || new common.FetchHttpClient(requestSigner, this._circuitBreaker);
|
|
82
|
+
if (params.authenticationDetailsProvider &&
|
|
83
|
+
common.isRegionProvider(params.authenticationDetailsProvider)) {
|
|
84
|
+
const provider = params.authenticationDetailsProvider;
|
|
85
|
+
if (provider.getRegion()) {
|
|
86
|
+
this.region = provider.getRegion();
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* Get the endpoint that is being used to call (ex, https://www.example.com).
|
|
92
|
+
*/
|
|
93
|
+
get endpoint() {
|
|
94
|
+
return this._endpoint;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Sets the endpoint to call (ex, https://www.example.com).
|
|
98
|
+
* @param endpoint The endpoint of the service.
|
|
99
|
+
*/
|
|
100
|
+
set endpoint(endpoint) {
|
|
101
|
+
this._endpoint = endpoint;
|
|
102
|
+
this._endpoint = this._endpoint + "/20210601";
|
|
103
|
+
if (this.logger)
|
|
104
|
+
this.logger.info(`VbInstanceClient endpoint set to ${this._endpoint}`);
|
|
105
|
+
}
|
|
106
|
+
get logger() {
|
|
107
|
+
return common.LOG.logger;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* Sets the region to call (ex, Region.US_PHOENIX_1).
|
|
111
|
+
* Note, this will call {@link #endpoint(String) endpoint} after resolving the endpoint.
|
|
112
|
+
* @param region The region of the service.
|
|
113
|
+
*/
|
|
114
|
+
set region(region) {
|
|
115
|
+
this.endpoint = common.EndpointBuilder.createEndpointFromRegion(VbInstanceClient.serviceEndpointTemplate, region);
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* Sets the regionId to call (ex, 'us-phoenix-1').
|
|
119
|
+
*
|
|
120
|
+
* Note, this will first try to map the region ID to a known Region and call {@link #region(Region) region}.
|
|
121
|
+
* If no known Region could be determined, it will create an endpoint assuming its in default Realm OC1
|
|
122
|
+
* and then call {@link #endpoint(String) endpoint}.
|
|
123
|
+
* @param regionId The public region ID.
|
|
124
|
+
*/
|
|
125
|
+
set regionId(regionId) {
|
|
126
|
+
this.endpoint = common.EndpointBuilder.createEndpointFromRegionId(VbInstanceClient.serviceEndpointTemplate, regionId);
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Creates a new VbInstanceWaiter for resources for this service.
|
|
130
|
+
*
|
|
131
|
+
* @param config The waiter configuration for termination and delay strategy
|
|
132
|
+
* @return The service waiters.
|
|
133
|
+
*/
|
|
134
|
+
createWaiters(config) {
|
|
135
|
+
this._waiters = new vbinstance_waiter_1.VbInstanceWaiter(this, config);
|
|
136
|
+
return this._waiters;
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Gets the waiters available for resources for this service.
|
|
140
|
+
*
|
|
141
|
+
* @return The service waiters.
|
|
142
|
+
*/
|
|
143
|
+
getWaiters() {
|
|
144
|
+
if (this._waiters) {
|
|
145
|
+
return this._waiters;
|
|
146
|
+
}
|
|
147
|
+
throw Error("Waiters do not exist. Please create waiters.");
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Change the compartment for an vb instance
|
|
151
|
+
*
|
|
152
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
153
|
+
* @param ChangeVbInstanceCompartmentRequest
|
|
154
|
+
* @return ChangeVbInstanceCompartmentResponse
|
|
155
|
+
* @throws OciError when an error occurs
|
|
156
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/ChangeVbInstanceCompartment.ts.html |here} to see how to use ChangeVbInstanceCompartment API.
|
|
157
|
+
*/
|
|
158
|
+
changeVbInstanceCompartment(changeVbInstanceCompartmentRequest) {
|
|
159
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
160
|
+
if (this.logger)
|
|
161
|
+
this.logger.debug("Calling operation VbInstanceClient#changeVbInstanceCompartment.");
|
|
162
|
+
const pathParams = {
|
|
163
|
+
"{vbInstanceId}": changeVbInstanceCompartmentRequest.vbInstanceId
|
|
164
|
+
};
|
|
165
|
+
const queryParams = {};
|
|
166
|
+
let headerParams = {
|
|
167
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
168
|
+
"if-match": changeVbInstanceCompartmentRequest.ifMatch,
|
|
169
|
+
"opc-request-id": changeVbInstanceCompartmentRequest.opcRequestId,
|
|
170
|
+
"opc-retry-token": changeVbInstanceCompartmentRequest.opcRetryToken
|
|
171
|
+
};
|
|
172
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
173
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, changeVbInstanceCompartmentRequest.retryConfiguration, specRetryConfiguration);
|
|
174
|
+
if (this.logger)
|
|
175
|
+
retrier.logger = this.logger;
|
|
176
|
+
const request = yield oci_common_1.composeRequest({
|
|
177
|
+
baseEndpoint: this._endpoint,
|
|
178
|
+
defaultHeaders: this._defaultHeaders,
|
|
179
|
+
path: "/vbInstances/{vbInstanceId}/actions/changeCompartment",
|
|
180
|
+
method: "POST",
|
|
181
|
+
bodyContent: common.ObjectSerializer.serialize(changeVbInstanceCompartmentRequest.changeVbInstanceCompartmentDetails, "ChangeVbInstanceCompartmentDetails", model.ChangeVbInstanceCompartmentDetails.getJsonObj),
|
|
182
|
+
pathParams: pathParams,
|
|
183
|
+
headerParams: headerParams,
|
|
184
|
+
queryParams: queryParams
|
|
185
|
+
});
|
|
186
|
+
try {
|
|
187
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
188
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
189
|
+
responseObject: {},
|
|
190
|
+
responseHeaders: [
|
|
191
|
+
{
|
|
192
|
+
value: response.headers.get("opc-work-request-id"),
|
|
193
|
+
key: "opcWorkRequestId",
|
|
194
|
+
dataType: "string"
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
value: response.headers.get("opc-request-id"),
|
|
198
|
+
key: "opcRequestId",
|
|
199
|
+
dataType: "string"
|
|
200
|
+
}
|
|
201
|
+
]
|
|
202
|
+
});
|
|
203
|
+
return sdkResponse;
|
|
204
|
+
}
|
|
205
|
+
catch (err) {
|
|
206
|
+
throw err;
|
|
207
|
+
}
|
|
208
|
+
});
|
|
209
|
+
}
|
|
210
|
+
/**
|
|
211
|
+
* Creates a new Vb Instance.
|
|
212
|
+
*
|
|
213
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
214
|
+
* @param CreateVbInstanceRequest
|
|
215
|
+
* @return CreateVbInstanceResponse
|
|
216
|
+
* @throws OciError when an error occurs
|
|
217
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/CreateVbInstance.ts.html |here} to see how to use CreateVbInstance API.
|
|
218
|
+
*/
|
|
219
|
+
createVbInstance(createVbInstanceRequest) {
|
|
220
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
221
|
+
if (this.logger)
|
|
222
|
+
this.logger.debug("Calling operation VbInstanceClient#createVbInstance.");
|
|
223
|
+
const pathParams = {};
|
|
224
|
+
const queryParams = {};
|
|
225
|
+
let headerParams = {
|
|
226
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
227
|
+
"opc-retry-token": createVbInstanceRequest.opcRetryToken,
|
|
228
|
+
"opc-request-id": createVbInstanceRequest.opcRequestId
|
|
229
|
+
};
|
|
230
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
231
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, createVbInstanceRequest.retryConfiguration, specRetryConfiguration);
|
|
232
|
+
if (this.logger)
|
|
233
|
+
retrier.logger = this.logger;
|
|
234
|
+
const request = yield oci_common_1.composeRequest({
|
|
235
|
+
baseEndpoint: this._endpoint,
|
|
236
|
+
defaultHeaders: this._defaultHeaders,
|
|
237
|
+
path: "/vbInstances",
|
|
238
|
+
method: "POST",
|
|
239
|
+
bodyContent: common.ObjectSerializer.serialize(createVbInstanceRequest.createVbInstanceDetails, "CreateVbInstanceDetails", model.CreateVbInstanceDetails.getJsonObj),
|
|
240
|
+
pathParams: pathParams,
|
|
241
|
+
headerParams: headerParams,
|
|
242
|
+
queryParams: queryParams
|
|
243
|
+
});
|
|
244
|
+
try {
|
|
245
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
246
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
247
|
+
responseObject: {},
|
|
248
|
+
responseHeaders: [
|
|
249
|
+
{
|
|
250
|
+
value: response.headers.get("opc-work-request-id"),
|
|
251
|
+
key: "opcWorkRequestId",
|
|
252
|
+
dataType: "string"
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
value: response.headers.get("opc-request-id"),
|
|
256
|
+
key: "opcRequestId",
|
|
257
|
+
dataType: "string"
|
|
258
|
+
}
|
|
259
|
+
]
|
|
260
|
+
});
|
|
261
|
+
return sdkResponse;
|
|
262
|
+
}
|
|
263
|
+
catch (err) {
|
|
264
|
+
throw err;
|
|
265
|
+
}
|
|
266
|
+
});
|
|
267
|
+
}
|
|
268
|
+
/**
|
|
269
|
+
* Deletes an Vb Instance resource by identifier.
|
|
270
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
271
|
+
* @param DeleteVbInstanceRequest
|
|
272
|
+
* @return DeleteVbInstanceResponse
|
|
273
|
+
* @throws OciError when an error occurs
|
|
274
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/DeleteVbInstance.ts.html |here} to see how to use DeleteVbInstance API.
|
|
275
|
+
*/
|
|
276
|
+
deleteVbInstance(deleteVbInstanceRequest) {
|
|
277
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
278
|
+
if (this.logger)
|
|
279
|
+
this.logger.debug("Calling operation VbInstanceClient#deleteVbInstance.");
|
|
280
|
+
const pathParams = {
|
|
281
|
+
"{vbInstanceId}": deleteVbInstanceRequest.vbInstanceId
|
|
282
|
+
};
|
|
283
|
+
const queryParams = {};
|
|
284
|
+
let headerParams = {
|
|
285
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
286
|
+
"if-match": deleteVbInstanceRequest.ifMatch,
|
|
287
|
+
"opc-request-id": deleteVbInstanceRequest.opcRequestId
|
|
288
|
+
};
|
|
289
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
290
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, deleteVbInstanceRequest.retryConfiguration, specRetryConfiguration);
|
|
291
|
+
if (this.logger)
|
|
292
|
+
retrier.logger = this.logger;
|
|
293
|
+
const request = yield oci_common_1.composeRequest({
|
|
294
|
+
baseEndpoint: this._endpoint,
|
|
295
|
+
defaultHeaders: this._defaultHeaders,
|
|
296
|
+
path: "/vbInstances/{vbInstanceId}",
|
|
297
|
+
method: "DELETE",
|
|
298
|
+
pathParams: pathParams,
|
|
299
|
+
headerParams: headerParams,
|
|
300
|
+
queryParams: queryParams
|
|
301
|
+
});
|
|
302
|
+
try {
|
|
303
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
304
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
305
|
+
responseObject: {},
|
|
306
|
+
responseHeaders: [
|
|
307
|
+
{
|
|
308
|
+
value: response.headers.get("opc-work-request-id"),
|
|
309
|
+
key: "opcWorkRequestId",
|
|
310
|
+
dataType: "string"
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
value: response.headers.get("opc-request-id"),
|
|
314
|
+
key: "opcRequestId",
|
|
315
|
+
dataType: "string"
|
|
316
|
+
}
|
|
317
|
+
]
|
|
318
|
+
});
|
|
319
|
+
return sdkResponse;
|
|
320
|
+
}
|
|
321
|
+
catch (err) {
|
|
322
|
+
throw err;
|
|
323
|
+
}
|
|
324
|
+
});
|
|
325
|
+
}
|
|
326
|
+
/**
|
|
327
|
+
* Gets a VbInstance by identifier
|
|
328
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
329
|
+
* @param GetVbInstanceRequest
|
|
330
|
+
* @return GetVbInstanceResponse
|
|
331
|
+
* @throws OciError when an error occurs
|
|
332
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/GetVbInstance.ts.html |here} to see how to use GetVbInstance API.
|
|
333
|
+
*/
|
|
334
|
+
getVbInstance(getVbInstanceRequest) {
|
|
335
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
336
|
+
if (this.logger)
|
|
337
|
+
this.logger.debug("Calling operation VbInstanceClient#getVbInstance.");
|
|
338
|
+
const pathParams = {
|
|
339
|
+
"{vbInstanceId}": getVbInstanceRequest.vbInstanceId
|
|
340
|
+
};
|
|
341
|
+
const queryParams = {};
|
|
342
|
+
let headerParams = {
|
|
343
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
344
|
+
"opc-request-id": getVbInstanceRequest.opcRequestId
|
|
345
|
+
};
|
|
346
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
347
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, getVbInstanceRequest.retryConfiguration, specRetryConfiguration);
|
|
348
|
+
if (this.logger)
|
|
349
|
+
retrier.logger = this.logger;
|
|
350
|
+
const request = yield oci_common_1.composeRequest({
|
|
351
|
+
baseEndpoint: this._endpoint,
|
|
352
|
+
defaultHeaders: this._defaultHeaders,
|
|
353
|
+
path: "/vbInstances/{vbInstanceId}",
|
|
354
|
+
method: "GET",
|
|
355
|
+
pathParams: pathParams,
|
|
356
|
+
headerParams: headerParams,
|
|
357
|
+
queryParams: queryParams
|
|
358
|
+
});
|
|
359
|
+
try {
|
|
360
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
361
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
362
|
+
responseObject: {},
|
|
363
|
+
body: yield response.json(),
|
|
364
|
+
bodyKey: "vbInstance",
|
|
365
|
+
bodyModel: model.VbInstance,
|
|
366
|
+
type: "model.VbInstance",
|
|
367
|
+
responseHeaders: [
|
|
368
|
+
{
|
|
369
|
+
value: response.headers.get("etag"),
|
|
370
|
+
key: "etag",
|
|
371
|
+
dataType: "string"
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
value: response.headers.get("opc-request-id"),
|
|
375
|
+
key: "opcRequestId",
|
|
376
|
+
dataType: "string"
|
|
377
|
+
}
|
|
378
|
+
]
|
|
379
|
+
});
|
|
380
|
+
return sdkResponse;
|
|
381
|
+
}
|
|
382
|
+
catch (err) {
|
|
383
|
+
throw err;
|
|
384
|
+
}
|
|
385
|
+
});
|
|
386
|
+
}
|
|
387
|
+
/**
|
|
388
|
+
* Gets the status of the work request with the given ID.
|
|
389
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
390
|
+
* @param GetWorkRequestRequest
|
|
391
|
+
* @return GetWorkRequestResponse
|
|
392
|
+
* @throws OciError when an error occurs
|
|
393
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/GetWorkRequest.ts.html |here} to see how to use GetWorkRequest API.
|
|
394
|
+
*/
|
|
395
|
+
getWorkRequest(getWorkRequestRequest) {
|
|
396
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
397
|
+
if (this.logger)
|
|
398
|
+
this.logger.debug("Calling operation VbInstanceClient#getWorkRequest.");
|
|
399
|
+
const pathParams = {
|
|
400
|
+
"{workRequestId}": getWorkRequestRequest.workRequestId
|
|
401
|
+
};
|
|
402
|
+
const queryParams = {};
|
|
403
|
+
let headerParams = {
|
|
404
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
405
|
+
"opc-request-id": getWorkRequestRequest.opcRequestId
|
|
406
|
+
};
|
|
407
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
408
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, getWorkRequestRequest.retryConfiguration, specRetryConfiguration);
|
|
409
|
+
if (this.logger)
|
|
410
|
+
retrier.logger = this.logger;
|
|
411
|
+
const request = yield oci_common_1.composeRequest({
|
|
412
|
+
baseEndpoint: this._endpoint,
|
|
413
|
+
defaultHeaders: this._defaultHeaders,
|
|
414
|
+
path: "/workRequests/{workRequestId}",
|
|
415
|
+
method: "GET",
|
|
416
|
+
pathParams: pathParams,
|
|
417
|
+
headerParams: headerParams,
|
|
418
|
+
queryParams: queryParams
|
|
419
|
+
});
|
|
420
|
+
try {
|
|
421
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
422
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
423
|
+
responseObject: {},
|
|
424
|
+
body: yield response.json(),
|
|
425
|
+
bodyKey: "workRequest",
|
|
426
|
+
bodyModel: model.WorkRequest,
|
|
427
|
+
type: "model.WorkRequest",
|
|
428
|
+
responseHeaders: [
|
|
429
|
+
{
|
|
430
|
+
value: response.headers.get("etag"),
|
|
431
|
+
key: "etag",
|
|
432
|
+
dataType: "string"
|
|
433
|
+
},
|
|
434
|
+
{
|
|
435
|
+
value: response.headers.get("opc-request-id"),
|
|
436
|
+
key: "opcRequestId",
|
|
437
|
+
dataType: "string"
|
|
438
|
+
},
|
|
439
|
+
{
|
|
440
|
+
value: response.headers.get("retry-after"),
|
|
441
|
+
key: "retryAfter",
|
|
442
|
+
dataType: "number"
|
|
443
|
+
}
|
|
444
|
+
]
|
|
445
|
+
});
|
|
446
|
+
return sdkResponse;
|
|
447
|
+
}
|
|
448
|
+
catch (err) {
|
|
449
|
+
throw err;
|
|
450
|
+
}
|
|
451
|
+
});
|
|
452
|
+
}
|
|
453
|
+
/**
|
|
454
|
+
* Returns a list of Vb Instances.
|
|
455
|
+
*
|
|
456
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
457
|
+
* @param ListVbInstancesRequest
|
|
458
|
+
* @return ListVbInstancesResponse
|
|
459
|
+
* @throws OciError when an error occurs
|
|
460
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/ListVbInstances.ts.html |here} to see how to use ListVbInstances API.
|
|
461
|
+
*/
|
|
462
|
+
listVbInstances(listVbInstancesRequest) {
|
|
463
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
464
|
+
if (this.logger)
|
|
465
|
+
this.logger.debug("Calling operation VbInstanceClient#listVbInstances.");
|
|
466
|
+
const pathParams = {};
|
|
467
|
+
const queryParams = {
|
|
468
|
+
"compartmentId": listVbInstancesRequest.compartmentId,
|
|
469
|
+
"displayName": listVbInstancesRequest.displayName,
|
|
470
|
+
"lifecycleState": listVbInstancesRequest.lifecycleState,
|
|
471
|
+
"limit": listVbInstancesRequest.limit,
|
|
472
|
+
"page": listVbInstancesRequest.page,
|
|
473
|
+
"sortOrder": listVbInstancesRequest.sortOrder,
|
|
474
|
+
"sortBy": listVbInstancesRequest.sortBy
|
|
475
|
+
};
|
|
476
|
+
let headerParams = {
|
|
477
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
478
|
+
"opc-request-id": listVbInstancesRequest.opcRequestId
|
|
479
|
+
};
|
|
480
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
481
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listVbInstancesRequest.retryConfiguration, specRetryConfiguration);
|
|
482
|
+
if (this.logger)
|
|
483
|
+
retrier.logger = this.logger;
|
|
484
|
+
const request = yield oci_common_1.composeRequest({
|
|
485
|
+
baseEndpoint: this._endpoint,
|
|
486
|
+
defaultHeaders: this._defaultHeaders,
|
|
487
|
+
path: "/vbInstances",
|
|
488
|
+
method: "GET",
|
|
489
|
+
pathParams: pathParams,
|
|
490
|
+
headerParams: headerParams,
|
|
491
|
+
queryParams: queryParams
|
|
492
|
+
});
|
|
493
|
+
try {
|
|
494
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
495
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
496
|
+
responseObject: {},
|
|
497
|
+
body: yield response.json(),
|
|
498
|
+
bodyKey: "vbInstanceSummaryCollection",
|
|
499
|
+
bodyModel: model.VbInstanceSummaryCollection,
|
|
500
|
+
type: "model.VbInstanceSummaryCollection",
|
|
501
|
+
responseHeaders: [
|
|
502
|
+
{
|
|
503
|
+
value: response.headers.get("opc-request-id"),
|
|
504
|
+
key: "opcRequestId",
|
|
505
|
+
dataType: "string"
|
|
506
|
+
},
|
|
507
|
+
{
|
|
508
|
+
value: response.headers.get("opc-next-page"),
|
|
509
|
+
key: "opcNextPage",
|
|
510
|
+
dataType: "string"
|
|
511
|
+
},
|
|
512
|
+
{
|
|
513
|
+
value: response.headers.get("opc-previous-page"),
|
|
514
|
+
key: "opcPreviousPage",
|
|
515
|
+
dataType: "string"
|
|
516
|
+
}
|
|
517
|
+
]
|
|
518
|
+
});
|
|
519
|
+
return sdkResponse;
|
|
520
|
+
}
|
|
521
|
+
catch (err) {
|
|
522
|
+
throw err;
|
|
523
|
+
}
|
|
524
|
+
});
|
|
525
|
+
}
|
|
526
|
+
/**
|
|
527
|
+
* Get the errors of a work request.
|
|
528
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
529
|
+
* @param ListWorkRequestErrorsRequest
|
|
530
|
+
* @return ListWorkRequestErrorsResponse
|
|
531
|
+
* @throws OciError when an error occurs
|
|
532
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/ListWorkRequestErrors.ts.html |here} to see how to use ListWorkRequestErrors API.
|
|
533
|
+
*/
|
|
534
|
+
listWorkRequestErrors(listWorkRequestErrorsRequest) {
|
|
535
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
536
|
+
if (this.logger)
|
|
537
|
+
this.logger.debug("Calling operation VbInstanceClient#listWorkRequestErrors.");
|
|
538
|
+
const pathParams = {
|
|
539
|
+
"{workRequestId}": listWorkRequestErrorsRequest.workRequestId
|
|
540
|
+
};
|
|
541
|
+
const queryParams = {
|
|
542
|
+
"compartmentId": listWorkRequestErrorsRequest.compartmentId,
|
|
543
|
+
"limit": listWorkRequestErrorsRequest.limit,
|
|
544
|
+
"page": listWorkRequestErrorsRequest.page
|
|
545
|
+
};
|
|
546
|
+
let headerParams = {
|
|
547
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
548
|
+
"opc-request-id": listWorkRequestErrorsRequest.opcRequestId
|
|
549
|
+
};
|
|
550
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
551
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listWorkRequestErrorsRequest.retryConfiguration, specRetryConfiguration);
|
|
552
|
+
if (this.logger)
|
|
553
|
+
retrier.logger = this.logger;
|
|
554
|
+
const request = yield oci_common_1.composeRequest({
|
|
555
|
+
baseEndpoint: this._endpoint,
|
|
556
|
+
defaultHeaders: this._defaultHeaders,
|
|
557
|
+
path: "/workRequests/{workRequestId}/errors",
|
|
558
|
+
method: "GET",
|
|
559
|
+
pathParams: pathParams,
|
|
560
|
+
headerParams: headerParams,
|
|
561
|
+
queryParams: queryParams
|
|
562
|
+
});
|
|
563
|
+
try {
|
|
564
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
565
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
566
|
+
responseObject: {},
|
|
567
|
+
body: yield response.json(),
|
|
568
|
+
bodyKey: "workRequestErrorCollection",
|
|
569
|
+
bodyModel: model.WorkRequestErrorCollection,
|
|
570
|
+
type: "model.WorkRequestErrorCollection",
|
|
571
|
+
responseHeaders: [
|
|
572
|
+
{
|
|
573
|
+
value: response.headers.get("opc-request-id"),
|
|
574
|
+
key: "opcRequestId",
|
|
575
|
+
dataType: "string"
|
|
576
|
+
},
|
|
577
|
+
{
|
|
578
|
+
value: response.headers.get("opc-next-page"),
|
|
579
|
+
key: "opcNextPage",
|
|
580
|
+
dataType: "string"
|
|
581
|
+
},
|
|
582
|
+
{
|
|
583
|
+
value: response.headers.get("opc-previous-page"),
|
|
584
|
+
key: "opcPreviousPage",
|
|
585
|
+
dataType: "string"
|
|
586
|
+
}
|
|
587
|
+
]
|
|
588
|
+
});
|
|
589
|
+
return sdkResponse;
|
|
590
|
+
}
|
|
591
|
+
catch (err) {
|
|
592
|
+
throw err;
|
|
593
|
+
}
|
|
594
|
+
});
|
|
595
|
+
}
|
|
596
|
+
/**
|
|
597
|
+
* Get the logs of a work request.
|
|
598
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
599
|
+
* @param ListWorkRequestLogsRequest
|
|
600
|
+
* @return ListWorkRequestLogsResponse
|
|
601
|
+
* @throws OciError when an error occurs
|
|
602
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/ListWorkRequestLogs.ts.html |here} to see how to use ListWorkRequestLogs API.
|
|
603
|
+
*/
|
|
604
|
+
listWorkRequestLogs(listWorkRequestLogsRequest) {
|
|
605
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
606
|
+
if (this.logger)
|
|
607
|
+
this.logger.debug("Calling operation VbInstanceClient#listWorkRequestLogs.");
|
|
608
|
+
const pathParams = {
|
|
609
|
+
"{workRequestId}": listWorkRequestLogsRequest.workRequestId
|
|
610
|
+
};
|
|
611
|
+
const queryParams = {
|
|
612
|
+
"compartmentId": listWorkRequestLogsRequest.compartmentId,
|
|
613
|
+
"limit": listWorkRequestLogsRequest.limit,
|
|
614
|
+
"page": listWorkRequestLogsRequest.page
|
|
615
|
+
};
|
|
616
|
+
let headerParams = {
|
|
617
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
618
|
+
"opc-request-id": listWorkRequestLogsRequest.opcRequestId
|
|
619
|
+
};
|
|
620
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
621
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listWorkRequestLogsRequest.retryConfiguration, specRetryConfiguration);
|
|
622
|
+
if (this.logger)
|
|
623
|
+
retrier.logger = this.logger;
|
|
624
|
+
const request = yield oci_common_1.composeRequest({
|
|
625
|
+
baseEndpoint: this._endpoint,
|
|
626
|
+
defaultHeaders: this._defaultHeaders,
|
|
627
|
+
path: "/workRequests/{workRequestId}/logs",
|
|
628
|
+
method: "GET",
|
|
629
|
+
pathParams: pathParams,
|
|
630
|
+
headerParams: headerParams,
|
|
631
|
+
queryParams: queryParams
|
|
632
|
+
});
|
|
633
|
+
try {
|
|
634
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
635
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
636
|
+
responseObject: {},
|
|
637
|
+
body: yield response.json(),
|
|
638
|
+
bodyKey: "workRequestLogEntryCollection",
|
|
639
|
+
bodyModel: model.WorkRequestLogEntryCollection,
|
|
640
|
+
type: "model.WorkRequestLogEntryCollection",
|
|
641
|
+
responseHeaders: [
|
|
642
|
+
{
|
|
643
|
+
value: response.headers.get("opc-request-id"),
|
|
644
|
+
key: "opcRequestId",
|
|
645
|
+
dataType: "string"
|
|
646
|
+
},
|
|
647
|
+
{
|
|
648
|
+
value: response.headers.get("opc-next-page"),
|
|
649
|
+
key: "opcNextPage",
|
|
650
|
+
dataType: "string"
|
|
651
|
+
},
|
|
652
|
+
{
|
|
653
|
+
value: response.headers.get("opc-previous-page"),
|
|
654
|
+
key: "opcPreviousPage",
|
|
655
|
+
dataType: "string"
|
|
656
|
+
}
|
|
657
|
+
]
|
|
658
|
+
});
|
|
659
|
+
return sdkResponse;
|
|
660
|
+
}
|
|
661
|
+
catch (err) {
|
|
662
|
+
throw err;
|
|
663
|
+
}
|
|
664
|
+
});
|
|
665
|
+
}
|
|
666
|
+
/**
|
|
667
|
+
* Lists the work requests in a compartment.
|
|
668
|
+
*
|
|
669
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
670
|
+
* @param ListWorkRequestsRequest
|
|
671
|
+
* @return ListWorkRequestsResponse
|
|
672
|
+
* @throws OciError when an error occurs
|
|
673
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/ListWorkRequests.ts.html |here} to see how to use ListWorkRequests API.
|
|
674
|
+
*/
|
|
675
|
+
listWorkRequests(listWorkRequestsRequest) {
|
|
676
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
677
|
+
if (this.logger)
|
|
678
|
+
this.logger.debug("Calling operation VbInstanceClient#listWorkRequests.");
|
|
679
|
+
const pathParams = {};
|
|
680
|
+
const queryParams = {
|
|
681
|
+
"compartmentId": listWorkRequestsRequest.compartmentId,
|
|
682
|
+
"page": listWorkRequestsRequest.page,
|
|
683
|
+
"limit": listWorkRequestsRequest.limit,
|
|
684
|
+
"vbInstanceId": listWorkRequestsRequest.vbInstanceId
|
|
685
|
+
};
|
|
686
|
+
let headerParams = {
|
|
687
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
688
|
+
"opc-request-id": listWorkRequestsRequest.opcRequestId
|
|
689
|
+
};
|
|
690
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
691
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listWorkRequestsRequest.retryConfiguration, specRetryConfiguration);
|
|
692
|
+
if (this.logger)
|
|
693
|
+
retrier.logger = this.logger;
|
|
694
|
+
const request = yield oci_common_1.composeRequest({
|
|
695
|
+
baseEndpoint: this._endpoint,
|
|
696
|
+
defaultHeaders: this._defaultHeaders,
|
|
697
|
+
path: "/workRequests",
|
|
698
|
+
method: "GET",
|
|
699
|
+
pathParams: pathParams,
|
|
700
|
+
headerParams: headerParams,
|
|
701
|
+
queryParams: queryParams
|
|
702
|
+
});
|
|
703
|
+
try {
|
|
704
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
705
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
706
|
+
responseObject: {},
|
|
707
|
+
body: yield response.json(),
|
|
708
|
+
bodyKey: "workRequestSummaryCollection",
|
|
709
|
+
bodyModel: model.WorkRequestSummaryCollection,
|
|
710
|
+
type: "model.WorkRequestSummaryCollection",
|
|
711
|
+
responseHeaders: [
|
|
712
|
+
{
|
|
713
|
+
value: response.headers.get("opc-request-id"),
|
|
714
|
+
key: "opcRequestId",
|
|
715
|
+
dataType: "string"
|
|
716
|
+
},
|
|
717
|
+
{
|
|
718
|
+
value: response.headers.get("opc-next-page"),
|
|
719
|
+
key: "opcNextPage",
|
|
720
|
+
dataType: "string"
|
|
721
|
+
},
|
|
722
|
+
{
|
|
723
|
+
value: response.headers.get("opc-previous-page"),
|
|
724
|
+
key: "opcPreviousPage",
|
|
725
|
+
dataType: "string"
|
|
726
|
+
}
|
|
727
|
+
]
|
|
728
|
+
});
|
|
729
|
+
return sdkResponse;
|
|
730
|
+
}
|
|
731
|
+
catch (err) {
|
|
732
|
+
throw err;
|
|
733
|
+
}
|
|
734
|
+
});
|
|
735
|
+
}
|
|
736
|
+
/**
|
|
737
|
+
* Summarizes the applications for a vb instance.
|
|
738
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
739
|
+
* @param RequestSummarizedApplicationsRequest
|
|
740
|
+
* @return RequestSummarizedApplicationsResponse
|
|
741
|
+
* @throws OciError when an error occurs
|
|
742
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/RequestSummarizedApplications.ts.html |here} to see how to use RequestSummarizedApplications API.
|
|
743
|
+
*/
|
|
744
|
+
requestSummarizedApplications(requestSummarizedApplicationsRequest) {
|
|
745
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
746
|
+
if (this.logger)
|
|
747
|
+
this.logger.debug("Calling operation VbInstanceClient#requestSummarizedApplications.");
|
|
748
|
+
const pathParams = {
|
|
749
|
+
"{vbInstanceId}": requestSummarizedApplicationsRequest.vbInstanceId
|
|
750
|
+
};
|
|
751
|
+
const queryParams = {};
|
|
752
|
+
let headerParams = {
|
|
753
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
754
|
+
"opc-request-id": requestSummarizedApplicationsRequest.opcRequestId,
|
|
755
|
+
"if-match": requestSummarizedApplicationsRequest.ifMatch,
|
|
756
|
+
"opc-retry-token": requestSummarizedApplicationsRequest.opcRetryToken
|
|
757
|
+
};
|
|
758
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
759
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, requestSummarizedApplicationsRequest.retryConfiguration, specRetryConfiguration);
|
|
760
|
+
if (this.logger)
|
|
761
|
+
retrier.logger = this.logger;
|
|
762
|
+
const request = yield oci_common_1.composeRequest({
|
|
763
|
+
baseEndpoint: this._endpoint,
|
|
764
|
+
defaultHeaders: this._defaultHeaders,
|
|
765
|
+
path: "/vbInstances/{vbInstanceId}/actions/applications",
|
|
766
|
+
method: "POST",
|
|
767
|
+
bodyContent: common.ObjectSerializer.serialize(requestSummarizedApplicationsRequest.requestSummarizedApplicationsDetails, "RequestSummarizedApplicationsDetails", model.RequestSummarizedApplicationsDetails.getJsonObj),
|
|
768
|
+
pathParams: pathParams,
|
|
769
|
+
headerParams: headerParams,
|
|
770
|
+
queryParams: queryParams
|
|
771
|
+
});
|
|
772
|
+
try {
|
|
773
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
774
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
775
|
+
responseObject: {},
|
|
776
|
+
body: yield response.json(),
|
|
777
|
+
bodyKey: "applicationSummaryCollection",
|
|
778
|
+
bodyModel: model.ApplicationSummaryCollection,
|
|
779
|
+
type: "model.ApplicationSummaryCollection",
|
|
780
|
+
responseHeaders: [
|
|
781
|
+
{
|
|
782
|
+
value: response.headers.get("etag"),
|
|
783
|
+
key: "etag",
|
|
784
|
+
dataType: "string"
|
|
785
|
+
},
|
|
786
|
+
{
|
|
787
|
+
value: response.headers.get("opc-request-id"),
|
|
788
|
+
key: "opcRequestId",
|
|
789
|
+
dataType: "string"
|
|
790
|
+
}
|
|
791
|
+
]
|
|
792
|
+
});
|
|
793
|
+
return sdkResponse;
|
|
794
|
+
}
|
|
795
|
+
catch (err) {
|
|
796
|
+
throw err;
|
|
797
|
+
}
|
|
798
|
+
});
|
|
799
|
+
}
|
|
800
|
+
/**
|
|
801
|
+
* Start an vb instance that was previously in an INACTIVE state. If the previous state is not
|
|
802
|
+
* INACTIVE, then the state of the vbInstance will not be changed and a 409 response returned.
|
|
803
|
+
*
|
|
804
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
805
|
+
* @param StartVbInstanceRequest
|
|
806
|
+
* @return StartVbInstanceResponse
|
|
807
|
+
* @throws OciError when an error occurs
|
|
808
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/StartVbInstance.ts.html |here} to see how to use StartVbInstance API.
|
|
809
|
+
*/
|
|
810
|
+
startVbInstance(startVbInstanceRequest) {
|
|
811
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
812
|
+
if (this.logger)
|
|
813
|
+
this.logger.debug("Calling operation VbInstanceClient#startVbInstance.");
|
|
814
|
+
const pathParams = {
|
|
815
|
+
"{vbInstanceId}": startVbInstanceRequest.vbInstanceId
|
|
816
|
+
};
|
|
817
|
+
const queryParams = {};
|
|
818
|
+
let headerParams = {
|
|
819
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
820
|
+
"if-match": startVbInstanceRequest.ifMatch,
|
|
821
|
+
"opc-request-id": startVbInstanceRequest.opcRequestId,
|
|
822
|
+
"opc-retry-token": startVbInstanceRequest.opcRetryToken
|
|
823
|
+
};
|
|
824
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
825
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, startVbInstanceRequest.retryConfiguration, specRetryConfiguration);
|
|
826
|
+
if (this.logger)
|
|
827
|
+
retrier.logger = this.logger;
|
|
828
|
+
const request = yield oci_common_1.composeRequest({
|
|
829
|
+
baseEndpoint: this._endpoint,
|
|
830
|
+
defaultHeaders: this._defaultHeaders,
|
|
831
|
+
path: "/vbInstances/{vbInstanceId}/actions/start",
|
|
832
|
+
method: "POST",
|
|
833
|
+
pathParams: pathParams,
|
|
834
|
+
headerParams: headerParams,
|
|
835
|
+
queryParams: queryParams
|
|
836
|
+
});
|
|
837
|
+
try {
|
|
838
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
839
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
840
|
+
responseObject: {},
|
|
841
|
+
responseHeaders: [
|
|
842
|
+
{
|
|
843
|
+
value: response.headers.get("opc-work-request-id"),
|
|
844
|
+
key: "opcWorkRequestId",
|
|
845
|
+
dataType: "string"
|
|
846
|
+
},
|
|
847
|
+
{
|
|
848
|
+
value: response.headers.get("opc-request-id"),
|
|
849
|
+
key: "opcRequestId",
|
|
850
|
+
dataType: "string"
|
|
851
|
+
}
|
|
852
|
+
]
|
|
853
|
+
});
|
|
854
|
+
return sdkResponse;
|
|
855
|
+
}
|
|
856
|
+
catch (err) {
|
|
857
|
+
throw err;
|
|
858
|
+
}
|
|
859
|
+
});
|
|
860
|
+
}
|
|
861
|
+
/**
|
|
862
|
+
* Stop an vb instance that was previously in an ACTIVE state. If the previous state is not
|
|
863
|
+
* ACTIVE, then the state of the vbInstance will not be changed and a 409 response returned.
|
|
864
|
+
*
|
|
865
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
866
|
+
* @param StopVbInstanceRequest
|
|
867
|
+
* @return StopVbInstanceResponse
|
|
868
|
+
* @throws OciError when an error occurs
|
|
869
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/StopVbInstance.ts.html |here} to see how to use StopVbInstance API.
|
|
870
|
+
*/
|
|
871
|
+
stopVbInstance(stopVbInstanceRequest) {
|
|
872
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
873
|
+
if (this.logger)
|
|
874
|
+
this.logger.debug("Calling operation VbInstanceClient#stopVbInstance.");
|
|
875
|
+
const pathParams = {
|
|
876
|
+
"{vbInstanceId}": stopVbInstanceRequest.vbInstanceId
|
|
877
|
+
};
|
|
878
|
+
const queryParams = {};
|
|
879
|
+
let headerParams = {
|
|
880
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
881
|
+
"if-match": stopVbInstanceRequest.ifMatch,
|
|
882
|
+
"opc-request-id": stopVbInstanceRequest.opcRequestId,
|
|
883
|
+
"opc-retry-token": stopVbInstanceRequest.opcRetryToken
|
|
884
|
+
};
|
|
885
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
886
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, stopVbInstanceRequest.retryConfiguration, specRetryConfiguration);
|
|
887
|
+
if (this.logger)
|
|
888
|
+
retrier.logger = this.logger;
|
|
889
|
+
const request = yield oci_common_1.composeRequest({
|
|
890
|
+
baseEndpoint: this._endpoint,
|
|
891
|
+
defaultHeaders: this._defaultHeaders,
|
|
892
|
+
path: "/vbInstances/{vbInstanceId}/actions/stop",
|
|
893
|
+
method: "POST",
|
|
894
|
+
pathParams: pathParams,
|
|
895
|
+
headerParams: headerParams,
|
|
896
|
+
queryParams: queryParams
|
|
897
|
+
});
|
|
898
|
+
try {
|
|
899
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
900
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
901
|
+
responseObject: {},
|
|
902
|
+
responseHeaders: [
|
|
903
|
+
{
|
|
904
|
+
value: response.headers.get("opc-work-request-id"),
|
|
905
|
+
key: "opcWorkRequestId",
|
|
906
|
+
dataType: "string"
|
|
907
|
+
},
|
|
908
|
+
{
|
|
909
|
+
value: response.headers.get("opc-request-id"),
|
|
910
|
+
key: "opcRequestId",
|
|
911
|
+
dataType: "string"
|
|
912
|
+
}
|
|
913
|
+
]
|
|
914
|
+
});
|
|
915
|
+
return sdkResponse;
|
|
916
|
+
}
|
|
917
|
+
catch (err) {
|
|
918
|
+
throw err;
|
|
919
|
+
}
|
|
920
|
+
});
|
|
921
|
+
}
|
|
922
|
+
/**
|
|
923
|
+
* Updates the Vb Instance.
|
|
924
|
+
* This operation does not retry by default if the user has not defined a retry configuration.
|
|
925
|
+
* @param UpdateVbInstanceRequest
|
|
926
|
+
* @return UpdateVbInstanceResponse
|
|
927
|
+
* @throws OciError when an error occurs
|
|
928
|
+
* @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/2.11.1/visualbuilder/UpdateVbInstance.ts.html |here} to see how to use UpdateVbInstance API.
|
|
929
|
+
*/
|
|
930
|
+
updateVbInstance(updateVbInstanceRequest) {
|
|
931
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
932
|
+
if (this.logger)
|
|
933
|
+
this.logger.debug("Calling operation VbInstanceClient#updateVbInstance.");
|
|
934
|
+
const pathParams = {
|
|
935
|
+
"{vbInstanceId}": updateVbInstanceRequest.vbInstanceId
|
|
936
|
+
};
|
|
937
|
+
const queryParams = {};
|
|
938
|
+
let headerParams = {
|
|
939
|
+
"Content-Type": common.Constants.APPLICATION_JSON,
|
|
940
|
+
"if-match": updateVbInstanceRequest.ifMatch,
|
|
941
|
+
"opc-request-id": updateVbInstanceRequest.opcRequestId
|
|
942
|
+
};
|
|
943
|
+
const specRetryConfiguration = common.NoRetryConfigurationDetails;
|
|
944
|
+
const retrier = oci_common_1.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, updateVbInstanceRequest.retryConfiguration, specRetryConfiguration);
|
|
945
|
+
if (this.logger)
|
|
946
|
+
retrier.logger = this.logger;
|
|
947
|
+
const request = yield oci_common_1.composeRequest({
|
|
948
|
+
baseEndpoint: this._endpoint,
|
|
949
|
+
defaultHeaders: this._defaultHeaders,
|
|
950
|
+
path: "/vbInstances/{vbInstanceId}",
|
|
951
|
+
method: "PUT",
|
|
952
|
+
bodyContent: common.ObjectSerializer.serialize(updateVbInstanceRequest.updateVbInstanceDetails, "UpdateVbInstanceDetails", model.UpdateVbInstanceDetails.getJsonObj),
|
|
953
|
+
pathParams: pathParams,
|
|
954
|
+
headerParams: headerParams,
|
|
955
|
+
queryParams: queryParams
|
|
956
|
+
});
|
|
957
|
+
try {
|
|
958
|
+
const response = yield retrier.makeServiceCall(this._httpClient, request);
|
|
959
|
+
const sdkResponse = oci_common_1.composeResponse({
|
|
960
|
+
responseObject: {},
|
|
961
|
+
responseHeaders: [
|
|
962
|
+
{
|
|
963
|
+
value: response.headers.get("opc-work-request-id"),
|
|
964
|
+
key: "opcWorkRequestId",
|
|
965
|
+
dataType: "string"
|
|
966
|
+
},
|
|
967
|
+
{
|
|
968
|
+
value: response.headers.get("opc-request-id"),
|
|
969
|
+
key: "opcRequestId",
|
|
970
|
+
dataType: "string"
|
|
971
|
+
}
|
|
972
|
+
]
|
|
973
|
+
});
|
|
974
|
+
return sdkResponse;
|
|
975
|
+
}
|
|
976
|
+
catch (err) {
|
|
977
|
+
throw err;
|
|
978
|
+
}
|
|
979
|
+
});
|
|
980
|
+
}
|
|
981
|
+
}
|
|
982
|
+
exports.VbInstanceClient = VbInstanceClient;
|
|
983
|
+
VbInstanceClient.serviceEndpointTemplate = "https://visualbuilder.{region}.ocp.{secondLevelDomain}";
|
|
984
|
+
//# sourceMappingURL=client.js.map
|