@aws-sdk/client-redshift-serverless 3.312.0 → 3.316.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.
@@ -9,161 +9,161 @@ const RedshiftServerlessServiceException_1 = require("../models/RedshiftServerle
9
9
  const se_ConvertRecoveryPointToSnapshotCommand = async (input, context) => {
10
10
  const headers = sharedHeaders("ConvertRecoveryPointToSnapshot");
11
11
  let body;
12
- body = JSON.stringify(se_ConvertRecoveryPointToSnapshotRequest(input, context));
12
+ body = JSON.stringify((0, smithy_client_1._json)(input));
13
13
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
14
14
  };
15
15
  exports.se_ConvertRecoveryPointToSnapshotCommand = se_ConvertRecoveryPointToSnapshotCommand;
16
16
  const se_CreateEndpointAccessCommand = async (input, context) => {
17
17
  const headers = sharedHeaders("CreateEndpointAccess");
18
18
  let body;
19
- body = JSON.stringify(se_CreateEndpointAccessRequest(input, context));
19
+ body = JSON.stringify((0, smithy_client_1._json)(input));
20
20
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
21
21
  };
22
22
  exports.se_CreateEndpointAccessCommand = se_CreateEndpointAccessCommand;
23
23
  const se_CreateNamespaceCommand = async (input, context) => {
24
24
  const headers = sharedHeaders("CreateNamespace");
25
25
  let body;
26
- body = JSON.stringify(se_CreateNamespaceRequest(input, context));
26
+ body = JSON.stringify((0, smithy_client_1._json)(input));
27
27
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
28
28
  };
29
29
  exports.se_CreateNamespaceCommand = se_CreateNamespaceCommand;
30
30
  const se_CreateSnapshotCommand = async (input, context) => {
31
31
  const headers = sharedHeaders("CreateSnapshot");
32
32
  let body;
33
- body = JSON.stringify(se_CreateSnapshotRequest(input, context));
33
+ body = JSON.stringify((0, smithy_client_1._json)(input));
34
34
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
35
35
  };
36
36
  exports.se_CreateSnapshotCommand = se_CreateSnapshotCommand;
37
37
  const se_CreateUsageLimitCommand = async (input, context) => {
38
38
  const headers = sharedHeaders("CreateUsageLimit");
39
39
  let body;
40
- body = JSON.stringify(se_CreateUsageLimitRequest(input, context));
40
+ body = JSON.stringify((0, smithy_client_1._json)(input));
41
41
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
42
42
  };
43
43
  exports.se_CreateUsageLimitCommand = se_CreateUsageLimitCommand;
44
44
  const se_CreateWorkgroupCommand = async (input, context) => {
45
45
  const headers = sharedHeaders("CreateWorkgroup");
46
46
  let body;
47
- body = JSON.stringify(se_CreateWorkgroupRequest(input, context));
47
+ body = JSON.stringify((0, smithy_client_1._json)(input));
48
48
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
49
49
  };
50
50
  exports.se_CreateWorkgroupCommand = se_CreateWorkgroupCommand;
51
51
  const se_DeleteEndpointAccessCommand = async (input, context) => {
52
52
  const headers = sharedHeaders("DeleteEndpointAccess");
53
53
  let body;
54
- body = JSON.stringify(se_DeleteEndpointAccessRequest(input, context));
54
+ body = JSON.stringify((0, smithy_client_1._json)(input));
55
55
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
56
56
  };
57
57
  exports.se_DeleteEndpointAccessCommand = se_DeleteEndpointAccessCommand;
58
58
  const se_DeleteNamespaceCommand = async (input, context) => {
59
59
  const headers = sharedHeaders("DeleteNamespace");
60
60
  let body;
61
- body = JSON.stringify(se_DeleteNamespaceRequest(input, context));
61
+ body = JSON.stringify((0, smithy_client_1._json)(input));
62
62
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
63
63
  };
64
64
  exports.se_DeleteNamespaceCommand = se_DeleteNamespaceCommand;
65
65
  const se_DeleteResourcePolicyCommand = async (input, context) => {
66
66
  const headers = sharedHeaders("DeleteResourcePolicy");
67
67
  let body;
68
- body = JSON.stringify(se_DeleteResourcePolicyRequest(input, context));
68
+ body = JSON.stringify((0, smithy_client_1._json)(input));
69
69
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
70
70
  };
71
71
  exports.se_DeleteResourcePolicyCommand = se_DeleteResourcePolicyCommand;
72
72
  const se_DeleteSnapshotCommand = async (input, context) => {
73
73
  const headers = sharedHeaders("DeleteSnapshot");
74
74
  let body;
75
- body = JSON.stringify(se_DeleteSnapshotRequest(input, context));
75
+ body = JSON.stringify((0, smithy_client_1._json)(input));
76
76
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
77
77
  };
78
78
  exports.se_DeleteSnapshotCommand = se_DeleteSnapshotCommand;
79
79
  const se_DeleteUsageLimitCommand = async (input, context) => {
80
80
  const headers = sharedHeaders("DeleteUsageLimit");
81
81
  let body;
82
- body = JSON.stringify(se_DeleteUsageLimitRequest(input, context));
82
+ body = JSON.stringify((0, smithy_client_1._json)(input));
83
83
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
84
84
  };
85
85
  exports.se_DeleteUsageLimitCommand = se_DeleteUsageLimitCommand;
86
86
  const se_DeleteWorkgroupCommand = async (input, context) => {
87
87
  const headers = sharedHeaders("DeleteWorkgroup");
88
88
  let body;
89
- body = JSON.stringify(se_DeleteWorkgroupRequest(input, context));
89
+ body = JSON.stringify((0, smithy_client_1._json)(input));
90
90
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
91
91
  };
92
92
  exports.se_DeleteWorkgroupCommand = se_DeleteWorkgroupCommand;
93
93
  const se_GetCredentialsCommand = async (input, context) => {
94
94
  const headers = sharedHeaders("GetCredentials");
95
95
  let body;
96
- body = JSON.stringify(se_GetCredentialsRequest(input, context));
96
+ body = JSON.stringify((0, smithy_client_1._json)(input));
97
97
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
98
98
  };
99
99
  exports.se_GetCredentialsCommand = se_GetCredentialsCommand;
100
100
  const se_GetEndpointAccessCommand = async (input, context) => {
101
101
  const headers = sharedHeaders("GetEndpointAccess");
102
102
  let body;
103
- body = JSON.stringify(se_GetEndpointAccessRequest(input, context));
103
+ body = JSON.stringify((0, smithy_client_1._json)(input));
104
104
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
105
105
  };
106
106
  exports.se_GetEndpointAccessCommand = se_GetEndpointAccessCommand;
107
107
  const se_GetNamespaceCommand = async (input, context) => {
108
108
  const headers = sharedHeaders("GetNamespace");
109
109
  let body;
110
- body = JSON.stringify(se_GetNamespaceRequest(input, context));
110
+ body = JSON.stringify((0, smithy_client_1._json)(input));
111
111
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
112
112
  };
113
113
  exports.se_GetNamespaceCommand = se_GetNamespaceCommand;
114
114
  const se_GetRecoveryPointCommand = async (input, context) => {
115
115
  const headers = sharedHeaders("GetRecoveryPoint");
116
116
  let body;
117
- body = JSON.stringify(se_GetRecoveryPointRequest(input, context));
117
+ body = JSON.stringify((0, smithy_client_1._json)(input));
118
118
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
119
119
  };
120
120
  exports.se_GetRecoveryPointCommand = se_GetRecoveryPointCommand;
121
121
  const se_GetResourcePolicyCommand = async (input, context) => {
122
122
  const headers = sharedHeaders("GetResourcePolicy");
123
123
  let body;
124
- body = JSON.stringify(se_GetResourcePolicyRequest(input, context));
124
+ body = JSON.stringify((0, smithy_client_1._json)(input));
125
125
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
126
126
  };
127
127
  exports.se_GetResourcePolicyCommand = se_GetResourcePolicyCommand;
128
128
  const se_GetSnapshotCommand = async (input, context) => {
129
129
  const headers = sharedHeaders("GetSnapshot");
130
130
  let body;
131
- body = JSON.stringify(se_GetSnapshotRequest(input, context));
131
+ body = JSON.stringify((0, smithy_client_1._json)(input));
132
132
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
133
133
  };
134
134
  exports.se_GetSnapshotCommand = se_GetSnapshotCommand;
135
135
  const se_GetTableRestoreStatusCommand = async (input, context) => {
136
136
  const headers = sharedHeaders("GetTableRestoreStatus");
137
137
  let body;
138
- body = JSON.stringify(se_GetTableRestoreStatusRequest(input, context));
138
+ body = JSON.stringify((0, smithy_client_1._json)(input));
139
139
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
140
140
  };
141
141
  exports.se_GetTableRestoreStatusCommand = se_GetTableRestoreStatusCommand;
142
142
  const se_GetUsageLimitCommand = async (input, context) => {
143
143
  const headers = sharedHeaders("GetUsageLimit");
144
144
  let body;
145
- body = JSON.stringify(se_GetUsageLimitRequest(input, context));
145
+ body = JSON.stringify((0, smithy_client_1._json)(input));
146
146
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
147
147
  };
148
148
  exports.se_GetUsageLimitCommand = se_GetUsageLimitCommand;
149
149
  const se_GetWorkgroupCommand = async (input, context) => {
150
150
  const headers = sharedHeaders("GetWorkgroup");
151
151
  let body;
152
- body = JSON.stringify(se_GetWorkgroupRequest(input, context));
152
+ body = JSON.stringify((0, smithy_client_1._json)(input));
153
153
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
154
154
  };
155
155
  exports.se_GetWorkgroupCommand = se_GetWorkgroupCommand;
156
156
  const se_ListEndpointAccessCommand = async (input, context) => {
157
157
  const headers = sharedHeaders("ListEndpointAccess");
158
158
  let body;
159
- body = JSON.stringify(se_ListEndpointAccessRequest(input, context));
159
+ body = JSON.stringify((0, smithy_client_1._json)(input));
160
160
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
161
161
  };
162
162
  exports.se_ListEndpointAccessCommand = se_ListEndpointAccessCommand;
163
163
  const se_ListNamespacesCommand = async (input, context) => {
164
164
  const headers = sharedHeaders("ListNamespaces");
165
165
  let body;
166
- body = JSON.stringify(se_ListNamespacesRequest(input, context));
166
+ body = JSON.stringify((0, smithy_client_1._json)(input));
167
167
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
168
168
  };
169
169
  exports.se_ListNamespacesCommand = se_ListNamespacesCommand;
@@ -184,105 +184,105 @@ exports.se_ListSnapshotsCommand = se_ListSnapshotsCommand;
184
184
  const se_ListTableRestoreStatusCommand = async (input, context) => {
185
185
  const headers = sharedHeaders("ListTableRestoreStatus");
186
186
  let body;
187
- body = JSON.stringify(se_ListTableRestoreStatusRequest(input, context));
187
+ body = JSON.stringify((0, smithy_client_1._json)(input));
188
188
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
189
189
  };
190
190
  exports.se_ListTableRestoreStatusCommand = se_ListTableRestoreStatusCommand;
191
191
  const se_ListTagsForResourceCommand = async (input, context) => {
192
192
  const headers = sharedHeaders("ListTagsForResource");
193
193
  let body;
194
- body = JSON.stringify(se_ListTagsForResourceRequest(input, context));
194
+ body = JSON.stringify((0, smithy_client_1._json)(input));
195
195
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
196
196
  };
197
197
  exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
198
198
  const se_ListUsageLimitsCommand = async (input, context) => {
199
199
  const headers = sharedHeaders("ListUsageLimits");
200
200
  let body;
201
- body = JSON.stringify(se_ListUsageLimitsRequest(input, context));
201
+ body = JSON.stringify((0, smithy_client_1._json)(input));
202
202
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
203
203
  };
204
204
  exports.se_ListUsageLimitsCommand = se_ListUsageLimitsCommand;
205
205
  const se_ListWorkgroupsCommand = async (input, context) => {
206
206
  const headers = sharedHeaders("ListWorkgroups");
207
207
  let body;
208
- body = JSON.stringify(se_ListWorkgroupsRequest(input, context));
208
+ body = JSON.stringify((0, smithy_client_1._json)(input));
209
209
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
210
210
  };
211
211
  exports.se_ListWorkgroupsCommand = se_ListWorkgroupsCommand;
212
212
  const se_PutResourcePolicyCommand = async (input, context) => {
213
213
  const headers = sharedHeaders("PutResourcePolicy");
214
214
  let body;
215
- body = JSON.stringify(se_PutResourcePolicyRequest(input, context));
215
+ body = JSON.stringify((0, smithy_client_1._json)(input));
216
216
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
217
217
  };
218
218
  exports.se_PutResourcePolicyCommand = se_PutResourcePolicyCommand;
219
219
  const se_RestoreFromRecoveryPointCommand = async (input, context) => {
220
220
  const headers = sharedHeaders("RestoreFromRecoveryPoint");
221
221
  let body;
222
- body = JSON.stringify(se_RestoreFromRecoveryPointRequest(input, context));
222
+ body = JSON.stringify((0, smithy_client_1._json)(input));
223
223
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
224
224
  };
225
225
  exports.se_RestoreFromRecoveryPointCommand = se_RestoreFromRecoveryPointCommand;
226
226
  const se_RestoreFromSnapshotCommand = async (input, context) => {
227
227
  const headers = sharedHeaders("RestoreFromSnapshot");
228
228
  let body;
229
- body = JSON.stringify(se_RestoreFromSnapshotRequest(input, context));
229
+ body = JSON.stringify((0, smithy_client_1._json)(input));
230
230
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
231
231
  };
232
232
  exports.se_RestoreFromSnapshotCommand = se_RestoreFromSnapshotCommand;
233
233
  const se_RestoreTableFromSnapshotCommand = async (input, context) => {
234
234
  const headers = sharedHeaders("RestoreTableFromSnapshot");
235
235
  let body;
236
- body = JSON.stringify(se_RestoreTableFromSnapshotRequest(input, context));
236
+ body = JSON.stringify((0, smithy_client_1._json)(input));
237
237
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
238
238
  };
239
239
  exports.se_RestoreTableFromSnapshotCommand = se_RestoreTableFromSnapshotCommand;
240
240
  const se_TagResourceCommand = async (input, context) => {
241
241
  const headers = sharedHeaders("TagResource");
242
242
  let body;
243
- body = JSON.stringify(se_TagResourceRequest(input, context));
243
+ body = JSON.stringify((0, smithy_client_1._json)(input));
244
244
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
245
245
  };
246
246
  exports.se_TagResourceCommand = se_TagResourceCommand;
247
247
  const se_UntagResourceCommand = async (input, context) => {
248
248
  const headers = sharedHeaders("UntagResource");
249
249
  let body;
250
- body = JSON.stringify(se_UntagResourceRequest(input, context));
250
+ body = JSON.stringify((0, smithy_client_1._json)(input));
251
251
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
252
252
  };
253
253
  exports.se_UntagResourceCommand = se_UntagResourceCommand;
254
254
  const se_UpdateEndpointAccessCommand = async (input, context) => {
255
255
  const headers = sharedHeaders("UpdateEndpointAccess");
256
256
  let body;
257
- body = JSON.stringify(se_UpdateEndpointAccessRequest(input, context));
257
+ body = JSON.stringify((0, smithy_client_1._json)(input));
258
258
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
259
259
  };
260
260
  exports.se_UpdateEndpointAccessCommand = se_UpdateEndpointAccessCommand;
261
261
  const se_UpdateNamespaceCommand = async (input, context) => {
262
262
  const headers = sharedHeaders("UpdateNamespace");
263
263
  let body;
264
- body = JSON.stringify(se_UpdateNamespaceRequest(input, context));
264
+ body = JSON.stringify((0, smithy_client_1._json)(input));
265
265
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
266
266
  };
267
267
  exports.se_UpdateNamespaceCommand = se_UpdateNamespaceCommand;
268
268
  const se_UpdateSnapshotCommand = async (input, context) => {
269
269
  const headers = sharedHeaders("UpdateSnapshot");
270
270
  let body;
271
- body = JSON.stringify(se_UpdateSnapshotRequest(input, context));
271
+ body = JSON.stringify((0, smithy_client_1._json)(input));
272
272
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
273
273
  };
274
274
  exports.se_UpdateSnapshotCommand = se_UpdateSnapshotCommand;
275
275
  const se_UpdateUsageLimitCommand = async (input, context) => {
276
276
  const headers = sharedHeaders("UpdateUsageLimit");
277
277
  let body;
278
- body = JSON.stringify(se_UpdateUsageLimitRequest(input, context));
278
+ body = JSON.stringify((0, smithy_client_1._json)(input));
279
279
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
280
280
  };
281
281
  exports.se_UpdateUsageLimitCommand = se_UpdateUsageLimitCommand;
282
282
  const se_UpdateWorkgroupCommand = async (input, context) => {
283
283
  const headers = sharedHeaders("UpdateWorkgroup");
284
284
  let body;
285
- body = JSON.stringify(se_UpdateWorkgroupRequest(input, context));
285
+ body = JSON.stringify((0, smithy_client_1._json)(input));
286
286
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
287
287
  };
288
288
  exports.se_UpdateWorkgroupCommand = se_UpdateWorkgroupCommand;
@@ -297,7 +297,7 @@ const de_ConvertRecoveryPointToSnapshotCommand = async (output, context) => {
297
297
  $metadata: deserializeMetadata(output),
298
298
  ...contents,
299
299
  };
300
- return Promise.resolve(response);
300
+ return response;
301
301
  };
