@aws-sdk/client-codestar-connections 3.312.0 → 3.315.0
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/dist-cjs/protocols/Aws_json1_0.js +54 -355
- package/dist-es/protocols/Aws_json1_0.js +55 -356
- package/package.json +6 -6
|
@@ -1,77 +1,77 @@
|
|
|
1
1
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
2
|
-
import { decorateServiceException as __decorateServiceException,
|
|
2
|
+
import { _json, decorateServiceException as __decorateServiceException, withBaseException, } from "@aws-sdk/smithy-client";
|
|
3
3
|
import { CodeStarConnectionsServiceException as __BaseException } from "../models/CodeStarConnectionsServiceException";
|
|
4
4
|
import { ConflictException, LimitExceededException, ResourceNotFoundException, ResourceUnavailableException, UnsupportedOperationException, } from "../models/models_0";
|
|
5
5
|
export const se_CreateConnectionCommand = async (input, context) => {
|
|
6
6
|
const headers = sharedHeaders("CreateConnection");
|
|
7
7
|
let body;
|
|
8
|
-
body = JSON.stringify(
|
|
8
|
+
body = JSON.stringify(_json(input));
|
|
9
9
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
10
10
|
};
|
|
11
11
|
export const se_CreateHostCommand = async (input, context) => {
|
|
12
12
|
const headers = sharedHeaders("CreateHost");
|
|
13
13
|
let body;
|
|
14
|
-
body = JSON.stringify(
|
|
14
|
+
body = JSON.stringify(_json(input));
|
|
15
15
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
16
16
|
};
|
|
17
17
|
export const se_DeleteConnectionCommand = async (input, context) => {
|
|
18
18
|
const headers = sharedHeaders("DeleteConnection");
|
|
19
19
|
let body;
|
|
20
|
-
body = JSON.stringify(
|
|
20
|
+
body = JSON.stringify(_json(input));
|
|
21
21
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
22
22
|
};
|
|
23
23
|
export const se_DeleteHostCommand = async (input, context) => {
|
|
24
24
|
const headers = sharedHeaders("DeleteHost");
|
|
25
25
|
let body;
|
|
26
|
-
body = JSON.stringify(
|
|
26
|
+
body = JSON.stringify(_json(input));
|
|
27
27
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
28
28
|
};
|
|
29
29
|
export const se_GetConnectionCommand = async (input, context) => {
|
|
30
30
|
const headers = sharedHeaders("GetConnection");
|
|
31
31
|
let body;
|
|
32
|
-
body = JSON.stringify(
|
|
32
|
+
body = JSON.stringify(_json(input));
|
|
33
33
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
34
34
|
};
|
|
35
35
|
export const se_GetHostCommand = async (input, context) => {
|
|
36
36
|
const headers = sharedHeaders("GetHost");
|
|
37
37
|
let body;
|
|
38
|
-
body = JSON.stringify(
|
|
38
|
+
body = JSON.stringify(_json(input));
|
|
39
39
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
40
40
|
};
|
|
41
41
|
export const se_ListConnectionsCommand = async (input, context) => {
|
|
42
42
|
const headers = sharedHeaders("ListConnections");
|
|
43
43
|
let body;
|
|
44
|
-
body = JSON.stringify(
|
|
44
|
+
body = JSON.stringify(_json(input));
|
|
45
45
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
46
46
|
};
|
|
47
47
|
export const se_ListHostsCommand = async (input, context) => {
|
|
48
48
|
const headers = sharedHeaders("ListHosts");
|
|
49
49
|
let body;
|
|
50
|
-
body = JSON.stringify(
|
|
50
|
+
body = JSON.stringify(_json(input));
|
|
51
51
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
52
52
|
};
|
|
53
53
|
export const se_ListTagsForResourceCommand = async (input, context) => {
|
|
54
54
|
const headers = sharedHeaders("ListTagsForResource");
|
|
55
55
|
let body;
|
|
56
|
-
body = JSON.stringify(
|
|
56
|
+
body = JSON.stringify(_json(input));
|
|
57
57
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
58
58
|
};
|
|
59
59
|
export const se_TagResourceCommand = async (input, context) => {
|
|
60
60
|
const headers = sharedHeaders("TagResource");
|
|
61
61
|
let body;
|
|
62
|
-
body = JSON.stringify(
|
|
62
|
+
body = JSON.stringify(_json(input));
|
|
63
63
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
64
64
|
};
|
|
65
65
|
export const se_UntagResourceCommand = async (input, context) => {
|
|
66
66
|
const headers = sharedHeaders("UntagResource");
|
|
67
67
|
let body;
|
|
68
|
-
body = JSON.stringify(
|
|
68
|
+
body = JSON.stringify(_json(input));
|
|
69
69
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
70
70
|
};
|
|
71
71
|
export const se_UpdateHostCommand = async (input, context) => {
|
|
72
72
|
const headers = sharedHeaders("UpdateHost");
|
|
73
73
|
let body;
|
|
74
|
-
body = JSON.stringify(
|
|
74
|
+
body = JSON.stringify(_json(input));
|
|
75
75
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
76
76
|
};
|
|
77
77
|
export const de_CreateConnectionCommand = async (output, context) => {
|
|
@@ -80,12 +80,12 @@ export const de_CreateConnectionCommand = async (output, context) => {
|
|
|
80
80
|
}
|
|
81
81
|
const data = await parseBody(output.body, context);
|
|
82
82
|
let contents = {};
|
|
83
|
-
contents =
|
|
83
|
+
contents = _json(data);
|
|
84
84
|
const response = {
|
|
85
85
|
$metadata: deserializeMetadata(output),
|
|
86
86
|
...contents,
|
|
87
87
|
};
|
|
88
|
-
return
|
|
88
|
+
return response;
|
|
89
89
|
};
|
|
90
90
|
const de_CreateConnectionCommandError = async (output, context) => {
|
|
91
91
|
const parsedOutput = {
|
|
@@ -105,10 +105,9 @@ const de_CreateConnectionCommandError = async (output, context) => {
|
|
|
105
105
|
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
106
106
|
default:
|
|
107
107
|
const parsedBody = parsedOutput.body;
|
|
108
|
-
throwDefaultError({
|
|
108
|
+
return throwDefaultError({
|
|
109
109
|
output,
|
|
110
110
|
parsedBody,
|
|
111
|
-
exceptionCtor: __BaseException,
|
|
112
111
|
errorCode,
|
|
113
112
|
});
|
|
114
113
|
}
|
|
@@ -119,12 +118,12 @@ export const de_CreateHostCommand = async (output, context) => {
|
|
|
119
118
|
}
|
|
120
119
|
const data = await parseBody(output.body, context);
|
|
121
120
|
let contents = {};
|
|
122
|
-
contents =
|
|
121
|
+
contents = _json(data);
|
|
123
122
|
const response = {
|
|
124
123
|
$metadata: deserializeMetadata(output),
|
|
125
124
|
...contents,
|
|
126
125
|
};
|
|
127
|
-
return
|
|
126
|
+
return response;
|
|
128
127
|
};
|
|
129
128
|
const de_CreateHostCommandError = async (output, context) => {
|
|
130
129
|
const parsedOutput = {
|
|
@@ -138,10 +137,9 @@ const de_CreateHostCommandError = async (output, context) => {
|
|
|
138
137
|
throw await de_LimitExceededExceptionRes(parsedOutput, context);
|
|
139
138
|
default:
|
|
140
139
|
const parsedBody = parsedOutput.body;
|
|
141
|
-
throwDefaultError({
|
|
140
|
+
return throwDefaultError({
|
|
142
141
|
output,
|
|
143
142
|
parsedBody,
|
|
144
|
-
exceptionCtor: __BaseException,
|
|
145
143
|
errorCode,
|
|
146
144
|
});
|
|
147
145
|
}
|
|
@@ -152,12 +150,12 @@ export const de_DeleteConnectionCommand = async (output, context) => {
|
|
|
152
150
|
}
|
|
153
151
|
const data = await parseBody(output.body, context);
|
|
154
152
|
let contents = {};
|
|
155
|
-
contents =
|
|
153
|
+
contents = _json(data);
|
|
156
154
|
const response = {
|
|
157
155
|
$metadata: deserializeMetadata(output),
|
|
158
156
|
...contents,
|
|
159
157
|
};
|
|
160
|
-
return
|
|
158
|
+
return response;
|
|
161
159
|
};
|
|
162
160
|
const de_DeleteConnectionCommandError = async (output, context) => {
|
|
163
161
|
const parsedOutput = {
|
|
@@ -171,10 +169,9 @@ const de_DeleteConnectionCommandError = async (output, context) => {
|
|
|
171
169
|
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
172
170
|
default:
|
|
173
171
|
const parsedBody = parsedOutput.body;
|
|
174
|
-
throwDefaultError({
|
|
172
|
+
return throwDefaultError({
|
|
175
173
|
output,
|
|
176
174
|
parsedBody,
|
|
177
|
-
exceptionCtor: __BaseException,
|
|
178
175
|
errorCode,
|
|
179
176
|
});
|
|
180
177
|
}
|
|
@@ -185,12 +182,12 @@ export const de_DeleteHostCommand = async (output, context) => {
|
|
|
185
182
|
}
|
|
186
183
|
const data = await parseBody(output.body, context);
|
|
187
184
|
let contents = {};
|
|
188
|
-
contents =
|
|
185
|
+
contents = _json(data);
|
|
189
186
|
const response = {
|
|
190
187
|
$metadata: deserializeMetadata(output),
|
|
191
188
|
...contents,
|
|
192
189
|
};
|
|
193
|
-
return
|
|
190
|
+
return response;
|
|
194
191
|
};
|
|
195
192
|
const de_DeleteHostCommandError = async (output, context) => {
|
|
196
193
|
const parsedOutput = {
|
|
@@ -207,10 +204,9 @@ const de_DeleteHostCommandError = async (output, context) => {
|
|
|
207
204
|
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
208
205
|
default:
|
|
209
206
|
const parsedBody = parsedOutput.body;
|
|
210
|
-
throwDefaultError({
|
|
207
|
+
return throwDefaultError({
|
|
211
208
|
output,
|
|
212
209
|
parsedBody,
|
|
213
|
-
exceptionCtor: __BaseException,
|
|
214
210
|
errorCode,
|
|
215
211
|
});
|
|
216
212
|
}
|
|
@@ -221,12 +217,12 @@ export const de_GetConnectionCommand = async (output, context) => {
|
|
|
221
217
|
}
|
|
222
218
|
const data = await parseBody(output.body, context);
|
|
223
219
|
let contents = {};
|
|
224
|
-
contents =
|
|
220
|
+
contents = _json(data);
|
|
225
221
|
const response = {
|
|
226
222
|
$metadata: deserializeMetadata(output),
|
|
227
223
|
...contents,
|
|
228
224
|
};
|
|
229
|
-
return
|
|
225
|
+
return response;
|
|
230
226
|
};
|
|
231
227
|
const de_GetConnectionCommandError = async (output, context) => {
|
|
232
228
|
const parsedOutput = {
|
|
@@ -243,10 +239,9 @@ const de_GetConnectionCommandError = async (output, context) => {
|
|
|
243
239
|
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
244
240
|
default:
|
|
245
241
|
const parsedBody = parsedOutput.body;
|
|
246
|
-
throwDefaultError({
|
|
242
|
+
return throwDefaultError({
|
|
247
243
|
output,
|
|
248
244
|
parsedBody,
|
|
249
|
-
exceptionCtor: __BaseException,
|
|
250
245
|
errorCode,
|
|
251
246
|
});
|
|
252
247
|
}
|
|
@@ -257,12 +252,12 @@ export const de_GetHostCommand = async (output, context) => {
|
|
|
257
252
|
}
|
|
258
253
|
const data = await parseBody(output.body, context);
|
|
259
254
|
let contents = {};
|
|
260
|
-
contents =
|
|
255
|
+
contents = _json(data);
|
|
261
256
|
const response = {
|
|
262
257
|
$metadata: deserializeMetadata(output),
|
|
263
258
|
...contents,
|
|
264
259
|
};
|
|
265
|
-
return
|
|
260
|
+
return response;
|
|
266
261
|
};
|
|
267
262
|
const de_GetHostCommandError = async (output, context) => {
|
|
268
263
|
const parsedOutput = {
|
|
@@ -279,10 +274,9 @@ const de_GetHostCommandError = async (output, context) => {
|
|
|
279
274
|
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
280
275
|
default:
|
|
281
276
|
const parsedBody = parsedOutput.body;
|
|
282
|
-
throwDefaultError({
|
|
277
|
+
return throwDefaultError({
|
|
283
278
|
output,
|
|
284
279
|
parsedBody,
|
|
285
|
-
exceptionCtor: __BaseException,
|
|
286
280
|
errorCode,
|
|
287
281
|
});
|
|
288
282
|
}
|
|
@@ -293,12 +287,12 @@ export const de_ListConnectionsCommand = async (output, context) => {
|
|
|
293
287
|
}
|
|
294
288
|
const data = await parseBody(output.body, context);
|
|
295
289
|
let contents = {};
|
|
296
|
-
contents =
|
|
290
|
+
contents = _json(data);
|
|
297
291
|
const response = {
|
|
298
292
|
$metadata: deserializeMetadata(output),
|
|
299
293
|
...contents,
|
|
300
294
|
};
|
|
301
|
-
return
|
|
295
|
+
return response;
|
|
302
296
|
};
|
|
303
297
|
const de_ListConnectionsCommandError = async (output, context) => {
|
|
304
298
|
const parsedOutput = {
|
|
@@ -307,10 +301,9 @@ const de_ListConnectionsCommandError = async (output, context) => {
|
|
|
307
301
|
};
|
|
308
302
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
309
303
|
const parsedBody = parsedOutput.body;
|
|
310
|
-
throwDefaultError({
|
|
304
|
+
return throwDefaultError({
|
|
311
305
|
output,
|
|
312
306
|
parsedBody,
|
|
313
|
-
exceptionCtor: __BaseException,
|
|
314
307
|
errorCode,
|
|
315
308
|
});
|
|
316
309
|
};
|
|
@@ -320,12 +313,12 @@ export const de_ListHostsCommand = async (output, context) => {
|
|
|
320
313
|
}
|
|
321
314
|
const data = await parseBody(output.body, context);
|
|
322
315
|
let contents = {};
|
|
323
|
-
contents =
|
|
316
|
+
contents = _json(data);
|
|
324
317
|
const response = {
|
|
325
318
|
$metadata: deserializeMetadata(output),
|
|
326
319
|
...contents,
|
|
327
320
|
};
|
|
328
|
-
return
|
|
321
|
+
return response;
|
|
329
322
|
};
|
|
330
323
|
const de_ListHostsCommandError = async (output, context) => {
|
|
331
324
|
const parsedOutput = {
|
|
@@ -334,10 +327,9 @@ const de_ListHostsCommandError = async (output, context) => {
|
|
|
334
327
|
};
|
|
335
328
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
336
329
|
const parsedBody = parsedOutput.body;
|
|
337
|
-
throwDefaultError({
|
|
330
|
+
return throwDefaultError({
|
|
338
331
|
output,
|
|
339
332
|
parsedBody,
|
|
340
|
-
exceptionCtor: __BaseException,
|
|
341
333
|
errorCode,
|
|
342
334
|
});
|
|
343
335
|
};
|
|
@@ -347,12 +339,12 @@ export const de_ListTagsForResourceCommand = async (output, context) => {
|
|
|
347
339
|
}
|
|
348
340
|
const data = await parseBody(output.body, context);
|
|
349
341
|
let contents = {};
|
|
350
|
-
contents =
|
|
342
|
+
contents = _json(data);
|
|
351
343
|
const response = {
|
|
352
344
|
$metadata: deserializeMetadata(output),
|
|
353
345
|
...contents,
|
|
354
346
|
};
|
|
355
|
-
return
|
|
347
|
+
return response;
|
|
356
348
|
};
|
|
357
349
|
const de_ListTagsForResourceCommandError = async (output, context) => {
|
|
358
350
|
const parsedOutput = {
|
|
@@ -366,10 +358,9 @@ const de_ListTagsForResourceCommandError = async (output, context) => {
|
|
|
366
358
|
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
367
359
|
default:
|
|
368
360
|
const parsedBody = parsedOutput.body;
|
|
369
|
-
throwDefaultError({
|
|
361
|
+
return throwDefaultError({
|
|
370
362
|
output,
|
|
371
363
|
parsedBody,
|
|
372
|
-
exceptionCtor: __BaseException,
|
|
373
364
|
errorCode,
|
|
374
365
|
});
|
|
375
366
|
}
|
|
@@ -380,12 +371,12 @@ export const de_TagResourceCommand = async (output, context) => {
|
|
|
380
371
|
}
|
|
381
372
|
const data = await parseBody(output.body, context);
|
|
382
373
|
let contents = {};
|
|
383
|
-
contents =
|
|
374
|
+
contents = _json(data);
|
|
384
375
|
const response = {
|
|
385
376
|
$metadata: deserializeMetadata(output),
|
|
386
377
|
...contents,
|
|
387
378
|
};
|
|
388
|
-
return
|
|
379
|
+
return response;
|
|
389
380
|
};
|
|
390
381
|
const de_TagResourceCommandError = async (output, context) => {
|
|
391
382
|
const parsedOutput = {
|
|
@@ -402,10 +393,9 @@ const de_TagResourceCommandError = async (output, context) => {
|
|
|
402
393
|
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
403
394
|
default:
|
|
404
395
|
const parsedBody = parsedOutput.body;
|
|
405
|
-
throwDefaultError({
|
|
396
|
+
return throwDefaultError({
|
|
406
397
|
output,
|
|
407
398
|
parsedBody,
|
|
408
|
-
exceptionCtor: __BaseException,
|
|
409
399
|
errorCode,
|
|
410
400
|
});
|
|
411
401
|
}
|
|
@@ -416,12 +406,12 @@ export const de_UntagResourceCommand = async (output, context) => {
|
|
|
416
406
|
}
|
|
417
407
|
const data = await parseBody(output.body, context);
|
|
418
408
|
let contents = {};
|
|
419
|
-
contents =
|
|
409
|
+
contents = _json(data);
|
|
420
410
|
const response = {
|
|
421
411
|
$metadata: deserializeMetadata(output),
|
|
422
412
|
...contents,
|
|
423
413
|
};
|
|
424
|
-
return
|
|
414
|
+
return response;
|
|
425
415
|
};
|
|
426
416
|
const de_UntagResourceCommandError = async (output, context) => {
|
|
427
417
|
const parsedOutput = {
|
|
@@ -435,10 +425,9 @@ const de_UntagResourceCommandError = async (output, context) => {
|
|
|
435
425
|
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
436
426
|
default:
|
|
437
427
|
const parsedBody = parsedOutput.body;
|
|
438
|
-
throwDefaultError({
|
|
428
|
+
return throwDefaultError({
|
|
439
429
|
output,
|
|
440
430
|
parsedBody,
|
|
441
|
-
exceptionCtor: __BaseException,
|
|
442
431
|
errorCode,
|
|
443
432
|
});
|
|
444
433
|
}
|
|
@@ -449,12 +438,12 @@ export const de_UpdateHostCommand = async (output, context) => {
|
|
|
449
438
|
}
|
|
450
439
|
const data = await parseBody(output.body, context);
|
|
451
440
|
let contents = {};
|
|
452
|
-
contents =
|
|
441
|
+
contents = _json(data);
|
|
453
442
|
const response = {
|
|
454
443
|
$metadata: deserializeMetadata(output),
|
|
455
444
|
...contents,
|
|
456
445
|
};
|
|
457
|
-
return
|
|
446
|
+
return response;
|
|
458
447
|
};
|
|
459
448
|
const de_UpdateHostCommandError = async (output, context) => {
|
|
460
449
|
const parsedOutput = {
|
|
@@ -477,17 +466,16 @@ const de_UpdateHostCommandError = async (output, context) => {
|
|
|
477
466
|
throw await de_UnsupportedOperationExceptionRes(parsedOutput, context);
|
|
478
467
|
default:
|
|
479
468
|
const parsedBody = parsedOutput.body;
|
|
480
|
-
throwDefaultError({
|
|
469
|
+
return throwDefaultError({
|
|
481
470
|
output,
|
|
482
471
|
parsedBody,
|
|
483
|
-
exceptionCtor: __BaseException,
|
|
484
472
|
errorCode,
|
|
485
473
|
});
|
|
486
474
|
}
|
|
487
475
|
};
|
|
488
476
|
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
489
477
|
const body = parsedOutput.body;
|
|
490
|
-
const deserialized =
|
|
478
|
+
const deserialized = _json(body);
|
|
491
479
|
const exception = new ConflictException({
|
|
492
480
|
$metadata: deserializeMetadata(parsedOutput),
|
|
493
481
|
...deserialized,
|
|
@@ -496,7 +484,7 @@ const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
|
496
484
|
};
|
|
497
485
|
const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
498
486
|
const body = parsedOutput.body;
|
|
499
|
-
const deserialized =
|
|
487
|
+
const deserialized = _json(body);
|
|
500
488
|
const exception = new LimitExceededException({
|
|
501
489
|
$metadata: deserializeMetadata(parsedOutput),
|
|
502
490
|
...deserialized,
|
|
@@ -505,7 +493,7 @@ const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
|
505
493
|
};
|
|
506
494
|
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
507
495
|
const body = parsedOutput.body;
|
|
508
|
-
const deserialized =
|
|
496
|
+
const deserialized = _json(body);
|
|
509
497
|
const exception = new ResourceNotFoundException({
|
|
510
498
|
$metadata: deserializeMetadata(parsedOutput),
|
|
511
499
|
...deserialized,
|
|
@@ -514,7 +502,7 @@ const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
|
514
502
|
};
|
|
515
503
|
const de_ResourceUnavailableExceptionRes = async (parsedOutput, context) => {
|
|
516
504
|
const body = parsedOutput.body;
|
|
517
|
-
const deserialized =
|
|
505
|
+
const deserialized = _json(body);
|
|
518
506
|
const exception = new ResourceUnavailableException({
|
|
519
507
|
$metadata: deserializeMetadata(parsedOutput),
|
|
520
508
|
...deserialized,
|
|
@@ -523,303 +511,13 @@ const de_ResourceUnavailableExceptionRes = async (parsedOutput, context) => {
|
|
|
523
511
|
};
|
|
524
512
|
const de_UnsupportedOperationExceptionRes = async (parsedOutput, context) => {
|
|
525
513
|
const body = parsedOutput.body;
|
|
526
|
-
const deserialized =
|
|
514
|
+
const deserialized = _json(body);
|
|
527
515
|
const exception = new UnsupportedOperationException({
|
|
528
516
|
$metadata: deserializeMetadata(parsedOutput),
|
|
529
517
|
...deserialized,
|
|
530
518
|
});
|
|
531
519
|
return __decorateServiceException(exception, body);
|
|
532
520
|
};
|
|
533
|
-
const se_CreateConnectionInput = (input, context) => {
|
|
534
|
-
return {
|
|
535
|
-
...(input.ConnectionName != null && { ConnectionName: input.ConnectionName }),
|
|
536
|
-
...(input.HostArn != null && { HostArn: input.HostArn }),
|
|
537
|
-
...(input.ProviderType != null && { ProviderType: input.ProviderType }),
|
|
538
|
-
...(input.Tags != null && { Tags: se_TagList(input.Tags, context) }),
|
|
539
|
-
};
|
|
540
|
-
};
|
|
541
|
-
const se_CreateHostInput = (input, context) => {
|
|
542
|
-
return {
|
|
543
|
-
...(input.Name != null && { Name: input.Name }),
|
|
544
|
-
...(input.ProviderEndpoint != null && { ProviderEndpoint: input.ProviderEndpoint }),
|
|
545
|
-
...(input.ProviderType != null && { ProviderType: input.ProviderType }),
|
|
546
|
-
...(input.Tags != null && { Tags: se_TagList(input.Tags, context) }),
|
|
547
|
-
...(input.VpcConfiguration != null && { VpcConfiguration: se_VpcConfiguration(input.VpcConfiguration, context) }),
|
|
548
|
-
};
|
|
549
|
-
};
|
|
550
|
-
const se_DeleteConnectionInput = (input, context) => {
|
|
551
|
-
return {
|
|
552
|
-
...(input.ConnectionArn != null && { ConnectionArn: input.ConnectionArn }),
|
|
553
|
-
};
|
|
554
|
-
};
|
|
555
|
-
const se_DeleteHostInput = (input, context) => {
|
|
556
|
-
return {
|
|
557
|
-
...(input.HostArn != null && { HostArn: input.HostArn }),
|
|
558
|
-
};
|
|
559
|
-
};
|
|
560
|
-
const se_GetConnectionInput = (input, context) => {
|
|
561
|
-
return {
|
|
562
|
-
...(input.ConnectionArn != null && { ConnectionArn: input.ConnectionArn }),
|
|
563
|
-
};
|
|
564
|
-
};
|
|
565
|
-
const se_GetHostInput = (input, context) => {
|
|
566
|
-
return {
|
|
567
|
-
...(input.HostArn != null && { HostArn: input.HostArn }),
|
|
568
|
-
};
|
|
569
|
-
};
|
|
570
|
-
const se_ListConnectionsInput = (input, context) => {
|
|
571
|
-
return {
|
|
572
|
-
...(input.HostArnFilter != null && { HostArnFilter: input.HostArnFilter }),
|
|
573
|
-
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
574
|
-
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
575
|
-
...(input.ProviderTypeFilter != null && { ProviderTypeFilter: input.ProviderTypeFilter }),
|
|
576
|
-
};
|
|
577
|
-
};
|
|
578
|
-
const se_ListHostsInput = (input, context) => {
|
|
579
|
-
return {
|
|
580
|
-
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
581
|
-
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
582
|
-
};
|
|
583
|
-
};
|
|
584
|
-
const se_ListTagsForResourceInput = (input, context) => {
|
|
585
|
-
return {
|
|
586
|
-
...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
|
|
587
|
-
};
|
|
588
|
-
};
|
|
589
|
-
const se_SecurityGroupIds = (input, context) => {
|
|
590
|
-
return input
|
|
591
|
-
.filter((e) => e != null)
|
|
592
|
-
.map((entry) => {
|
|
593
|
-
return entry;
|
|
594
|
-
});
|
|
595
|
-
};
|
|
596
|
-
const se_SubnetIds = (input, context) => {
|
|
597
|
-
return input
|
|
598
|
-
.filter((e) => e != null)
|
|
599
|
-
.map((entry) => {
|
|
600
|
-
return entry;
|
|
601
|
-
});
|
|
602
|
-
};
|
|
603
|
-
const se_Tag = (input, context) => {
|
|
604
|
-
return {
|
|
605
|
-
...(input.Key != null && { Key: input.Key }),
|
|
606
|
-
...(input.Value != null && { Value: input.Value }),
|
|
607
|
-
};
|
|
608
|
-
};
|
|
609
|
-
const se_TagKeyList = (input, context) => {
|
|
610
|
-
return input
|
|
611
|
-
.filter((e) => e != null)
|
|
612
|
-
.map((entry) => {
|
|
613
|
-
return entry;
|
|
614
|
-
});
|
|
615
|
-
};
|
|
616
|
-
const se_TagList = (input, context) => {
|
|
617
|
-
return input
|
|
618
|
-
.filter((e) => e != null)
|
|
619
|
-
.map((entry) => {
|
|
620
|
-
return se_Tag(entry, context);
|
|
621
|
-
});
|
|
622
|
-
};
|
|
623
|
-
const se_TagResourceInput = (input, context) => {
|
|
624
|
-
return {
|
|
625
|
-
...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
|
|
626
|
-
...(input.Tags != null && { Tags: se_TagList(input.Tags, context) }),
|
|
627
|
-
};
|
|
628
|
-
};
|
|
629
|
-
const se_UntagResourceInput = (input, context) => {
|
|
630
|
-
return {
|
|
631
|
-
...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
|
|
632
|
-
...(input.TagKeys != null && { TagKeys: se_TagKeyList(input.TagKeys, context) }),
|
|
633
|
-
};
|
|
634
|
-
};
|
|
635
|
-
const se_UpdateHostInput = (input, context) => {
|
|
636
|
-
return {
|
|
637
|
-
...(input.HostArn != null && { HostArn: input.HostArn }),
|
|
638
|
-
...(input.ProviderEndpoint != null && { ProviderEndpoint: input.ProviderEndpoint }),
|
|
639
|
-
...(input.VpcConfiguration != null && { VpcConfiguration: se_VpcConfiguration(input.VpcConfiguration, context) }),
|
|
640
|
-
};
|
|
641
|
-
};
|
|
642
|
-
const se_VpcConfiguration = (input, context) => {
|
|
643
|
-
return {
|
|
644
|
-
...(input.SecurityGroupIds != null && { SecurityGroupIds: se_SecurityGroupIds(input.SecurityGroupIds, context) }),
|
|
645
|
-
...(input.SubnetIds != null && { SubnetIds: se_SubnetIds(input.SubnetIds, context) }),
|
|
646
|
-
...(input.TlsCertificate != null && { TlsCertificate: input.TlsCertificate }),
|
|
647
|
-
...(input.VpcId != null && { VpcId: input.VpcId }),
|
|
648
|
-
};
|
|
649
|
-
};
|
|
650
|
-
const de_ConflictException = (output, context) => {
|
|
651
|
-
return {
|
|
652
|
-
Message: __expectString(output.Message),
|
|
653
|
-
};
|
|
654
|
-
};
|
|
655
|
-
const de_Connection = (output, context) => {
|
|
656
|
-
return {
|
|
657
|
-
ConnectionArn: __expectString(output.ConnectionArn),
|
|
658
|
-
ConnectionName: __expectString(output.ConnectionName),
|
|
659
|
-
ConnectionStatus: __expectString(output.ConnectionStatus),
|
|
660
|
-
HostArn: __expectString(output.HostArn),
|
|
661
|
-
OwnerAccountId: __expectString(output.OwnerAccountId),
|
|
662
|
-
ProviderType: __expectString(output.ProviderType),
|
|
663
|
-
};
|
|
664
|
-
};
|
|
665
|
-
const de_ConnectionList = (output, context) => {
|
|
666
|
-
const retVal = (output || [])
|
|
667
|
-
.filter((e) => e != null)
|
|
668
|
-
.map((entry) => {
|
|
669
|
-
if (entry === null) {
|
|
670
|
-
return null;
|
|
671
|
-
}
|
|
672
|
-
return de_Connection(entry, context);
|
|
673
|
-
});
|
|
674
|
-
return retVal;
|
|
675
|
-
};
|
|
676
|
-
const de_CreateConnectionOutput = (output, context) => {
|
|
677
|
-
return {
|
|
678
|
-
ConnectionArn: __expectString(output.ConnectionArn),
|
|
679
|
-
Tags: output.Tags != null ? de_TagList(output.Tags, context) : undefined,
|
|
680
|
-
};
|
|
681
|
-
};
|
|
682
|
-
const de_CreateHostOutput = (output, context) => {
|
|
683
|
-
return {
|
|
684
|
-
HostArn: __expectString(output.HostArn),
|
|
685
|
-
Tags: output.Tags != null ? de_TagList(output.Tags, context) : undefined,
|
|
686
|
-
};
|
|
687
|
-
};
|
|
688
|
-
const de_DeleteConnectionOutput = (output, context) => {
|
|
689
|
-
return {};
|
|
690
|
-
};
|
|
691
|
-
const de_DeleteHostOutput = (output, context) => {
|
|
692
|
-
return {};
|
|
693
|
-
};
|
|
694
|
-
const de_GetConnectionOutput = (output, context) => {
|
|
695
|
-
return {
|
|
696
|
-
Connection: output.Connection != null ? de_Connection(output.Connection, context) : undefined,
|
|
697
|
-
};
|
|
698
|
-
};
|
|
699
|
-
const de_GetHostOutput = (output, context) => {
|
|
700
|
-
return {
|
|
701
|
-
Name: __expectString(output.Name),
|
|
702
|
-
ProviderEndpoint: __expectString(output.ProviderEndpoint),
|
|
703
|
-
ProviderType: __expectString(output.ProviderType),
|
|
704
|
-
Status: __expectString(output.Status),
|
|
705
|
-
VpcConfiguration: output.VpcConfiguration != null ? de_VpcConfiguration(output.VpcConfiguration, context) : undefined,
|
|
706
|
-
};
|
|
707
|
-
};
|
|
708
|
-
const de_Host = (output, context) => {
|
|
709
|
-
return {
|
|
710
|
-
HostArn: __expectString(output.HostArn),
|
|
711
|
-
Name: __expectString(output.Name),
|
|
712
|
-
ProviderEndpoint: __expectString(output.ProviderEndpoint),
|
|
713
|
-
ProviderType: __expectString(output.ProviderType),
|
|
714
|
-
Status: __expectString(output.Status),
|
|
715
|
-
StatusMessage: __expectString(output.StatusMessage),
|
|
716
|
-
VpcConfiguration: output.VpcConfiguration != null ? de_VpcConfiguration(output.VpcConfiguration, context) : undefined,
|
|
717
|
-
};
|
|
718
|
-
};
|
|
719
|
-
const de_HostList = (output, context) => {
|
|
720
|
-
const retVal = (output || [])
|
|
721
|
-
.filter((e) => e != null)
|
|
722
|
-
.map((entry) => {
|
|
723
|
-
if (entry === null) {
|
|
724
|
-
return null;
|
|
725
|
-
}
|
|
726
|
-
return de_Host(entry, context);
|
|
727
|
-
});
|
|
728
|
-
return retVal;
|
|
729
|
-
};
|
|
730
|
-
const de_LimitExceededException = (output, context) => {
|
|
731
|
-
return {
|
|
732
|
-
Message: __expectString(output.Message),
|
|
733
|
-
};
|
|
734
|
-
};
|
|
735
|
-
const de_ListConnectionsOutput = (output, context) => {
|
|
736
|
-
return {
|
|
737
|
-
Connections: output.Connections != null ? de_ConnectionList(output.Connections, context) : undefined,
|
|
738
|
-
NextToken: __expectString(output.NextToken),
|
|
739
|
-
};
|
|
740
|
-
};
|
|
741
|
-
const de_ListHostsOutput = (output, context) => {
|
|
742
|
-
return {
|
|
743
|
-
Hosts: output.Hosts != null ? de_HostList(output.Hosts, context) : undefined,
|
|
744
|
-
NextToken: __expectString(output.NextToken),
|
|
745
|
-
};
|
|
746
|
-
};
|
|
747
|
-
const de_ListTagsForResourceOutput = (output, context) => {
|
|
748
|
-
return {
|
|
749
|
-
Tags: output.Tags != null ? de_TagList(output.Tags, context) : undefined,
|
|
750
|
-
};
|
|
751
|
-
};
|
|
752
|
-
const de_ResourceNotFoundException = (output, context) => {
|
|
753
|
-
return {
|
|
754
|
-
Message: __expectString(output.Message),
|
|
755
|
-
};
|
|
756
|
-
};
|
|
757
|
-
const de_ResourceUnavailableException = (output, context) => {
|
|
758
|
-
return {
|
|
759
|
-
Message: __expectString(output.Message),
|
|
760
|
-
};
|
|
761
|
-
};
|
|
762
|
-
const de_SecurityGroupIds = (output, context) => {
|
|
763
|
-
const retVal = (output || [])
|
|
764
|
-
.filter((e) => e != null)
|
|
765
|
-
.map((entry) => {
|
|
766
|
-
if (entry === null) {
|
|
767
|
-
return null;
|
|
768
|
-
}
|
|
769
|
-
return __expectString(entry);
|
|
770
|
-
});
|
|
771
|
-
return retVal;
|
|
772
|
-
};
|
|
773
|
-
const de_SubnetIds = (output, context) => {
|
|
774
|
-
const retVal = (output || [])
|
|
775
|
-
.filter((e) => e != null)
|
|
776
|
-
.map((entry) => {
|
|
777
|
-
if (entry === null) {
|
|
778
|
-
return null;
|
|
779
|
-
}
|
|
780
|
-
return __expectString(entry);
|
|
781
|
-
});
|
|
782
|
-
return retVal;
|
|
783
|
-
};
|
|
784
|
-
const de_Tag = (output, context) => {
|
|
785
|
-
return {
|
|
786
|
-
Key: __expectString(output.Key),
|
|
787
|
-
Value: __expectString(output.Value),
|
|
788
|
-
};
|
|
789
|
-
};
|
|
790
|
-
const de_TagList = (output, context) => {
|
|
791
|
-
const retVal = (output || [])
|
|
792
|
-
.filter((e) => e != null)
|
|
793
|
-
.map((entry) => {
|
|
794
|
-
if (entry === null) {
|
|
795
|
-
return null;
|
|
796
|
-
}
|
|
797
|
-
return de_Tag(entry, context);
|
|
798
|
-
});
|
|
799
|
-
return retVal;
|
|
800
|
-
};
|
|
801
|
-
const de_TagResourceOutput = (output, context) => {
|
|
802
|
-
return {};
|
|
803
|
-
};
|
|
804
|
-
const de_UnsupportedOperationException = (output, context) => {
|
|
805
|
-
return {
|
|
806
|
-
Message: __expectString(output.Message),
|
|
807
|
-
};
|
|
808
|
-
};
|
|
809
|
-
const de_UntagResourceOutput = (output, context) => {
|
|
810
|
-
return {};
|
|
811
|
-
};
|
|
812
|
-
const de_UpdateHostOutput = (output, context) => {
|
|
813
|
-
return {};
|
|
814
|
-
};
|
|
815
|
-
const de_VpcConfiguration = (output, context) => {
|
|
816
|
-
return {
|
|
817
|
-
SecurityGroupIds: output.SecurityGroupIds != null ? de_SecurityGroupIds(output.SecurityGroupIds, context) : undefined,
|
|
818
|
-
SubnetIds: output.SubnetIds != null ? de_SubnetIds(output.SubnetIds, context) : undefined,
|
|
819
|
-
TlsCertificate: __expectString(output.TlsCertificate),
|
|
820
|
-
VpcId: __expectString(output.VpcId),
|
|
821
|
-
};
|
|
822
|
-
};
|
|
823
521
|
const deserializeMetadata = (output) => ({
|
|
824
522
|
httpStatusCode: output.statusCode,
|
|
825
523
|
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
@@ -833,6 +531,7 @@ const collectBody = (streamBody = new Uint8Array(), context) => {
|
|
|
833
531
|
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
834
532
|
};
|
|
835
533
|
const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
534
|
+
const throwDefaultError = withBaseException(__BaseException);
|
|
836
535
|
const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
|
|
837
536
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
838
537
|
const contents = {
|