@aws-sdk/client-mwaa 3.928.0 → 3.930.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.
Files changed (36) hide show
  1. package/dist-cjs/index.js +722 -789
  2. package/dist-cjs/runtimeConfig.shared.js +2 -0
  3. package/dist-es/MWAAClient.js +2 -0
  4. package/dist-es/commands/CreateCliTokenCommand.js +3 -10
  5. package/dist-es/commands/CreateEnvironmentCommand.js +3 -10
  6. package/dist-es/commands/CreateWebLoginTokenCommand.js +3 -10
  7. package/dist-es/commands/DeleteEnvironmentCommand.js +3 -9
  8. package/dist-es/commands/GetEnvironmentCommand.js +3 -10
  9. package/dist-es/commands/InvokeRestApiCommand.js +3 -10
  10. package/dist-es/commands/ListEnvironmentsCommand.js +3 -9
  11. package/dist-es/commands/ListTagsForResourceCommand.js +3 -9
  12. package/dist-es/commands/PublishMetricsCommand.js +3 -9
  13. package/dist-es/commands/TagResourceCommand.js +3 -9
  14. package/dist-es/commands/UntagResourceCommand.js +3 -9
  15. package/dist-es/commands/UpdateEnvironmentCommand.js +3 -10
  16. package/dist-es/models/models_0.js +0 -33
  17. package/dist-es/runtimeConfig.shared.js +2 -0
  18. package/dist-es/schemas/schemas_0.js +686 -0
  19. package/dist-types/MWAAClient.d.ts +10 -1
  20. package/dist-types/models/models_0.d.ts +0 -32
  21. package/dist-types/runtimeConfig.browser.d.ts +1 -0
  22. package/dist-types/runtimeConfig.d.ts +1 -0
  23. package/dist-types/runtimeConfig.native.d.ts +1 -0
  24. package/dist-types/runtimeConfig.shared.d.ts +1 -0
  25. package/dist-types/schemas/schemas_0.d.ts +68 -0
  26. package/dist-types/ts3.4/MWAAClient.d.ts +4 -0
  27. package/dist-types/ts3.4/models/models_0.d.ts +0 -22
  28. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +4 -0
  29. package/dist-types/ts3.4/runtimeConfig.d.ts +4 -0
  30. package/dist-types/ts3.4/runtimeConfig.native.d.ts +4 -0
  31. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +4 -0
  32. package/dist-types/ts3.4/schemas/schemas_0.d.ts +75 -0
  33. package/package.json +33 -33
  34. package/dist-es/protocols/Aws_restJson1.js +0 -652
  35. package/dist-types/protocols/Aws_restJson1.d.ts +0 -110
  36. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +0 -149
