@aws-sdk/client-acm-pca 3.310.0 → 3.315.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,212 +1,143 @@
1
1
  import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
2
- import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectString as __expectString, parseEpochTimestamp as __parseEpochTimestamp, throwDefaultError, } from "@aws-sdk/smithy-client";
2
+ import { _json, decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectString as __expectString, parseEpochTimestamp as __parseEpochTimestamp, take, withBaseException, } from "@aws-sdk/smithy-client";
3
3
  import { ACMPCAServiceException as __BaseException } from "../models/ACMPCAServiceException";
4
4
  import { CertificateMismatchException, ConcurrentModificationException, InvalidArgsException, InvalidArnException, InvalidNextTokenException, InvalidPolicyException, InvalidRequestException, InvalidStateException, InvalidTagException, LimitExceededException, LockoutPreventedException, MalformedCertificateException, MalformedCSRException, PermissionAlreadyExistsException, RequestAlreadyProcessedException, RequestFailedException, RequestInProgressException, ResourceNotFoundException, TooManyTagsException, } from "../models/models_0";
5
5
  export const se_CreateCertificateAuthorityCommand = async (input, context) => {
6
- const headers = {
7
- "content-type": "application/x-amz-json-1.1",
8
- "x-amz-target": "ACMPrivateCA.CreateCertificateAuthority",
9
- };
6
+ const headers = sharedHeaders("CreateCertificateAuthority");
10
7
  let body;
11
- body = JSON.stringify(se_CreateCertificateAuthorityRequest(input, context));
8
+ body = JSON.stringify(_json(input));
12
9
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
13
10
  };
14
11
  export const se_CreateCertificateAuthorityAuditReportCommand = async (input, context) => {
15
- const headers = {
16
- "content-type": "application/x-amz-json-1.1",
17
- "x-amz-target": "ACMPrivateCA.CreateCertificateAuthorityAuditReport",
18
- };
12
+ const headers = sharedHeaders("CreateCertificateAuthorityAuditReport");
19
13
  let body;
20
- body = JSON.stringify(se_CreateCertificateAuthorityAuditReportRequest(input, context));
14
+ body = JSON.stringify(_json(input));
21
15
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
22
16
  };
23
17
  export const se_CreatePermissionCommand = async (input, context) => {
24
- const headers = {
25
- "content-type": "application/x-amz-json-1.1",
26
- "x-amz-target": "ACMPrivateCA.CreatePermission",
27
- };
18
+ const headers = sharedHeaders("CreatePermission");
28
19
  let body;
29
- body = JSON.stringify(se_CreatePermissionRequest(input, context));
20
+ body = JSON.stringify(_json(input));
30
21
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
31
22
  };
32
23
  export const se_DeleteCertificateAuthorityCommand = async (input, context) => {
33
- const headers = {
34
- "content-type": "application/x-amz-json-1.1",
35
- "x-amz-target": "ACMPrivateCA.DeleteCertificateAuthority",
36
- };
24
+ const headers = sharedHeaders("DeleteCertificateAuthority");
37
25
  let body;
38
- body = JSON.stringify(se_DeleteCertificateAuthorityRequest(input, context));
26
+ body = JSON.stringify(_json(input));
39
27
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
40
28
  };
41
29
  export const se_DeletePermissionCommand = async (input, context) => {
42
- const headers = {
43
- "content-type": "application/x-amz-json-1.1",
44
- "x-amz-target": "ACMPrivateCA.DeletePermission",
45
- };
30
+ const headers = sharedHeaders("DeletePermission");
46
31
  let body;
47
- body = JSON.stringify(se_DeletePermissionRequest(input, context));
32
+ body = JSON.stringify(_json(input));
48
33
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
49
34
  };
50
35
  export const se_DeletePolicyCommand = async (input, context) => {
51
- const headers = {
52
- "content-type": "application/x-amz-json-1.1",
53
- "x-amz-target": "ACMPrivateCA.DeletePolicy",
54
- };
36
+ const headers = sharedHeaders("DeletePolicy");
55
37
  let body;
56
- body = JSON.stringify(se_DeletePolicyRequest(input, context));
38
+ body = JSON.stringify(_json(input));
57
39
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
58
40
  };
59
41
  export const se_DescribeCertificateAuthorityCommand = async (input, context) => {
60
- const headers = {
61
- "content-type": "application/x-amz-json-1.1",
62
- "x-amz-target": "ACMPrivateCA.DescribeCertificateAuthority",
63
- };
42
+ const headers = sharedHeaders("DescribeCertificateAuthority");
64
43
  let body;
65
- body = JSON.stringify(se_DescribeCertificateAuthorityRequest(input, context));
44
+ body = JSON.stringify(_json(input));
66
45
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
67
46
  };
68
47
  export const se_DescribeCertificateAuthorityAuditReportCommand = async (input, context) => {
69
- const headers = {
70
- "content-type": "application/x-amz-json-1.1",
71
- "x-amz-target": "ACMPrivateCA.DescribeCertificateAuthorityAuditReport",
72
- };
48
+ const headers = sharedHeaders("DescribeCertificateAuthorityAuditReport");
73
49
  let body;
74
- body = JSON.stringify(se_DescribeCertificateAuthorityAuditReportRequest(input, context));
50
+ body = JSON.stringify(_json(input));
75
51
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
76
52
  };
77
53
  export const se_GetCertificateCommand = async (input, context) => {
78
- const headers = {
79
- "content-type": "application/x-amz-json-1.1",
80
- "x-amz-target": "ACMPrivateCA.GetCertificate",
81
- };
54
+ const headers = sharedHeaders("GetCertificate");
82
55
  let body;
83
- body = JSON.stringify(se_GetCertificateRequest(input, context));
56
+ body = JSON.stringify(_json(input));
84
57
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
85
58
  };
86
59
  export const se_GetCertificateAuthorityCertificateCommand = async (input, context) => {
87
- const headers = {
88
- "content-type": "application/x-amz-json-1.1",
89
- "x-amz-target": "ACMPrivateCA.GetCertificateAuthorityCertificate",
90
- };
60
+ const headers = sharedHeaders("GetCertificateAuthorityCertificate");
91
61
  let body;
92
- body = JSON.stringify(se_GetCertificateAuthorityCertificateRequest(input, context));
62
+ body = JSON.stringify(_json(input));
93
63
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
94
64
  };
95
65
  export const se_GetCertificateAuthorityCsrCommand = async (input, context) => {
96
- const headers = {
97
- "content-type": "application/x-amz-json-1.1",
98
- "x-amz-target": "ACMPrivateCA.GetCertificateAuthorityCsr",
99
- };
66
+ const headers = sharedHeaders("GetCertificateAuthorityCsr");
100
67
  let body;
101
- body = JSON.stringify(se_GetCertificateAuthorityCsrRequest(input, context));
68
+ body = JSON.stringify(_json(input));
102
69
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
103
70
  };
104
71
  export const se_GetPolicyCommand = async (input, context) => {
105
- const headers = {
106
- "content-type": "application/x-amz-json-1.1",
107
- "x-amz-target": "ACMPrivateCA.GetPolicy",
108
- };
72
+ const headers = sharedHeaders("GetPolicy");
109
73
  let body;
110
- body = JSON.stringify(se_GetPolicyRequest(input, context));
74
+ body = JSON.stringify(_json(input));
111
75
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
112
76
  };
113
77
  export const se_ImportCertificateAuthorityCertificateCommand = async (input, context) => {
114
- const headers = {
115
- "content-type": "application/x-amz-json-1.1",
116
- "x-amz-target": "ACMPrivateCA.ImportCertificateAuthorityCertificate",
117
- };
78
+ const headers = sharedHeaders("ImportCertificateAuthorityCertificate");
118
79
  let body;
119
80
  body = JSON.stringify(se_ImportCertificateAuthorityCertificateRequest(input, context));
120
81
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
121
82
  };
122
83
  export const se_IssueCertificateCommand = async (input, context) => {
123
- const headers = {
124
- "content-type": "application/x-amz-json-1.1",
125
- "x-amz-target": "ACMPrivateCA.IssueCertificate",
126
- };
84
+ const headers = sharedHeaders("IssueCertificate");
127
85
  let body;
128
86
  body = JSON.stringify(se_IssueCertificateRequest(input, context));
129
87
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
130
88
  };
131
89
  export const se_ListCertificateAuthoritiesCommand = async (input, context) => {
132
- const headers = {
133
- "content-type": "application/x-amz-json-1.1",
134
- "x-amz-target": "ACMPrivateCA.ListCertificateAuthorities",
135
- };
90
+ const headers = sharedHeaders("ListCertificateAuthorities");
136
91
  let body;
137
- body = JSON.stringify(se_ListCertificateAuthoritiesRequest(input, context));
92
+ body = JSON.stringify(_json(input));
138
93
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
139
94
  };
140
95
  export const se_ListPermissionsCommand = async (input, context) => {
141
- const headers = {
142
- "content-type": "application/x-amz-json-1.1",
143
- "x-amz-target": "ACMPrivateCA.ListPermissions",
144
- };
96
+ const headers = sharedHeaders("ListPermissions");
145
97
  let body;
146
- body = JSON.stringify(se_ListPermissionsRequest(input, context));
98
+ body = JSON.stringify(_json(input));
147
99
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
148
100
  };
149
101
  export const se_ListTagsCommand = async (input, context) => {
150
- const headers = {
151
- "content-type": "application/x-amz-json-1.1",
152
- "x-amz-target": "ACMPrivateCA.ListTags",
153
- };
102
+ const headers = sharedHeaders("ListTags");
154
103
  let body;
155
- body = JSON.stringify(se_ListTagsRequest(input, context));
104
+ body = JSON.stringify(_json(input));
156
105
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
157
106
  };
158
107
  export const se_PutPolicyCommand = async (input, context) => {
159
- const headers = {
160
- "content-type": "application/x-amz-json-1.1",
161
- "x-amz-target": "ACMPrivateCA.PutPolicy",
162
- };
108
+ const headers = sharedHeaders("PutPolicy");
163
109
  let body;
164
- body = JSON.stringify(se_PutPolicyRequest(input, context));
110
+ body = JSON.stringify(_json(input));
165
111
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
166
112
  };