302
302
  exports.de_ConvertRecoveryPointToSnapshotCommand = de_ConvertRecoveryPointToSnapshotCommand;
303
303
  const de_ConvertRecoveryPointToSnapshotCommandError = async (output, context) => {
@@ -327,10 +327,9 @@ const de_ConvertRecoveryPointToSnapshotCommandError = async (output, context) =>
327
327
  throw await de_ValidationExceptionRes(parsedOutput, context);
328
328
  default:
329
329
  const parsedBody = parsedOutput.body;
330
- (0, smithy_client_1.throwDefaultError)({
330
+ return throwDefaultError({
331
331
  output,
332
332
  parsedBody,
333
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
334
333
  errorCode,
335
334
  });
336
335
  }
@@ -346,7 +345,7 @@ const de_CreateEndpointAccessCommand = async (output, context) => {
346
345
  $metadata: deserializeMetadata(output),
347
346
  ...contents,
348
347
  };
349
- return Promise.resolve(response);
348
+ return response;
350
349
  };
351
350
  exports.de_CreateEndpointAccessCommand = de_CreateEndpointAccessCommand;
352
351
  const de_CreateEndpointAccessCommandError = async (output, context) => {
@@ -376,10 +375,9 @@ const de_CreateEndpointAccessCommandError = async (output, context) => {
376
375
  throw await de_ValidationExceptionRes(parsedOutput, context);
377
376
  default:
378
377
  const parsedBody = parsedOutput.body;
379
- (0, smithy_client_1.throwDefaultError)({
378
+ return throwDefaultError({
380
379
  output,
381
380
  parsedBody,
382
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
383
381
  errorCode,
384
382
  });
385
383
  }
@@ -395,7 +393,7 @@ const de_CreateNamespaceCommand = async (output, context) => {
395
393
  $metadata: deserializeMetadata(output),
396
394
  ...contents,
397
395
  };
398
- return Promise.resolve(response);
396
+ return response;
399
397
  };
400
398
  exports.de_CreateNamespaceCommand = de_CreateNamespaceCommand;
401
399
  const de_CreateNamespaceCommandError = async (output, context) => {
@@ -419,10 +417,9 @@ const de_CreateNamespaceCommandError = async (output, context) => {
419
417
  throw await de_ValidationExceptionRes(parsedOutput, context);
420
418
  default:
421
419
  const parsedBody = parsedOutput.body;
422
- (0, smithy_client_1.throwDefaultError)({
420
+ return throwDefaultError({
423
421
  output,
424
422
  parsedBody,
425
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
426
423
  errorCode,
427
424
  });
428
425
  }
@@ -438,7 +435,7 @@ const de_CreateSnapshotCommand = async (output, context) => {
438
435
  $metadata: deserializeMetadata(output),
439
436
  ...contents,
440
437
  };
441
- return Promise.resolve(response);
438
+ return response;
442
439
  };
443
440
  exports.de_CreateSnapshotCommand = de_CreateSnapshotCommand;
444
441
  const de_CreateSnapshotCommandError = async (output, context) => {
@@ -468,10 +465,9 @@ const de_CreateSnapshotCommandError = async (output, context) => {
468
465
  throw await de_ValidationExceptionRes(parsedOutput, context);
469
466
  default:
470
467
  const parsedBody = parsedOutput.body;
471
- (0, smithy_client_1.throwDefaultError)({
468
+ return throwDefaultError({
472
469
  output,
473
470
  parsedBody,
474
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
475
471
  errorCode,
476
472
  });
477
473
  }
@@ -482,12 +478,12 @@ const de_CreateUsageLimitCommand = async (output, context) => {
482
478
  }
483
479
  const data = await parseBody(output.body, context);
484
480
  let contents = {};
485
- contents = de_CreateUsageLimitResponse(data, context);
481
+ contents = (0, smithy_client_1._json)(data);
486
482
  const response = {
487
483
  $metadata: deserializeMetadata(output),
488
484
  ...contents,
489
485
  };
490
- return Promise.resolve(response);
486
+ return response;
491
487
  };
492
488
  exports.de_CreateUsageLimitCommand = de_CreateUsageLimitCommand;
493
489
  const de_CreateUsageLimitCommandError = async (output, context) => {
@@ -514,10 +510,9 @@ const de_CreateUsageLimitCommandError = async (output, context) => {
514
510
  throw await de_ValidationExceptionRes(parsedOutput, context);
515
511
  default:
516
512
  const parsedBody = parsedOutput.body;
517
- (0, smithy_client_1.throwDefaultError)({
513
+ return throwDefaultError({
518
514
  output,
519
515
  parsedBody,
520
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
521
516
  errorCode,
522
517
  });
523
518
  }
@@ -533,7 +528,7 @@ const de_CreateWorkgroupCommand = async (output, context) => {
533
528
  $metadata: deserializeMetadata(output),
534
529
  ...contents,
535
530
  };
536
- return Promise.resolve(response);
531
+ return response;
537
532
  };
538
533
  exports.de_CreateWorkgroupCommand = de_CreateWorkgroupCommand;
539
534
  const de_CreateWorkgroupCommandError = async (output, context) => {
@@ -563,10 +558,9 @@ const de_CreateWorkgroupCommandError = async (output, context) => {
563
558
  throw await de_ValidationExceptionRes(parsedOutput, context);
564
559
  default:
565
560
  const parsedBody = parsedOutput.body;
566
- (0, smithy_client_1.throwDefaultError)({
561
+ return throwDefaultError({
567
562
  output,
568
563
  parsedBody,
569
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
570
564
  errorCode,
571
565
  });
572
566
  }
@@ -582,7 +576,7 @@ const de_DeleteEndpointAccessCommand = async (output, context) => {
582
576
  $metadata: deserializeMetadata(output),
583
577
  ...contents,
584
578
  };
585
- return Promise.resolve(response);
579
+ return response;
586
580
  };
587
581
  exports.de_DeleteEndpointAccessCommand = de_DeleteEndpointAccessCommand;
588
582
  const de_DeleteEndpointAccessCommandError = async (output, context) => {
@@ -606,10 +600,9 @@ const de_DeleteEndpointAccessCommandError = async (output, context) => {
606
600
  throw await de_ValidationExceptionRes(parsedOutput, context);
607
601
  default:
608
602
  const parsedBody = parsedOutput.body;
609
- (0, smithy_client_1.throwDefaultError)({
603
+ return throwDefaultError({
610
604
  output,
611
605
  parsedBody,
612
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
613
606
  errorCode,
614
607
  });
615
608
  }
@@ -625,7 +618,7 @@ const de_DeleteNamespaceCommand = async (output, context) => {
625
618
  $metadata: deserializeMetadata(output),
626
619
  ...contents,
627
620
  };
628
- return Promise.resolve(response);
621
+ return response;
629
622
  };
630
623
  exports.de_DeleteNamespaceCommand = de_DeleteNamespaceCommand;
631
624
  const de_DeleteNamespaceCommandError = async (output, context) => {
@@ -649,10 +642,9 @@ const de_DeleteNamespaceCommandError = async (output, context) => {
649
642
  throw await de_ValidationExceptionRes(parsedOutput, context);
650
643
  default:
651
644
  const parsedBody = parsedOutput.body;
652
- (0, smithy_client_1.throwDefaultError)({
645
+ return throwDefaultError({
653
646
  output,
654
647
  parsedBody,
655
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
656
648
  errorCode,
657
649
  });
658
650
  }
@@ -663,12 +655,12 @@ const de_DeleteResourcePolicyCommand = async (output, context) => {
663
655
  }
664
656
  const data = await parseBody(output.body, context);
665
657
  let contents = {};
666
- contents = de_DeleteResourcePolicyResponse(data, context);
658
+ contents = (0, smithy_client_1._json)(data);
667
659
  const response = {
668
660
  $metadata: deserializeMetadata(output),
669
661
  ...contents,
670
662
  };
671
- return Promise.resolve(response);
663
+ return response;
672
664
  };
673
665
  exports.de_DeleteResourcePolicyCommand = de_DeleteResourcePolicyCommand;
674
666
  const de_DeleteResourcePolicyCommandError = async (output, context) => {
@@ -689,10 +681,9 @@ const de_DeleteResourcePolicyCommandError = async (output, context) => {
689
681
  throw await de_ValidationExceptionRes(parsedOutput, context);
690
682
  default:
691
683
  const parsedBody = parsedOutput.body;
692
- (0, smithy_client_1.throwDefaultError)({
684
+ return throwDefaultError({
693
685
  output,
694
686
  parsedBody,
695
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
696
687
  errorCode,
697
688
  });
698
689
  }
@@ -708,7 +699,7 @@ const de_DeleteSnapshotCommand = async (output, context) => {
708
699
  $metadata: deserializeMetadata(output),
709
700
  ...contents,
710
701
  };
711
- return Promise.resolve(response);
702
+ return response;
712
703
  };
713
704
  exports.de_DeleteSnapshotCommand = de_DeleteSnapshotCommand;
714
705
  const de_DeleteSnapshotCommandError = async (output, context) => {
@@ -732,10 +723,9 @@ const de_DeleteSnapshotCommandError = async (output, context) => {
732
723
  throw await de_ValidationExceptionRes(parsedOutput, context);
733
724
  default:
734
725
  const parsedBody = parsedOutput.body;
735
- (0, smithy_client_1.throwDefaultError)({
726
+ return throwDefaultError({
736
727
  output,
737
728
  parsedBody,
738
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
739
729
  errorCode,
740
730
  });
741
731
  }
@@ -746,12 +736,12 @@ const de_DeleteUsageLimitCommand = async (output, context) => {
746
736
  }
747
737
  const data = await parseBody(output.body, context);
748
738
  let contents = {};
749
- contents = de_DeleteUsageLimitResponse(data, context);
739
+ contents = (0, smithy_client_1._json)(data);
750
740
  const response = {
751
741
  $metadata: deserializeMetadata(output),
752
742
  ...contents,
753
743
  };
754
- return Promise.resolve(response);
744
+ return response;
755
745
  };
756
746
  exports.de_DeleteUsageLimitCommand = de_DeleteUsageLimitCommand;
757
747
  const de_DeleteUsageLimitCommandError = async (output, context) => {
@@ -775,10 +765,9 @@ const de_DeleteUsageLimitCommandError = async (output, context) => {
775
765
  throw await de_ValidationExceptionRes(parsedOutput, context);
776
766
  default:
777
767
  const parsedBody = parsedOutput.body;
778
- (0, smithy_client_1.throwDefaultError)({
768
+ return throwDefaultError({
779
769
  output,
780
770
  parsedBody,
781
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
782
771
  errorCode,
783
772
  });
784
773
  }
@@ -794,7 +783,7 @@ const de_DeleteWorkgroupCommand = async (output, context) => {
794
783
  $metadata: deserializeMetadata(output),
795
784
  ...contents,
796
785
  };
797
- return Promise.resolve(response);
786
+ return response;
798
787
  };
799
788
  exports.de_DeleteWorkgroupCommand = de_DeleteWorkgroupCommand;
800
789
  const de_DeleteWorkgroupCommandError = async (output, context) => {
@@ -818,10 +807,9 @@ const de_DeleteWorkgroupCommandError = async (output, context) => {
818
807
  throw await de_ValidationExceptionRes(parsedOutput, context);
819
808
  default:
820
809
  const parsedBody = parsedOutput.body;
821
- (0, smithy_client_1.throwDefaultError)({
810
+ return throwDefaultError({
822
811
  output,
823
812
  parsedBody,
824
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
825
813
  errorCode,
826
814
  });
827
815
  }
@@ -837,7 +825,7 @@ const de_GetCredentialsCommand = async (output, context) => {
837
825
  $metadata: deserializeMetadata(output),
838
826
  ...contents,
839
827
  };
840
- return Promise.resolve(response);
828
+ return response;
841
829
  };
842
830
  exports.de_GetCredentialsCommand = de_GetCredentialsCommand;
843
831
  const de_GetCredentialsCommandError = async (output, context) => {
@@ -858,10 +846,9 @@ const de_GetCredentialsCommandError = async (output, context) => {
858
846
  throw await de_ValidationExceptionRes(parsedOutput, context);
859
847
  default:
860
848
  const parsedBody = parsedOutput.body;
861
- (0, smithy_client_1.throwDefaultError)({
849
+ return throwDefaultError({
862
850
  output,
863
851
  parsedBody,
864
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
865
852
  errorCode,
866
853
  });
867
854
  }
@@ -877,7 +864,7 @@ const de_GetEndpointAccessCommand = async (output, context) => {
877
864
  $metadata: deserializeMetadata(output),
878
865
  ...contents,
879
866
  };
880
- return Promise.resolve(response);
867
+ return response;
881
868
  };
882
869
  exports.de_GetEndpointAccessCommand = de_GetEndpointAccessCommand;
883
870
  const de_GetEndpointAccessCommandError = async (output, context) => {
@@ -901,10 +888,9 @@ const de_GetEndpointAccessCommandError = async (output, context) => {
901
888
  throw await de_ValidationExceptionRes(parsedOutput, context);
902
889
  default:
903
890
  const parsedBody = parsedOutput.body;
904
- (0, smithy_client_1.throwDefaultError)({
891
+ return throwDefaultError({
905
892
  output,
906
893
  parsedBody,
907
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
908
894
  errorCode,
909
895
  });
910
896
  }
@@ -920,7 +906,7 @@ const de_GetNamespaceCommand = async (output, context) => {
920
906
  $metadata: deserializeMetadata(output),
921
907
  ...contents,
922
908
  };
923
- return Promise.resolve(response);
909
+ return response;
924
910
  };
925
911
  exports.de_GetNamespaceCommand = de_GetNamespaceCommand;
926
912
  const de_GetNamespaceCommandError = async (output, context) => {
@@ -941,10 +927,9 @@ const de_GetNamespaceCommandError = async (output, context) => {
941
927
  throw await de_ValidationExceptionRes(parsedOutput, context);
942
928
  default:
943
929
  const parsedBody = parsedOutput.body;
944
- (0, smithy_client_1.throwDefaultError)({
930
+ return throwDefaultError({
945
931
  output,
946
932
  parsedBody,
947
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
948
933
  errorCode,
949
934
  });
950
935
  }
@@ -960,7 +945,7 @@ const de_GetRecoveryPointCommand = async (output, context) => {
960
945
  $metadata: deserializeMetadata(output),
961
946
  ...contents,
962
947
  };
963
- return Promise.resolve(response);
948
+ return response;
964
949
  };
965
950
  exports.de_GetRecoveryPointCommand = de_GetRecoveryPointCommand;
966
951
  const de_GetRecoveryPointCommandError = async (output, context) => {
@@ -984,10 +969,9 @@ const de_GetRecoveryPointCommandError = async (output, context) => {
984
969
  throw await de_ValidationExceptionRes(parsedOutput, context);
985
970
  default:
986
971
  const parsedBody = parsedOutput.body;
987
- (0, smithy_client_1.throwDefaultError)({
972
+ return throwDefaultError({
988
973
  output,
989
974
  parsedBody,
990
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
991
975
  errorCode,
992
976
  });
993
977
  }
@@ -998,12 +982,12 @@ const de_GetResourcePolicyCommand = async (output, context) => {
998
982
  }
999
983
  const data = await parseBody(output.body, context);
1000
984
  let contents = {};
1001
- contents = de_GetResourcePolicyResponse(data, context);
985
+ contents = (0, smithy_client_1._json)(data);
1002
986
  const response = {
1003
987
  $metadata: deserializeMetadata(output),
1004
988
  ...contents,
1005
989
  };
1006
- return Promise.resolve(response);
990
+ return response;
1007
991
  };
1008
992
  exports.de_GetResourcePolicyCommand = de_GetResourcePolicyCommand;
1009
993
  const de_GetResourcePolicyCommandError = async (output, context) => {
@@ -1024,10 +1008,9 @@ const de_GetResourcePolicyCommandError = async (output, context) => {
1024
1008
  throw await de_ValidationExceptionRes(parsedOutput, context);
1025
1009
  default:
1026
1010
  const parsedBody = parsedOutput.body;
1027
- (0, smithy_client_1.throwDefaultError)({
1011
+ return throwDefaultError({
1028
1012
  output,
1029
1013
  parsedBody,
1030
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1031
1014
  errorCode,
1032
1015
  });
1033
1016
  }
@@ -1043,7 +1026,7 @@ const de_GetSnapshotCommand = async (output, context) => {
1043
1026
  $metadata: deserializeMetadata(output),
1044
1027
  ...contents,
1045
1028
  };
1046
- return Promise.resolve(response);
1029
+ return response;
1047
1030
  };
1048
1031
  exports.de_GetSnapshotCommand = de_GetSnapshotCommand;
1049
1032
  const de_GetSnapshotCommandError = async (output, context) => {
@@ -1064,10 +1047,9 @@ const de_GetSnapshotCommandError = async (output, context) => {
1064
1047
  throw await de_ValidationExceptionRes(parsedOutput, context);
1065
1048
  default:
1066
1049
  const parsedBody = parsedOutput.body;
1067
- (0, smithy_client_1.throwDefaultError)({
1050
+ return throwDefaultError({
1068
1051
  output,
1069
1052
  parsedBody,
1070
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1071
1053
  errorCode,
1072
1054
  });
1073
1055
  }
@@ -1083,7 +1065,7 @@ const de_GetTableRestoreStatusCommand = async (output, context) => {
1083
1065
  $metadata: deserializeMetadata(output),
1084
1066
  ...contents,
1085
1067
  };
1086
- return Promise.resolve(response);
1068
+ return response;
1087
1069
  };
1088
1070
  exports.de_GetTableRestoreStatusCommand = de_GetTableRestoreStatusCommand;
1089
1071
  const de_GetTableRestoreStatusCommandError = async (output, context) => {
@@ -1101,10 +1083,9 @@ const de_GetTableRestoreStatusCommandError = async (output, context) => {
1101
1083
  throw await de_ValidationExceptionRes(parsedOutput, context);
1102
1084
  default:
1103
1085
  const parsedBody = parsedOutput.body;
1104
- (0, smithy_client_1.throwDefaultError)({
1086
+ return throwDefaultError({
1105
1087
  output,
1106
1088
  parsedBody,
1107
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1108
1089
  errorCode,
1109
1090
  });
1110
1091
  }
@@ -1115,12 +1096,12 @@ const de_GetUsageLimitCommand = async (output, context) => {
1115
1096
  }
1116
1097
  const data = await parseBody(output.body, context);
1117
1098
  let contents = {};
1118
- contents = de_GetUsageLimitResponse(data, context);
1099
+ contents = (0, smithy_client_1._json)(data);
1119
1100
  const response = {
1120
1101
  $metadata: deserializeMetadata(output),
1121
1102
  ...contents,
1122
1103
  };
1123
- return Promise.resolve(response);
1104
+ return response;
1124
1105
  };
1125
1106
  exports.de_GetUsageLimitCommand = de_GetUsageLimitCommand;
1126
1107
  const de_GetUsageLimitCommandError = async (output, context) => {
@@ -1144,10 +1125,9 @@ const de_GetUsageLimitCommandError = async (output, context) => {
1144
1125
  throw await de_ValidationExceptionRes(parsedOutput, context);
1145
1126
  default:
1146
1127
  const parsedBody = parsedOutput.body;
1147
- (0, smithy_client_1.throwDefaultError)({
1128
+ return throwDefaultError({
1148
1129
  output,
1149
1130
  parsedBody,
1150
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1151
1131
  errorCode,
1152
1132
  });
1153
1133
  }
@@ -1163,7 +1143,7 @@ const de_GetWorkgroupCommand = async (output, context) => {
1163
1143
  $metadata: deserializeMetadata(output),
1164
1144
  ...contents,
1165
1145
  };
1166
- return Promise.resolve(response);
1146
+ return response;
1167
1147
  };
1168
1148
  exports.de_GetWorkgroupCommand = de_GetWorkgroupCommand;
1169
1149
  const de_GetWorkgroupCommandError = async (output, context) => {
@@ -1184,10 +1164,9 @@ const de_GetWorkgroupCommandError = async (output, context) => {
1184
1164
  throw await de_ValidationExceptionRes(parsedOutput, context);
1185
1165
  default:
1186
1166
  const parsedBody = parsedOutput.body;
1187
- (0, smithy_client_1.throwDefaultError)({
1167
+ return throwDefaultError({
1188
1168
  output,
1189
1169
  parsedBody,
1190
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1191
1170
  errorCode,
1192
1171
  });
1193
1172
  }
@@ -1203,7 +1182,7 @@ const de_ListEndpointAccessCommand = async (output, context) => {
1203
1182
  $metadata: deserializeMetadata(output),
1204
1183
  ...contents,
1205
1184
  };
1206
- return Promise.resolve(response);
1185
+ return response;
1207
1186
  };
1208
1187
  exports.de_ListEndpointAccessCommand = de_ListEndpointAccessCommand;
1209
1188
  const de_ListEndpointAccessCommandError = async (output, context) => {
@@ -1227,10 +1206,9 @@ const de_ListEndpointAccessCommandError = async (output, context) => {
1227
1206
  throw await de_ValidationExceptionRes(parsedOutput, context);
1228
1207
  default:
1229
1208
  const parsedBody = parsedOutput.body;
1230
- (0, smithy_client_1.throwDefaultError)({
1209
+ return throwDefaultError({
1231
1210
  output,
1232
1211
  parsedBody,
1233
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1234
1212
  errorCode,
1235
1213
  });
1236
1214
  }
@@ -1246,7 +1224,7 @@ const de_ListNamespacesCommand = async (output, context) => {
1246
1224
  $metadata: deserializeMetadata(output),
1247
1225
  ...contents,
1248
1226
  };
1249
- return Promise.resolve(response);
1227
+ return response;
1250
1228
  };
1251
1229
  exports.de_ListNamespacesCommand = de_ListNamespacesCommand;
1252
1230
  const de_ListNamespacesCommandError = async (output, context) => {
@@ -1264,10 +1242,9 @@ const de_ListNamespacesCommandError = async (output, context) => {
1264
1242
  throw await de_ValidationExceptionRes(parsedOutput, context);
1265
1243
  default:
1266
1244
  const parsedBody = parsedOutput.body;
1267
- (0, smithy_client_1.throwDefaultError)({
1245
+ return throwDefaultError({
1268
1246
  output,
1269
1247
  parsedBody,
1270
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1271
1248
  errorCode,
1272
1249
  });
1273
1250
  }
@@ -1283,7 +1260,7 @@ const de_ListRecoveryPointsCommand = async (output, context) => {
1283
1260
  $metadata: deserializeMetadata(output),
1284
1261
  ...contents,
1285
1262
  };
1286
- return Promise.resolve(response);
1263
+ return response;
1287
1264
  };
1288
1265
  exports.de_ListRecoveryPointsCommand = de_ListRecoveryPointsCommand;
1289
1266
  const de_ListRecoveryPointsCommandError = async (output, context) => {
@@ -1301,10 +1278,9 @@ const de_ListRecoveryPointsCommandError = async (output, context) => {
1301
1278
  throw await de_ValidationExceptionRes(parsedOutput, context);
1302
1279
  default:
1303
1280
  const parsedBody = parsedOutput.body;
1304
- (0, smithy_client_1.throwDefaultError)({
1281
+ return throwDefaultError({
1305
1282
  output,
1306
1283
  parsedBody,
1307
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1308
1284
  errorCode,
1309
1285
  });
1310
1286
  }
@@ -1320,7 +1296,7 @@ const de_ListSnapshotsCommand = async (output, context) => {
1320
1296
  $metadata: deserializeMetadata(output),
1321
1297
  ...contents,
1322
1298
  };
1323
- return Promise.resolve(response);
1299
+ return response;
1324
1300
  };
1325
1301
  exports.de_ListSnapshotsCommand = de_ListSnapshotsCommand;
1326
1302
  const de_ListSnapshotsCommandError = async (output, context) => {
@@ -1341,10 +1317,9 @@ const de_ListSnapshotsCommandError = async (output, context) => {
1341
1317
  throw await de_ValidationExceptionRes(parsedOutput, context);
1342
1318
  default:
1343
1319
  const parsedBody = parsedOutput.body;
1344
- (0, smithy_client_1.throwDefaultError)({
1320
+ return throwDefaultError({
1345
1321
  output,
1346
1322
  parsedBody,
1347
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1348
1323
  errorCode,
1349
1324
  });
1350
1325
  }
@@ -1360,7 +1335,7 @@ const de_ListTableRestoreStatusCommand = async (output, context) => {
1360
1335
  $metadata: deserializeMetadata(output),
1361
1336
  ...contents,
1362
1337
  };
1363
- return Promise.resolve(response);
1338
+ return response;
1364
1339
  };
1365
1340
  exports.de_ListTableRestoreStatusCommand = de_ListTableRestoreStatusCommand;
1366
1341
  const de_ListTableRestoreStatusCommandError = async (output, context) => {
@@ -1381,10 +1356,9 @@ const de_ListTableRestoreStatusCommandError = async (output, context) => {
1381
1356
  throw await de_ValidationExceptionRes(parsedOutput, context);
1382
1357
  default:
1383
1358
  const parsedBody = parsedOutput.body;
1384
- (0, smithy_client_1.throwDefaultError)({
1359
+ return throwDefaultError({
1385
1360
  output,
1386
1361
  parsedBody,
1387
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1388
1362
  errorCode,
1389
1363
  });
1390
1364
  }
@@ -1395,12 +1369,12 @@ const de_ListTagsForResourceCommand = async (output, context) => {
1395
1369
  }
1396
1370
  const data = await parseBody(output.body, context);
1397
1371
  let contents = {};
1398
- contents = de_ListTagsForResourceResponse(data, context);
1372
+ contents = (0, smithy_client_1._json)(data);
1399
1373
  const response = {
1400
1374
  $metadata: deserializeMetadata(output),
1401
1375
  ...contents,
1402
1376
  };
1403
- return Promise.resolve(response);
1377
+ return response;
1404
1378
  };
1405
1379
  exports.de_ListTagsForResourceCommand = de_ListTagsForResourceCommand;
1406
1380
  const de_ListTagsForResourceCommandError = async (output, context) => {
@@ -1424,10 +1398,9 @@ const de_ListTagsForResourceCommandError = async (output, context) => {
1424
1398
  throw await de_ValidationExceptionRes(parsedOutput, context);
1425
1399
  default:
1426
1400
  const parsedBody = parsedOutput.body;
1427
- (0, smithy_client_1.throwDefaultError)({
1401
+ return throwDefaultError({
1428
1402
  output,
1429
1403
  parsedBody,
1430
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1431
1404
  errorCode,
1432
1405
  });
1433
1406
  }
@@ -1438,12 +1411,12 @@ const de_ListUsageLimitsCommand = async (output, context) => {
1438
1411
  }
1439
1412
  const data = await parseBody(output.body, context);
1440
1413
  let contents = {};
1441
- contents = de_ListUsageLimitsResponse(data, context);
1414
+ contents = (0, smithy_client_1._json)(data);
1442
1415
  const response = {
1443
1416
  $metadata: deserializeMetadata(output),
1444
1417
  ...contents,
1445
1418
  };
1446
- return Promise.resolve(response);
1419
+ return response;
1447
1420
  };
1448
1421
  exports.de_ListUsageLimitsCommand = de_ListUsageLimitsCommand;
1449
1422
  const de_ListUsageLimitsCommandError = async (output, context) => {
@@ -1470,10 +1443,9 @@ const de_ListUsageLimitsCommandError = async (output, context) => {
1470
1443
  throw await de_ValidationExceptionRes(parsedOutput, context);
1471
1444
  default:
1472
1445
  const parsedBody = parsedOutput.body;
1473
- (0, smithy_client_1.throwDefaultError)({
1446
+ return throwDefaultError({
1474
1447
  output,
1475
1448
  parsedBody,
1476
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1477
1449
  errorCode,
1478
1450
  });
1479
1451
  }
@@ -1489,7 +1461,7 @@ const de_ListWorkgroupsCommand = async (output, context) => {
1489
1461
  $metadata: deserializeMetadata(output),
1490
1462
  ...contents,
1491
1463
  };
1492
- return Promise.resolve(response);
1464
+ return response;
1493
1465
  };
1494
1466
  exports.de_ListWorkgroupsCommand = de_ListWorkgroupsCommand;
1495
1467
  const de_ListWorkgroupsCommandError = async (output, context) => {
@@ -1507,10 +1479,9 @@ const de_ListWorkgroupsCommandError = async (output, context) => {
1507
1479
  throw await de_ValidationExceptionRes(parsedOutput, context);
1508
1480
  default:
1509
1481
  const parsedBody = parsedOutput.body;
1510
- (0, smithy_client_1.throwDefaultError)({
1482
+ return throwDefaultError({
1511
1483
  output,
1512
1484
  parsedBody,
1513
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1514
1485
  errorCode,
1515
1486
  });
1516
1487
  }
@@ -1521,12 +1492,12 @@ const de_PutResourcePolicyCommand = async (output, context) => {
1521
1492
  }
1522
1493
  const data = await parseBody(output.body, context);
1523
1494
  let contents = {};
1524
- contents = de_PutResourcePolicyResponse(data, context);
1495
+ contents = (0, smithy_client_1._json)(data);
1525
1496
  const response = {
1526
1497
  $metadata: deserializeMetadata(output),
1527
1498
  ...contents,
1528
1499
  };
1529
- return Promise.resolve(response);
1500
+ return response;
1530
1501
  };
1531
1502
  exports.de_PutResourcePolicyCommand = de_PutResourcePolicyCommand;
1532
1503
  const de_PutResourcePolicyCommandError = async (output, context) => {
@@ -1553,10 +1524,9 @@ const de_PutResourcePolicyCommandError = async (output, context) => {
1553
1524
  throw await de_ValidationExceptionRes(parsedOutput, context);
1554
1525
  default:
1555
1526
  const parsedBody = parsedOutput.body;
1556
- (0, smithy_client_1.throwDefaultError)({
1527
+ return throwDefaultError({
1557
1528
  output,
1558
1529
  parsedBody,
1559
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1560
1530
  errorCode,
1561
1531
  });
1562
1532
  }
@@ -1572,7 +1542,7 @@ const de_RestoreFromRecoveryPointCommand = async (output, context) => {
1572
1542
  $metadata: deserializeMetadata(output),
1573
1543
  ...contents,
1574
1544
  };
1575
- return Promise.resolve(response);
1545
+ return response;
1576
1546
  };
1577
1547
  exports.de_RestoreFromRecoveryPointCommand = de_RestoreFromRecoveryPointCommand;
1578
1548
  const de_RestoreFromRecoveryPointCommandError = async (output, context) => {
@@ -1596,10 +1566,9 @@ const de_RestoreFromRecoveryPointCommandError = async (output, context) => {
1596
1566
  throw await de_ValidationExceptionRes(parsedOutput, context);
1597
1567
  default:
1598
1568
  const parsedBody = parsedOutput.body;
1599
- (0, smithy_client_1.throwDefaultError)({
1569
+ return throwDefaultError({
1600
1570
  output,
1601
1571
  parsedBody,
1602
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1603
1572
  errorCode,
1604
1573
  });
1605
1574
  }
@@ -1615,7 +1584,7 @@ const de_RestoreFromSnapshotCommand = async (output, context) => {
1615
1584
  $metadata: deserializeMetadata(output),
1616
1585
  ...contents,
1617
1586
  };
1618
- return Promise.resolve(response);
1587
+ return response;
1619
1588
  };
1620
1589
  exports.de_RestoreFromSnapshotCommand = de_RestoreFromSnapshotCommand;
1621
1590
  const de_RestoreFromSnapshotCommandError = async (output, context) => {
@@ -1642,10 +1611,9 @@ const de_RestoreFromSnapshotCommandError = async (output, context) => {
1642
1611
  throw await de_ValidationExceptionRes(parsedOutput, context);
1643
1612
  default:
1644
1613
  const parsedBody = parsedOutput.body;
1645
- (0, smithy_client_1.throwDefaultError)({
1614
+ return throwDefaultError({
1646
1615
  output,
1647
1616
  parsedBody,
1648
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1649
1617
  errorCode,
1650
1618
  });
1651
1619
  }
@@ -1661,7 +1629,7 @@ const de_RestoreTableFromSnapshotCommand = async (output, context) => {
1661
1629
  $metadata: deserializeMetadata(output),
1662
1630
  ...contents,
1663
1631
  };
1664
- return Promise.resolve(response);
1632
+ return response;
1665
1633
  };
1666
1634
  exports.de_RestoreTableFromSnapshotCommand = de_RestoreTableFromSnapshotCommand;
1667
1635
  const de_RestoreTableFromSnapshotCommandError = async (output, context) => {
@@ -1685,10 +1653,9 @@ const de_RestoreTableFromSnapshotCommandError = async (output, context) => {
1685
1653
  throw await de_ValidationExceptionRes(parsedOutput, context);
1686
1654
  default:
1687
1655
  const parsedBody = parsedOutput.body;
1688
- (0, smithy_client_1.throwDefaultError)({
1656
+ return throwDefaultError({
1689
1657
  output,
1690
1658
  parsedBody,
1691
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1692
1659
  errorCode,
1693
1660
  });
1694
1661
  }
@@ -1699,12 +1666,12 @@ const de_TagResourceCommand = async (output, context) => {
1699
1666
  }
1700
1667
  const data = await parseBody(output.body, context);
1701
1668
  let contents = {};
1702
- contents = de_TagResourceResponse(data, context);
1669
+ contents = (0, smithy_client_1._json)(data);
1703
1670
  const response = {
1704
1671
  $metadata: deserializeMetadata(output),
1705
1672
  ...contents,
1706
1673
  };
1707
- return Promise.resolve(response);
1674
+ return response;
1708
1675
  };
1709
1676
  exports.de_TagResourceCommand = de_TagResourceCommand;
1710
1677
  const de_TagResourceCommandError = async (output, context) => {
@@ -1731,10 +1698,9 @@ const de_TagResourceCommandError = async (output, context) => {
1731
1698
  throw await de_ValidationExceptionRes(parsedOutput, context);
1732
1699
  default:
1733
1700
  const parsedBody = parsedOutput.body;
1734
- (0, smithy_client_1.throwDefaultError)({
1701
+ return throwDefaultError({
1735
1702
  output,
1736
1703
  parsedBody,
1737
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1738
1704
  errorCode,
1739
1705
  });
1740
1706
  }
@@ -1745,12 +1711,12 @@ const de_UntagResourceCommand = async (output, context) => {
1745
1711
  }
1746
1712
  const data = await parseBody(output.body, context);
1747
1713
  let contents = {};
1748
- contents = de_UntagResourceResponse(data, context);
1714
+ contents = (0, smithy_client_1._json)(data);
1749
1715
  const response = {
1750
1716
  $metadata: deserializeMetadata(output),
1751
1717
  ...contents,
1752
1718
  };
1753
- return Promise.resolve(response);
1719
+ return response;
1754
1720
  };
1755
1721
  exports.de_UntagResourceCommand = de_UntagResourceCommand;
1756
1722
  const de_UntagResourceCommandError = async (output, context) => {
@@ -1774,10 +1740,9 @@ const de_UntagResourceCommandError = async (output, context) => {
1774
1740
  throw await de_ValidationExceptionRes(parsedOutput, context);
1775
1741
  default:
1776
1742
  const parsedBody = parsedOutput.body;
1777
- (0, smithy_client_1.throwDefaultError)({
1743
+ return throwDefaultError({
1778
1744
  output,
1779
1745
  parsedBody,
1780
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1781
1746
  errorCode,
1782
1747
  });
1783
1748
  }
@@ -1793,7 +1758,7 @@ const de_UpdateEndpointAccessCommand = async (output, context) => {
1793
1758
  $metadata: deserializeMetadata(output),
1794
1759
  ...contents,
1795
1760
  };
1796
- return Promise.resolve(response);
1761
+ return response;
1797
1762
  };
1798
1763
  exports.de_UpdateEndpointAccessCommand = de_UpdateEndpointAccessCommand;
1799
1764
  const de_UpdateEndpointAccessCommandError = async (output, context) => {
@@ -1820,10 +1785,9 @@ const de_UpdateEndpointAccessCommandError = async (output, context) => {
1820
1785
  throw await de_ValidationExceptionRes(parsedOutput, context);
1821
1786
  default:
1822
1787
  const parsedBody = parsedOutput.body;
1823
- (0, smithy_client_1.throwDefaultError)({
1788
+ return throwDefaultError({
1824
1789
  output,
1825
1790
  parsedBody,
1826
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1827
1791
  errorCode,
1828
1792
  });
1829
1793
  }
@@ -1839,7 +1803,7 @@ const de_UpdateNamespaceCommand = async (output, context) => {
1839
1803
  $metadata: deserializeMetadata(output),
1840
1804
  ...contents,
1841
1805
  };
1842
- return Promise.resolve(response);
1806
+ return response;
1843
1807
  };
1844
1808
  exports.de_UpdateNamespaceCommand = de_UpdateNamespaceCommand;
1845
1809
  const de_UpdateNamespaceCommandError = async (output, context) => {
@@ -1863,10 +1827,9 @@ const de_UpdateNamespaceCommandError = async (output, context) => {
1863
1827
  throw await de_ValidationExceptionRes(parsedOutput, context);
1864
1828
  default:
1865
1829
  const parsedBody = parsedOutput.body;
1866
- (0, smithy_client_1.throwDefaultError)({
1830
+ return throwDefaultError({
1867
1831
  output,
1868
1832
  parsedBody,
1869
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1870
1833
  errorCode,
1871
1834
  });
1872
1835
  }
@@ -1882,7 +1845,7 @@ const de_UpdateSnapshotCommand = async (output, context) => {
1882
1845
  $metadata: deserializeMetadata(output),
1883
1846
  ...contents,
1884
1847
  };
1885
- return Promise.resolve(response);
1848
+ return response;
1886
1849
  };
1887
1850
  exports.de_UpdateSnapshotCommand = de_UpdateSnapshotCommand;
1888
1851
  const de_UpdateSnapshotCommandError = async (output, context) => {
@@ -1906,10 +1869,9 @@ const de_UpdateSnapshotCommandError = async (output, context) => {
1906
1869
  throw await de_ValidationExceptionRes(parsedOutput, context);
1907
1870
  default:
1908
1871
  const parsedBody = parsedOutput.body;
1909
- (0, smithy_client_1.throwDefaultError)({
1872
+ return throwDefaultError({
1910
1873
  output,
1911
1874
  parsedBody,
1912
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1913
1875
  errorCode,
1914
1876
  });
1915
1877
  }
@@ -1920,12 +1882,12 @@ const de_UpdateUsageLimitCommand = async (output, context) => {
1920
1882
  }
1921
1883
  const data = await parseBody(output.body, context);
1922
1884
  let contents = {};
1923
- contents = de_UpdateUsageLimitResponse(data, context);
1885
+ contents = (0, smithy_client_1._json)(data);
1924
1886
  const response = {
1925
1887
  $metadata: deserializeMetadata(output),
1926
1888
  ...contents,
1927
1889
  };
1928
- return Promise.resolve(response);
1890
+ return response;
1929
1891
  };
1930
1892
  exports.de_UpdateUsageLimitCommand = de_UpdateUsageLimitCommand;
1931
1893
  const de_UpdateUsageLimitCommandError = async (output, context) => {
@@ -1949,10 +1911,9 @@ const de_UpdateUsageLimitCommandError = async (output, context) => {
1949
1911
  throw await de_ValidationExceptionRes(parsedOutput, context);
1950
1912
  default:
1951
1913
  const parsedBody = parsedOutput.body;
1952
- (0, smithy_client_1.throwDefaultError)({
1914
+ return throwDefaultError({
1953
1915
  output,
1954
1916
  parsedBody,
1955
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
1956
1917
  errorCode,
1957
1918
  });
1958
1919
  }
@@ -1968,7 +1929,7 @@ const de_UpdateWorkgroupCommand = async (output, context) => {
1968
1929
  $metadata: deserializeMetadata(output),
1969
1930
  ...contents,
1970
1931
  };
1971
- return Promise.resolve(response);
1932
+ return response;
1972
1933
  };
1973
1934
  exports.de_UpdateWorkgroupCommand = de_UpdateWorkgroupCommand;
1974
1935
  const de_UpdateWorkgroupCommandError = async (output, context) => {
@@ -1995,17 +1956,16 @@ const de_UpdateWorkgroupCommandError = async (output, context) => {
1995
1956
  throw await de_ValidationExceptionRes(parsedOutput, context);
1996
1957
  default:
1997
1958
  const parsedBody = parsedOutput.body;
1998
- (0, smithy_client_1.throwDefaultError)({
1959
+ return throwDefaultError({
1999
1960
  output,
2000
1961
  parsedBody,
2001
- exceptionCtor: RedshiftServerlessServiceException_1.RedshiftServerlessServiceException,
2002
1962
  errorCode,
2003
1963
  });
2004
1964
  }
2005
1965
  };
2006
1966
  const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
2007
1967
  const body = parsedOutput.body;
2008
- const deserialized = de_AccessDeniedException(body, context);
1968
+ const deserialized = (0, smithy_client_1._json)(body);
2009
1969
  const exception = new models_0_1.AccessDeniedException({
2010
1970
  $metadata: deserializeMetadata(parsedOutput),
2011
1971
  ...deserialized,
@@ -2014,7 +1974,7 @@ const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
2014
1974
  };
2015
1975
  const de_ConflictExceptionRes = async (parsedOutput, context) => {
2016
1976
  const body = parsedOutput.body;
2017
- const deserialized = de_ConflictException(body, context);
1977
+ const deserialized = (0, smithy_client_1._json)(body);
2018
1978
  const exception = new models_0_1.ConflictException({
2019
1979
  $metadata: deserializeMetadata(parsedOutput),
2020
1980
  ...deserialized,
@@ -2023,7 +1983,7 @@ const de_ConflictExceptionRes = async (parsedOutput, context) => {
2023
1983
  };
2024
1984
  const de_InsufficientCapacityExceptionRes = async (parsedOutput, context) => {
2025
1985
  const body = parsedOutput.body;
2026
- const deserialized = de_InsufficientCapacityException(body, context);
1986
+ const deserialized = (0, smithy_client_1._json)(body);
2027
1987
  const exception = new models_0_1.InsufficientCapacityException({
2028
1988
  $metadata: deserializeMetadata(parsedOutput),
2029
1989
  ...deserialized,
@@ -2032,7 +1992,7 @@ const de_InsufficientCapacityExceptionRes = async (parsedOutput, context) => {
2032
1992
  };
2033
1993
  const de_InternalServerExceptionRes = async (parsedOutput, context) => {
2034
1994
  const body = parsedOutput.body;
2035
- const deserialized = de_InternalServerException(body, context);
1995
+ const deserialized = (0, smithy_client_1._json)(body);
2036
1996
  const exception = new models_0_1.InternalServerException({
2037
1997
  $metadata: deserializeMetadata(parsedOutput),
2038
1998
  ...deserialized,
@@ -2041,7 +2001,7 @@ const de_InternalServerExceptionRes = async (parsedOutput, context) => {
2041
2001
  };
2042
2002
  const de_InvalidPaginationExceptionRes = async (parsedOutput, context) => {
2043
2003
  const body = parsedOutput.body;
2044
- const deserialized = de_InvalidPaginationException(body, context);
2004
+ const deserialized = (0, smithy_client_1._json)(body);
2045
2005
  const exception = new models_0_1.InvalidPaginationException({
2046
2006
  $metadata: deserializeMetadata(parsedOutput),
2047
2007
  ...deserialized,
@@ -2050,7 +2010,7 @@ const de_InvalidPaginationExceptionRes = async (parsedOutput, context) => {
2050
2010
  };
2051
2011
  const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
2052
2012
  const body = parsedOutput.body;
2053
- const deserialized = de_ResourceNotFoundException(body, context);
2013
+ const deserialized = (0, smithy_client_1._json)(body);
2054
2014
  const exception = new models_0_1.ResourceNotFoundException({
2055
2015
  $metadata: deserializeMetadata(parsedOutput),
2056
2016
  ...deserialized,
@@ -2059,7 +2019,7 @@ const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
2059
2019
  };
2060
2020
  const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
2061
2021
  const body = parsedOutput.body;
2062
- const deserialized = de_ServiceQuotaExceededException(body, context);
2022
+ const deserialized = (0, smithy_client_1._json)(body);
2063
2023
  const exception = new models_0_1.ServiceQuotaExceededException({
2064
2024
  $metadata: deserializeMetadata(parsedOutput),
2065
2025
  ...deserialized,
@@ -2068,7 +2028,7 @@ const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
2068
2028
  };
2069
2029
  const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
2070
2030
  const body = parsedOutput.body;
2071
- const deserialized = de_ThrottlingException(body, context);
2031
+ const deserialized = (0, smithy_client_1._json)(body);
2072
2032
  const exception = new models_0_1.ThrottlingException({
2073
2033
  $metadata: deserializeMetadata(parsedOutput),
2074
2034
  ...deserialized,
@@ -2077,7 +2037,7 @@ const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
2077
2037
  };
2078
2038
  const de_TooManyTagsExceptionRes = async (parsedOutput, context) => {
2079
2039
  const body = parsedOutput.body;
2080
- const deserialized = de_TooManyTagsException(body, context);
2040
+ const deserialized = (0, smithy_client_1._json)(body);
2081
2041
  const exception = new models_0_1.TooManyTagsException({
2082
2042
  $metadata: deserializeMetadata(parsedOutput),
2083
2043
  ...deserialized,
@@ -2086,1009 +2046,335 @@ const de_TooManyTagsExceptionRes = async (parsedOutput, context) => {
2086
2046
  };
2087
2047
  const de_ValidationExceptionRes = async (parsedOutput, context) => {
2088
2048
  const body = parsedOutput.body;
2089
- const deserialized = de_ValidationException(body, context);
2049
+ const deserialized = (0, smithy_client_1._json)(body);
2090
2050
  const exception = new models_0_1.ValidationException({
2091
2051
  $metadata: deserializeMetadata(parsedOutput),
2092
2052
  ...deserialized,
2093
2053
  });
2094
2054
  return (0, smithy_client_1.decorateServiceException)(exception, body);
2095
2055
  };
2096
- const se_ConfigParameter = (input, context) => {
2097
- return {
2098
- ...(input.parameterKey != null && { parameterKey: input.parameterKey }),
2099
- ...(input.parameterValue != null && { parameterValue: input.parameterValue }),
2100
- };
2101
- };
2102
- const se_ConfigParameterList = (input, context) => {
2103
- return input
2104
- .filter((e) => e != null)
2105
- .map((entry) => {
2106
- return se_ConfigParameter(entry, context);
2107
- });
2108
- };
2109
- const se_ConvertRecoveryPointToSnapshotRequest = (input, context) => {
2110
- return {
2111
- ...(input.recoveryPointId != null && { recoveryPointId: input.recoveryPointId }),
2112
- ...(input.retentionPeriod != null && { retentionPeriod: input.retentionPeriod }),
2113
- ...(input.snapshotName != null && { snapshotName: input.snapshotName }),
2114
- ...(input.tags != null && { tags: se_TagList(input.tags, context) }),
2115
- };
2116
- };
2117
- const se_CreateEndpointAccessRequest = (input, context) => {
2118
- return {
2119
- ...(input.endpointName != null && { endpointName: input.endpointName }),
2120
- ...(input.subnetIds != null && { subnetIds: se_SubnetIdList(input.subnetIds, context) }),
2121
- ...(input.vpcSecurityGroupIds != null && {
2122
- vpcSecurityGroupIds: se_VpcSecurityGroupIdList(input.vpcSecurityGroupIds, context),
2123
- }),
2124
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2125
- };
2126
- };
2127
- const se_CreateNamespaceRequest = (input, context) => {
2128
- return {
2129
- ...(input.adminUserPassword != null && { adminUserPassword: input.adminUserPassword }),
2130
- ...(input.adminUsername != null && { adminUsername: input.adminUsername }),
2131
- ...(input.dbName != null && { dbName: input.dbName }),
2132
- ...(input.defaultIamRoleArn != null && { defaultIamRoleArn: input.defaultIamRoleArn }),
2133
- ...(input.iamRoles != null && { iamRoles: se_IamRoleArnList(input.iamRoles, context) }),
2134
- ...(input.kmsKeyId != null && { kmsKeyId: input.kmsKeyId }),
2135
- ...(input.logExports != null && { logExports: se_LogExportList(input.logExports, context) }),
2136
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2137
- ...(input.tags != null && { tags: se_TagList(input.tags, context) }),
2138
- };
2139
- };
2140
- const se_CreateSnapshotRequest = (input, context) => {
2141
- return {
2142
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2143
- ...(input.retentionPeriod != null && { retentionPeriod: input.retentionPeriod }),
2144
- ...(input.snapshotName != null && { snapshotName: input.snapshotName }),
2145
- ...(input.tags != null && { tags: se_TagList(input.tags, context) }),
2146
- };
2147
- };
2148
- const se_CreateUsageLimitRequest = (input, context) => {
2149
- return {
2150
- ...(input.amount != null && { amount: input.amount }),
2151
- ...(input.breachAction != null && { breachAction: input.breachAction }),
2152
- ...(input.period != null && { period: input.period }),
2153
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2154
- ...(input.usageType != null && { usageType: input.usageType }),
2155
- };
2156
- };
2157
- const se_CreateWorkgroupRequest = (input, context) => {
2158
- return {
2159
- ...(input.baseCapacity != null && { baseCapacity: input.baseCapacity }),
2160
- ...(input.configParameters != null && {
2161
- configParameters: se_ConfigParameterList(input.configParameters, context),
2162
- }),
2163
- ...(input.enhancedVpcRouting != null && { enhancedVpcRouting: input.enhancedVpcRouting }),
2164
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2165
- ...(input.port != null && { port: input.port }),
2166
- ...(input.publiclyAccessible != null && { publiclyAccessible: input.publiclyAccessible }),
2167
- ...(input.securityGroupIds != null && {
2168
- securityGroupIds: se_SecurityGroupIdList(input.securityGroupIds, context),
2169
- }),
2170
- ...(input.subnetIds != null && { subnetIds: se_SubnetIdList(input.subnetIds, context) }),
2171
- ...(input.tags != null && { tags: se_TagList(input.tags, context) }),
2172
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2173
- };
2174
- };
2175
- const se_DeleteEndpointAccessRequest = (input, context) => {
2176
- return {
2177
- ...(input.endpointName != null && { endpointName: input.endpointName }),
2178
- };
2179
- };
2180
- const se_DeleteNamespaceRequest = (input, context) => {
2181
- return {
2182
- ...(input.finalSnapshotName != null && { finalSnapshotName: input.finalSnapshotName }),
2183
- ...(input.finalSnapshotRetentionPeriod != null && {
2184
- finalSnapshotRetentionPeriod: input.finalSnapshotRetentionPeriod,
2185
- }),
2186
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2187
- };
2188
- };
2189
- const se_DeleteResourcePolicyRequest = (input, context) => {
2190
- return {
2191
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2192
- };
2193
- };
2194
- const se_DeleteSnapshotRequest = (input, context) => {
2195
- return {
2196
- ...(input.snapshotName != null && { snapshotName: input.snapshotName }),
2197
- };
2198
- };
2199
- const se_DeleteUsageLimitRequest = (input, context) => {
2200
- return {
2201
- ...(input.usageLimitId != null && { usageLimitId: input.usageLimitId }),
2202
- };
2203
- };
2204
- const se_DeleteWorkgroupRequest = (input, context) => {
2205
- return {
2206
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2207
- };
2208
- };
2209
- const se_GetCredentialsRequest = (input, context) => {
2210
- return {
2211
- ...(input.dbName != null && { dbName: input.dbName }),
2212
- ...(input.durationSeconds != null && { durationSeconds: input.durationSeconds }),
2213
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2214
- };
2215
- };
2216
- const se_GetEndpointAccessRequest = (input, context) => {
2217
- return {
2218
- ...(input.endpointName != null && { endpointName: input.endpointName }),
2219
- };
2220
- };
2221
- const se_GetNamespaceRequest = (input, context) => {
2222
- return {
2223
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2224
- };
2225
- };
2226
- const se_GetRecoveryPointRequest = (input, context) => {
2227
- return {
2228
- ...(input.recoveryPointId != null && { recoveryPointId: input.recoveryPointId }),
2229
- };
2230
- };
2231
- const se_GetResourcePolicyRequest = (input, context) => {
2232
- return {
2233
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2234
- };
2235
- };
2236
- const se_GetSnapshotRequest = (input, context) => {
2237
- return {
2238
- ...(input.ownerAccount != null && { ownerAccount: input.ownerAccount }),
2239
- ...(input.snapshotArn != null && { snapshotArn: input.snapshotArn }),
2240
- ...(input.snapshotName != null && { snapshotName: input.snapshotName }),
2241
- };
2242
- };
2243
- const se_GetTableRestoreStatusRequest = (input, context) => {
2244
- return {
2245
- ...(input.tableRestoreRequestId != null && { tableRestoreRequestId: input.tableRestoreRequestId }),
2246
- };
2247
- };
2248
- const se_GetUsageLimitRequest = (input, context) => {
2249
- return {
2250
- ...(input.usageLimitId != null && { usageLimitId: input.usageLimitId }),
2251
- };
2252
- };
2253
- const se_GetWorkgroupRequest = (input, context) => {
2254
- return {
2255
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2256
- };
2257
- };
2258
- const se_IamRoleArnList = (input, context) => {
2259
- return input
2260
- .filter((e) => e != null)
2261
- .map((entry) => {
2262
- return entry;
2263
- });
2264
- };
2265
- const se_ListEndpointAccessRequest = (input, context) => {
2266
- return {
2267
- ...(input.maxResults != null && { maxResults: input.maxResults }),
2268
- ...(input.nextToken != null && { nextToken: input.nextToken }),
2269
- ...(input.vpcId != null && { vpcId: input.vpcId }),
2270
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2271
- };
2272
- };
2273
- const se_ListNamespacesRequest = (input, context) => {
2274
- return {
2275
- ...(input.maxResults != null && { maxResults: input.maxResults }),
2276
- ...(input.nextToken != null && { nextToken: input.nextToken }),
2277
- };
2278
- };
2279
2056
  const se_ListRecoveryPointsRequest = (input, context) => {
2280
- return {
2281
- ...(input.endTime != null && { endTime: Math.round(input.endTime.getTime() / 1000) }),
2282
- ...(input.maxResults != null && { maxResults: input.maxResults }),
2283
- ...(input.namespaceArn != null && { namespaceArn: input.namespaceArn }),
2284
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2285
- ...(input.nextToken != null && { nextToken: input.nextToken }),
2286
- ...(input.startTime != null && { startTime: Math.round(input.startTime.getTime() / 1000) }),
2287
- };
2288
- };
2289
- const se_ListSnapshotsRequest = (input, context) => {
2290
- return {
2291
- ...(input.endTime != null && { endTime: Math.round(input.endTime.getTime() / 1000) }),
2292
- ...(input.maxResults != null && { maxResults: input.maxResults }),
2293
- ...(input.namespaceArn != null && { namespaceArn: input.namespaceArn }),
2294
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2295
- ...(input.nextToken != null && { nextToken: input.nextToken }),
2296
- ...(input.ownerAccount != null && { ownerAccount: input.ownerAccount }),
2297
- ...(input.startTime != null && { startTime: Math.round(input.startTime.getTime() / 1000) }),
2298
- };
2299
- };
2300
- const se_ListTableRestoreStatusRequest = (input, context) => {
2301
- return {
2302
- ...(input.maxResults != null && { maxResults: input.maxResults }),
2303
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2304
- ...(input.nextToken != null && { nextToken: input.nextToken }),
2305
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2306
- };
2307
- };
2308
- const se_ListTagsForResourceRequest = (input, context) => {
2309
- return {
2310
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2311
- };
2312
- };
2313
- const se_ListUsageLimitsRequest = (input, context) => {
2314
- return {
2315
- ...(input.maxResults != null && { maxResults: input.maxResults }),
2316
- ...(input.nextToken != null && { nextToken: input.nextToken }),
2317
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2318
- ...(input.usageType != null && { usageType: input.usageType }),
2319
- };
2320
- };
2321
- const se_ListWorkgroupsRequest = (input, context) => {
2322
- return {
2323
- ...(input.maxResults != null && { maxResults: input.maxResults }),
2324
- ...(input.nextToken != null && { nextToken: input.nextToken }),
2325
- };
2326
- };
2327
- const se_LogExportList = (input, context) => {
2328
- return input
2329
- .filter((e) => e != null)
2330
- .map((entry) => {
2331
- return entry;
2332
- });
2333
- };
2334
- const se_PutResourcePolicyRequest = (input, context) => {
2335
- return {
2336
- ...(input.policy != null && { policy: input.policy }),
2337
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2338
- };
2339
- };
2340
- const se_RestoreFromRecoveryPointRequest = (input, context) => {
2341
- return {
2342
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2343
- ...(input.recoveryPointId != null && { recoveryPointId: input.recoveryPointId }),
2344
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2345
- };
2346
- };
2347
- const se_RestoreFromSnapshotRequest = (input, context) => {
2348
- return {
2349
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2350
- ...(input.ownerAccount != null && { ownerAccount: input.ownerAccount }),
2351
- ...(input.snapshotArn != null && { snapshotArn: input.snapshotArn }),
2352
- ...(input.snapshotName != null && { snapshotName: input.snapshotName }),
2353
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2354
- };
2355
- };
2356
- const se_RestoreTableFromSnapshotRequest = (input, context) => {
2357
- return {
2358
- ...(input.activateCaseSensitiveIdentifier != null && {
2359
- activateCaseSensitiveIdentifier: input.activateCaseSensitiveIdentifier,
2360
- }),
2361
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2362
- ...(input.newTableName != null && { newTableName: input.newTableName }),
2363
- ...(input.snapshotName != null && { snapshotName: input.snapshotName }),
2364
- ...(input.sourceDatabaseName != null && { sourceDatabaseName: input.sourceDatabaseName }),
2365
- ...(input.sourceSchemaName != null && { sourceSchemaName: input.sourceSchemaName }),
2366
- ...(input.sourceTableName != null && { sourceTableName: input.sourceTableName }),
2367
- ...(input.targetDatabaseName != null && { targetDatabaseName: input.targetDatabaseName }),
2368
- ...(input.targetSchemaName != null && { targetSchemaName: input.targetSchemaName }),
2369
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2370
- };
2371
- };
2372
- const se_SecurityGroupIdList = (input, context) => {
2373
- return input
2374
- .filter((e) => e != null)
2375
- .map((entry) => {
2376
- return entry;
2377
- });
2378
- };
2379
- const se_SubnetIdList = (input, context) => {
2380
- return input
2381
- .filter((e) => e != null)
2382
- .map((entry) => {
2383
- return entry;
2384
- });
2385
- };
2386
- const se_Tag = (input, context) => {
2387
- return {
2388
- ...(input.key != null && { key: input.key }),
2389
- ...(input.value != null && { value: input.value }),
2390
- };
2391
- };
2392
- const se_TagKeyList = (input, context) => {
2393
- return input
2394
- .filter((e) => e != null)
2395
- .map((entry) => {
2396
- return entry;
2397
- });
2398
- };
2399
- const se_TagList = (input, context) => {
2400
- return input
2401
- .filter((e) => e != null)
2402
- .map((entry) => {
2403
- return se_Tag(entry, context);
2404
- });
2405
- };
2406
- const se_TagResourceRequest = (input, context) => {
2407
- return {
2408
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2409
- ...(input.tags != null && { tags: se_TagList(input.tags, context) }),
2410
- };
2411
- };
2412
- const se_UntagResourceRequest = (input, context) => {
2413
- return {
2414
- ...(input.resourceArn != null && { resourceArn: input.resourceArn }),
2415
- ...(input.tagKeys != null && { tagKeys: se_TagKeyList(input.tagKeys, context) }),
2416
- };
2417
- };
2418
- const se_UpdateEndpointAccessRequest = (input, context) => {
2419
- return {
2420
- ...(input.endpointName != null && { endpointName: input.endpointName }),
2421
- ...(input.vpcSecurityGroupIds != null && {
2422
- vpcSecurityGroupIds: se_VpcSecurityGroupIdList(input.vpcSecurityGroupIds, context),
2423
- }),
2424
- };
2425
- };
2426
- const se_UpdateNamespaceRequest = (input, context) => {
2427
- return {
2428
- ...(input.adminUserPassword != null && { adminUserPassword: input.adminUserPassword }),
2429
- ...(input.adminUsername != null && { adminUsername: input.adminUsername }),
2430
- ...(input.defaultIamRoleArn != null && { defaultIamRoleArn: input.defaultIamRoleArn }),
2431
- ...(input.iamRoles != null && { iamRoles: se_IamRoleArnList(input.iamRoles, context) }),
2432
- ...(input.kmsKeyId != null && { kmsKeyId: input.kmsKeyId }),
2433
- ...(input.logExports != null && { logExports: se_LogExportList(input.logExports, context) }),
2434
- ...(input.namespaceName != null && { namespaceName: input.namespaceName }),
2435
- };
2436
- };
2437
- const se_UpdateSnapshotRequest = (input, context) => {
2438
- return {
2439
- ...(input.retentionPeriod != null && { retentionPeriod: input.retentionPeriod }),
2440
- ...(input.snapshotName != null && { snapshotName: input.snapshotName }),
2441
- };
2442
- };
2443
- const se_UpdateUsageLimitRequest = (input, context) => {
2444
- return {
2445
- ...(input.amount != null && { amount: input.amount }),
2446
- ...(input.breachAction != null && { breachAction: input.breachAction }),
2447
- ...(input.usageLimitId != null && { usageLimitId: input.usageLimitId }),
2448
- };
2449
- };
2450
- const se_UpdateWorkgroupRequest = (input, context) => {
2451
- return {
2452
- ...(input.baseCapacity != null && { baseCapacity: input.baseCapacity }),
2453
- ...(input.configParameters != null && {
2454
- configParameters: se_ConfigParameterList(input.configParameters, context),
2455
- }),
2456
- ...(input.enhancedVpcRouting != null && { enhancedVpcRouting: input.enhancedVpcRouting }),
2457
- ...(input.port != null && { port: input.port }),
2458
- ...(input.publiclyAccessible != null && { publiclyAccessible: input.publiclyAccessible }),
2459
- ...(input.securityGroupIds != null && {
2460
- securityGroupIds: se_SecurityGroupIdList(input.securityGroupIds, context),
2461
- }),
2462
- ...(input.subnetIds != null && { subnetIds: se_SubnetIdList(input.subnetIds, context) }),
2463
- ...(input.workgroupName != null && { workgroupName: input.workgroupName }),
2464
- };
2465
- };
2466
- const se_VpcSecurityGroupIdList = (input, context) => {
2467
- return input
2468
- .filter((e) => e != null)
2469
- .map((entry) => {
2470
- return entry;
2057
+ return (0, smithy_client_1.take)(input, {
2058
+ endTime: (_) => Math.round(_.getTime() / 1000),
2059
+ maxResults: [],
2060
+ namespaceArn: [],
2061
+ namespaceName: [],
2062
+ nextToken: [],
2063
+ startTime: (_) => Math.round(_.getTime() / 1000),
2471
2064
  });
2472
2065
  };
2473
- const de_AccessDeniedException = (output, context) => {
2474
- return {
2475
- code: (0, smithy_client_1.expectString)(output.code),
2476
- message: (0, smithy_client_1.expectString)(output.message),
2477
- };
2478
- };
2479
- const de_AccountIdList = (output, context) => {
2480
- const retVal = (output || [])
2481
- .filter((e) => e != null)
2482
- .map((entry) => {
2483
- if (entry === null) {
2484
- return null;
2485
- }
2486
- return (0, smithy_client_1.expectString)(entry);
2487
- });
2488
- return retVal;
2489
- };
2490
- const de_ConfigParameter = (output, context) => {
2491
- return {
2492
- parameterKey: (0, smithy_client_1.expectString)(output.parameterKey),
2493
- parameterValue: (0, smithy_client_1.expectString)(output.parameterValue),
2494
- };
2495
- };
2496
- const de_ConfigParameterList = (output, context) => {
2497
- const retVal = (output || [])
2498
- .filter((e) => e != null)
2499
- .map((entry) => {
2500
- if (entry === null) {
2501
- return null;
2502
- }
2503
- return de_ConfigParameter(entry, context);
2066
+ const se_ListSnapshotsRequest = (input, context) => {
2067
+ return (0, smithy_client_1.take)(input, {
2068
+ endTime: (_) => Math.round(_.getTime() / 1000),
2069
+ maxResults: [],
2070
+ namespaceArn: [],
2071
+ namespaceName: [],
2072
+ nextToken: [],
2073
+ ownerAccount: [],
2074
+ startTime: (_) => Math.round(_.getTime() / 1000),
2504
2075
  });
2505
- return retVal;
2506
- };
2507
- const de_ConflictException = (output, context) => {
2508
- return {
2509
- message: (0, smithy_client_1.expectString)(output.message),
2510
- };
2511
2076
  };
2512
2077
  const de_ConvertRecoveryPointToSnapshotResponse = (output, context) => {
2513
- return {
2514
- snapshot: output.snapshot != null ? de_Snapshot(output.snapshot, context) : undefined,
2515
- };
2078
+ return (0, smithy_client_1.take)(output, {
2079
+ snapshot: (_) => de_Snapshot(_, context),
2080
+ });
2516
2081
  };
2517
2082
  const de_CreateEndpointAccessResponse = (output, context) => {
2518
- return {
2519
- endpoint: output.endpoint != null ? de_EndpointAccess(output.endpoint, context) : undefined,
2520
- };
2083
+ return (0, smithy_client_1.take)(output, {
2084
+ endpoint: (_) => de_EndpointAccess(_, context),
2085
+ });
2521
2086
  };
2522
2087
  const de_CreateNamespaceResponse = (output, context) => {
2523
- return {
2524
- namespace: output.namespace != null ? de_Namespace(output.namespace, context) : undefined,
2525
- };
2088
+ return (0, smithy_client_1.take)(output, {
2089
+ namespace: (_) => de_Namespace(_, context),
2090
+ });
2526
2091
  };
2527
2092
  const de_CreateSnapshotResponse = (output, context) => {
2528
- return {
2529
- snapshot: output.snapshot != null ? de_Snapshot(output.snapshot, context) : undefined,
2530
- };
2531
- };
2532
- const de_CreateUsageLimitResponse = (output, context) => {
2533
- return {
2534
- usageLimit: output.usageLimit != null ? de_UsageLimit(output.usageLimit, context) : undefined,
2535
- };
2093
+ return (0, smithy_client_1.take)(output, {
2094
+ snapshot: (_) => de_Snapshot(_, context),
2095
+ });
2536
2096
  };
2537
2097
  const de_CreateWorkgroupResponse = (output, context) => {
2538
- return {
2539
- workgroup: output.workgroup != null ? de_Workgroup(output.workgroup, context) : undefined,
2540
- };
2098
+ return (0, smithy_client_1.take)(output, {
2099
+ workgroup: (_) => de_Workgroup(_, context),
2100
+ });
2541
2101
  };
2542
2102
  const de_DeleteEndpointAccessResponse = (output, context) => {
2543
- return {
2544
- endpoint: output.endpoint != null ? de_EndpointAccess(output.endpoint, context) : undefined,
2545
- };
2103
+ return (0, smithy_client_1.take)(output, {
2104
+ endpoint: (_) => de_EndpointAccess(_, context),
2105
+ });
2546
2106
  };
2547
2107
  const de_DeleteNamespaceResponse = (output, context) => {
2548
- return {
2549
- namespace: output.namespace != null ? de_Namespace(output.namespace, context) : undefined,
2550
- };
2551
- };
2552
- const de_DeleteResourcePolicyResponse = (output, context) => {
2553
- return {};
2108
+ return (0, smithy_client_1.take)(output, {
2109
+ namespace: (_) => de_Namespace(_, context),
2110
+ });
2554
2111
  };
2555
2112
  const de_DeleteSnapshotResponse = (output, context) => {
2556
- return {
2557
- snapshot: output.snapshot != null ? de_Snapshot(output.snapshot, context) : undefined,
2558
- };
2559
- };
2560
- const de_DeleteUsageLimitResponse = (output, context) => {
2561
- return {
2562
- usageLimit: output.usageLimit != null ? de_UsageLimit(output.usageLimit, context) : undefined,
2563
- };
2113
+ return (0, smithy_client_1.take)(output, {
2114
+ snapshot: (_) => de_Snapshot(_, context),
2115
+ });
2564
2116
  };
2565
2117
  const de_DeleteWorkgroupResponse = (output, context) => {
2566
- return {
2567
- workgroup: output.workgroup != null ? de_Workgroup(output.workgroup, context) : undefined,
2568
- };
2569
- };
2570
- const de_Endpoint = (output, context) => {
2571
- return {
2572
- address: (0, smithy_client_1.expectString)(output.address),
2573
- port: (0, smithy_client_1.expectInt32)(output.port),
2574
- vpcEndpoints: output.vpcEndpoints != null ? de_VpcEndpointList(output.vpcEndpoints, context) : undefined,
2575
- };
2118
+ return (0, smithy_client_1.take)(output, {
2119
+ workgroup: (_) => de_Workgroup(_, context),
2120
+ });
2576
2121
  };
2577
2122
  const de_EndpointAccess = (output, context) => {
2578
- return {
2579
- address: (0, smithy_client_1.expectString)(output.address),
2580
- endpointArn: (0, smithy_client_1.expectString)(output.endpointArn),
2581
- endpointCreateTime: output.endpointCreateTime != null
2582
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(output.endpointCreateTime))
2583
- : undefined,
2584
- endpointName: (0, smithy_client_1.expectString)(output.endpointName),
2585
- endpointStatus: (0, smithy_client_1.expectString)(output.endpointStatus),
2586
- port: (0, smithy_client_1.expectInt32)(output.port),
2587
- subnetIds: output.subnetIds != null ? de_SubnetIdList(output.subnetIds, context) : undefined,
2588
- vpcEndpoint: output.vpcEndpoint != null ? de_VpcEndpoint(output.vpcEndpoint, context) : undefined,
2589
- vpcSecurityGroups: output.vpcSecurityGroups != null
2590
- ? de_VpcSecurityGroupMembershipList(output.vpcSecurityGroups, context)
2591
- : undefined,
2592
- workgroupName: (0, smithy_client_1.expectString)(output.workgroupName),
2593
- };
2123
+ return (0, smithy_client_1.take)(output, {
2124
+ address: smithy_client_1.expectString,
2125
+ endpointArn: smithy_client_1.expectString,
2126
+ endpointCreateTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
2127
+ endpointName: smithy_client_1.expectString,
2128
+ endpointStatus: smithy_client_1.expectString,
2129
+ port: smithy_client_1.expectInt32,
2130
+ subnetIds: smithy_client_1._json,
2131
+ vpcEndpoint: smithy_client_1._json,
2132
+ vpcSecurityGroups: smithy_client_1._json,
2133
+ workgroupName: smithy_client_1.expectString,
2134
+ });
2594
2135
  };
2595
2136
  const de_EndpointAccessList = (output, context) => {
2596
2137
  const retVal = (output || [])
2597
2138
  .filter((e) => e != null)
2598
2139
  .map((entry) => {
2599
- if (entry === null) {
2600
- return null;
2601
- }
2602
2140
  return de_EndpointAccess(entry, context);
2603
2141
  });
2604
2142
  return retVal;
2605
2143
  };
2606
2144
  const de_GetCredentialsResponse = (output, context) => {
2607
- return {
2608
- dbPassword: (0, smithy_client_1.expectString)(output.dbPassword),
2609
- dbUser: (0, smithy_client_1.expectString)(output.dbUser),
2610
- expiration: output.expiration != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.expiration))) : undefined,
2611
- nextRefreshTime: output.nextRefreshTime != null
2612
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.nextRefreshTime)))
2613
- : undefined,
2614
- };
2145
+ return (0, smithy_client_1.take)(output, {
2146
+ dbPassword: smithy_client_1.expectString,
2147
+ dbUser: smithy_client_1.expectString,
2148
+ expiration: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
2149
+ nextRefreshTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
2150
+ });
2615
2151
  };
2616
2152
  const de_GetEndpointAccessResponse = (output, context) => {
2617
- return {
2618
- endpoint: output.endpoint != null ? de_EndpointAccess(output.endpoint, context) : undefined,
2619
- };
2153
+ return (0, smithy_client_1.take)(output, {
2154
+ endpoint: (_) => de_EndpointAccess(_, context),
2155
+ });
2620
2156
  };
2621
2157
  const de_GetNamespaceResponse = (output, context) => {
2622
- return {
2623
- namespace: output.namespace != null ? de_Namespace(output.namespace, context) : undefined,
2624
- };
2158
+ return (0, smithy_client_1.take)(output, {
2159
+ namespace: (_) => de_Namespace(_, context),
2160
+ });
2625
2161
  };
2626
2162
  const de_GetRecoveryPointResponse = (output, context) => {
2627
- return {
2628
- recoveryPoint: output.recoveryPoint != null ? de_RecoveryPoint(output.recoveryPoint, context) : undefined,
2629
- };
2630
- };
2631
- const de_GetResourcePolicyResponse = (output, context) => {
2632
- return {
2633
- resourcePolicy: output.resourcePolicy != null ? de_ResourcePolicy(output.resourcePolicy, context) : undefined,
2634
- };
2163
+ return (0, smithy_client_1.take)(output, {
2164
+ recoveryPoint: (_) => de_RecoveryPoint(_, context),
2165
+ });
2635
2166
  };
2636
2167
  const de_GetSnapshotResponse = (output, context) => {
2637
- return {
2638
- snapshot: output.snapshot != null ? de_Snapshot(output.snapshot, context) : undefined,
2639
- };
2168
+ return (0, smithy_client_1.take)(output, {
2169
+ snapshot: (_) => de_Snapshot(_, context),
2170
+ });
2640
2171
  };
2641
2172
  const de_GetTableRestoreStatusResponse = (output, context) => {
2642
- return {
2643
- tableRestoreStatus: output.tableRestoreStatus != null ? de_TableRestoreStatus(output.tableRestoreStatus, context) : undefined,
2644
- };
2645
- };
2646
- const de_GetUsageLimitResponse = (output, context) => {
2647
- return {
2648
- usageLimit: output.usageLimit != null ? de_UsageLimit(output.usageLimit, context) : undefined,
2649
- };
2173
+ return (0, smithy_client_1.take)(output, {
2174
+ tableRestoreStatus: (_) => de_TableRestoreStatus(_, context),
2175
+ });
2650
2176
  };
2651
2177
  const de_GetWorkgroupResponse = (output, context) => {
2652
- return {
2653
- workgroup: output.workgroup != null ? de_Workgroup(output.workgroup, context) : undefined,
2654
- };
2655
- };
2656
- const de_IamRoleArnList = (output, context) => {
2657
- const retVal = (output || [])
2658
- .filter((e) => e != null)
2659
- .map((entry) => {
2660
- if (entry === null) {
2661
- return null;
2662
- }
2663
- return (0, smithy_client_1.expectString)(entry);
2178
+ return (0, smithy_client_1.take)(output, {
2179
+ workgroup: (_) => de_Workgroup(_, context),
2664
2180
  });
2665
- return retVal;
2666
- };
2667
- const de_InsufficientCapacityException = (output, context) => {
2668
- return {
2669
- message: (0, smithy_client_1.expectString)(output.message),
2670
- };
2671
- };
2672
- const de_InternalServerException = (output, context) => {
2673
- return {
2674
- message: (0, smithy_client_1.expectString)(output.message),
2675
- };
2676
- };
2677
- const de_InvalidPaginationException = (output, context) => {
2678
- return {
2679
- message: (0, smithy_client_1.expectString)(output.message),
2680
- };
2681
2181
  };
2682
2182
  const de_ListEndpointAccessResponse = (output, context) => {
2683
- return {
2684
- endpoints: output.endpoints != null ? de_EndpointAccessList(output.endpoints, context) : undefined,
2685
- nextToken: (0, smithy_client_1.expectString)(output.nextToken),
2686
- };
2183
+ return (0, smithy_client_1.take)(output, {
2184
+ endpoints: (_) => de_EndpointAccessList(_, context),
2185
+ nextToken: smithy_client_1.expectString,
2186
+ });
2687
2187
  };
2688
2188
  const de_ListNamespacesResponse = (output, context) => {
2689
- return {
2690
- namespaces: output.namespaces != null ? de_NamespaceList(output.namespaces, context) : undefined,
2691
- nextToken: (0, smithy_client_1.expectString)(output.nextToken),
2692
- };
2189
+ return (0, smithy_client_1.take)(output, {
2190
+ namespaces: (_) => de_NamespaceList(_, context),
2191
+ nextToken: smithy_client_1.expectString,
2192
+ });
2693
2193
  };
2694
2194
  const de_ListRecoveryPointsResponse = (output, context) => {
2695
- return {
2696
- nextToken: (0, smithy_client_1.expectString)(output.nextToken),
2697
- recoveryPoints: output.recoveryPoints != null ? de_RecoveryPointList(output.recoveryPoints, context) : undefined,
2698
- };
2195
+ return (0, smithy_client_1.take)(output, {
2196
+ nextToken: smithy_client_1.expectString,
2197
+ recoveryPoints: (_) => de_RecoveryPointList(_, context),
2198
+ });
2699
2199
  };
2700
2200
  const de_ListSnapshotsResponse = (output, context) => {
2701
- return {
2702
- nextToken: (0, smithy_client_1.expectString)(output.nextToken),
2703
- snapshots: output.snapshots != null ? de_SnapshotList(output.snapshots, context) : undefined,
2704
- };
2201
+ return (0, smithy_client_1.take)(output, {
2202
+ nextToken: smithy_client_1.expectString,
2203
+ snapshots: (_) => de_SnapshotList(_, context),
2204
+ });
2705
2205
  };
2706
2206
  const de_ListTableRestoreStatusResponse = (output, context) => {
2707
- return {
2708
- nextToken: (0, smithy_client_1.expectString)(output.nextToken),
2709
- tableRestoreStatuses: output.tableRestoreStatuses != null ? de_TableRestoreStatusList(output.tableRestoreStatuses, context) : undefined,
2710
- };
2711
- };
2712
- const de_ListTagsForResourceResponse = (output, context) => {
2713
- return {
2714
- tags: output.tags != null ? de_TagList(output.tags, context) : undefined,
2715
- };
2716
- };
2717
- const de_ListUsageLimitsResponse = (output, context) => {
2718
- return {
2719
- nextToken: (0, smithy_client_1.expectString)(output.nextToken),
2720
- usageLimits: output.usageLimits != null ? de_UsageLimits(output.usageLimits, context) : undefined,
2721
- };
2207
+ return (0, smithy_client_1.take)(output, {
2208
+ nextToken: smithy_client_1.expectString,
2209
+ tableRestoreStatuses: (_) => de_TableRestoreStatusList(_, context),
2210
+ });
2722
2211
  };
2723
2212
  const de_ListWorkgroupsResponse = (output, context) => {
2724
- return {
2725
- nextToken: (0, smithy_client_1.expectString)(output.nextToken),
2726
- workgroups: output.workgroups != null ? de_WorkgroupList(output.workgroups, context) : undefined,
2727
- };
2728
- };
2729
- const de_LogExportList = (output, context) => {
2730
- const retVal = (output || [])
2731
- .filter((e) => e != null)
2732
- .map((entry) => {
2733
- if (entry === null) {
2734
- return null;
2735
- }
2736
- return (0, smithy_client_1.expectString)(entry);
2213
+ return (0, smithy_client_1.take)(output, {
2214
+ nextToken: smithy_client_1.expectString,
2215
+ workgroups: (_) => de_WorkgroupList(_, context),
2737
2216
  });
2738
- return retVal;
2739
2217
  };
2740
2218
  const de_Namespace = (output, context) => {
2741
- return {
2742
- adminUsername: (0, smithy_client_1.expectString)(output.adminUsername),
2743
- creationDate: output.creationDate != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(output.creationDate)) : undefined,
2744
- dbName: (0, smithy_client_1.expectString)(output.dbName),
2745
- defaultIamRoleArn: (0, smithy_client_1.expectString)(output.defaultIamRoleArn),
2746
- iamRoles: output.iamRoles != null ? de_IamRoleArnList(output.iamRoles, context) : undefined,
2747
- kmsKeyId: (0, smithy_client_1.expectString)(output.kmsKeyId),
2748
- logExports: output.logExports != null ? de_LogExportList(output.logExports, context) : undefined,
2749
- namespaceArn: (0, smithy_client_1.expectString)(output.namespaceArn),
2750
- namespaceId: (0, smithy_client_1.expectString)(output.namespaceId),
2751
- namespaceName: (0, smithy_client_1.expectString)(output.namespaceName),
2752
- status: (0, smithy_client_1.expectString)(output.status),
2753
- };
2219
+ return (0, smithy_client_1.take)(output, {
2220
+ adminUsername: smithy_client_1.expectString,
2221
+ creationDate: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
2222
+ dbName: smithy_client_1.expectString,
2223
+ defaultIamRoleArn: smithy_client_1.expectString,
2224
+ iamRoles: smithy_client_1._json,
2225
+ kmsKeyId: smithy_client_1.expectString,
2226
+ logExports: smithy_client_1._json,
2227
+ namespaceArn: smithy_client_1.expectString,
2228
+ namespaceId: smithy_client_1.expectString,
2229
+ namespaceName: smithy_client_1.expectString,
2230
+ status: smithy_client_1.expectString,
2231
+ });
2754
2232
  };
2755
2233
  const de_NamespaceList = (output, context) => {
2756
2234
  const retVal = (output || [])
2757
2235
  .filter((e) => e != null)
2758
2236
  .map((entry) => {
2759
- if (entry === null) {
2760
- return null;
2761
- }
2762
2237
  return de_Namespace(entry, context);
2763
2238
  });
2764
2239
  return retVal;
2765
2240
  };
2766
- const de_NetworkInterface = (output, context) => {
2767
- return {
2768
- availabilityZone: (0, smithy_client_1.expectString)(output.availabilityZone),
2769
- networkInterfaceId: (0, smithy_client_1.expectString)(output.networkInterfaceId),
2770
- privateIpAddress: (0, smithy_client_1.expectString)(output.privateIpAddress),
2771
- subnetId: (0, smithy_client_1.expectString)(output.subnetId),
2772
- };
2773
- };
2774
- const de_NetworkInterfaceList = (output, context) => {
2775
- const retVal = (output || [])
2776
- .filter((e) => e != null)
2777
- .map((entry) => {
2778
- if (entry === null) {
2779
- return null;
2780
- }
2781
- return de_NetworkInterface(entry, context);
2782
- });
2783
- return retVal;
2784
- };
2785
- const de_PutResourcePolicyResponse = (output, context) => {
2786
- return {
2787
- resourcePolicy: output.resourcePolicy != null ? de_ResourcePolicy(output.resourcePolicy, context) : undefined,
2788
- };
2789
- };
2790
2241
  const de_RecoveryPoint = (output, context) => {
2791
- return {
2792
- namespaceArn: (0, smithy_client_1.expectString)(output.namespaceArn),
2793
- namespaceName: (0, smithy_client_1.expectString)(output.namespaceName),
2794
- recoveryPointCreateTime: output.recoveryPointCreateTime != null
2795
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(output.recoveryPointCreateTime))
2796
- : undefined,
2797
- recoveryPointId: (0, smithy_client_1.expectString)(output.recoveryPointId),
2798
- totalSizeInMegaBytes: (0, smithy_client_1.limitedParseDouble)(output.totalSizeInMegaBytes),
2799
- workgroupName: (0, smithy_client_1.expectString)(output.workgroupName),
2800
- };
2242
+ return (0, smithy_client_1.take)(output, {
2243
+ namespaceArn: smithy_client_1.expectString,
2244
+ namespaceName: smithy_client_1.expectString,
2245
+ recoveryPointCreateTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
2246
+ recoveryPointId: smithy_client_1.expectString,
2247
+ totalSizeInMegaBytes: smithy_client_1.limitedParseDouble,
2248
+ workgroupName: smithy_client_1.expectString,
2249
+ });
2801
2250
  };
2802
2251
  const de_RecoveryPointList = (output, context) => {
2803
2252
  const retVal = (output || [])
2804
2253
  .filter((e) => e != null)
2805
2254
  .map((entry) => {
2806
- if (entry === null) {
2807
- return null;
2808
- }
2809
2255
  return de_RecoveryPoint(entry, context);
2810
2256
  });
2811
2257
  return retVal;
2812
2258
  };
2813
- const de_ResourceNotFoundException = (output, context) => {
2814
- return {
2815
- message: (0, smithy_client_1.expectString)(output.message),
2816
- resourceName: (0, smithy_client_1.expectString)(output.resourceName),
2817
- };
2818
- };
2819
- const de_ResourcePolicy = (output, context) => {
2820
- return {
2821
- policy: (0, smithy_client_1.expectString)(output.policy),
2822
- resourceArn: (0, smithy_client_1.expectString)(output.resourceArn),
2823
- };
2824
- };
2825
2259
  const de_RestoreFromRecoveryPointResponse = (output, context) => {
2826
- return {
2827
- namespace: output.namespace != null ? de_Namespace(output.namespace, context) : undefined,
2828
- recoveryPointId: (0, smithy_client_1.expectString)(output.recoveryPointId),
2829
- };
2260
+ return (0, smithy_client_1.take)(output, {
2261
+ namespace: (_) => de_Namespace(_, context),
2262
+ recoveryPointId: smithy_client_1.expectString,
2263
+ });
2830
2264
  };
2831
2265
  const de_RestoreFromSnapshotResponse = (output, context) => {
2832
- return {
2833
- namespace: output.namespace != null ? de_Namespace(output.namespace, context) : undefined,
2834
- ownerAccount: (0, smithy_client_1.expectString)(output.ownerAccount),
2835
- snapshotName: (0, smithy_client_1.expectString)(output.snapshotName),
2836
- };
2266
+ return (0, smithy_client_1.take)(output, {
2267
+ namespace: (_) => de_Namespace(_, context),
2268
+ ownerAccount: smithy_client_1.expectString,
2269
+ snapshotName: smithy_client_1.expectString,
2270
+ });
2837
2271
  };
2838
2272
  const de_RestoreTableFromSnapshotResponse = (output, context) => {
2839
- return {
2840
- tableRestoreStatus: output.tableRestoreStatus != null ? de_TableRestoreStatus(output.tableRestoreStatus, context) : undefined,
2841
- };
2842
- };
2843
- const de_SecurityGroupIdList = (output, context) => {
2844
- const retVal = (output || [])
2845
- .filter((e) => e != null)
2846
- .map((entry) => {
2847
- if (entry === null) {
2848
- return null;
2849
- }
2850
- return (0, smithy_client_1.expectString)(entry);
2273
+ return (0, smithy_client_1.take)(output, {
2274
+ tableRestoreStatus: (_) => de_TableRestoreStatus(_, context),
2851
2275
  });
2852
- return retVal;
2853
- };
2854
- const de_ServiceQuotaExceededException = (output, context) => {
2855
- return {
2856
- message: (0, smithy_client_1.expectString)(output.message),
2857
- };
2858
2276
  };
2859
2277
  const de_Snapshot = (output, context) => {
2860
- return {
2861
- accountsWithProvisionedRestoreAccess: output.accountsWithProvisionedRestoreAccess != null
2862
- ? de_AccountIdList(output.accountsWithProvisionedRestoreAccess, context)
2863
- : undefined,
2864
- accountsWithRestoreAccess: output.accountsWithRestoreAccess != null
2865
- ? de_AccountIdList(output.accountsWithRestoreAccess, context)
2866
- : undefined,
2867
- actualIncrementalBackupSizeInMegaBytes: (0, smithy_client_1.limitedParseDouble)(output.actualIncrementalBackupSizeInMegaBytes),
2868
- adminUsername: (0, smithy_client_1.expectString)(output.adminUsername),
2869
- backupProgressInMegaBytes: (0, smithy_client_1.limitedParseDouble)(output.backupProgressInMegaBytes),
2870
- currentBackupRateInMegaBytesPerSecond: (0, smithy_client_1.limitedParseDouble)(output.currentBackupRateInMegaBytesPerSecond),
2871
- elapsedTimeInSeconds: (0, smithy_client_1.expectLong)(output.elapsedTimeInSeconds),
2872
- estimatedSecondsToCompletion: (0, smithy_client_1.expectLong)(output.estimatedSecondsToCompletion),
2873
- kmsKeyId: (0, smithy_client_1.expectString)(output.kmsKeyId),
2874
- namespaceArn: (0, smithy_client_1.expectString)(output.namespaceArn),
2875
- namespaceName: (0, smithy_client_1.expectString)(output.namespaceName),
2876
- ownerAccount: (0, smithy_client_1.expectString)(output.ownerAccount),
2877
- snapshotArn: (0, smithy_client_1.expectString)(output.snapshotArn),
2878
- snapshotCreateTime: output.snapshotCreateTime != null
2879
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(output.snapshotCreateTime))
2880
- : undefined,
2881
- snapshotName: (0, smithy_client_1.expectString)(output.snapshotName),
2882
- snapshotRemainingDays: (0, smithy_client_1.expectInt32)(output.snapshotRemainingDays),
2883
- snapshotRetentionPeriod: (0, smithy_client_1.expectInt32)(output.snapshotRetentionPeriod),
2884
- snapshotRetentionStartTime: output.snapshotRetentionStartTime != null
2885
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(output.snapshotRetentionStartTime))
2886
- : undefined,
2887
- status: (0, smithy_client_1.expectString)(output.status),
2888
- totalBackupSizeInMegaBytes: (0, smithy_client_1.limitedParseDouble)(output.totalBackupSizeInMegaBytes),
2889
- };
2278
+ return (0, smithy_client_1.take)(output, {
2279
+ accountsWithProvisionedRestoreAccess: smithy_client_1._json,
2280
+ accountsWithRestoreAccess: smithy_client_1._json,
2281
+ actualIncrementalBackupSizeInMegaBytes: smithy_client_1.limitedParseDouble,
2282
+ adminUsername: smithy_client_1.expectString,
2283
+ backupProgressInMegaBytes: smithy_client_1.limitedParseDouble,
2284
+ currentBackupRateInMegaBytesPerSecond: smithy_client_1.limitedParseDouble,
2285
+ elapsedTimeInSeconds: smithy_client_1.expectLong,
2286
+ estimatedSecondsToCompletion: smithy_client_1.expectLong,
2287
+ kmsKeyId: smithy_client_1.expectString,
2288
+ namespaceArn: smithy_client_1.expectString,
2289
+ namespaceName: smithy_client_1.expectString,
2290
+ ownerAccount: smithy_client_1.expectString,
2291
+ snapshotArn: smithy_client_1.expectString,
2292
+ snapshotCreateTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
2293
+ snapshotName: smithy_client_1.expectString,
2294
+ snapshotRemainingDays: smithy_client_1.expectInt32,
2295
+ snapshotRetentionPeriod: smithy_client_1.expectInt32,
2296
+ snapshotRetentionStartTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
2297
+ status: smithy_client_1.expectString,
2298
+ totalBackupSizeInMegaBytes: smithy_client_1.limitedParseDouble,
2299
+ });
2890
2300
  };
2891
2301
  const de_SnapshotList = (output, context) => {
2892
2302
  const retVal = (output || [])
2893
2303
  .filter((e) => e != null)
2894
2304
  .map((entry) => {
2895
- if (entry === null) {
2896
- return null;
2897
- }
2898
2305
  return de_Snapshot(entry, context);
2899
2306
  });
2900
2307
  return retVal;
2901
2308
  };
2902
- const de_SubnetIdList = (output, context) => {
2903
- const retVal = (output || [])
2904
- .filter((e) => e != null)
2905
- .map((entry) => {
2906
- if (entry === null) {
2907
- return null;
2908
- }
2909
- return (0, smithy_client_1.expectString)(entry);
2910
- });
2911
- return retVal;
2912
- };
2913
2309
  const de_TableRestoreStatus = (output, context) => {
2914
- return {
2915
- message: (0, smithy_client_1.expectString)(output.message),
2916
- namespaceName: (0, smithy_client_1.expectString)(output.namespaceName),
2917
- newTableName: (0, smithy_client_1.expectString)(output.newTableName),
2918
- progressInMegaBytes: (0, smithy_client_1.expectLong)(output.progressInMegaBytes),
2919
- requestTime: output.requestTime != null
2920
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.requestTime)))
2921
- : undefined,
2922
- snapshotName: (0, smithy_client_1.expectString)(output.snapshotName),
2923
- sourceDatabaseName: (0, smithy_client_1.expectString)(output.sourceDatabaseName),
2924
- sourceSchemaName: (0, smithy_client_1.expectString)(output.sourceSchemaName),
2925
- sourceTableName: (0, smithy_client_1.expectString)(output.sourceTableName),
2926
- status: (0, smithy_client_1.expectString)(output.status),
2927
- tableRestoreRequestId: (0, smithy_client_1.expectString)(output.tableRestoreRequestId),
2928
- targetDatabaseName: (0, smithy_client_1.expectString)(output.targetDatabaseName),
2929
- targetSchemaName: (0, smithy_client_1.expectString)(output.targetSchemaName),
2930
- totalDataInMegaBytes: (0, smithy_client_1.expectLong)(output.totalDataInMegaBytes),
2931
- workgroupName: (0, smithy_client_1.expectString)(output.workgroupName),
2932
- };
2310
+ return (0, smithy_client_1.take)(output, {
2311
+ message: smithy_client_1.expectString,
2312
+ namespaceName: smithy_client_1.expectString,
2313
+ newTableName: smithy_client_1.expectString,
2314
+ progressInMegaBytes: smithy_client_1.expectLong,
2315
+ requestTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
2316
+ snapshotName: smithy_client_1.expectString,
2317
+ sourceDatabaseName: smithy_client_1.expectString,
2318
+ sourceSchemaName: smithy_client_1.expectString,
2319
+ sourceTableName: smithy_client_1.expectString,
2320
+ status: smithy_client_1.expectString,
2321
+ tableRestoreRequestId: smithy_client_1.expectString,
2322
+ targetDatabaseName: smithy_client_1.expectString,
2323
+ targetSchemaName: smithy_client_1.expectString,
2324
+ totalDataInMegaBytes: smithy_client_1.expectLong,
2325
+ workgroupName: smithy_client_1.expectString,
2326
+ });
2933
2327
  };
2934
2328
  const de_TableRestoreStatusList = (output, context) => {
2935
2329
  const retVal = (output || [])
2936
2330
  .filter((e) => e != null)
2937
2331
  .map((entry) => {
2938
- if (entry === null) {
2939
- return null;
2940
- }
2941
2332
  return de_TableRestoreStatus(entry, context);
2942
2333
  });
2943
2334
  return retVal;
2944
2335
  };
2945
- const de_Tag = (output, context) => {
2946
- return {
2947
- key: (0, smithy_client_1.expectString)(output.key),
2948
- value: (0, smithy_client_1.expectString)(output.value),
2949
- };
2950
- };
2951
- const de_TagList = (output, context) => {
2952
- const retVal = (output || [])
2953
- .filter((e) => e != null)
2954
- .map((entry) => {
2955
- if (entry === null) {
2956
- return null;
2957
- }
2958
- return de_Tag(entry, context);
2959
- });
2960
- return retVal;
2961
- };
2962
- const de_TagResourceResponse = (output, context) => {
2963
- return {};
2964
- };
2965
- const de_ThrottlingException = (output, context) => {
2966
- return {
2967
- code: (0, smithy_client_1.expectString)(output.code),
2968
- message: (0, smithy_client_1.expectString)(output.message),
2969
- };
2970
- };
2971
- const de_TooManyTagsException = (output, context) => {
2972
- return {
2973
- message: (0, smithy_client_1.expectString)(output.message),
2974
- resourceName: (0, smithy_client_1.expectString)(output.resourceName),
2975
- };
2976
- };
2977
- const de_UntagResourceResponse = (output, context) => {
2978
- return {};
2979
- };
2980
2336
  const de_UpdateEndpointAccessResponse = (output, context) => {
2981
- return {
2982
- endpoint: output.endpoint != null ? de_EndpointAccess(output.endpoint, context) : undefined,
2983
- };
2337
+ return (0, smithy_client_1.take)(output, {
2338
+ endpoint: (_) => de_EndpointAccess(_, context),
2339
+ });
2984
2340
  };
2985
2341
  const de_UpdateNamespaceResponse = (output, context) => {
2986
- return {
2987
- namespace: output.namespace != null ? de_Namespace(output.namespace, context) : undefined,
2988
- };
2989
- };
2990
- const de_UpdateSnapshotResponse = (output, context) => {
2991
- return {
2992
- snapshot: output.snapshot != null ? de_Snapshot(output.snapshot, context) : undefined,
2993
- };
2994
- };
2995
- const de_UpdateUsageLimitResponse = (output, context) => {
2996
- return {
2997
- usageLimit: output.usageLimit != null ? de_UsageLimit(output.usageLimit, context) : undefined,
2998
- };
2999
- };
3000
- const de_UpdateWorkgroupResponse = (output, context) => {
3001
- return {
3002
- workgroup: output.workgroup != null ? de_Workgroup(output.workgroup, context) : undefined,
3003
- };
3004
- };
3005
- const de_UsageLimit = (output, context) => {
3006
- return {
3007
- amount: (0, smithy_client_1.expectLong)(output.amount),
3008
- breachAction: (0, smithy_client_1.expectString)(output.breachAction),
3009
- period: (0, smithy_client_1.expectString)(output.period),
3010
- resourceArn: (0, smithy_client_1.expectString)(output.resourceArn),
3011
- usageLimitArn: (0, smithy_client_1.expectString)(output.usageLimitArn),
3012
- usageLimitId: (0, smithy_client_1.expectString)(output.usageLimitId),
3013
- usageType: (0, smithy_client_1.expectString)(output.usageType),
3014
- };
3015
- };
3016
- const de_UsageLimits = (output, context) => {
3017
- const retVal = (output || [])
3018
- .filter((e) => e != null)
3019
- .map((entry) => {
3020
- if (entry === null) {
3021
- return null;
3022
- }
3023
- return de_UsageLimit(entry, context);
2342
+ return (0, smithy_client_1.take)(output, {
2343
+ namespace: (_) => de_Namespace(_, context),
3024
2344
  });
3025
- return retVal;
3026
2345
  };
3027
- const de_ValidationException = (output, context) => {
3028
- return {
3029
- message: (0, smithy_client_1.expectString)(output.message),
3030
- };
3031
- };
3032
- const de_VpcEndpoint = (output, context) => {
3033
- return {
3034
- networkInterfaces: output.networkInterfaces != null ? de_NetworkInterfaceList(output.networkInterfaces, context) : undefined,
3035
- vpcEndpointId: (0, smithy_client_1.expectString)(output.vpcEndpointId),
3036
- vpcId: (0, smithy_client_1.expectString)(output.vpcId),
3037
- };
3038
- };
3039
- const de_VpcEndpointList = (output, context) => {
3040
- const retVal = (output || [])
3041
- .filter((e) => e != null)
3042
- .map((entry) => {
3043
- if (entry === null) {
3044
- return null;
3045
- }
3046
- return de_VpcEndpoint(entry, context);
2346
+ const de_UpdateSnapshotResponse = (output, context) => {
2347
+ return (0, smithy_client_1.take)(output, {
2348
+ snapshot: (_) => de_Snapshot(_, context),
3047
2349
  });
3048
- return retVal;
3049
2350
  };
3050
- const de_VpcSecurityGroupMembership = (output, context) => {
3051
- return {
3052
- status: (0, smithy_client_1.expectString)(output.status),
3053
- vpcSecurityGroupId: (0, smithy_client_1.expectString)(output.vpcSecurityGroupId),
3054
- };
3055
- };
3056
- const de_VpcSecurityGroupMembershipList = (output, context) => {
3057
- const retVal = (output || [])
3058
- .filter((e) => e != null)
3059
- .map((entry) => {
3060
- if (entry === null) {
3061
- return null;
3062
- }
3063
- return de_VpcSecurityGroupMembership(entry, context);
2351
+ const de_UpdateWorkgroupResponse = (output, context) => {
2352
+ return (0, smithy_client_1.take)(output, {
2353
+ workgroup: (_) => de_Workgroup(_, context),
3064
2354
  });
3065
- return retVal;
3066
2355
  };
3067
2356
  const de_Workgroup = (output, context) => {
3068
- return {
3069
- baseCapacity: (0, smithy_client_1.expectInt32)(output.baseCapacity),
3070
- configParameters: output.configParameters != null ? de_ConfigParameterList(output.configParameters, context) : undefined,
3071
- creationDate: output.creationDate != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(output.creationDate)) : undefined,
3072
- endpoint: output.endpoint != null ? de_Endpoint(output.endpoint, context) : undefined,
3073
- enhancedVpcRouting: (0, smithy_client_1.expectBoolean)(output.enhancedVpcRouting),
3074
- namespaceName: (0, smithy_client_1.expectString)(output.namespaceName),
3075
- port: (0, smithy_client_1.expectInt32)(output.port),
3076
- publiclyAccessible: (0, smithy_client_1.expectBoolean)(output.publiclyAccessible),
3077
- securityGroupIds: output.securityGroupIds != null ? de_SecurityGroupIdList(output.securityGroupIds, context) : undefined,
3078
- status: (0, smithy_client_1.expectString)(output.status),
3079
- subnetIds: output.subnetIds != null ? de_SubnetIdList(output.subnetIds, context) : undefined,
3080
- workgroupArn: (0, smithy_client_1.expectString)(output.workgroupArn),
3081
- workgroupId: (0, smithy_client_1.expectString)(output.workgroupId),
3082
- workgroupName: (0, smithy_client_1.expectString)(output.workgroupName),
3083
- };
2357
+ return (0, smithy_client_1.take)(output, {
2358
+ baseCapacity: smithy_client_1.expectInt32,
2359
+ configParameters: smithy_client_1._json,
2360
+ creationDate: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
2361
+ endpoint: smithy_client_1._json,
2362
+ enhancedVpcRouting: smithy_client_1.expectBoolean,
2363
+ namespaceName: smithy_client_1.expectString,
2364
+ port: smithy_client_1.expectInt32,
2365
+ publiclyAccessible: smithy_client_1.expectBoolean,
2366
+ securityGroupIds: smithy_client_1._json,
2367
+ status: smithy_client_1.expectString,
2368
+ subnetIds: smithy_client_1._json,
2369
+ workgroupArn: smithy_client_1.expectString,
2370
+ workgroupId: smithy_client_1.expectString,
2371
+ workgroupName: smithy_client_1.expectString,
2372
+ });
3084
2373
  };
3085
2374
  const de_WorkgroupList = (output, context) => {
3086
2375
  const retVal = (output || [])
3087
2376
  .filter((e) => e != null)
3088
2377
  .map((entry) => {
3089
- if (entry === null) {
3090
- return null;
3091
- }
3092
2378
  return de_Workgroup(entry, context);
3093
2379
  });
3094
2380
  return retVal;
@@ -3106,6 +2392,7 @@ const collectBody = (streamBody = new Uint8Array(), context) => {
3106
2392
  return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
3107
2393
  };
3108
2394
  const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
2395
+ const throwDefaultError = (0, smithy_client_1.withBaseException)(RedshiftServerlessServiceException_1.RedshiftServerlessServiceException);
3109
2396
  const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
3110
2397
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
3111
2398
  const contents = {