@researchdatabox/raido-openapi-generated-node 0.0.1 → 0.0.3
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/README.md +1 -1
- package/dist/api/apis.js +5 -9
- package/dist/api/{basicRaidExperimentalApi.js → raidApi.js} +98 -69
- package/dist/api/{publicExperimentalApi.js → servicePointApi.js} +115 -29
- package/dist/model/access.js +44 -0
- package/dist/model/accessStatement.js +35 -0
- package/dist/model/accessType.js +22 -6
- package/dist/model/{descriptionBlock.js → alternateIdentifier.js} +9 -9
- package/dist/model/{alternateUrlBlock.js → alternateUrl.js} +5 -5
- package/dist/model/closedRaid.js +35 -0
- package/dist/model/{apiKey.js → contributor.js} +21 -36
- package/dist/model/contributorPosition.js +9 -9
- package/dist/model/contributorRole.js +9 -9
- package/dist/model/description.js +41 -0
- package/dist/model/descriptionType.js +22 -6
- package/dist/model/{updateAuthzRequestStatus.js → failureResponse.js} +25 -16
- package/dist/model/id.js +80 -0
- package/dist/model/{publicServicePoint.js → language.js} +9 -12
- package/dist/model/{datesBlock.js → modelDate.js} +8 -5
- package/dist/model/models.js +100 -140
- package/dist/model/{organisationBlock.js → organisation.js} +12 -12
- package/dist/model/organisationRole.js +9 -9
- package/dist/model/{appUserExtraV1.js → owner.js} +20 -17
- package/dist/model/{raidListItemV2.js → raidChange.js} +21 -21
- package/dist/model/raidCreateRequest.js +107 -0
- package/dist/model/raidDto.js +107 -0
- package/dist/model/raidUpdateRequest.js +107 -0
- package/dist/model/registrationAgency.js +38 -0
- package/dist/model/relatedObject.js +47 -0
- package/dist/model/{publicClosedMetadataSchemaV1.js → relatedObjectCategory.js} +10 -16
- package/dist/model/relatedObjectType.js +35 -0
- package/dist/model/{accessBlock.js → relatedRaid.js} +12 -12
- package/dist/model/relatedRaidType.js +35 -0
- package/dist/model/servicePoint.js +31 -1
- package/dist/model/servicePointCreateRequest.js +104 -0
- package/dist/model/servicePointUpdateRequest.js +113 -0
- package/dist/model/{contributorBlock.js → spatialCoverage.js} +13 -19
- package/dist/model/spatialCoveragePlace.js +35 -0
- package/dist/model/subject.js +41 -0
- package/dist/model/{generateApiTokenResponse.js → subjectKeyword.js} +13 -13
- package/dist/model/{titleBlock.js → title.js} +14 -8
- package/dist/model/titleType.js +22 -6
- package/dist/model/traditionalKnowledgeLabel.js +35 -0
- package/dist/model/validationFailure.js +1 -1
- package/dist/model/{readRaidResponseV2.js → validationFailureResponse.js} +26 -38
- package/package.json +3 -3
- package/dist/api/adminExperimentalApi.js +0 -1092
- package/dist/api/unauthzExperimentalApi.js +0 -147
- package/dist/model/appUser.js +0 -83
- package/dist/model/authzRequestExtraV1.js +0 -104
- package/dist/model/authzRequestStatus.js +0 -20
- package/dist/model/contributorIdentifierSchemeType.js +0 -18
- package/dist/model/contributorPositionRaidMetadataSchemaType.js +0 -22
- package/dist/model/contributorPositionSchemeType.js +0 -18
- package/dist/model/contributorRoleCreditNisoOrgType.js +0 -31
- package/dist/model/contributorRoleSchemeType.js +0 -18
- package/dist/model/generateApiTokenRequest.js +0 -29
- package/dist/model/idBlock.js +0 -65
- package/dist/model/legacyMetadataSchemaV1.js +0 -68
- package/dist/model/migrateLegacyRaidRequest.js +0 -35
- package/dist/model/migrateLegacyRaidRequestMintRequest.js +0 -41
- package/dist/model/mintRaidoSchemaV1Request.js +0 -38
- package/dist/model/mintRaidoSchemaV1RequestMintRequest.js +0 -32
- package/dist/model/mintResponse.js +0 -41
- package/dist/model/organisationIdentifierSchemeType.js +0 -18
- package/dist/model/organisationRoleSchemeType.js +0 -18
- package/dist/model/organisationRoleType.js +0 -22
- package/dist/model/publicRaidMetadataSchemaV1.js +0 -80
- package/dist/model/publicReadRaidMetadataResponseV1.js +0 -80
- package/dist/model/publicReadRaidResponseV3.js +0 -56
- package/dist/model/raidListRequestV2.js +0 -35
- package/dist/model/raidoMetadataSchemaV1.js +0 -80
- package/dist/model/raidoMetaschema.js +0 -22
- package/dist/model/readRaidV2Request.js +0 -29
- package/dist/model/updateAuthzRequest.js +0 -38
- package/dist/model/updateAuthzResponse.js +0 -29
- package/dist/model/updateRaidoSchemaV1Request.js +0 -29
- package/dist/model/versionResult.js +0 -47
package/README.md
CHANGED
package/dist/api/apis.js
CHANGED
|
@@ -15,14 +15,10 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.APIS = exports.HttpError = void 0;
|
|
18
|
-
__exportStar(require("./
|
|
19
|
-
const
|
|
20
|
-
__exportStar(require("./
|
|
21
|
-
const
|
|
22
|
-
__exportStar(require("./publicExperimentalApi"), exports);
|
|
23
|
-
const publicExperimentalApi_1 = require("./publicExperimentalApi");
|
|
24
|
-
__exportStar(require("./unauthzExperimentalApi"), exports);
|
|
25
|
-
const unauthzExperimentalApi_1 = require("./unauthzExperimentalApi");
|
|
18
|
+
__exportStar(require("./raidApi"), exports);
|
|
19
|
+
const raidApi_1 = require("./raidApi");
|
|
20
|
+
__exportStar(require("./servicePointApi"), exports);
|
|
21
|
+
const servicePointApi_1 = require("./servicePointApi");
|
|
26
22
|
class HttpError extends Error {
|
|
27
23
|
response;
|
|
28
24
|
body;
|
|
@@ -36,4 +32,4 @@ class HttpError extends Error {
|
|
|
36
32
|
}
|
|
37
33
|
}
|
|
38
34
|
exports.HttpError = HttpError;
|
|
39
|
-
exports.APIS = [
|
|
35
|
+
exports.APIS = [raidApi_1.RaidApi, servicePointApi_1.ServicePointApi];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
3
|
* RAID v2 API
|
|
4
|
-
* This file is where all the endpoint paths are defined, it\'s the \"top level\' of the OpenAPI definition that links all the different files together. The `3.0` in the filename refers to this file being based on OpenAPI 3.0 as opposed to OpenAPI 3.1, which the tooling doesn\'t support yet. The `2.0.0` in the version field refers to the fact that there\'s already a `1.0.0` used for the legacy RAiD application
|
|
4
|
+
* This file is where all the endpoint paths are defined, it\'s the \"top level\' of the OpenAPI definition that links all the different files together. The `3.0` in the filename refers to this file being based on OpenAPI 3.0 as opposed to OpenAPI 3.1, which the tooling doesn\'t support yet. The `2.0.0` in the version field refers to the fact that there\'s already a `1.0.0` used for the legacy RAiD application. Note that swagger ui doesn\'t currently work with our spec, see https://github.com/swagger-api/swagger-ui/issues/7724 But the spec works fine with openapi-generator tooling.
|
|
5
5
|
*
|
|
6
6
|
* The version of the OpenAPI document: 2.0.0
|
|
7
7
|
* Contact: contact@raid.org
|
|
@@ -14,25 +14,25 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
14
14
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.
|
|
17
|
+
exports.RaidApi = exports.RaidApiApiKeys = void 0;
|
|
18
18
|
const request_1 = __importDefault(require("request"));
|
|
19
19
|
const models_1 = require("../model/models");
|
|
20
20
|
const models_2 = require("../model/models");
|
|
21
21
|
const apis_1 = require("./apis");
|
|
22
|
-
let defaultBasePath = 'https://
|
|
22
|
+
let defaultBasePath = 'https://api.prod.raid.org.au';
|
|
23
23
|
// ===============================================
|
|
24
24
|
// This file is autogenerated - Please do not edit
|
|
25
25
|
// ===============================================
|
|
26
|
-
var
|
|
27
|
-
(function (
|
|
28
|
-
})(
|
|
29
|
-
class
|
|
26
|
+
var RaidApiApiKeys;
|
|
27
|
+
(function (RaidApiApiKeys) {
|
|
28
|
+
})(RaidApiApiKeys = exports.RaidApiApiKeys || (exports.RaidApiApiKeys = {}));
|
|
29
|
+
class RaidApi {
|
|
30
30
|
_basePath = defaultBasePath;
|
|
31
31
|
_defaultHeaders = {};
|
|
32
32
|
_useQuerystring = false;
|
|
33
33
|
authentications = {
|
|
34
34
|
'default': new models_1.VoidAuth(),
|
|
35
|
-
'
|
|
35
|
+
'bearerAuth': new models_2.HttpBearerAuth(),
|
|
36
36
|
};
|
|
37
37
|
interceptors = [];
|
|
38
38
|
constructor(basePathOrUsername, password, basePath) {
|
|
@@ -66,10 +66,10 @@ class BasicRaidExperimentalApi {
|
|
|
66
66
|
this.authentications.default = auth;
|
|
67
67
|
}
|
|
68
68
|
setApiKey(key, value) {
|
|
69
|
-
this.authentications[
|
|
69
|
+
this.authentications[RaidApiApiKeys[key]].apiKey = value;
|
|
70
70
|
}
|
|
71
71
|
set accessToken(accessToken) {
|
|
72
|
-
this.authentications.
|
|
72
|
+
this.authentications.bearerAuth.accessToken = accessToken;
|
|
73
73
|
}
|
|
74
74
|
addInterceptor(interceptor) {
|
|
75
75
|
this.interceptors.push(interceptor);
|
|
@@ -77,10 +77,11 @@ class BasicRaidExperimentalApi {
|
|
|
77
77
|
/**
|
|
78
78
|
*
|
|
79
79
|
* @summary list raids
|
|
80
|
-
* @param
|
|
80
|
+
* @param servicePointId
|
|
81
|
+
* @param includeFields The top level fields to include in each RAiD in the response body. Excludes all other fields.
|
|
81
82
|
*/
|
|
82
|
-
async
|
|
83
|
-
const localVarPath = this.basePath + '/
|
|
83
|
+
async findAllRaids(servicePointId, includeFields, options = { headers: {} }) {
|
|
84
|
+
const localVarPath = this.basePath + '/raid/';
|
|
84
85
|
let localVarQueryParameters = {};
|
|
85
86
|
let localVarHeaderParams = Object.assign({}, this._defaultHeaders);
|
|
86
87
|
const produces = ['application/json'];
|
|
@@ -92,24 +93,25 @@ class BasicRaidExperimentalApi {
|
|
|
92
93
|
localVarHeaderParams.Accept = produces.join(',');
|
|
93
94
|
}
|
|
94
95
|
let localVarFormParams = {};
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
96
|
+
if (servicePointId !== undefined) {
|
|
97
|
+
localVarQueryParameters['servicePointId'] = models_1.ObjectSerializer.serialize(servicePointId, "number");
|
|
98
|
+
}
|
|
99
|
+
if (includeFields !== undefined) {
|
|
100
|
+
localVarQueryParameters['includeFields'] = models_1.ObjectSerializer.serialize(includeFields, "Array<string>");
|
|
98
101
|
}
|
|
99
102
|
Object.assign(localVarHeaderParams, options.headers);
|
|
100
103
|
let localVarUseFormData = false;
|
|
101
104
|
let localVarRequestOptions = {
|
|
102
|
-
method: '
|
|
105
|
+
method: 'GET',
|
|
103
106
|
qs: localVarQueryParameters,
|
|
104
107
|
headers: localVarHeaderParams,
|
|
105
108
|
uri: localVarPath,
|
|
106
109
|
useQuerystring: this._useQuerystring,
|
|
107
110
|
json: true,
|
|
108
|
-
body: models_1.ObjectSerializer.serialize(raidListRequestV2, "RaidListRequestV2")
|
|
109
111
|
};
|
|
110
112
|
let authenticationPromise = Promise.resolve();
|
|
111
|
-
if (this.authentications.
|
|
112
|
-
authenticationPromise = authenticationPromise.then(() => this.authentications.
|
|
113
|
+
if (this.authentications.bearerAuth.accessToken) {
|
|
114
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.bearerAuth.applyToRequest(localVarRequestOptions));
|
|
113
115
|
}
|
|
114
116
|
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
|
|
115
117
|
let interceptorPromise = authenticationPromise;
|
|
@@ -132,7 +134,7 @@ class BasicRaidExperimentalApi {
|
|
|
132
134
|
}
|
|
133
135
|
else {
|
|
134
136
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
135
|
-
body = models_1.ObjectSerializer.deserialize(body, "Array<
|
|
137
|
+
body = models_1.ObjectSerializer.deserialize(body, "Array<RaidDto>");
|
|
136
138
|
resolve({ response: response, body: body });
|
|
137
139
|
}
|
|
138
140
|
else {
|
|
@@ -145,11 +147,15 @@ class BasicRaidExperimentalApi {
|
|
|
145
147
|
}
|
|
146
148
|
/**
|
|
147
149
|
*
|
|
148
|
-
* @summary
|
|
149
|
-
* @param
|
|
150
|
+
* @summary read a raid, caller must be authorized
|
|
151
|
+
* @param prefix Prefix of the raid handle
|
|
152
|
+
* @param suffix Suffix of the raid handle
|
|
153
|
+
* @param version The version of the raid
|
|
150
154
|
*/
|
|
151
|
-
async
|
|
152
|
-
const localVarPath = this.basePath + '/
|
|
155
|
+
async findRaidByName(prefix, suffix, version, options = { headers: {} }) {
|
|
156
|
+
const localVarPath = this.basePath + '/raid/{prefix}/{suffix}'
|
|
157
|
+
.replace('{' + 'prefix' + '}', encodeURIComponent(String(prefix)))
|
|
158
|
+
.replace('{' + 'suffix' + '}', encodeURIComponent(String(suffix)));
|
|
153
159
|
let localVarQueryParameters = {};
|
|
154
160
|
let localVarHeaderParams = Object.assign({}, this._defaultHeaders);
|
|
155
161
|
const produces = ['application/json'];
|
|
@@ -161,24 +167,30 @@ class BasicRaidExperimentalApi {
|
|
|
161
167
|
localVarHeaderParams.Accept = produces.join(',');
|
|
162
168
|
}
|
|
163
169
|
let localVarFormParams = {};
|
|
164
|
-
// verify required parameter '
|
|
165
|
-
if (
|
|
166
|
-
throw new Error('Required parameter
|
|
170
|
+
// verify required parameter 'prefix' is not null or undefined
|
|
171
|
+
if (prefix === null || prefix === undefined) {
|
|
172
|
+
throw new Error('Required parameter prefix was null or undefined when calling findRaidByName.');
|
|
173
|
+
}
|
|
174
|
+
// verify required parameter 'suffix' is not null or undefined
|
|
175
|
+
if (suffix === null || suffix === undefined) {
|
|
176
|
+
throw new Error('Required parameter suffix was null or undefined when calling findRaidByName.');
|
|
177
|
+
}
|
|
178
|
+
if (version !== undefined) {
|
|
179
|
+
localVarQueryParameters['version'] = models_1.ObjectSerializer.serialize(version, "number");
|
|
167
180
|
}
|
|
168
181
|
Object.assign(localVarHeaderParams, options.headers);
|
|
169
182
|
let localVarUseFormData = false;
|
|
170
183
|
let localVarRequestOptions = {
|
|
171
|
-
method: '
|
|
184
|
+
method: 'GET',
|
|
172
185
|
qs: localVarQueryParameters,
|
|
173
186
|
headers: localVarHeaderParams,
|
|
174
187
|
uri: localVarPath,
|
|
175
188
|
useQuerystring: this._useQuerystring,
|
|
176
189
|
json: true,
|
|
177
|
-
body: models_1.ObjectSerializer.serialize(mintRaidoSchemaV1Request, "MintRaidoSchemaV1Request")
|
|
178
190
|
};
|
|
179
191
|
let authenticationPromise = Promise.resolve();
|
|
180
|
-
if (this.authentications.
|
|
181
|
-
authenticationPromise = authenticationPromise.then(() => this.authentications.
|
|
192
|
+
if (this.authentications.bearerAuth.accessToken) {
|
|
193
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.bearerAuth.applyToRequest(localVarRequestOptions));
|
|
182
194
|
}
|
|
183
195
|
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
|
|
184
196
|
let interceptorPromise = authenticationPromise;
|
|
@@ -201,7 +213,7 @@ class BasicRaidExperimentalApi {
|
|
|
201
213
|
}
|
|
202
214
|
else {
|
|
203
215
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
204
|
-
body = models_1.ObjectSerializer.deserialize(body, "
|
|
216
|
+
body = models_1.ObjectSerializer.deserialize(body, "RaidDto");
|
|
205
217
|
resolve({ response: response, body: body });
|
|
206
218
|
}
|
|
207
219
|
else {
|
|
@@ -214,11 +226,11 @@ class BasicRaidExperimentalApi {
|
|
|
214
226
|
}
|
|
215
227
|
/**
|
|
216
228
|
*
|
|
217
|
-
* @summary
|
|
218
|
-
* @param
|
|
229
|
+
* @summary mint a raid
|
|
230
|
+
* @param raidCreateRequest
|
|
219
231
|
*/
|
|
220
|
-
async
|
|
221
|
-
const localVarPath = this.basePath + '/
|
|
232
|
+
async mintRaid(raidCreateRequest, options = { headers: {} }) {
|
|
233
|
+
const localVarPath = this.basePath + '/raid/';
|
|
222
234
|
let localVarQueryParameters = {};
|
|
223
235
|
let localVarHeaderParams = Object.assign({}, this._defaultHeaders);
|
|
224
236
|
const produces = ['application/json'];
|
|
@@ -230,9 +242,9 @@ class BasicRaidExperimentalApi {
|
|
|
230
242
|
localVarHeaderParams.Accept = produces.join(',');
|
|
231
243
|
}
|
|
232
244
|
let localVarFormParams = {};
|
|
233
|
-
// verify required parameter '
|
|
234
|
-
if (
|
|
235
|
-
throw new Error('Required parameter
|
|
245
|
+
// verify required parameter 'raidCreateRequest' is not null or undefined
|
|
246
|
+
if (raidCreateRequest === null || raidCreateRequest === undefined) {
|
|
247
|
+
throw new Error('Required parameter raidCreateRequest was null or undefined when calling mintRaid.');
|
|
236
248
|
}
|
|
237
249
|
Object.assign(localVarHeaderParams, options.headers);
|
|
238
250
|
let localVarUseFormData = false;
|
|
@@ -243,11 +255,11 @@ class BasicRaidExperimentalApi {
|
|
|
243
255
|
uri: localVarPath,
|
|
244
256
|
useQuerystring: this._useQuerystring,
|
|
245
257
|
json: true,
|
|
246
|
-
body: models_1.ObjectSerializer.serialize(
|
|
258
|
+
body: models_1.ObjectSerializer.serialize(raidCreateRequest, "RaidCreateRequest")
|
|
247
259
|
};
|
|
248
260
|
let authenticationPromise = Promise.resolve();
|
|
249
|
-
if (this.authentications.
|
|
250
|
-
authenticationPromise = authenticationPromise.then(() => this.authentications.
|
|
261
|
+
if (this.authentications.bearerAuth.accessToken) {
|
|
262
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.bearerAuth.applyToRequest(localVarRequestOptions));
|
|
251
263
|
}
|
|
252
264
|
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
|
|
253
265
|
let interceptorPromise = authenticationPromise;
|
|
@@ -270,7 +282,7 @@ class BasicRaidExperimentalApi {
|
|
|
270
282
|
}
|
|
271
283
|
else {
|
|
272
284
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
273
|
-
body = models_1.ObjectSerializer.deserialize(body, "
|
|
285
|
+
body = models_1.ObjectSerializer.deserialize(body, "RaidDto");
|
|
274
286
|
resolve({ response: response, body: body });
|
|
275
287
|
}
|
|
276
288
|
else {
|
|
@@ -283,11 +295,14 @@ class BasicRaidExperimentalApi {
|
|
|
283
295
|
}
|
|
284
296
|
/**
|
|
285
297
|
*
|
|
286
|
-
* @summary
|
|
287
|
-
* @param
|
|
298
|
+
* @summary A list of the changes to the raid
|
|
299
|
+
* @param prefix Prefix of the raid handle
|
|
300
|
+
* @param suffix Suffix of the raid handle
|
|
288
301
|
*/
|
|
289
|
-
async
|
|
290
|
-
const localVarPath = this.basePath + '/
|
|
302
|
+
async raidHistory(prefix, suffix, options = { headers: {} }) {
|
|
303
|
+
const localVarPath = this.basePath + '/raid/{prefix}/{suffix}/history'
|
|
304
|
+
.replace('{' + 'prefix' + '}', encodeURIComponent(String(prefix)))
|
|
305
|
+
.replace('{' + 'suffix' + '}', encodeURIComponent(String(suffix)));
|
|
291
306
|
let localVarQueryParameters = {};
|
|
292
307
|
let localVarHeaderParams = Object.assign({}, this._defaultHeaders);
|
|
293
308
|
const produces = ['application/json'];
|
|
@@ -299,24 +314,27 @@ class BasicRaidExperimentalApi {
|
|
|
299
314
|
localVarHeaderParams.Accept = produces.join(',');
|
|
300
315
|
}
|
|
301
316
|
let localVarFormParams = {};
|
|
302
|
-
// verify required parameter '
|
|
303
|
-
if (
|
|
304
|
-
throw new Error('Required parameter
|
|
317
|
+
// verify required parameter 'prefix' is not null or undefined
|
|
318
|
+
if (prefix === null || prefix === undefined) {
|
|
319
|
+
throw new Error('Required parameter prefix was null or undefined when calling raidHistory.');
|
|
320
|
+
}
|
|
321
|
+
// verify required parameter 'suffix' is not null or undefined
|
|
322
|
+
if (suffix === null || suffix === undefined) {
|
|
323
|
+
throw new Error('Required parameter suffix was null or undefined when calling raidHistory.');
|
|
305
324
|
}
|
|
306
325
|
Object.assign(localVarHeaderParams, options.headers);
|
|
307
326
|
let localVarUseFormData = false;
|
|
308
327
|
let localVarRequestOptions = {
|
|
309
|
-
method: '
|
|
328
|
+
method: 'GET',
|
|
310
329
|
qs: localVarQueryParameters,
|
|
311
330
|
headers: localVarHeaderParams,
|
|
312
331
|
uri: localVarPath,
|
|
313
332
|
useQuerystring: this._useQuerystring,
|
|
314
333
|
json: true,
|
|
315
|
-
body: models_1.ObjectSerializer.serialize(updateRaidoSchemaV1Request, "UpdateRaidoSchemaV1Request")
|
|
316
334
|
};
|
|
317
335
|
let authenticationPromise = Promise.resolve();
|
|
318
|
-
if (this.authentications.
|
|
319
|
-
authenticationPromise = authenticationPromise.then(() => this.authentications.
|
|
336
|
+
if (this.authentications.bearerAuth.accessToken) {
|
|
337
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.bearerAuth.applyToRequest(localVarRequestOptions));
|
|
320
338
|
}
|
|
321
339
|
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
|
|
322
340
|
let interceptorPromise = authenticationPromise;
|
|
@@ -339,7 +357,7 @@ class BasicRaidExperimentalApi {
|
|
|
339
357
|
}
|
|
340
358
|
else {
|
|
341
359
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
342
|
-
body = models_1.ObjectSerializer.deserialize(body, "
|
|
360
|
+
body = models_1.ObjectSerializer.deserialize(body, "Array<RaidChange>");
|
|
343
361
|
resolve({ response: response, body: body });
|
|
344
362
|
}
|
|
345
363
|
else {
|
|
@@ -352,11 +370,14 @@ class BasicRaidExperimentalApi {
|
|
|
352
370
|
}
|
|
353
371
|
/**
|
|
354
372
|
*
|
|
355
|
-
* @
|
|
356
|
-
* @param
|
|
373
|
+
* @param prefix Prefix of the raid handle
|
|
374
|
+
* @param suffix Suffix of the raid handle
|
|
375
|
+
* @param raidUpdateRequest
|
|
357
376
|
*/
|
|
358
|
-
async
|
|
359
|
-
const localVarPath = this.basePath + '/
|
|
377
|
+
async updateRaid(prefix, suffix, raidUpdateRequest, options = { headers: {} }) {
|
|
378
|
+
const localVarPath = this.basePath + '/raid/{prefix}/{suffix}'
|
|
379
|
+
.replace('{' + 'prefix' + '}', encodeURIComponent(String(prefix)))
|
|
380
|
+
.replace('{' + 'suffix' + '}', encodeURIComponent(String(suffix)));
|
|
360
381
|
let localVarQueryParameters = {};
|
|
361
382
|
let localVarHeaderParams = Object.assign({}, this._defaultHeaders);
|
|
362
383
|
const produces = ['application/json'];
|
|
@@ -368,24 +389,32 @@ class BasicRaidExperimentalApi {
|
|
|
368
389
|
localVarHeaderParams.Accept = produces.join(',');
|
|
369
390
|
}
|
|
370
391
|
let localVarFormParams = {};
|
|
371
|
-
// verify required parameter '
|
|
372
|
-
if (
|
|
373
|
-
throw new Error('Required parameter
|
|
392
|
+
// verify required parameter 'prefix' is not null or undefined
|
|
393
|
+
if (prefix === null || prefix === undefined) {
|
|
394
|
+
throw new Error('Required parameter prefix was null or undefined when calling updateRaid.');
|
|
395
|
+
}
|
|
396
|
+
// verify required parameter 'suffix' is not null or undefined
|
|
397
|
+
if (suffix === null || suffix === undefined) {
|
|
398
|
+
throw new Error('Required parameter suffix was null or undefined when calling updateRaid.');
|
|
399
|
+
}
|
|
400
|
+
// verify required parameter 'raidUpdateRequest' is not null or undefined
|
|
401
|
+
if (raidUpdateRequest === null || raidUpdateRequest === undefined) {
|
|
402
|
+
throw new Error('Required parameter raidUpdateRequest was null or undefined when calling updateRaid.');
|
|
374
403
|
}
|
|
375
404
|
Object.assign(localVarHeaderParams, options.headers);
|
|
376
405
|
let localVarUseFormData = false;
|
|
377
406
|
let localVarRequestOptions = {
|
|
378
|
-
method: '
|
|
407
|
+
method: 'PUT',
|
|
379
408
|
qs: localVarQueryParameters,
|
|
380
409
|
headers: localVarHeaderParams,
|
|
381
410
|
uri: localVarPath,
|
|
382
411
|
useQuerystring: this._useQuerystring,
|
|
383
412
|
json: true,
|
|
384
|
-
body: models_1.ObjectSerializer.serialize(
|
|
413
|
+
body: models_1.ObjectSerializer.serialize(raidUpdateRequest, "RaidUpdateRequest")
|
|
385
414
|
};
|
|
386
415
|
let authenticationPromise = Promise.resolve();
|
|
387
|
-
if (this.authentications.
|
|
388
|
-
authenticationPromise = authenticationPromise.then(() => this.authentications.
|
|
416
|
+
if (this.authentications.bearerAuth.accessToken) {
|
|
417
|
+
authenticationPromise = authenticationPromise.then(() => this.authentications.bearerAuth.applyToRequest(localVarRequestOptions));
|
|
389
418
|
}
|
|
390
419
|
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
|
|
391
420
|
let interceptorPromise = authenticationPromise;
|
|
@@ -408,7 +437,7 @@ class BasicRaidExperimentalApi {
|
|
|
408
437
|
}
|
|
409
438
|
else {
|
|
410
439
|
if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
|
|
411
|
-
body = models_1.ObjectSerializer.deserialize(body, "
|
|
440
|
+
body = models_1.ObjectSerializer.deserialize(body, "RaidDto");
|
|
412
441
|
resolve({ response: response, body: body });
|
|
413
442
|
}
|
|
414
443
|
else {
|
|
@@ -420,4 +449,4 @@ class BasicRaidExperimentalApi {
|
|
|
420
449
|
});
|
|
421
450
|
}
|
|
422
451
|
}
|
|
423
|
-
exports.
|
|
452
|
+
exports.RaidApi = RaidApi;
|