167
113
  export const se_RestoreCertificateAuthorityCommand = async (input, context) => {
168
- const headers = {
169
- "content-type": "application/x-amz-json-1.1",
170
- "x-amz-target": "ACMPrivateCA.RestoreCertificateAuthority",
171
- };
114
+ const headers = sharedHeaders("RestoreCertificateAuthority");
172
115
  let body;
173
- body = JSON.stringify(se_RestoreCertificateAuthorityRequest(input, context));
116
+ body = JSON.stringify(_json(input));
174
117
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
175
118
  };
176
119
  export const se_RevokeCertificateCommand = async (input, context) => {
177
- const headers = {
178
- "content-type": "application/x-amz-json-1.1",
179
- "x-amz-target": "ACMPrivateCA.RevokeCertificate",
180
- };
120
+ const headers = sharedHeaders("RevokeCertificate");
181
121
  let body;
182
- body = JSON.stringify(se_RevokeCertificateRequest(input, context));
122
+ body = JSON.stringify(_json(input));
183
123
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
184
124
  };
185
125
  export const se_TagCertificateAuthorityCommand = async (input, context) => {
186
- const headers = {
187
- "content-type": "application/x-amz-json-1.1",
188
- "x-amz-target": "ACMPrivateCA.TagCertificateAuthority",
189
- };
126
+ const headers = sharedHeaders("TagCertificateAuthority");
190
127
  let body;
191
- body = JSON.stringify(se_TagCertificateAuthorityRequest(input, context));
128
+ body = JSON.stringify(_json(input));
192
129
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
193
130
  };
194
131
  export const se_UntagCertificateAuthorityCommand = async (input, context) => {
195
- const headers = {
196
- "content-type": "application/x-amz-json-1.1",
197
- "x-amz-target": "ACMPrivateCA.UntagCertificateAuthority",
198
- };
132
+ const headers = sharedHeaders("UntagCertificateAuthority");
199
133
  let body;
200
- body = JSON.stringify(se_UntagCertificateAuthorityRequest(input, context));
134
+ body = JSON.stringify(_json(input));
201
135
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
202
136
  };
203
137
  export const se_UpdateCertificateAuthorityCommand = async (input, context) => {
204
- const headers = {
205
- "content-type": "application/x-amz-json-1.1",
206
- "x-amz-target": "ACMPrivateCA.UpdateCertificateAuthority",
207
- };
138
+ const headers = sharedHeaders("UpdateCertificateAuthority");
208
139
  let body;
209
- body = JSON.stringify(se_UpdateCertificateAuthorityRequest(input, context));
140
+ body = JSON.stringify(_json(input));
210
141
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
211
142
  };
212
143
  export const de_CreateCertificateAuthorityCommand = async (output, context) => {
@@ -215,12 +146,12 @@ export const de_CreateCertificateAuthorityCommand = async (output, context) => {
215
146
  }
216
147
  const data = await parseBody(output.body, context);
217
148
  let contents = {};
218
- contents = de_CreateCertificateAuthorityResponse(data, context);
149
+ contents = _json(data);
219
150
  const response = {
220
151
  $metadata: deserializeMetadata(output),
221
152
  ...contents,
222
153
  };
223
- return Promise.resolve(response);
154
+ return response;
224
155
  };