@@ -1,652 +0,0 @@
1
- import { loadRestJsonErrorCode, parseJsonBody as parseBody, parseJsonErrorBody as parseErrorBody } from "@aws-sdk/core";
2
- import { requestBuilder as rb } from "@smithy/core";
3
- import { isValidHostname as __isValidHostname, } from "@smithy/protocol-http";
4
- import { _json, collectBody, decorateServiceException as __decorateServiceException, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, map, parseEpochTimestamp as __parseEpochTimestamp, serializeFloat as __serializeFloat, take, withBaseException, } from "@smithy/smithy-client";
5
- import { AccessDeniedException, InternalServerException, ResourceNotFoundException, RestApiClientException, RestApiServerException, ValidationException, } from "../models/models_0";
6
- import { MWAAServiceException as __BaseException } from "../models/MWAAServiceException";
7
- export const se_CreateCliTokenCommand = async (input, context) => {
8
- const b = rb(input, context);
9
- const headers = {};
10
- b.bp("/clitoken/{Name}");
11
- b.p("Name", () => input.Name, "{Name}", false);
12
- let body;
13
- let { hostname: resolvedHostname } = await context.endpoint();
14
- if (context.disableHostPrefix !== true) {
15
- resolvedHostname = "env." + resolvedHostname;
16
- if (!__isValidHostname(resolvedHostname)) {
17
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
18
- }
19
- }
20
- b.hn(resolvedHostname);
21
- b.m("POST").h(headers).b(body);
22
- return b.build();
23
- };
24
- export const se_CreateEnvironmentCommand = async (input, context) => {
25
- const b = rb(input, context);
26
- const headers = {
27
- "content-type": "application/json",
28
- };
29
- b.bp("/environments/{Name}");
30
- b.p("Name", () => input.Name, "{Name}", false);
31
- let body;
32
- body = JSON.stringify(take(input, {
33
- AirflowConfigurationOptions: (_) => _json(_),
34
- AirflowVersion: [],
35
- DagS3Path: [],
36
- EndpointManagement: [],
37
- EnvironmentClass: [],
38
- ExecutionRoleArn: [],
39
- KmsKey: [],
40
- LoggingConfiguration: (_) => _json(_),
41
- MaxWebservers: [],
42
- MaxWorkers: [],
43
- MinWebservers: [],
44
- MinWorkers: [],
45
- NetworkConfiguration: (_) => _json(_),
46
- PluginsS3ObjectVersion: [],
47
- PluginsS3Path: [],
48
- RequirementsS3ObjectVersion: [],
49
- RequirementsS3Path: [],
50
- Schedulers: [],
51
- SourceBucketArn: [],
52
- StartupScriptS3ObjectVersion: [],
53
- StartupScriptS3Path: [],
54
- Tags: (_) => _json(_),
55
- WebserverAccessMode: [],
56
- WeeklyMaintenanceWindowStart: [],
57
- }));
58
- let { hostname: resolvedHostname } = await context.endpoint();
59
- if (context.disableHostPrefix !== true) {
60
- resolvedHostname = "api." + resolvedHostname;
61
- if (!__isValidHostname(resolvedHostname)) {
62
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
63
- }
64
- }
65
- b.hn(resolvedHostname);
66
- b.m("PUT").h(headers).b(body);
67
- return b.build();
68
- };
69
- export const se_CreateWebLoginTokenCommand = async (input, context) => {
70
- const b = rb(input, context);
71
- const headers = {};
72
- b.bp("/webtoken/{Name}");
73
- b.p("Name", () => input.Name, "{Name}", false);
74
- let body;
75
- let { hostname: resolvedHostname } = await context.endpoint();
76
- if (context.disableHostPrefix !== true) {
77
- resolvedHostname = "env." + resolvedHostname;
78
- if (!__isValidHostname(resolvedHostname)) {
79
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
80
- }
81
- }
82
- b.hn(resolvedHostname);
83
- b.m("POST").h(headers).b(body);
84
- return b.build();
85
- };
86
- export const se_DeleteEnvironmentCommand = async (input, context) => {
87
- const b = rb(input, context);
88
- const headers = {};
89
- b.bp("/environments/{Name}");
90
- b.p("Name", () => input.Name, "{Name}", false);
91
- let body;
92
- let { hostname: resolvedHostname } = await context.endpoint();
93
- if (context.disableHostPrefix !== true) {
94
- resolvedHostname = "api." + resolvedHostname;
95
- if (!__isValidHostname(resolvedHostname)) {
96
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
97
- }
98
- }
99
- b.hn(resolvedHostname);
100
- b.m("DELETE").h(headers).b(body);
101
- return b.build();
102
- };
103
- export const se_GetEnvironmentCommand = async (input, context) => {
104
- const b = rb(input, context);
105
- const headers = {};
106
- b.bp("/environments/{Name}");
107
- b.p("Name", () => input.Name, "{Name}", false);
108
- let body;
109
- let { hostname: resolvedHostname } = await context.endpoint();
110
- if (context.disableHostPrefix !== true) {
111
- resolvedHostname = "api." + resolvedHostname;
112
- if (!__isValidHostname(resolvedHostname)) {
113
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
114
- }
115
- }
116
- b.hn(resolvedHostname);
117
- b.m("GET").h(headers).b(body);
118
- return b.build();
119
- };
120
- export const se_InvokeRestApiCommand = async (input, context) => {
121
- const b = rb(input, context);
122
- const headers = {
123
- "content-type": "application/json",
124
- };
125
- b.bp("/restapi/{Name}");
126
- b.p("Name", () => input.Name, "{Name}", false);
127
- let body;
128
- body = JSON.stringify(take(input, {
129
- Body: (_) => se_RestApiRequestBody(_, context),
130
- Method: [],
131
- Path: [],
132
- QueryParameters: (_) => se_Document(_, context),
133
- }));
134
- let { hostname: resolvedHostname } = await context.endpoint();
135
- if (context.disableHostPrefix !== true) {
136
- resolvedHostname = "env." + resolvedHostname;
137
- if (!__isValidHostname(resolvedHostname)) {
138
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
139
- }
140
- }
141
- b.hn(resolvedHostname);
142
- b.m("POST").h(headers).b(body);
143
- return b.build();
144
- };
145
- export const se_ListEnvironmentsCommand = async (input, context) => {
146
- const b = rb(input, context);
147
- const headers = {};
148
- b.bp("/environments");
149
- const query = map({
150
- [_NT]: [, input[_NT]],
151
- [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
152
- });
153
- let body;
154
- let { hostname: resolvedHostname } = await context.endpoint();
155
- if (context.disableHostPrefix !== true) {
156
- resolvedHostname = "api." + resolvedHostname;
157
- if (!__isValidHostname(resolvedHostname)) {
158
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
159
- }
160
- }
161
- b.hn(resolvedHostname);
162
- b.m("GET").h(headers).q(query).b(body);
163
- return b.build();
164
- };
165
- export const se_ListTagsForResourceCommand = async (input, context) => {
166
- const b = rb(input, context);
167
- const headers = {};
168
- b.bp("/tags/{ResourceArn}");
169
- b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
170
- let body;
171
- let { hostname: resolvedHostname } = await context.endpoint();
172
- if (context.disableHostPrefix !== true) {
173
- resolvedHostname = "api." + resolvedHostname;
174
- if (!__isValidHostname(resolvedHostname)) {
175
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
176
- }
177
- }
178
- b.hn(resolvedHostname);
179
- b.m("GET").h(headers).b(body);
180
- return b.build();
181
- };
182
- export const se_PublishMetricsCommand = async (input, context) => {
183
- const b = rb(input, context);
184
- const headers = {
185
- "content-type": "application/json",
186
- };
187
- b.bp("/metrics/environments/{EnvironmentName}");
188
- b.p("EnvironmentName", () => input.EnvironmentName, "{EnvironmentName}", false);
189
- let body;
190
- body = JSON.stringify(take(input, {
191
- MetricData: (_) => se_MetricData(_, context),
192
- }));
193
- let { hostname: resolvedHostname } = await context.endpoint();
194
- if (context.disableHostPrefix !== true) {
195
- resolvedHostname = "ops." + resolvedHostname;
196
- if (!__isValidHostname(resolvedHostname)) {
197
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
198
- }
199
- }
200
- b.hn(resolvedHostname);
201
- b.m("POST").h(headers).b(body);
202
- return b.build();
203
- };
204
- export const se_TagResourceCommand = async (input, context) => {
205
- const b = rb(input, context);
206
- const headers = {
207
- "content-type": "application/json",
208
- };
209
- b.bp("/tags/{ResourceArn}");
210
- b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
211
- let body;
212
- body = JSON.stringify(take(input, {
213
- Tags: (_) => _json(_),
214
- }));
215
- let { hostname: resolvedHostname } = await context.endpoint();
216
- if (context.disableHostPrefix !== true) {
217
- resolvedHostname = "api." + resolvedHostname;
218
- if (!__isValidHostname(resolvedHostname)) {
219
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
220
- }
221
- }
222
- b.hn(resolvedHostname);
223
- b.m("POST").h(headers).b(body);
224
- return b.build();
225
- };
226
- export const se_UntagResourceCommand = async (input, context) => {
227
- const b = rb(input, context);
228
- const headers = {};
229
- b.bp("/tags/{ResourceArn}");
230
- b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
231
- const query = map({
232
- [_tK]: [__expectNonNull(input.tagKeys, `tagKeys`) != null, () => input[_tK] || []],
233
- });
234
- let body;
235
- let { hostname: resolvedHostname } = await context.endpoint();
236
- if (context.disableHostPrefix !== true) {
237
- resolvedHostname = "api." + resolvedHostname;
238
- if (!__isValidHostname(resolvedHostname)) {
239
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
240
- }
241
- }
242
- b.hn(resolvedHostname);
243
- b.m("DELETE").h(headers).q(query).b(body);
244
- return b.build();
245
- };
246
- export const se_UpdateEnvironmentCommand = async (input, context) => {
247
- const b = rb(input, context);
248
- const headers = {
249
- "content-type": "application/json",
250
- };
251
- b.bp("/environments/{Name}");
252
- b.p("Name", () => input.Name, "{Name}", false);
253
- let body;
254
- body = JSON.stringify(take(input, {
255
- AirflowConfigurationOptions: (_) => _json(_),
256
- AirflowVersion: [],
257
- DagS3Path: [],
258
- EnvironmentClass: [],
259
- ExecutionRoleArn: [],
260
- LoggingConfiguration: (_) => _json(_),
261
- MaxWebservers: [],
262
- MaxWorkers: [],
263
- MinWebservers: [],
264
- MinWorkers: [],
265
- NetworkConfiguration: (_) => _json(_),
266
- PluginsS3ObjectVersion: [],
267
- PluginsS3Path: [],
268
- RequirementsS3ObjectVersion: [],
269
- RequirementsS3Path: [],
270
- Schedulers: [],
271
- SourceBucketArn: [],
272
- StartupScriptS3ObjectVersion: [],
273
- StartupScriptS3Path: [],
274
- WebserverAccessMode: [],
275
- WeeklyMaintenanceWindowStart: [],
276
- WorkerReplacementStrategy: [],
277
- }));
278
- let { hostname: resolvedHostname } = await context.endpoint();
279
- if (context.disableHostPrefix !== true) {
280
- resolvedHostname = "api." + resolvedHostname;
281
- if (!__isValidHostname(resolvedHostname)) {
282
- throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
283
- }
284
- }
285
- b.hn(resolvedHostname);
286
- b.m("PATCH").h(headers).b(body);
287
- return b.build();
288
- };
289
- export const de_CreateCliTokenCommand = async (output, context) => {
290
- if (output.statusCode !== 200 && output.statusCode >= 300) {
291
- return de_CommandError(output, context);
292
- }
293
- const contents = map({
294
- $metadata: deserializeMetadata(output),
295
- });
296
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
297
- const doc = take(data, {
298
- CliToken: __expectString,
299
- WebServerHostname: __expectString,
300
- });
301
- Object.assign(contents, doc);
302
- return contents;
303
- };
304
- export const de_CreateEnvironmentCommand = async (output, context) => {
305
- if (output.statusCode !== 200 && output.statusCode >= 300) {
306
- return de_CommandError(output, context);
307
- }
308
- const contents = map({
309
- $metadata: deserializeMetadata(output),
310
- });
311
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
312
- const doc = take(data, {
313
- Arn: __expectString,
314
- });
315
- Object.assign(contents, doc);
316
- return contents;
317
- };
318
- export const de_CreateWebLoginTokenCommand = async (output, context) => {
319
- if (output.statusCode !== 200 && output.statusCode >= 300) {
320
- return de_CommandError(output, context);
321
- }
322
- const contents = map({
323
- $metadata: deserializeMetadata(output),
324
- });
325
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
326
- const doc = take(data, {
327
- AirflowIdentity: __expectString,
328
- IamIdentity: __expectString,
329
- WebServerHostname: __expectString,
330
- WebToken: __expectString,
331
- });
332
- Object.assign(contents, doc);
333
- return contents;
334
- };
335
- export const de_DeleteEnvironmentCommand = async (output, context) => {
336
- if (output.statusCode !== 200 && output.statusCode >= 300) {
337
- return de_CommandError(output, context);
338
- }
339
- const contents = map({
340
- $metadata: deserializeMetadata(output),
341
- });
342
- await collectBody(output.body, context);
343
- return contents;
344
- };
345
- export const de_GetEnvironmentCommand = async (output, context) => {
346
- if (output.statusCode !== 200 && output.statusCode >= 300) {
347
- return de_CommandError(output, context);
348
- }
349
- const contents = map({
350
- $metadata: deserializeMetadata(output),
351
- });
352
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
353
- const doc = take(data, {
354
- Environment: (_) => de_Environment(_, context),
355
- });
356
- Object.assign(contents, doc);
357
- return contents;
358
- };
359
- export const de_InvokeRestApiCommand = async (output, context) => {
360
- if (output.statusCode !== 200 && output.statusCode >= 300) {
361
- return de_CommandError(output, context);
362
- }
363
- const contents = map({
364
- $metadata: deserializeMetadata(output),
365
- });
366
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
367
- const doc = take(data, {
368
- RestApiResponse: (_) => de_RestApiResponse(_, context),
369
- RestApiStatusCode: __expectInt32,
370
- });
371
- Object.assign(contents, doc);
372
- return contents;
373
- };
374
- export const de_ListEnvironmentsCommand = async (output, context) => {
375
- if (output.statusCode !== 200 && output.statusCode >= 300) {
376
- return de_CommandError(output, context);
377
- }
378
- const contents = map({
379
- $metadata: deserializeMetadata(output),
380
- });
381
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
382
- const doc = take(data, {
383
- Environments: _json,
384
- NextToken: __expectString,
385
- });
386
- Object.assign(contents, doc);
387
- return contents;
388
- };
389
- export const de_ListTagsForResourceCommand = async (output, context) => {
390
- if (output.statusCode !== 200 && output.statusCode >= 300) {
391
- return de_CommandError(output, context);
392
- }
393
- const contents = map({
394
- $metadata: deserializeMetadata(output),
395
- });
396
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
397
- const doc = take(data, {
398
- Tags: _json,
399
- });
400
- Object.assign(contents, doc);
401
- return contents;
402
- };
403
- export const de_PublishMetricsCommand = async (output, context) => {
404
- if (output.statusCode !== 200 && output.statusCode >= 300) {
405
- return de_CommandError(output, context);
406
- }
407
- const contents = map({
408
- $metadata: deserializeMetadata(output),
409
- });
410
- await collectBody(output.body, context);
411
- return contents;
412
- };
413
- export const de_TagResourceCommand = async (output, context) => {
414
- if (output.statusCode !== 200 && output.statusCode >= 300) {
415
- return de_CommandError(output, context);
416
- }
417
- const contents = map({
418
- $metadata: deserializeMetadata(output),
419
- });
420
- await collectBody(output.body, context);
421
- return contents;
422
- };
423
- export const de_UntagResourceCommand = async (output, context) => {
424
- if (output.statusCode !== 200 && output.statusCode >= 300) {
425
- return de_CommandError(output, context);
426
- }
427
- const contents = map({
428
- $metadata: deserializeMetadata(output),
429
- });
430
- await collectBody(output.body, context);
431
- return contents;
432
- };
433
- export const de_UpdateEnvironmentCommand = async (output, context) => {
434
- if (output.statusCode !== 200 && output.statusCode >= 300) {
435
- return de_CommandError(output, context);
436
- }
437
- const contents = map({
438
- $metadata: deserializeMetadata(output),
439
- });
440
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
441
- const doc = take(data, {
442
- Arn: __expectString,
443
- });
444
- Object.assign(contents, doc);
445
- return contents;
446
- };
447
- const de_CommandError = async (output, context) => {
448
- const parsedOutput = {
449
- ...output,
450
- body: await parseErrorBody(output.body, context),
451
- };
452
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
453
- switch (errorCode) {
454
- case "ResourceNotFoundException":
455
- case "com.amazonaws.mwaa#ResourceNotFoundException":
456
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
457
- case "InternalServerException":
458
- case "com.amazonaws.mwaa#InternalServerException":
459
- throw await de_InternalServerExceptionRes(parsedOutput, context);
460
- case "ValidationException":
461
- case "com.amazonaws.mwaa#ValidationException":
462
- throw await de_ValidationExceptionRes(parsedOutput, context);
463
- case "AccessDeniedException":
464
- case "com.amazonaws.mwaa#AccessDeniedException":
465
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
466
- case "RestApiClientException":
467
- case "com.amazonaws.mwaa#RestApiClientException":
468
- throw await de_RestApiClientExceptionRes(parsedOutput, context);
469
- case "RestApiServerException":
470
- case "com.amazonaws.mwaa#RestApiServerException":
471
- throw await de_RestApiServerExceptionRes(parsedOutput, context);
472
- default:
473
- const parsedBody = parsedOutput.body;
474
- return throwDefaultError({
475
- output,
476
- parsedBody,
477
- errorCode,
478
- });
479
- }
480
- };
481
- const throwDefaultError = withBaseException(__BaseException);
482
- const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
483
- const contents = map({});
484
- const data = parsedOutput.body;
485
- const doc = take(data, {
486
- Message: __expectString,
487
- });
488
- Object.assign(contents, doc);
489
- const exception = new AccessDeniedException({
490
- $metadata: deserializeMetadata(parsedOutput),
491
- ...contents,
492
- });
493
- return __decorateServiceException(exception, parsedOutput.body);
494
- };
495
- const de_InternalServerExceptionRes = async (parsedOutput, context) => {
496
- const contents = map({});
497
- const data = parsedOutput.body;
498
- const doc = take(data, {
499
- message: __expectString,
500
- });
501
- Object.assign(contents, doc);
502
- const exception = new InternalServerException({
503
- $metadata: deserializeMetadata(parsedOutput),
504
- ...contents,
505
- });
506
- return __decorateServiceException(exception, parsedOutput.body);
507
- };
508
- const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
509
- const contents = map({});
510
- const data = parsedOutput.body;
511
- const doc = take(data, {
512
- message: __expectString,
513
- });
514
- Object.assign(contents, doc);
515
- const exception = new ResourceNotFoundException({
516
- $metadata: deserializeMetadata(parsedOutput),
517
- ...contents,
518
- });
519
- return __decorateServiceException(exception, parsedOutput.body);
520
- };
521
- const de_RestApiClientExceptionRes = async (parsedOutput, context) => {
522
- const contents = map({});
523
- const data = parsedOutput.body;
524
- const doc = take(data, {
525
- RestApiResponse: (_) => de_RestApiResponse(_, context),
526
- RestApiStatusCode: __expectInt32,
527
- });
528
- Object.assign(contents, doc);
529
- const exception = new RestApiClientException({
530
- $metadata: deserializeMetadata(parsedOutput),
531
- ...contents,
532
- });
533
- return __decorateServiceException(exception, parsedOutput.body);
534
- };
535
- const de_RestApiServerExceptionRes = async (parsedOutput, context) => {
536
- const contents = map({});
537
- const data = parsedOutput.body;
538
- const doc = take(data, {
539
- RestApiResponse: (_) => de_RestApiResponse(_, context),
540
- RestApiStatusCode: __expectInt32,
541
- });
542
- Object.assign(contents, doc);
543
- const exception = new RestApiServerException({
544
- $metadata: deserializeMetadata(parsedOutput),
545
- ...contents,
546
- });
547
- return __decorateServiceException(exception, parsedOutput.body);
548
- };
549
- const de_ValidationExceptionRes = async (parsedOutput, context) => {
550
- const contents = map({});
551
- const data = parsedOutput.body;
552
- const doc = take(data, {
553
- message: __expectString,
554
- });
555
- Object.assign(contents, doc);
556
- const exception = new ValidationException({
557
- $metadata: deserializeMetadata(parsedOutput),
558
- ...contents,
559
- });
560
- return __decorateServiceException(exception, parsedOutput.body);
561
- };
562
- const se_MetricData = (input, context) => {
563
- return input
564
- .filter((e) => e != null)
565
- .map((entry) => {
566
- return se_MetricDatum(entry, context);
567
- });
568
- };
569
- const se_MetricDatum = (input, context) => {
570
- return take(input, {
571
- Dimensions: _json,
572
- MetricName: [],
573
- StatisticValues: (_) => se_StatisticSet(_, context),
574
- Timestamp: (_) => _.getTime() / 1_000,
575
- Unit: [],
576
- Value: __serializeFloat,
577
- });
578
- };
579
- const se_RestApiRequestBody = (input, context) => {
580
- return input;
581
- };
582
- const se_StatisticSet = (input, context) => {
583
- return take(input, {
584
- Maximum: __serializeFloat,
585
- Minimum: __serializeFloat,
586
- SampleCount: [],
587
- Sum: __serializeFloat,
588
- });
589
- };
590
- const se_Document = (input, context) => {
591
- return input;
592
- };
593
- const de_Environment = (output, context) => {
594
- return take(output, {
595
- AirflowConfigurationOptions: _json,
596
- AirflowVersion: __expectString,
597
- Arn: __expectString,
598
- CeleryExecutorQueue: __expectString,
599
- CreatedAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
600
- DagS3Path: __expectString,
601
- DatabaseVpcEndpointService: __expectString,
602
- EndpointManagement: __expectString,
603
- EnvironmentClass: __expectString,
604
- ExecutionRoleArn: __expectString,
605
- KmsKey: __expectString,
606
- LastUpdate: (_) => de_LastUpdate(_, context),
607
- LoggingConfiguration: _json,
608
- MaxWebservers: __expectInt32,
609
- MaxWorkers: __expectInt32,
610
- MinWebservers: __expectInt32,
611
- MinWorkers: __expectInt32,
612
- Name: __expectString,
613
- NetworkConfiguration: _json,
614
- PluginsS3ObjectVersion: __expectString,
615
- PluginsS3Path: __expectString,
616
- RequirementsS3ObjectVersion: __expectString,
617
- RequirementsS3Path: __expectString,
618
- Schedulers: __expectInt32,
619
- ServiceRoleArn: __expectString,
620
- SourceBucketArn: __expectString,
621
- StartupScriptS3ObjectVersion: __expectString,
622
- StartupScriptS3Path: __expectString,
623
- Status: __expectString,
624
- Tags: _json,
625
- WebserverAccessMode: __expectString,
626
- WebserverUrl: __expectString,
627
- WebserverVpcEndpointService: __expectString,
628
- WeeklyMaintenanceWindowStart: __expectString,
629
- });
630
- };
631
- const de_LastUpdate = (output, context) => {
632
- return take(output, {
633
- CreatedAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
634
- Error: _json,
635
- Source: __expectString,
636
- Status: __expectString,
637
- WorkerReplacementStrategy: __expectString,
638
- });
639
- };
640
- const de_RestApiResponse = (output, context) => {
641
- return output;
642
- };
643
- const deserializeMetadata = (output) => ({
644
- httpStatusCode: output.statusCode,
645
- requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
646
- extendedRequestId: output.headers["x-amz-id-2"],
647
- cfId: output.headers["x-amz-cf-id"],
648
- });
649
- const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
650
- const _MR = "MaxResults";
651
- const _NT = "NextToken";
652
- const _tK = "tagKeys";