225
156
  const de_CreateCertificateAuthorityCommandError = async (output, context) => {
226
157
  const parsedOutput = {
@@ -243,10 +174,9 @@ const de_CreateCertificateAuthorityCommandError = async (output, context) => {
243
174
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
244
175
  default:
245
176
  const parsedBody = parsedOutput.body;
246
- throwDefaultError({
177
+ return throwDefaultError({
247
178
  output,
248
179
  parsedBody,
249
- exceptionCtor: __BaseException,
250
180
  errorCode,
251
181
  });
252
182
  }
@@ -257,12 +187,12 @@ export const de_CreateCertificateAuthorityAuditReportCommand = async (output, co
257
187
  }
258
188
  const data = await parseBody(output.body, context);
259
189
  let contents = {};
260
- contents = de_CreateCertificateAuthorityAuditReportResponse(data, context);
190
+ contents = _json(data);
261
191
  const response = {
262
192
  $metadata: deserializeMetadata(output),
263
193
  ...contents,
264
194
  };
265
- return Promise.resolve(response);
195
+ return response;
266
196
  };
267
197
  const de_CreateCertificateAuthorityAuditReportCommandError = async (output, context) => {
268
198
  const parsedOutput = {
@@ -291,10 +221,9 @@ const de_CreateCertificateAuthorityAuditReportCommandError = async (output, cont
291
221
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
292
222
  default:
293
223
  const parsedBody = parsedOutput.body;
294
- throwDefaultError({
224
+ return throwDefaultError({
295
225
  output,
296
226
  parsedBody,
297
- exceptionCtor: __BaseException,
298
227
  errorCode,
299
228
  });
300
229
  }
@@ -307,7 +236,7 @@ export const de_CreatePermissionCommand = async (output, context) => {
307
236
  const response = {
308
237
  $metadata: deserializeMetadata(output),
309
238
  };
310
- return Promise.resolve(response);
239
+ return response;
311
240
  };
312
241
  const de_CreatePermissionCommandError = async (output, context) => {
313
242
  const parsedOutput = {
@@ -336,10 +265,9 @@ const de_CreatePermissionCommandError = async (output, context) => {
336
265
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
337
266
  default:
338
267
  const parsedBody = parsedOutput.body;
339
- throwDefaultError({
268
+ return throwDefaultError({
340
269
  output,
341
270
  parsedBody,
342
- exceptionCtor: __BaseException,
343
271
  errorCode,
344
272
  });
345
273
  }
@@ -352,7 +280,7 @@ export const de_DeleteCertificateAuthorityCommand = async (output, context) => {
352
280
  const response = {
353
281
  $metadata: deserializeMetadata(output),
354
282
  };
355
- return Promise.resolve(response);
283
+ return response;
356
284
  };
357
285
  const de_DeleteCertificateAuthorityCommandError = async (output, context) => {
358
286
  const parsedOutput = {
@@ -375,10 +303,9 @@ const de_DeleteCertificateAuthorityCommandError = async (output, context) => {
375
303
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
376
304
  default:
377
305
  const parsedBody = parsedOutput.body;
378
- throwDefaultError({
306
+ return throwDefaultError({
379
307
  output,
380
308
  parsedBody,
381
- exceptionCtor: __BaseException,
382
309
  errorCode,
383
310
  });
384
311
  }
@@ -391,7 +318,7 @@ export const de_DeletePermissionCommand = async (output, context) => {
391
318
  const response = {
392
319
  $metadata: deserializeMetadata(output),
393
320
  };
394
- return Promise.resolve(response);
321
+ return response;
395
322
  };
396
323
  const de_DeletePermissionCommandError = async (output, context) => {
397
324
  const parsedOutput = {
@@ -414,10 +341,9 @@ const de_DeletePermissionCommandError = async (output, context) => {
414
341
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
415
342
  default:
416
343
  const parsedBody = parsedOutput.body;
417
- throwDefaultError({
344
+ return throwDefaultError({
418
345
  output,
419
346
  parsedBody,
420
- exceptionCtor: __BaseException,
421
347
  errorCode,
422
348
  });
423
349
  }
@@ -430,7 +356,7 @@ export const de_DeletePolicyCommand = async (output, context) => {
430
356
  const response = {
431
357
  $metadata: deserializeMetadata(output),
432
358
  };
433
- return Promise.resolve(response);
359
+ return response;
434
360
  };
435
361
  const de_DeletePolicyCommandError = async (output, context) => {
436
362
  const parsedOutput = {
@@ -459,10 +385,9 @@ const de_DeletePolicyCommandError = async (output, context) => {
459
385
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
460
386
  default:
461
387
  const parsedBody = parsedOutput.body;
462
- throwDefaultError({
388
+ return throwDefaultError({
463
389
  output,
464
390
  parsedBody,
465
- exceptionCtor: __BaseException,
466
391
  errorCode,
467
392
  });
468
393
  }
@@ -478,7 +403,7 @@ export const de_DescribeCertificateAuthorityCommand = async (output, context) =>
478
403
  $metadata: deserializeMetadata(output),
479
404
  ...contents,
480
405
  };
481
- return Promise.resolve(response);
406
+ return response;
482
407
  };
483
408
  const de_DescribeCertificateAuthorityCommandError = async (output, context) => {
484
409
  const parsedOutput = {
@@ -495,10 +420,9 @@ const de_DescribeCertificateAuthorityCommandError = async (output, context) => {
495
420
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
496
421
  default:
497
422
  const parsedBody = parsedOutput.body;
498
- throwDefaultError({
423
+ return throwDefaultError({
499
424
  output,
500
425
  parsedBody,
501
- exceptionCtor: __BaseException,
502
426
  errorCode,
503
427
  });
504
428
  }
@@ -514,7 +438,7 @@ export const de_DescribeCertificateAuthorityAuditReportCommand = async (output,
514
438
  $metadata: deserializeMetadata(output),
515
439
  ...contents,
516
440
  };
517
- return Promise.resolve(response);
441
+ return response;
518
442
  };
519
443
  const de_DescribeCertificateAuthorityAuditReportCommandError = async (output, context) => {
520
444
  const parsedOutput = {
@@ -534,10 +458,9 @@ const de_DescribeCertificateAuthorityAuditReportCommandError = async (output, co
534
458
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
535
459
  default:
536
460
  const parsedBody = parsedOutput.body;
537
- throwDefaultError({
461
+ return throwDefaultError({
538
462
  output,
539
463
  parsedBody,
540
- exceptionCtor: __BaseException,
541
464
  errorCode,
542
465
  });
543
466
  }
@@ -548,12 +471,12 @@ export const de_GetCertificateCommand = async (output, context) => {
548
471
  }
549
472
  const data = await parseBody(output.body, context);
550
473
  let contents = {};
551
- contents = de_GetCertificateResponse(data, context);
474
+ contents = _json(data);
552
475
  const response = {
553
476
  $metadata: deserializeMetadata(output),
554
477
  ...contents,
555
478
  };
556
- return Promise.resolve(response);
479
+ return response;
557
480
  };
558
481
  const de_GetCertificateCommandError = async (output, context) => {
559
482
  const parsedOutput = {
@@ -579,10 +502,9 @@ const de_GetCertificateCommandError = async (output, context) => {
579
502
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
580
503
  default:
581
504
  const parsedBody = parsedOutput.body;
582
- throwDefaultError({
505
+ return throwDefaultError({
583
506
  output,
584
507
  parsedBody,
585
- exceptionCtor: __BaseException,
586
508
  errorCode,
587
509
  });
588
510
  }
@@ -593,12 +515,12 @@ export const de_GetCertificateAuthorityCertificateCommand = async (output, conte
593
515
  }
594
516
  const data = await parseBody(output.body, context);
595
517
  let contents = {};
596
- contents = de_GetCertificateAuthorityCertificateResponse(data, context);
518
+ contents = _json(data);
597
519
  const response = {
598
520
  $metadata: deserializeMetadata(output),
599
521
  ...contents,
600
522
  };
601
- return Promise.resolve(response);
523
+ return response;
602
524
  };
603
525
  const de_GetCertificateAuthorityCertificateCommandError = async (output, context) => {
604
526
  const parsedOutput = {
@@ -618,10 +540,9 @@ const de_GetCertificateAuthorityCertificateCommandError = async (output, context
618
540
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
619
541
  default:
620
542
  const parsedBody = parsedOutput.body;
621
- throwDefaultError({
543
+ return throwDefaultError({
622
544
  output,
623
545
  parsedBody,
624
- exceptionCtor: __BaseException,
625
546
  errorCode,
626
547
  });
627
548
  }
@@ -632,12 +553,12 @@ export const de_GetCertificateAuthorityCsrCommand = async (output, context) => {
632
553
  }
633
554
  const data = await parseBody(output.body, context);
634
555
  let contents = {};
635
- contents = de_GetCertificateAuthorityCsrResponse(data, context);
556
+ contents = _json(data);
636
557
  const response = {
637
558
  $metadata: deserializeMetadata(output),
638
559
  ...contents,
639
560
  };
640
- return Promise.resolve(response);
561
+ return response;
641
562
  };
642
563
  const de_GetCertificateAuthorityCsrCommandError = async (output, context) => {
643
564
  const parsedOutput = {
@@ -663,10 +584,9 @@ const de_GetCertificateAuthorityCsrCommandError = async (output, context) => {
663
584
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
664
585
  default:
665
586
  const parsedBody = parsedOutput.body;
666
- throwDefaultError({
587
+ return throwDefaultError({
667
588
  output,
668
589
  parsedBody,
669
- exceptionCtor: __BaseException,
670
590
  errorCode,
671
591
  });
672
592
  }
@@ -677,12 +597,12 @@ export const de_GetPolicyCommand = async (output, context) => {
677
597
  }
678
598
  const data = await parseBody(output.body, context);
679
599
  let contents = {};
680
- contents = de_GetPolicyResponse(data, context);
600
+ contents = _json(data);
681
601
  const response = {
682
602
  $metadata: deserializeMetadata(output),
683
603
  ...contents,
684
604
  };
685
- return Promise.resolve(response);
605
+ return response;
686
606
  };
687
607
  const de_GetPolicyCommandError = async (output, context) => {
688
608
  const parsedOutput = {
@@ -705,10 +625,9 @@ const de_GetPolicyCommandError = async (output, context) => {
705
625
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
706
626
  default:
707
627
  const parsedBody = parsedOutput.body;
708
- throwDefaultError({
628
+ return throwDefaultError({
709
629
  output,
710
630
  parsedBody,
711
- exceptionCtor: __BaseException,
712
631
  errorCode,
713
632
  });
714
633
  }
@@ -721,7 +640,7 @@ export const de_ImportCertificateAuthorityCertificateCommand = async (output, co
721
640
  const response = {
722
641
  $metadata: deserializeMetadata(output),
723
642
  };
724
- return Promise.resolve(response);
643
+ return response;
725
644
  };
726
645
  const de_ImportCertificateAuthorityCertificateCommandError = async (output, context) => {
727
646
  const parsedOutput = {
@@ -759,10 +678,9 @@ const de_ImportCertificateAuthorityCertificateCommandError = async (output, cont
759
678
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
760
679
  default:
761
680
  const parsedBody = parsedOutput.body;
762
- throwDefaultError({
681
+ return throwDefaultError({
763
682
  output,
764
683
  parsedBody,
765
- exceptionCtor: __BaseException,
766
684
  errorCode,
767
685
  });
768
686
  }
@@ -773,12 +691,12 @@ export const de_IssueCertificateCommand = async (output, context) => {
773
691
  }
774
692
  const data = await parseBody(output.body, context);
775
693
  let contents = {};
776
- contents = de_IssueCertificateResponse(data, context);
694
+ contents = _json(data);
777
695
  const response = {
778
696
  $metadata: deserializeMetadata(output),
779
697
  ...contents,
780
698
  };
781
- return Promise.resolve(response);
699
+ return response;
782
700
  };
783
701
  const de_IssueCertificateCommandError = async (output, context) => {
784
702
  const parsedOutput = {
@@ -807,10 +725,9 @@ const de_IssueCertificateCommandError = async (output, context) => {
807
725
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
808
726
  default:
809
727
  const parsedBody = parsedOutput.body;
810
- throwDefaultError({
728
+ return throwDefaultError({
811
729
  output,
812
730
  parsedBody,
813
- exceptionCtor: __BaseException,
814
731
  errorCode,
815
732
  });
816
733
  }
@@ -826,7 +743,7 @@ export const de_ListCertificateAuthoritiesCommand = async (output, context) => {
826
743
  $metadata: deserializeMetadata(output),
827
744
  ...contents,
828
745
  };
829
- return Promise.resolve(response);
746
+ return response;
830
747
  };
831
748
  const de_ListCertificateAuthoritiesCommandError = async (output, context) => {
832
749
  const parsedOutput = {
@@ -840,10 +757,9 @@ const de_ListCertificateAuthoritiesCommandError = async (output, context) => {
840
757
  throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
841
758
  default:
842
759
  const parsedBody = parsedOutput.body;
843
- throwDefaultError({
760
+ return throwDefaultError({
844
761
  output,
845
762
  parsedBody,
846
- exceptionCtor: __BaseException,
847
763
  errorCode,
848
764
  });
849
765
  }
@@ -859,7 +775,7 @@ export const de_ListPermissionsCommand = async (output, context) => {
859
775
  $metadata: deserializeMetadata(output),
860
776
  ...contents,
861
777
  };
862
- return Promise.resolve(response);
778
+ return response;
863
779
  };
864
780
  const de_ListPermissionsCommandError = async (output, context) => {
865
781
  const parsedOutput = {
@@ -885,10 +801,9 @@ const de_ListPermissionsCommandError = async (output, context) => {
885
801
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
886
802
  default:
887
803
  const parsedBody = parsedOutput.body;
888
- throwDefaultError({
804
+ return throwDefaultError({
889
805
  output,
890
806
  parsedBody,
891
- exceptionCtor: __BaseException,
892
807
  errorCode,
893
808
  });
894
809
  }
@@ -899,12 +814,12 @@ export const de_ListTagsCommand = async (output, context) => {
899
814
  }
900
815
  const data = await parseBody(output.body, context);
901
816
  let contents = {};
902
- contents = de_ListTagsResponse(data, context);
817
+ contents = _json(data);
903
818
  const response = {
904
819
  $metadata: deserializeMetadata(output),
905
820
  ...contents,
906
821
  };
907
- return Promise.resolve(response);
822
+ return response;
908
823
  };
909
824
  const de_ListTagsCommandError = async (output, context) => {
910
825
  const parsedOutput = {
@@ -924,10 +839,9 @@ const de_ListTagsCommandError = async (output, context) => {
924
839
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
925
840
  default:
926
841
  const parsedBody = parsedOutput.body;
927
- throwDefaultError({
842
+ return throwDefaultError({
928
843
  output,
929
844
  parsedBody,
930
- exceptionCtor: __BaseException,
931
845
  errorCode,
932
846
  });
933
847
  }
@@ -940,7 +854,7 @@ export const de_PutPolicyCommand = async (output, context) => {
940
854
  const response = {
941
855
  $metadata: deserializeMetadata(output),
942
856
  };
943
- return Promise.resolve(response);
857
+ return response;
944
858
  };
945
859
  const de_PutPolicyCommandError = async (output, context) => {
946
860
  const parsedOutput = {
@@ -972,10 +886,9 @@ const de_PutPolicyCommandError = async (output, context) => {
972
886
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
973
887
  default:
974
888
  const parsedBody = parsedOutput.body;
975
- throwDefaultError({
889
+ return throwDefaultError({
976
890
  output,
977
891
  parsedBody,
978
- exceptionCtor: __BaseException,
979
892
  errorCode,
980
893
  });
981
894
  }
@@ -988,7 +901,7 @@ export const de_RestoreCertificateAuthorityCommand = async (output, context) =>
988
901
  const response = {
989
902
  $metadata: deserializeMetadata(output),
990
903
  };
991
- return Promise.resolve(response);
904
+ return response;
992
905
  };
993
906
  const de_RestoreCertificateAuthorityCommandError = async (output, context) => {
994
907
  const parsedOutput = {
@@ -1008,10 +921,9 @@ const de_RestoreCertificateAuthorityCommandError = async (output, context) => {
1008
921
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1009
922
  default:
1010
923
  const parsedBody = parsedOutput.body;
1011
- throwDefaultError({
924
+ return throwDefaultError({
1012
925
  output,
1013
926
  parsedBody,
1014
- exceptionCtor: __BaseException,
1015
927
  errorCode,
1016
928
  });
1017
929
  }
@@ -1024,7 +936,7 @@ export const de_RevokeCertificateCommand = async (output, context) => {
1024
936
  const response = {
1025
937
  $metadata: deserializeMetadata(output),
1026
938
  };
1027
- return Promise.resolve(response);
939
+ return response;
1028
940
  };
1029
941
  const de_RevokeCertificateCommandError = async (output, context) => {
1030
942
  const parsedOutput = {
@@ -1062,10 +974,9 @@ const de_RevokeCertificateCommandError = async (output, context) => {
1062
974
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1063
975
  default:
1064
976
  const parsedBody = parsedOutput.body;
1065
- throwDefaultError({
977
+ return throwDefaultError({
1066
978
  output,
1067
979
  parsedBody,
1068
- exceptionCtor: __BaseException,
1069
980
  errorCode,
1070
981
  });
1071
982
  }
@@ -1078,7 +989,7 @@ export const de_TagCertificateAuthorityCommand = async (output, context) => {
1078
989
  const response = {
1079
990
  $metadata: deserializeMetadata(output),
1080
991
  };
1081
- return Promise.resolve(response);
992
+ return response;
1082
993
  };
1083
994
  const de_TagCertificateAuthorityCommandError = async (output, context) => {
1084
995
  const parsedOutput = {
@@ -1104,10 +1015,9 @@ const de_TagCertificateAuthorityCommandError = async (output, context) => {
1104
1015
  throw await de_TooManyTagsExceptionRes(parsedOutput, context);
1105
1016
  default:
1106
1017
  const parsedBody = parsedOutput.body;
1107
- throwDefaultError({
1018
+ return throwDefaultError({
1108
1019
  output,
1109
1020
  parsedBody,
1110
- exceptionCtor: __BaseException,
1111
1021
  errorCode,
1112
1022
  });
1113
1023
  }
@@ -1120,7 +1030,7 @@ export const de_UntagCertificateAuthorityCommand = async (output, context) => {
1120
1030
  const response = {
1121
1031
  $metadata: deserializeMetadata(output),
1122
1032
  };
1123
- return Promise.resolve(response);
1033
+ return response;
1124
1034
  };
1125
1035
  const de_UntagCertificateAuthorityCommandError = async (output, context) => {
1126
1036
  const parsedOutput = {
@@ -1143,10 +1053,9 @@ const de_UntagCertificateAuthorityCommandError = async (output, context) => {
1143
1053
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1144
1054
  default:
1145
1055
  const parsedBody = parsedOutput.body;
1146
- throwDefaultError({
1056
+ return throwDefaultError({
1147
1057
  output,
1148
1058
  parsedBody,
1149
- exceptionCtor: __BaseException,
1150
1059
  errorCode,
1151
1060
  });
1152
1061
  }
@@ -1159,7 +1068,7 @@ export const de_UpdateCertificateAuthorityCommand = async (output, context) => {
1159
1068
  const response = {
1160
1069
  $metadata: deserializeMetadata(output),
1161
1070
  };
1162
- return Promise.resolve(response);
1071
+ return response;
1163
1072
  };
1164
1073
  const de_UpdateCertificateAuthorityCommandError = async (output, context) => {
1165
1074
  const parsedOutput = {
@@ -1188,17 +1097,16 @@ const de_UpdateCertificateAuthorityCommandError = async (output, context) => {
1188
1097
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1189
1098
  default:
1190
1099
  const parsedBody = parsedOutput.body;
1191
- throwDefaultError({
1100
+ return throwDefaultError({
1192
1101
  output,
1193
1102
  parsedBody,
1194
- exceptionCtor: __BaseException,
1195
1103
  errorCode,
1196
1104
  });
1197
1105
  }
1198
1106
  };
1199
1107
  const de_CertificateMismatchExceptionRes = async (parsedOutput, context) => {
1200
1108
  const body = parsedOutput.body;
1201
- const deserialized = de_CertificateMismatchException(body, context);
1109
+ const deserialized = _json(body);
1202
1110
  const exception = new CertificateMismatchException({
1203
1111
  $metadata: deserializeMetadata(parsedOutput),
1204
1112
  ...deserialized,
@@ -1207,7 +1115,7 @@ const de_CertificateMismatchExceptionRes = async (parsedOutput, context) => {
1207
1115
  };
1208
1116
  const de_ConcurrentModificationExceptionRes = async (parsedOutput, context) => {
1209
1117
  const body = parsedOutput.body;
1210
- const deserialized = de_ConcurrentModificationException(body, context);
1118
+ const deserialized = _json(body);
1211
1119
  const exception = new ConcurrentModificationException({
1212
1120
  $metadata: deserializeMetadata(parsedOutput),
1213
1121
  ...deserialized,
@@ -1216,7 +1124,7 @@ const de_ConcurrentModificationExceptionRes = async (parsedOutput, context) => {
1216
1124
  };
1217
1125
  const de_InvalidArgsExceptionRes = async (parsedOutput, context) => {
1218
1126
  const body = parsedOutput.body;
1219
- const deserialized = de_InvalidArgsException(body, context);
1127
+ const deserialized = _json(body);
1220
1128
  const exception = new InvalidArgsException({
1221
1129
  $metadata: deserializeMetadata(parsedOutput),
1222
1130
  ...deserialized,
@@ -1225,7 +1133,7 @@ const de_InvalidArgsExceptionRes = async (parsedOutput, context) => {
1225
1133
  };
1226
1134
  const de_InvalidArnExceptionRes = async (parsedOutput, context) => {
1227
1135
  const body = parsedOutput.body;
1228
- const deserialized = de_InvalidArnException(body, context);
1136
+ const deserialized = _json(body);
1229
1137
  const exception = new InvalidArnException({
1230
1138
  $metadata: deserializeMetadata(parsedOutput),
1231
1139
  ...deserialized,
@@ -1234,7 +1142,7 @@ const de_InvalidArnExceptionRes = async (parsedOutput, context) => {
1234
1142
  };
1235
1143
  const de_InvalidNextTokenExceptionRes = async (parsedOutput, context) => {
1236
1144
  const body = parsedOutput.body;
1237
- const deserialized = de_InvalidNextTokenException(body, context);
1145
+ const deserialized = _json(body);
1238
1146
  const exception = new InvalidNextTokenException({
1239
1147
  $metadata: deserializeMetadata(parsedOutput),
1240
1148
  ...deserialized,
@@ -1243,7 +1151,7 @@ const de_InvalidNextTokenExceptionRes = async (parsedOutput, context) => {
1243
1151
  };
1244
1152
  const de_InvalidPolicyExceptionRes = async (parsedOutput, context) => {
1245
1153
  const body = parsedOutput.body;
1246
- const deserialized = de_InvalidPolicyException(body, context);
1154
+ const deserialized = _json(body);
1247
1155
  const exception = new InvalidPolicyException({
1248
1156
  $metadata: deserializeMetadata(parsedOutput),
1249
1157
  ...deserialized,
@@ -1252,7 +1160,7 @@ const de_InvalidPolicyExceptionRes = async (parsedOutput, context) => {
1252
1160
  };
1253
1161
  const de_InvalidRequestExceptionRes = async (parsedOutput, context) => {
1254
1162
  const body = parsedOutput.body;
1255
- const deserialized = de_InvalidRequestException(body, context);
1163
+ const deserialized = _json(body);
1256
1164
  const exception = new InvalidRequestException({
1257
1165
  $metadata: deserializeMetadata(parsedOutput),
1258
1166
  ...deserialized,
@@ -1261,7 +1169,7 @@ const de_InvalidRequestExceptionRes = async (parsedOutput, context) => {
1261
1169
  };
1262
1170
  const de_InvalidStateExceptionRes = async (parsedOutput, context) => {
1263
1171
  const body = parsedOutput.body;
1264
- const deserialized = de_InvalidStateException(body, context);
1172
+ const deserialized = _json(body);
1265
1173
  const exception = new InvalidStateException({
1266
1174
  $metadata: deserializeMetadata(parsedOutput),
1267
1175
  ...deserialized,
@@ -1270,7 +1178,7 @@ const de_InvalidStateExceptionRes = async (parsedOutput, context) => {
1270
1178
  };
1271
1179
  const de_InvalidTagExceptionRes = async (parsedOutput, context) => {
1272
1180
  const body = parsedOutput.body;
1273
- const deserialized = de_InvalidTagException(body, context);
1181
+ const deserialized = _json(body);
1274
1182
  const exception = new InvalidTagException({
1275
1183
  $metadata: deserializeMetadata(parsedOutput),
1276
1184
  ...deserialized,
@@ -1279,7 +1187,7 @@ const de_InvalidTagExceptionRes = async (parsedOutput, context) => {
1279
1187
  };
1280
1188
  const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
1281
1189
  const body = parsedOutput.body;
1282
- const deserialized = de_LimitExceededException(body, context);
1190
+ const deserialized = _json(body);
1283
1191
  const exception = new LimitExceededException({
1284
1192
  $metadata: deserializeMetadata(parsedOutput),
1285
1193
  ...deserialized,
@@ -1288,7 +1196,7 @@ const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
1288
1196
  };
1289
1197
  const de_LockoutPreventedExceptionRes = async (parsedOutput, context) => {
1290
1198
  const body = parsedOutput.body;
1291
- const deserialized = de_LockoutPreventedException(body, context);
1199
+ const deserialized = _json(body);
1292
1200
  const exception = new LockoutPreventedException({
1293
1201
  $metadata: deserializeMetadata(parsedOutput),
1294
1202
  ...deserialized,
@@ -1297,7 +1205,7 @@ const de_LockoutPreventedExceptionRes = async (parsedOutput, context) => {
1297
1205
  };
1298
1206
  const de_MalformedCertificateExceptionRes = async (parsedOutput, context) => {
1299
1207
  const body = parsedOutput.body;
1300
- const deserialized = de_MalformedCertificateException(body, context);
1208
+ const deserialized = _json(body);
1301
1209
  const exception = new MalformedCertificateException({
1302
1210
  $metadata: deserializeMetadata(parsedOutput),
1303
1211
  ...deserialized,
@@ -1306,7 +1214,7 @@ const de_MalformedCertificateExceptionRes = async (parsedOutput, context) => {
1306
1214
  };
1307
1215
  const de_MalformedCSRExceptionRes = async (parsedOutput, context) => {
1308
1216
  const body = parsedOutput.body;
1309
- const deserialized = de_MalformedCSRException(body, context);
1217
+ const deserialized = _json(body);
1310
1218
  const exception = new MalformedCSRException({
1311
1219
  $metadata: deserializeMetadata(parsedOutput),
1312
1220
  ...deserialized,
@@ -1315,7 +1223,7 @@ const de_MalformedCSRExceptionRes = async (parsedOutput, context) => {
1315
1223
  };
1316
1224
  const de_PermissionAlreadyExistsExceptionRes = async (parsedOutput, context) => {
1317
1225
  const body = parsedOutput.body;
1318
- const deserialized = de_PermissionAlreadyExistsException(body, context);
1226
+ const deserialized = _json(body);
1319
1227
  const exception = new PermissionAlreadyExistsException({
1320
1228
  $metadata: deserializeMetadata(parsedOutput),
1321
1229
  ...deserialized,
@@ -1324,7 +1232,7 @@ const de_PermissionAlreadyExistsExceptionRes = async (parsedOutput, context) =>
1324
1232
  };
1325
1233
  const de_RequestAlreadyProcessedExceptionRes = async (parsedOutput, context) => {
1326
1234
  const body = parsedOutput.body;
1327
- const deserialized = de_RequestAlreadyProcessedException(body, context);
1235
+ const deserialized = _json(body);
1328
1236
  const exception = new RequestAlreadyProcessedException({
1329
1237
  $metadata: deserializeMetadata(parsedOutput),
1330
1238
  ...deserialized,
@@ -1333,7 +1241,7 @@ const de_RequestAlreadyProcessedExceptionRes = async (parsedOutput, context) =>
1333
1241
  };
1334
1242
  const de_RequestFailedExceptionRes = async (parsedOutput, context) => {
1335
1243
  const body = parsedOutput.body;
1336
- const deserialized = de_RequestFailedException(body, context);
1244
+ const deserialized = _json(body);
1337
1245
  const exception = new RequestFailedException({
1338
1246
  $metadata: deserializeMetadata(parsedOutput),
1339
1247
  ...deserialized,
@@ -1342,7 +1250,7 @@ const de_RequestFailedExceptionRes = async (parsedOutput, context) => {
1342
1250
  };
1343
1251
  const de_RequestInProgressExceptionRes = async (parsedOutput, context) => {
1344
1252
  const body = parsedOutput.body;
1345
- const deserialized = de_RequestInProgressException(body, context);
1253
+ const deserialized = _json(body);
1346
1254
  const exception = new RequestInProgressException({
1347
1255
  $metadata: deserializeMetadata(parsedOutput),
1348
1256
  ...deserialized,
@@ -1351,7 +1259,7 @@ const de_RequestInProgressExceptionRes = async (parsedOutput, context) => {
1351
1259
  };
1352
1260
  const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
1353
1261
  const body = parsedOutput.body;
1354
- const deserialized = de_ResourceNotFoundException(body, context);
1262
+ const deserialized = _json(body);
1355
1263
  const exception = new ResourceNotFoundException({
1356
1264
  $metadata: deserializeMetadata(parsedOutput),
1357
1265
  ...deserialized,
@@ -1360,807 +1268,102 @@ const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
1360
1268
  };
1361
1269
  const de_TooManyTagsExceptionRes = async (parsedOutput, context) => {
1362
1270
  const body = parsedOutput.body;
1363
- const deserialized = de_TooManyTagsException(body, context);
1271
+ const deserialized = _json(body);
1364
1272
  const exception = new TooManyTagsException({
1365
1273
  $metadata: deserializeMetadata(parsedOutput),
1366
1274
  ...deserialized,
1367
1275
  });
1368
1276
  return __decorateServiceException(exception, body);
1369
1277
  };
1370
- const se_AccessDescription = (input, context) => {
1371
- return {
1372
- ...(input.AccessLocation != null && { AccessLocation: se_GeneralName(input.AccessLocation, context) }),
1373
- ...(input.AccessMethod != null && { AccessMethod: se_AccessMethod(input.AccessMethod, context) }),
1374
- };
1375
- };
1376
- const se_AccessDescriptionList = (input, context) => {
1377
- return input
1378
- .filter((e) => e != null)
1379
- .map((entry) => {
1380
- return se_AccessDescription(entry, context);
1381
- });
1382
- };
1383
- const se_AccessMethod = (input, context) => {
1384
- return {
1385
- ...(input.AccessMethodType != null && { AccessMethodType: input.AccessMethodType }),
1386
- ...(input.CustomObjectIdentifier != null && { CustomObjectIdentifier: input.CustomObjectIdentifier }),
1387
- };
1388
- };
1389
- const se_ActionList = (input, context) => {
1390
- return input
1391
- .filter((e) => e != null)
1392
- .map((entry) => {
1393
- return entry;
1394
- });
1395
- };
1396
- const se_ApiPassthrough = (input, context) => {
1397
- return {
1398
- ...(input.Extensions != null && { Extensions: se_Extensions(input.Extensions, context) }),
1399
- ...(input.Subject != null && { Subject: se_ASN1Subject(input.Subject, context) }),
1400
- };
1401
- };
1402
- const se_ASN1Subject = (input, context) => {
1403
- return {
1404
- ...(input.CommonName != null && { CommonName: input.CommonName }),
1405
- ...(input.Country != null && { Country: input.Country }),
1406
- ...(input.CustomAttributes != null && {
1407
- CustomAttributes: se_CustomAttributeList(input.CustomAttributes, context),
1408
- }),
1409
- ...(input.DistinguishedNameQualifier != null && { DistinguishedNameQualifier: input.DistinguishedNameQualifier }),
1410
- ...(input.GenerationQualifier != null && { GenerationQualifier: input.GenerationQualifier }),
1411
- ...(input.GivenName != null && { GivenName: input.GivenName }),
1412
- ...(input.Initials != null && { Initials: input.Initials }),
1413
- ...(input.Locality != null && { Locality: input.Locality }),
1414
- ...(input.Organization != null && { Organization: input.Organization }),
1415
- ...(input.OrganizationalUnit != null && { OrganizationalUnit: input.OrganizationalUnit }),
1416
- ...(input.Pseudonym != null && { Pseudonym: input.Pseudonym }),
1417
- ...(input.SerialNumber != null && { SerialNumber: input.SerialNumber }),
1418
- ...(input.State != null && { State: input.State }),
1419
- ...(input.Surname != null && { Surname: input.Surname }),
1420
- ...(input.Title != null && { Title: input.Title }),
1421
- };
1422
- };
1423
- const se_CertificateAuthorityConfiguration = (input, context) => {
1424
- return {
1425
- ...(input.CsrExtensions != null && { CsrExtensions: se_CsrExtensions(input.CsrExtensions, context) }),
1426
- ...(input.KeyAlgorithm != null && { KeyAlgorithm: input.KeyAlgorithm }),
1427
- ...(input.SigningAlgorithm != null && { SigningAlgorithm: input.SigningAlgorithm }),
1428
- ...(input.Subject != null && { Subject: se_ASN1Subject(input.Subject, context) }),
1429
- };
1430
- };
1431
- const se_CertificatePolicyList = (input, context) => {
1432
- return input
1433
- .filter((e) => e != null)
1434
- .map((entry) => {
1435
- return se_PolicyInformation(entry, context);
1436
- });
1437
- };
1438
- const se_CreateCertificateAuthorityAuditReportRequest = (input, context) => {
1439
- return {
1440
- ...(input.AuditReportResponseFormat != null && { AuditReportResponseFormat: input.AuditReportResponseFormat }),
1441
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1442
- ...(input.S3BucketName != null && { S3BucketName: input.S3BucketName }),
1443
- };
1444
- };
1445
- const se_CreateCertificateAuthorityRequest = (input, context) => {
1446
- return {
1447
- ...(input.CertificateAuthorityConfiguration != null && {
1448
- CertificateAuthorityConfiguration: se_CertificateAuthorityConfiguration(input.CertificateAuthorityConfiguration, context),
1449
- }),
1450
- ...(input.CertificateAuthorityType != null && { CertificateAuthorityType: input.CertificateAuthorityType }),
1451
- ...(input.IdempotencyToken != null && { IdempotencyToken: input.IdempotencyToken }),
1452
- ...(input.KeyStorageSecurityStandard != null && { KeyStorageSecurityStandard: input.KeyStorageSecurityStandard }),
1453
- ...(input.RevocationConfiguration != null && {
1454
- RevocationConfiguration: se_RevocationConfiguration(input.RevocationConfiguration, context),
1455
- }),
1456
- ...(input.Tags != null && { Tags: se_TagList(input.Tags, context) }),
1457
- ...(input.UsageMode != null && { UsageMode: input.UsageMode }),
1458
- };
1459
- };
1460
- const se_CreatePermissionRequest = (input, context) => {
1461
- return {
1462
- ...(input.Actions != null && { Actions: se_ActionList(input.Actions, context) }),
1463
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1464
- ...(input.Principal != null && { Principal: input.Principal }),
1465
- ...(input.SourceAccount != null && { SourceAccount: input.SourceAccount }),
1466
- };
1467
- };
1468
- const se_CrlConfiguration = (input, context) => {
1469
- return {
1470
- ...(input.CustomCname != null && { CustomCname: input.CustomCname }),
1471
- ...(input.Enabled != null && { Enabled: input.Enabled }),
1472
- ...(input.ExpirationInDays != null && { ExpirationInDays: input.ExpirationInDays }),
1473
- ...(input.S3BucketName != null && { S3BucketName: input.S3BucketName }),
1474
- ...(input.S3ObjectAcl != null && { S3ObjectAcl: input.S3ObjectAcl }),
1475
- };
1476
- };
1477
- const se_CsrExtensions = (input, context) => {
1478
- return {
1479
- ...(input.KeyUsage != null && { KeyUsage: se_KeyUsage(input.KeyUsage, context) }),
1480
- ...(input.SubjectInformationAccess != null && {
1481
- SubjectInformationAccess: se_AccessDescriptionList(input.SubjectInformationAccess, context),
1482
- }),
1483
- };
1484
- };
1485
- const se_CustomAttribute = (input, context) => {
1486
- return {
1487
- ...(input.ObjectIdentifier != null && { ObjectIdentifier: input.ObjectIdentifier }),
1488
- ...(input.Value != null && { Value: input.Value }),
1489
- };
1490
- };
1491
- const se_CustomAttributeList = (input, context) => {
1492
- return input
1493
- .filter((e) => e != null)
1494
- .map((entry) => {
1495
- return se_CustomAttribute(entry, context);
1496
- });
1497
- };
1498
- const se_CustomExtension = (input, context) => {
1499
- return {
1500
- ...(input.Critical != null && { Critical: input.Critical }),
1501
- ...(input.ObjectIdentifier != null && { ObjectIdentifier: input.ObjectIdentifier }),
1502
- ...(input.Value != null && { Value: input.Value }),
1503
- };
1504
- };
1505
- const se_CustomExtensionList = (input, context) => {
1506
- return input
1507
- .filter((e) => e != null)
1508
- .map((entry) => {
1509
- return se_CustomExtension(entry, context);
1510
- });
1511
- };
1512
- const se_DeleteCertificateAuthorityRequest = (input, context) => {
1513
- return {
1514
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1515
- ...(input.PermanentDeletionTimeInDays != null && {
1516
- PermanentDeletionTimeInDays: input.PermanentDeletionTimeInDays,
1517
- }),
1518
- };
1519
- };
1520
- const se_DeletePermissionRequest = (input, context) => {
1521
- return {
1522
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1523
- ...(input.Principal != null && { Principal: input.Principal }),
1524
- ...(input.SourceAccount != null && { SourceAccount: input.SourceAccount }),
1525
- };
1526
- };
1527
- const se_DeletePolicyRequest = (input, context) => {
1528
- return {
1529
- ...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
1530
- };
1531
- };
1532
- const se_DescribeCertificateAuthorityAuditReportRequest = (input, context) => {
1533
- return {
1534
- ...(input.AuditReportId != null && { AuditReportId: input.AuditReportId }),
1535
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1536
- };
1537
- };
1538
- const se_DescribeCertificateAuthorityRequest = (input, context) => {
1539
- return {
1540
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1541
- };
1542
- };
1543
- const se_EdiPartyName = (input, context) => {
1544
- return {
1545
- ...(input.NameAssigner != null && { NameAssigner: input.NameAssigner }),
1546
- ...(input.PartyName != null && { PartyName: input.PartyName }),
1547
- };
1548
- };
1549
- const se_ExtendedKeyUsage = (input, context) => {
1550
- return {
1551
- ...(input.ExtendedKeyUsageObjectIdentifier != null && {
1552
- ExtendedKeyUsageObjectIdentifier: input.ExtendedKeyUsageObjectIdentifier,
1553
- }),
1554
- ...(input.ExtendedKeyUsageType != null && { ExtendedKeyUsageType: input.ExtendedKeyUsageType }),
1555
- };
1556
- };
1557
- const se_ExtendedKeyUsageList = (input, context) => {
1558
- return input
1559
- .filter((e) => e != null)
1560
- .map((entry) => {
1561
- return se_ExtendedKeyUsage(entry, context);
1562
- });
1563
- };
1564
- const se_Extensions = (input, context) => {
1565
- return {
1566
- ...(input.CertificatePolicies != null && {
1567
- CertificatePolicies: se_CertificatePolicyList(input.CertificatePolicies, context),
1568
- }),
1569
- ...(input.CustomExtensions != null && {
1570
- CustomExtensions: se_CustomExtensionList(input.CustomExtensions, context),
1571
- }),
1572
- ...(input.ExtendedKeyUsage != null && {
1573
- ExtendedKeyUsage: se_ExtendedKeyUsageList(input.ExtendedKeyUsage, context),
1574
- }),
1575
- ...(input.KeyUsage != null && { KeyUsage: se_KeyUsage(input.KeyUsage, context) }),
1576
- ...(input.SubjectAlternativeNames != null && {
1577
- SubjectAlternativeNames: se_GeneralNameList(input.SubjectAlternativeNames, context),
1578
- }),
1579
- };
1580
- };
1581
- const se_GeneralName = (input, context) => {
1582
- return {
1583
- ...(input.DirectoryName != null && { DirectoryName: se_ASN1Subject(input.DirectoryName, context) }),
1584
- ...(input.DnsName != null && { DnsName: input.DnsName }),
1585
- ...(input.EdiPartyName != null && { EdiPartyName: se_EdiPartyName(input.EdiPartyName, context) }),
1586
- ...(input.IpAddress != null && { IpAddress: input.IpAddress }),
1587
- ...(input.OtherName != null && { OtherName: se_OtherName(input.OtherName, context) }),
1588
- ...(input.RegisteredId != null && { RegisteredId: input.RegisteredId }),
1589
- ...(input.Rfc822Name != null && { Rfc822Name: input.Rfc822Name }),
1590
- ...(input.UniformResourceIdentifier != null && { UniformResourceIdentifier: input.UniformResourceIdentifier }),
1591
- };
1592
- };
1593
- const se_GeneralNameList = (input, context) => {
1594
- return input
1595
- .filter((e) => e != null)
1596
- .map((entry) => {
1597
- return se_GeneralName(entry, context);
1598
- });
1599
- };
1600
- const se_GetCertificateAuthorityCertificateRequest = (input, context) => {
1601
- return {
1602
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1603
- };
1604
- };
1605
- const se_GetCertificateAuthorityCsrRequest = (input, context) => {
1606
- return {
1607
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1608
- };
1609
- };
1610
- const se_GetCertificateRequest = (input, context) => {
1611
- return {
1612
- ...(input.CertificateArn != null && { CertificateArn: input.CertificateArn }),
1613
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1614
- };
1615
- };
1616
- const se_GetPolicyRequest = (input, context) => {
1617
- return {
1618
- ...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
1619
- };
1620
- };
1621
1278
  const se_ImportCertificateAuthorityCertificateRequest = (input, context) => {
1622
- return {
1623
- ...(input.Certificate != null && { Certificate: context.base64Encoder(input.Certificate) }),
1624
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1625
- ...(input.CertificateChain != null && { CertificateChain: context.base64Encoder(input.CertificateChain) }),
1626
- };
1627
- };
1628
- const se_IssueCertificateRequest = (input, context) => {
1629
- return {
1630
- ...(input.ApiPassthrough != null && { ApiPassthrough: se_ApiPassthrough(input.ApiPassthrough, context) }),
1631
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1632
- ...(input.Csr != null && { Csr: context.base64Encoder(input.Csr) }),
1633
- ...(input.IdempotencyToken != null && { IdempotencyToken: input.IdempotencyToken }),
1634
- ...(input.SigningAlgorithm != null && { SigningAlgorithm: input.SigningAlgorithm }),
1635
- ...(input.TemplateArn != null && { TemplateArn: input.TemplateArn }),
1636
- ...(input.Validity != null && { Validity: se_Validity(input.Validity, context) }),
1637
- ...(input.ValidityNotBefore != null && { ValidityNotBefore: se_Validity(input.ValidityNotBefore, context) }),
1638
- };
1639
- };
1640
- const se_KeyUsage = (input, context) => {
1641
- return {
1642
- ...(input.CRLSign != null && { CRLSign: input.CRLSign }),
1643
- ...(input.DataEncipherment != null && { DataEncipherment: input.DataEncipherment }),
1644
- ...(input.DecipherOnly != null && { DecipherOnly: input.DecipherOnly }),
1645
- ...(input.DigitalSignature != null && { DigitalSignature: input.DigitalSignature }),
1646
- ...(input.EncipherOnly != null && { EncipherOnly: input.EncipherOnly }),
1647
- ...(input.KeyAgreement != null && { KeyAgreement: input.KeyAgreement }),
1648
- ...(input.KeyCertSign != null && { KeyCertSign: input.KeyCertSign }),
1649
- ...(input.KeyEncipherment != null && { KeyEncipherment: input.KeyEncipherment }),
1650
- ...(input.NonRepudiation != null && { NonRepudiation: input.NonRepudiation }),
1651
- };
1652
- };
1653
- const se_ListCertificateAuthoritiesRequest = (input, context) => {
1654
- return {
1655
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
1656
- ...(input.NextToken != null && { NextToken: input.NextToken }),
1657
- ...(input.ResourceOwner != null && { ResourceOwner: input.ResourceOwner }),
1658
- };
1659
- };
1660
- const se_ListPermissionsRequest = (input, context) => {
1661
- return {
1662
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1663
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
1664
- ...(input.NextToken != null && { NextToken: input.NextToken }),
1665
- };
1666
- };
1667
- const se_ListTagsRequest = (input, context) => {
1668
- return {
1669
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1670
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
1671
- ...(input.NextToken != null && { NextToken: input.NextToken }),
1672
- };
1673
- };
1674
- const se_OcspConfiguration = (input, context) => {
1675
- return {
1676
- ...(input.Enabled != null && { Enabled: input.Enabled }),
1677
- ...(input.OcspCustomCname != null && { OcspCustomCname: input.OcspCustomCname }),
1678
- };
1679
- };
1680
- const se_OtherName = (input, context) => {
1681
- return {
1682
- ...(input.TypeId != null && { TypeId: input.TypeId }),
1683
- ...(input.Value != null && { Value: input.Value }),
1684
- };
1685
- };
1686
- const se_PolicyInformation = (input, context) => {
1687
- return {
1688
- ...(input.CertPolicyId != null && { CertPolicyId: input.CertPolicyId }),
1689
- ...(input.PolicyQualifiers != null && {
1690
- PolicyQualifiers: se_PolicyQualifierInfoList(input.PolicyQualifiers, context),
1691
- }),
1692
- };
1693
- };
1694
- const se_PolicyQualifierInfo = (input, context) => {
1695
- return {
1696
- ...(input.PolicyQualifierId != null && { PolicyQualifierId: input.PolicyQualifierId }),
1697
- ...(input.Qualifier != null && { Qualifier: se_Qualifier(input.Qualifier, context) }),
1698
- };
1699
- };
1700
- const se_PolicyQualifierInfoList = (input, context) => {
1701
- return input
1702
- .filter((e) => e != null)
1703
- .map((entry) => {
1704
- return se_PolicyQualifierInfo(entry, context);
1279
+ return take(input, {
1280
+ Certificate: context.base64Encoder,
1281
+ CertificateAuthorityArn: [],
1282
+ CertificateChain: context.base64Encoder,
1705
1283
  });
1706
1284
  };
1707
- const se_PutPolicyRequest = (input, context) => {
1708
- return {
1709
- ...(input.Policy != null && { Policy: input.Policy }),
1710
- ...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
1711
- };
1712
- };
1713
- const se_Qualifier = (input, context) => {
1714
- return {
1715
- ...(input.CpsUri != null && { CpsUri: input.CpsUri }),
1716
- };
1717
- };
1718
- const se_RestoreCertificateAuthorityRequest = (input, context) => {
1719
- return {
1720
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1721
- };
1722
- };
1723
- const se_RevocationConfiguration = (input, context) => {
1724
- return {
1725
- ...(input.CrlConfiguration != null && { CrlConfiguration: se_CrlConfiguration(input.CrlConfiguration, context) }),
1726
- ...(input.OcspConfiguration != null && {
1727
- OcspConfiguration: se_OcspConfiguration(input.OcspConfiguration, context),
1728
- }),
1729
- };
1730
- };
1731
- const se_RevokeCertificateRequest = (input, context) => {
1732
- return {
1733
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1734
- ...(input.CertificateSerial != null && { CertificateSerial: input.CertificateSerial }),
1735
- ...(input.RevocationReason != null && { RevocationReason: input.RevocationReason }),
1736
- };
1737
- };
1738
- const se_Tag = (input, context) => {
1739
- return {
1740
- ...(input.Key != null && { Key: input.Key }),
1741
- ...(input.Value != null && { Value: input.Value }),
1742
- };
1743
- };
1744
- const se_TagCertificateAuthorityRequest = (input, context) => {
1745
- return {
1746
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1747
- ...(input.Tags != null && { Tags: se_TagList(input.Tags, context) }),
1748
- };
1749
- };
1750
- const se_TagList = (input, context) => {
1751
- return input
1752
- .filter((e) => e != null)
1753
- .map((entry) => {
1754
- return se_Tag(entry, context);
1755
- });
1756
- };
1757
- const se_UntagCertificateAuthorityRequest = (input, context) => {
1758
- return {
1759
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1760
- ...(input.Tags != null && { Tags: se_TagList(input.Tags, context) }),
1761
- };
1762
- };
1763
- const se_UpdateCertificateAuthorityRequest = (input, context) => {
1764
- return {
1765
- ...(input.CertificateAuthorityArn != null && { CertificateAuthorityArn: input.CertificateAuthorityArn }),
1766
- ...(input.RevocationConfiguration != null && {
1767
- RevocationConfiguration: se_RevocationConfiguration(input.RevocationConfiguration, context),
1768
- }),
1769
- ...(input.Status != null && { Status: input.Status }),
1770
- };
1771
- };
1772
- const se_Validity = (input, context) => {
1773
- return {
1774
- ...(input.Type != null && { Type: input.Type }),
1775
- ...(input.Value != null && { Value: input.Value }),
1776
- };
1777
- };
1778
- const de_AccessDescription = (output, context) => {
1779
- return {
1780
- AccessLocation: output.AccessLocation != null ? de_GeneralName(output.AccessLocation, context) : undefined,
1781
- AccessMethod: output.AccessMethod != null ? de_AccessMethod(output.AccessMethod, context) : undefined,
1782
- };
1783
- };
1784
- const de_AccessDescriptionList = (output, context) => {
1785
- const retVal = (output || [])
1786
- .filter((e) => e != null)
1787
- .map((entry) => {
1788
- if (entry === null) {
1789
- return null;
1790
- }
1791
- return de_AccessDescription(entry, context);
1792
- });
1793
- return retVal;
1794
- };
1795
- const de_AccessMethod = (output, context) => {
1796
- return {
1797
- AccessMethodType: __expectString(output.AccessMethodType),
1798
- CustomObjectIdentifier: __expectString(output.CustomObjectIdentifier),
1799
- };
1800
- };
1801
- const de_ActionList = (output, context) => {
1802
- const retVal = (output || [])
1803
- .filter((e) => e != null)
1804
- .map((entry) => {
1805
- if (entry === null) {
1806
- return null;
1807
- }
1808
- return __expectString(entry);
1285
+ const se_IssueCertificateRequest = (input, context) => {
1286
+ return take(input, {
1287
+ ApiPassthrough: _json,
1288
+ CertificateAuthorityArn: [],
1289
+ Csr: context.base64Encoder,
1290
+ IdempotencyToken: [],
1291
+ SigningAlgorithm: [],
1292
+ TemplateArn: [],
1293
+ Validity: _json,
1294
+ ValidityNotBefore: _json,
1809
1295
  });
1810
- return retVal;
1811
- };
1812
- const de_ASN1Subject = (output, context) => {
1813
- return {
1814
- CommonName: __expectString(output.CommonName),
1815
- Country: __expectString(output.Country),
1816
- CustomAttributes: output.CustomAttributes != null ? de_CustomAttributeList(output.CustomAttributes, context) : undefined,
1817
- DistinguishedNameQualifier: __expectString(output.DistinguishedNameQualifier),
1818
- GenerationQualifier: __expectString(output.GenerationQualifier),
1819
- GivenName: __expectString(output.GivenName),
1820
- Initials: __expectString(output.Initials),
1821
- Locality: __expectString(output.Locality),
1822
- Organization: __expectString(output.Organization),
1823
- OrganizationalUnit: __expectString(output.OrganizationalUnit),
1824
- Pseudonym: __expectString(output.Pseudonym),
1825
- SerialNumber: __expectString(output.SerialNumber),
1826
- State: __expectString(output.State),
1827
- Surname: __expectString(output.Surname),
1828
- Title: __expectString(output.Title),
1829
- };
1830
1296
  };
1831
1297
  const de_CertificateAuthorities = (output, context) => {
1832
1298
  const retVal = (output || [])
1833
1299
  .filter((e) => e != null)
1834
1300
  .map((entry) => {
1835
- if (entry === null) {
1836
- return null;
1837
- }
1838
1301
  return de_CertificateAuthority(entry, context);
1839
1302
  });
1840
1303
  return retVal;
1841
1304
  };
1842
1305
  const de_CertificateAuthority = (output, context) => {
1843
- return {
1844
- Arn: __expectString(output.Arn),
1845
- CertificateAuthorityConfiguration: output.CertificateAuthorityConfiguration != null
1846
- ? de_CertificateAuthorityConfiguration(output.CertificateAuthorityConfiguration, context)
1847
- : undefined,
1848
- CreatedAt: output.CreatedAt != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreatedAt))) : undefined,
1849
- FailureReason: __expectString(output.FailureReason),
1850
- KeyStorageSecurityStandard: __expectString(output.KeyStorageSecurityStandard),
1851
- LastStateChangeAt: output.LastStateChangeAt != null
1852
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.LastStateChangeAt)))
1853
- : undefined,
1854
- NotAfter: output.NotAfter != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.NotAfter))) : undefined,
1855
- NotBefore: output.NotBefore != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.NotBefore))) : undefined,
1856
- OwnerAccount: __expectString(output.OwnerAccount),
1857
- RestorableUntil: output.RestorableUntil != null
1858
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.RestorableUntil)))
1859
- : undefined,
1860
- RevocationConfiguration: output.RevocationConfiguration != null
1861
- ? de_RevocationConfiguration(output.RevocationConfiguration, context)
1862
- : undefined,
1863
- Serial: __expectString(output.Serial),
1864
- Status: __expectString(output.Status),
1865
- Type: __expectString(output.Type),
1866
- UsageMode: __expectString(output.UsageMode),
1867
- };
1868
- };
1869
- const de_CertificateAuthorityConfiguration = (output, context) => {
1870
- return {
1871
- CsrExtensions: output.CsrExtensions != null ? de_CsrExtensions(output.CsrExtensions, context) : undefined,
1872
- KeyAlgorithm: __expectString(output.KeyAlgorithm),
1873
- SigningAlgorithm: __expectString(output.SigningAlgorithm),
1874
- Subject: output.Subject != null ? de_ASN1Subject(output.Subject, context) : undefined,
1875
- };
1876
- };
1877
- const de_CertificateMismatchException = (output, context) => {
1878
- return {
1879
- message: __expectString(output.message),
1880
- };
1881
- };
1882
- const de_ConcurrentModificationException = (output, context) => {
1883
- return {
1884
- message: __expectString(output.message),
1885
- };
1886
- };
1887
- const de_CreateCertificateAuthorityAuditReportResponse = (output, context) => {
1888
- return {
1889
- AuditReportId: __expectString(output.AuditReportId),
1890
- S3Key: __expectString(output.S3Key),
1891
- };
1892
- };
1893
- const de_CreateCertificateAuthorityResponse = (output, context) => {
1894
- return {
1895
- CertificateAuthorityArn: __expectString(output.CertificateAuthorityArn),
1896
- };
1897
- };
1898
- const de_CrlConfiguration = (output, context) => {
1899
- return {
1900
- CustomCname: __expectString(output.CustomCname),
1901
- Enabled: __expectBoolean(output.Enabled),
1902
- ExpirationInDays: __expectInt32(output.ExpirationInDays),
1903
- S3BucketName: __expectString(output.S3BucketName),
1904
- S3ObjectAcl: __expectString(output.S3ObjectAcl),
1905
- };
1906
- };
1907
- const de_CsrExtensions = (output, context) => {
1908
- return {
1909
- KeyUsage: output.KeyUsage != null ? de_KeyUsage(output.KeyUsage, context) : undefined,
1910
- SubjectInformationAccess: output.SubjectInformationAccess != null
1911
- ? de_AccessDescriptionList(output.SubjectInformationAccess, context)
1912
- : undefined,
1913
- };
1914
- };
1915
- const de_CustomAttribute = (output, context) => {
1916
- return {
1917
- ObjectIdentifier: __expectString(output.ObjectIdentifier),
1918
- Value: __expectString(output.Value),
1919
- };
1920
- };
1921
- const de_CustomAttributeList = (output, context) => {
1922
- const retVal = (output || [])
1923
- .filter((e) => e != null)
1924
- .map((entry) => {
1925
- if (entry === null) {
1926
- return null;
1927
- }
1928
- return de_CustomAttribute(entry, context);
1306
+ return take(output, {
1307
+ Arn: __expectString,
1308
+ CertificateAuthorityConfiguration: _json,
1309
+ CreatedAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1310
+ FailureReason: __expectString,
1311
+ KeyStorageSecurityStandard: __expectString,
1312
+ LastStateChangeAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1313
+ NotAfter: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1314
+ NotBefore: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1315
+ OwnerAccount: __expectString,
1316
+ RestorableUntil: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1317
+ RevocationConfiguration: _json,
1318
+ Serial: __expectString,
1319
+ Status: __expectString,
1320
+ Type: __expectString,
1321
+ UsageMode: __expectString,
1929
1322
  });
1930
- return retVal;
1931
1323
  };
1932
1324
  const de_DescribeCertificateAuthorityAuditReportResponse = (output, context) => {
1933
- return {
1934
- AuditReportStatus: __expectString(output.AuditReportStatus),
1935
- CreatedAt: output.CreatedAt != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreatedAt))) : undefined,
1936
- S3BucketName: __expectString(output.S3BucketName),
1937
- S3Key: __expectString(output.S3Key),
1938
- };
1325
+ return take(output, {
1326
+ AuditReportStatus: __expectString,
1327
+ CreatedAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1328
+ S3BucketName: __expectString,
1329
+ S3Key: __expectString,
1330
+ });
1939
1331
  };
1940
1332
  const de_DescribeCertificateAuthorityResponse = (output, context) => {
1941
- return {
1942
- CertificateAuthority: output.CertificateAuthority != null ? de_CertificateAuthority(output.CertificateAuthority, context) : undefined,
1943
- };
1944
- };
1945
- const de_EdiPartyName = (output, context) => {
1946
- return {
1947
- NameAssigner: __expectString(output.NameAssigner),
1948
- PartyName: __expectString(output.PartyName),
1949
- };
1950
- };
1951
- const de_GeneralName = (output, context) => {
1952
- return {
1953
- DirectoryName: output.DirectoryName != null ? de_ASN1Subject(output.DirectoryName, context) : undefined,
1954
- DnsName: __expectString(output.DnsName),
1955
- EdiPartyName: output.EdiPartyName != null ? de_EdiPartyName(output.EdiPartyName, context) : undefined,
1956
- IpAddress: __expectString(output.IpAddress),
1957
- OtherName: output.OtherName != null ? de_OtherName(output.OtherName, context) : undefined,
1958
- RegisteredId: __expectString(output.RegisteredId),
1959
- Rfc822Name: __expectString(output.Rfc822Name),
1960
- UniformResourceIdentifier: __expectString(output.UniformResourceIdentifier),
1961
- };
1962
- };
1963
- const de_GetCertificateAuthorityCertificateResponse = (output, context) => {
1964
- return {
1965
- Certificate: __expectString(output.Certificate),
1966
- CertificateChain: __expectString(output.CertificateChain),
1967
- };
1968
- };
1969
- const de_GetCertificateAuthorityCsrResponse = (output, context) => {
1970
- return {
1971
- Csr: __expectString(output.Csr),
1972
- };
1973
- };
1974
- const de_GetCertificateResponse = (output, context) => {
1975
- return {
1976
- Certificate: __expectString(output.Certificate),
1977
- CertificateChain: __expectString(output.CertificateChain),
1978
- };
1979
- };
1980
- const de_GetPolicyResponse = (output, context) => {
1981
- return {
1982
- Policy: __expectString(output.Policy),
1983
- };
1984
- };
1985
- const de_InvalidArgsException = (output, context) => {
1986
- return {
1987
- message: __expectString(output.message),
1988
- };
1989
- };
1990
- const de_InvalidArnException = (output, context) => {
1991
- return {
1992
- message: __expectString(output.message),
1993
- };
1994
- };
1995
- const de_InvalidNextTokenException = (output, context) => {
1996
- return {
1997
- message: __expectString(output.message),
1998
- };
1999
- };
2000
- const de_InvalidPolicyException = (output, context) => {
2001
- return {
2002
- message: __expectString(output.message),
2003
- };
2004
- };
2005
- const de_InvalidRequestException = (output, context) => {
2006
- return {
2007
- message: __expectString(output.message),
2008
- };
2009
- };
2010
- const de_InvalidStateException = (output, context) => {
2011
- return {
2012
- message: __expectString(output.message),
2013
- };
2014
- };
2015
- const de_InvalidTagException = (output, context) => {
2016
- return {
2017
- message: __expectString(output.message),
2018
- };
2019
- };
2020
- const de_IssueCertificateResponse = (output, context) => {
2021
- return {
2022
- CertificateArn: __expectString(output.CertificateArn),
2023
- };
2024
- };
2025
- const de_KeyUsage = (output, context) => {
2026
- return {
2027
- CRLSign: __expectBoolean(output.CRLSign),
2028
- DataEncipherment: __expectBoolean(output.DataEncipherment),
2029
- DecipherOnly: __expectBoolean(output.DecipherOnly),
2030
- DigitalSignature: __expectBoolean(output.DigitalSignature),
2031
- EncipherOnly: __expectBoolean(output.EncipherOnly),
2032
- KeyAgreement: __expectBoolean(output.KeyAgreement),
2033
- KeyCertSign: __expectBoolean(output.KeyCertSign),
2034
- KeyEncipherment: __expectBoolean(output.KeyEncipherment),
2035
- NonRepudiation: __expectBoolean(output.NonRepudiation),
2036
- };
2037
- };
2038
- const de_LimitExceededException = (output, context) => {
2039
- return {
2040
- message: __expectString(output.message),
2041
- };
1333
+ return take(output, {
1334
+ CertificateAuthority: (_) => de_CertificateAuthority(_, context),
1335
+ });
2042
1336
  };
2043
1337
  const de_ListCertificateAuthoritiesResponse = (output, context) => {
2044
- return {
2045
- CertificateAuthorities: output.CertificateAuthorities != null
2046
- ? de_CertificateAuthorities(output.CertificateAuthorities, context)
2047
- : undefined,
2048
- NextToken: __expectString(output.NextToken),
2049
- };
1338
+ return take(output, {
1339
+ CertificateAuthorities: (_) => de_CertificateAuthorities(_, context),
1340
+ NextToken: __expectString,
1341
+ });
2050
1342
  };
2051
1343
  const de_ListPermissionsResponse = (output, context) => {
2052
- return {
2053
- NextToken: __expectString(output.NextToken),
2054
- Permissions: output.Permissions != null ? de_PermissionList(output.Permissions, context) : undefined,
2055
- };
2056
- };
2057
- const de_ListTagsResponse = (output, context) => {
2058
- return {
2059
- NextToken: __expectString(output.NextToken),
2060
- Tags: output.Tags != null ? de_TagList(output.Tags, context) : undefined,
2061
- };
2062
- };
2063
- const de_LockoutPreventedException = (output, context) => {
2064
- return {
2065
- message: __expectString(output.message),
2066
- };
2067
- };
2068
- const de_MalformedCertificateException = (output, context) => {
2069
- return {
2070
- message: __expectString(output.message),
2071
- };
2072
- };
2073
- const de_MalformedCSRException = (output, context) => {
2074
- return {
2075
- message: __expectString(output.message),
2076
- };
2077
- };
2078
- const de_OcspConfiguration = (output, context) => {
2079
- return {
2080
- Enabled: __expectBoolean(output.Enabled),
2081
- OcspCustomCname: __expectString(output.OcspCustomCname),
2082
- };
2083
- };
2084
- const de_OtherName = (output, context) => {
2085
- return {
2086
- TypeId: __expectString(output.TypeId),
2087
- Value: __expectString(output.Value),
2088
- };
1344
+ return take(output, {
1345
+ NextToken: __expectString,
1346
+ Permissions: (_) => de_PermissionList(_, context),
1347
+ });
2089
1348
  };
2090
1349
  const de_Permission = (output, context) => {
2091
- return {
2092
- Actions: output.Actions != null ? de_ActionList(output.Actions, context) : undefined,
2093
- CertificateAuthorityArn: __expectString(output.CertificateAuthorityArn),
2094
- CreatedAt: output.CreatedAt != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreatedAt))) : undefined,
2095
- Policy: __expectString(output.Policy),
2096
- Principal: __expectString(output.Principal),
2097
- SourceAccount: __expectString(output.SourceAccount),
2098
- };
2099
- };
2100
- const de_PermissionAlreadyExistsException = (output, context) => {
2101
- return {
2102
- message: __expectString(output.message),
2103
- };
1350
+ return take(output, {
1351
+ Actions: _json,
1352
+ CertificateAuthorityArn: __expectString,
1353
+ CreatedAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1354
+ Policy: __expectString,
1355
+ Principal: __expectString,
1356
+ SourceAccount: __expectString,
1357
+ });
2104
1358
  };
2105
1359
  const de_PermissionList = (output, context) => {
2106
1360
  const retVal = (output || [])
2107
1361
  .filter((e) => e != null)
2108
1362
  .map((entry) => {
2109
- if (entry === null) {
2110
- return null;
2111
- }
2112
1363
  return de_Permission(entry, context);
2113
1364
  });
2114
1365
  return retVal;
2115
1366
  };
2116
- const de_RequestAlreadyProcessedException = (output, context) => {
2117
- return {
2118
- message: __expectString(output.message),
2119
- };
2120
- };
2121
- const de_RequestFailedException = (output, context) => {
2122
- return {
2123
- message: __expectString(output.message),
2124
- };
2125
- };
2126
- const de_RequestInProgressException = (output, context) => {
2127
- return {
2128
- message: __expectString(output.message),
2129
- };
2130
- };
2131
- const de_ResourceNotFoundException = (output, context) => {
2132
- return {
2133
- message: __expectString(output.message),
2134
- };
2135
- };
2136
- const de_RevocationConfiguration = (output, context) => {
2137
- return {
2138
- CrlConfiguration: output.CrlConfiguration != null ? de_CrlConfiguration(output.CrlConfiguration, context) : undefined,
2139
- OcspConfiguration: output.OcspConfiguration != null ? de_OcspConfiguration(output.OcspConfiguration, context) : undefined,
2140
- };
2141
- };
2142
- const de_Tag = (output, context) => {
2143
- return {
2144
- Key: __expectString(output.Key),
2145
- Value: __expectString(output.Value),
2146
- };
2147
- };
2148
- const de_TagList = (output, context) => {
2149
- const retVal = (output || [])
2150
- .filter((e) => e != null)
2151
- .map((entry) => {
2152
- if (entry === null) {
2153
- return null;
2154
- }
2155
- return de_Tag(entry, context);
2156
- });
2157
- return retVal;
2158
- };
2159
- const de_TooManyTagsException = (output, context) => {
2160
- return {
2161
- message: __expectString(output.message),
2162
- };
2163
- };
2164
1367
  const deserializeMetadata = (output) => ({
2165
1368
  httpStatusCode: output.statusCode,
2166
1369
  requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
@@ -2174,6 +1377,7 @@ const collectBody = (streamBody = new Uint8Array(), context) => {
2174
1377
  return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
2175
1378
  };
2176
1379
  const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
1380
+ const throwDefaultError = withBaseException(__BaseException);
2177
1381
  const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
2178
1382
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
2179
1383
  const contents = {
@@ -2192,6 +1396,12 @@ const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, bod
2192
1396
  }
2193
1397
  return new __HttpRequest(contents);
2194
1398
  };
1399
+ function sharedHeaders(operation) {
1400
+ return {
1401
+ "content-type": "application/x-amz-json-1.1",
1402
+ "x-amz-target": `ACMPrivateCA.${operation}`,
1403
+ };
1404
+ }
2195
1405
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
2196
1406
  if (encoded.length) {
2197
1407
  return JSON.parse(encoded);