@aws-sdk/client-groundstation 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,7 +1,7 @@
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, expectObject as __expectObject, expectString as __expectString, expectUnion as __expectUnion, limitedParseDouble as __limitedParseDouble, map as __map, parseEpochTimestamp as __parseEpochTimestamp, resolvedPath as __resolvedPath, serializeFloat as __serializeFloat, throwDefaultError, } from "@aws-sdk/smithy-client";
2
+ import { _json, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, expectUnion as __expectUnion, limitedParseDouble as __limitedParseDouble, map, parseEpochTimestamp as __parseEpochTimestamp, resolvedPath as __resolvedPath, serializeFloat as __serializeFloat, take, withBaseException, } from "@aws-sdk/smithy-client";
3
3
  import { GroundStationServiceException as __BaseException } from "../models/GroundStationServiceException";
4
- import { ConfigTypeData, DependencyException, EphemerisData, InvalidParameterException, KmsKey, ResourceLimitExceededException, ResourceNotFoundException, } from "../models/models_0";
4
+ import { ConfigTypeData, DependencyException, EphemerisData, InvalidParameterException, ResourceLimitExceededException, ResourceNotFoundException, } from "../models/models_0";
5
5
  export const se_CancelContactCommand = async (input, context) => {
6
6
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
7
7
  const headers = {};
@@ -25,11 +25,11 @@ export const se_CreateConfigCommand = async (input, context) => {
25
25
  };
26
26
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/config";
27
27
  let body;
28
- body = JSON.stringify({
29
- ...(input.configData != null && { configData: se_ConfigTypeData(input.configData, context) }),
30
- ...(input.name != null && { name: input.name }),
31
- ...(input.tags != null && { tags: se_TagsMap(input.tags, context) }),
32
- });
28
+ body = JSON.stringify(take(input, {
29
+ configData: (_) => se_ConfigTypeData(_, context),
30
+ name: [],
31
+ tags: (_) => _json(_),
32
+ }));
33
33
  return new __HttpRequest({
34
34
  protocol,
35
35
  hostname,
@@ -47,16 +47,12 @@ export const se_CreateDataflowEndpointGroupCommand = async (input, context) => {
47
47
  };
48
48
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/dataflowEndpointGroup";
49
49
  let body;
50
- body = JSON.stringify({
51
- ...(input.contactPostPassDurationSeconds != null && {
52
- contactPostPassDurationSeconds: input.contactPostPassDurationSeconds,
53
- }),
54
- ...(input.contactPrePassDurationSeconds != null && {
55
- contactPrePassDurationSeconds: input.contactPrePassDurationSeconds,
56
- }),
57
- ...(input.endpointDetails != null && { endpointDetails: se_EndpointDetailsList(input.endpointDetails, context) }),
58
- ...(input.tags != null && { tags: se_TagsMap(input.tags, context) }),
59
- });
50
+ body = JSON.stringify(take(input, {
51
+ contactPostPassDurationSeconds: [],
52
+ contactPrePassDurationSeconds: [],
53
+ endpointDetails: (_) => _json(_),
54
+ tags: (_) => _json(_),
55
+ }));
60
56
  return new __HttpRequest({
61
57
  protocol,
62
58
  hostname,
@@ -74,16 +70,16 @@ export const se_CreateEphemerisCommand = async (input, context) => {
74
70
  };
75
71
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ephemeris";
76
72
  let body;
77
- body = JSON.stringify({
78
- ...(input.enabled != null && { enabled: input.enabled }),
79
- ...(input.ephemeris != null && { ephemeris: se_EphemerisData(input.ephemeris, context) }),
80
- ...(input.expirationTime != null && { expirationTime: Math.round(input.expirationTime.getTime() / 1000) }),
81
- ...(input.kmsKeyArn != null && { kmsKeyArn: input.kmsKeyArn }),
82
- ...(input.name != null && { name: input.name }),
83
- ...(input.priority != null && { priority: input.priority }),
84
- ...(input.satelliteId != null && { satelliteId: input.satelliteId }),
85
- ...(input.tags != null && { tags: se_TagsMap(input.tags, context) }),
86
- });
73
+ body = JSON.stringify(take(input, {
74
+ enabled: [],
75
+ ephemeris: (_) => se_EphemerisData(_, context),
76
+ expirationTime: (_) => Math.round(_.getTime() / 1000),
77
+ kmsKeyArn: [],
78
+ name: [],
79
+ priority: [],
80
+ satelliteId: [],
81
+ tags: (_) => _json(_),
82
+ }));
87
83
  return new __HttpRequest({
88
84
  protocol,
89
85
  hostname,
@@ -101,23 +97,17 @@ export const se_CreateMissionProfileCommand = async (input, context) => {
101
97
  };
102
98
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/missionprofile";
103
99
  let body;
104
- body = JSON.stringify({
105
- ...(input.contactPostPassDurationSeconds != null && {
106
- contactPostPassDurationSeconds: input.contactPostPassDurationSeconds,
107
- }),
108
- ...(input.contactPrePassDurationSeconds != null && {
109
- contactPrePassDurationSeconds: input.contactPrePassDurationSeconds,
110
- }),
111
- ...(input.dataflowEdges != null && { dataflowEdges: se_DataflowEdgeList(input.dataflowEdges, context) }),
112
- ...(input.minimumViableContactDurationSeconds != null && {
113
- minimumViableContactDurationSeconds: input.minimumViableContactDurationSeconds,
114
- }),
115
- ...(input.name != null && { name: input.name }),
116
- ...(input.streamsKmsKey != null && { streamsKmsKey: se_KmsKey(input.streamsKmsKey, context) }),
117
- ...(input.streamsKmsRole != null && { streamsKmsRole: input.streamsKmsRole }),
118
- ...(input.tags != null && { tags: se_TagsMap(input.tags, context) }),
119
- ...(input.trackingConfigArn != null && { trackingConfigArn: input.trackingConfigArn }),
120
- });
100
+ body = JSON.stringify(take(input, {
101
+ contactPostPassDurationSeconds: [],
102
+ contactPrePassDurationSeconds: [],
103
+ dataflowEdges: (_) => _json(_),
104
+ minimumViableContactDurationSeconds: [],
105
+ name: [],
106
+ streamsKmsKey: (_) => _json(_),
107
+ streamsKmsRole: [],
108
+ tags: (_) => _json(_),
109
+ trackingConfigArn: [],
110
+ }));
121
111
  return new __HttpRequest({
122
112
  protocol,
123
113
  hostname,
@@ -283,10 +273,10 @@ export const se_GetMinuteUsageCommand = async (input, context) => {
283
273
  };
284
274
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/minute-usage";
285
275
  let body;
286
- body = JSON.stringify({
287
- ...(input.month != null && { month: input.month }),
288
- ...(input.year != null && { year: input.year }),
289
- });
276
+ body = JSON.stringify(take(input, {
277
+ month: [],
278
+ year: [],
279
+ }));
290
280
  return new __HttpRequest({
291
281
  protocol,
292
282
  hostname,
@@ -356,16 +346,16 @@ export const se_ListContactsCommand = async (input, context) => {
356
346
  };
357
347
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/contacts";
358
348
  let body;
359
- body = JSON.stringify({
360
- ...(input.endTime != null && { endTime: Math.round(input.endTime.getTime() / 1000) }),
361
- ...(input.groundStation != null && { groundStation: input.groundStation }),
362
- ...(input.maxResults != null && { maxResults: input.maxResults }),
363
- ...(input.missionProfileArn != null && { missionProfileArn: input.missionProfileArn }),
364
- ...(input.nextToken != null && { nextToken: input.nextToken }),
365
- ...(input.satelliteArn != null && { satelliteArn: input.satelliteArn }),
366
- ...(input.startTime != null && { startTime: Math.round(input.startTime.getTime() / 1000) }),
367
- ...(input.statusList != null && { statusList: se_StatusList(input.statusList, context) }),
368
- });
349
+ body = JSON.stringify(take(input, {
350
+ endTime: (_) => Math.round(_.getTime() / 1000),
351
+ groundStation: [],
352
+ maxResults: [],
353
+ missionProfileArn: [],
354
+ nextToken: [],
355
+ satelliteArn: [],
356
+ startTime: (_) => Math.round(_.getTime() / 1000),
357
+ statusList: (_) => _json(_),
358
+ }));
369
359
  return new __HttpRequest({
370
360
  protocol,
371
361
  hostname,
@@ -407,12 +397,12 @@ export const se_ListEphemeridesCommand = async (input, context) => {
407
397
  nextToken: [, input.nextToken],
408
398
  });
409
399
  let body;
410
- body = JSON.stringify({
411
- ...(input.endTime != null && { endTime: Math.round(input.endTime.getTime() / 1000) }),
412
- ...(input.satelliteId != null && { satelliteId: input.satelliteId }),
413
- ...(input.startTime != null && { startTime: Math.round(input.startTime.getTime() / 1000) }),
414
- ...(input.statusList != null && { statusList: se_EphemerisStatusList(input.statusList, context) }),
415
- });
400
+ body = JSON.stringify(take(input, {
401
+ endTime: (_) => Math.round(_.getTime() / 1000),
402
+ satelliteId: [],
403
+ startTime: (_) => Math.round(_.getTime() / 1000),
404
+ statusList: (_) => _json(_),
405
+ }));
416
406
  return new __HttpRequest({
417
407
  protocol,
418
408
  hostname,
@@ -508,10 +498,10 @@ export const se_RegisterAgentCommand = async (input, context) => {
508
498
  };
509
499
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/agent";
510
500
  let body;
511
- body = JSON.stringify({
512
- ...(input.agentDetails != null && { agentDetails: se_AgentDetails(input.agentDetails, context) }),
513
- ...(input.discoveryData != null && { discoveryData: se_DiscoveryData(input.discoveryData, context) }),
514
- });
501
+ body = JSON.stringify(take(input, {
502
+ agentDetails: (_) => _json(_),
503
+ discoveryData: (_) => _json(_),
504
+ }));
515
505
  return new __HttpRequest({
516
506
  protocol,
517
507
  hostname,
@@ -529,14 +519,14 @@ export const se_ReserveContactCommand = async (input, context) => {
529
519
  };
530
520
  const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/contact";
531
521
  let body;
532
- body = JSON.stringify({
533
- ...(input.endTime != null && { endTime: Math.round(input.endTime.getTime() / 1000) }),
534
- ...(input.groundStation != null && { groundStation: input.groundStation }),
535
- ...(input.missionProfileArn != null && { missionProfileArn: input.missionProfileArn }),
536
- ...(input.satelliteArn != null && { satelliteArn: input.satelliteArn }),
537
- ...(input.startTime != null && { startTime: Math.round(input.startTime.getTime() / 1000) }),
538
- ...(input.tags != null && { tags: se_TagsMap(input.tags, context) }),
539
- });
522
+ body = JSON.stringify(take(input, {
523
+ endTime: (_) => Math.round(_.getTime() / 1000),
524
+ groundStation: [],
525
+ missionProfileArn: [],
526
+ satelliteArn: [],
527
+ startTime: (_) => Math.round(_.getTime() / 1000),
528
+ tags: (_) => _json(_),
529
+ }));
540
530
  return new __HttpRequest({
541
531
  protocol,
542
532
  hostname,
@@ -555,9 +545,9 @@ export const se_TagResourceCommand = async (input, context) => {
555
545
  let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
556
546
  resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
557
547
  let body;
558
- body = JSON.stringify({
559
- ...(input.tags != null && { tags: se_TagsMap(input.tags, context) }),
560
- });
548
+ body = JSON.stringify(take(input, {
549
+ tags: (_) => _json(_),
550
+ }));
561
551
  return new __HttpRequest({
562
552
  protocol,
563
553
  hostname,
@@ -599,13 +589,11 @@ export const se_UpdateAgentStatusCommand = async (input, context) => {
599
589
  let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/agent/{agentId}";
600
590
  resolvedPath = __resolvedPath(resolvedPath, input, "agentId", () => input.agentId, "{agentId}", false);
601
591
  let body;
602
- body = JSON.stringify({
603
- ...(input.aggregateStatus != null && { aggregateStatus: se_AggregateStatus(input.aggregateStatus, context) }),
604
- ...(input.componentStatuses != null && {
605
- componentStatuses: se_ComponentStatusList(input.componentStatuses, context),
606
- }),
607
- ...(input.taskId != null && { taskId: input.taskId }),
608
- });
592
+ body = JSON.stringify(take(input, {
593
+ aggregateStatus: (_) => _json(_),
594
+ componentStatuses: (_) => _json(_),
595
+ taskId: [],
596
+ }));
609
597
  return new __HttpRequest({
610
598
  protocol,
611
599
  hostname,
@@ -625,10 +613,10 @@ export const se_UpdateConfigCommand = async (input, context) => {
625
613
  resolvedPath = __resolvedPath(resolvedPath, input, "configId", () => input.configId, "{configId}", false);
626
614
  resolvedPath = __resolvedPath(resolvedPath, input, "configType", () => input.configType, "{configType}", false);
627
615
  let body;
628
- body = JSON.stringify({
629
- ...(input.configData != null && { configData: se_ConfigTypeData(input.configData, context) }),
630
- ...(input.name != null && { name: input.name }),
631
- });
616
+ body = JSON.stringify(take(input, {
617
+ configData: (_) => se_ConfigTypeData(_, context),
618
+ name: [],
619
+ }));
632
620
  return new __HttpRequest({
633
621
  protocol,
634
622
  hostname,
@@ -647,11 +635,11 @@ export const se_UpdateEphemerisCommand = async (input, context) => {
647
635
  let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ephemeris/{ephemerisId}";
648
636
  resolvedPath = __resolvedPath(resolvedPath, input, "ephemerisId", () => input.ephemerisId, "{ephemerisId}", false);
649
637
  let body;
650
- body = JSON.stringify({
651
- ...(input.enabled != null && { enabled: input.enabled }),
652
- ...(input.name != null && { name: input.name }),
653
- ...(input.priority != null && { priority: input.priority }),
654
- });
638
+ body = JSON.stringify(take(input, {
639
+ enabled: [],
640
+ name: [],
641
+ priority: [],
642
+ }));
655
643
  return new __HttpRequest({
656
644
  protocol,
657
645
  hostname,
@@ -670,22 +658,16 @@ export const se_UpdateMissionProfileCommand = async (input, context) => {
670
658
  let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/missionprofile/{missionProfileId}";
671
659
  resolvedPath = __resolvedPath(resolvedPath, input, "missionProfileId", () => input.missionProfileId, "{missionProfileId}", false);
672
660
  let body;
673
- body = JSON.stringify({
674
- ...(input.contactPostPassDurationSeconds != null && {
675
- contactPostPassDurationSeconds: input.contactPostPassDurationSeconds,
676
- }),
677
- ...(input.contactPrePassDurationSeconds != null && {
678
- contactPrePassDurationSeconds: input.contactPrePassDurationSeconds,
679
- }),
680
- ...(input.dataflowEdges != null && { dataflowEdges: se_DataflowEdgeList(input.dataflowEdges, context) }),
681
- ...(input.minimumViableContactDurationSeconds != null && {
682
- minimumViableContactDurationSeconds: input.minimumViableContactDurationSeconds,
683
- }),
684
- ...(input.name != null && { name: input.name }),
685
- ...(input.streamsKmsKey != null && { streamsKmsKey: se_KmsKey(input.streamsKmsKey, context) }),
686
- ...(input.streamsKmsRole != null && { streamsKmsRole: input.streamsKmsRole }),
687
- ...(input.trackingConfigArn != null && { trackingConfigArn: input.trackingConfigArn }),
688
- });
661
+ body = JSON.stringify(take(input, {
662
+ contactPostPassDurationSeconds: [],
663
+ contactPrePassDurationSeconds: [],
664
+ dataflowEdges: (_) => _json(_),
665
+ minimumViableContactDurationSeconds: [],
666
+ name: [],
667
+ streamsKmsKey: (_) => _json(_),
668
+ streamsKmsRole: [],
669
+ trackingConfigArn: [],
670
+ }));
689
671
  return new __HttpRequest({
690
672
  protocol,
691
673
  hostname,
@@ -704,9 +686,10 @@ export const de_CancelContactCommand = async (output, context) => {
704
686
  $metadata: deserializeMetadata(output),
705
687
  });
706
688
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
707
- if (data.contactId != null) {
708
- contents.contactId = __expectString(data.contactId);
709
- }
689
+ const doc = take(data, {
690
+ contactId: __expectString,
691
+ });
692
+ Object.assign(contents, doc);
710
693
  return contents;
711
694
  };
712
695
  const de_CancelContactCommandError = async (output, context) => {
@@ -727,10 +710,9 @@ const de_CancelContactCommandError = async (output, context) => {
727
710
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
728
711
  default:
729
712
  const parsedBody = parsedOutput.body;
730
- throwDefaultError({
713
+ return throwDefaultError({
731
714
  output,
732
715
  parsedBody,
733
- exceptionCtor: __BaseException,
734
716
  errorCode,
735
717
  });
736
718
  }
@@ -743,15 +725,12 @@ export const de_CreateConfigCommand = async (output, context) => {
743
725
  $metadata: deserializeMetadata(output),
744
726
  });
745
727
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
746
- if (data.configArn != null) {
747
- contents.configArn = __expectString(data.configArn);
748
- }
749
- if (data.configId != null) {
750
- contents.configId = __expectString(data.configId);
751
- }
752
- if (data.configType != null) {
753
- contents.configType = __expectString(data.configType);
754
- }
728
+ const doc = take(data, {
729
+ configArn: __expectString,
730
+ configId: __expectString,
731
+ configType: __expectString,
732
+ });
733
+ Object.assign(contents, doc);
755
734
  return contents;
756
735
  };
757
736
  const de_CreateConfigCommandError = async (output, context) => {
@@ -775,10 +754,9 @@ const de_CreateConfigCommandError = async (output, context) => {
775
754
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
776
755
  default:
777
756
  const parsedBody = parsedOutput.body;
778
- throwDefaultError({
757
+ return throwDefaultError({
779
758
  output,
780
759
  parsedBody,
781
- exceptionCtor: __BaseException,
782
760
  errorCode,
783
761
  });
784
762
  }
@@ -791,9 +769,10 @@ export const de_CreateDataflowEndpointGroupCommand = async (output, context) =>
791
769
  $metadata: deserializeMetadata(output),
792
770
  });
793
771
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
794
- if (data.dataflowEndpointGroupId != null) {
795
- contents.dataflowEndpointGroupId = __expectString(data.dataflowEndpointGroupId);
796
- }
772
+ const doc = take(data, {
773
+ dataflowEndpointGroupId: __expectString,
774
+ });
775
+ Object.assign(contents, doc);
797
776
  return contents;
798
777
  };
799
778
  const de_CreateDataflowEndpointGroupCommandError = async (output, context) => {
@@ -814,10 +793,9 @@ const de_CreateDataflowEndpointGroupCommandError = async (output, context) => {
814
793
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
815
794
  default:
816
795
  const parsedBody = parsedOutput.body;
817
- throwDefaultError({
796
+ return throwDefaultError({
818
797
  output,
819
798
  parsedBody,
820
- exceptionCtor: __BaseException,
821
799
  errorCode,
822
800
  });
823
801
  }
@@ -830,9 +808,10 @@ export const de_CreateEphemerisCommand = async (output, context) => {
830
808
  $metadata: deserializeMetadata(output),
831
809
  });
832
810
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
833
- if (data.ephemerisId != null) {
834
- contents.ephemerisId = __expectString(data.ephemerisId);
835
- }
811
+ const doc = take(data, {
812
+ ephemerisId: __expectString,
813
+ });
814
+ Object.assign(contents, doc);
836
815
  return contents;
837
816
  };
838
817
  const de_CreateEphemerisCommandError = async (output, context) => {
@@ -853,10 +832,9 @@ const de_CreateEphemerisCommandError = async (output, context) => {
853
832
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
854
833
  default:
855
834
  const parsedBody = parsedOutput.body;
856
- throwDefaultError({
835
+ return throwDefaultError({
857
836
  output,
858
837
  parsedBody,
859
- exceptionCtor: __BaseException,
860
838
  errorCode,
861
839
  });
862
840
  }
@@ -869,9 +847,10 @@ export const de_CreateMissionProfileCommand = async (output, context) => {
869
847
  $metadata: deserializeMetadata(output),
870
848
  });
871
849
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
872
- if (data.missionProfileId != null) {
873
- contents.missionProfileId = __expectString(data.missionProfileId);
874
- }
850
+ const doc = take(data, {
851
+ missionProfileId: __expectString,
852
+ });
853
+ Object.assign(contents, doc);
875
854
  return contents;
876
855
  };
877
856
  const de_CreateMissionProfileCommandError = async (output, context) => {
@@ -892,10 +871,9 @@ const de_CreateMissionProfileCommandError = async (output, context) => {
892
871
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
893
872
  default:
894
873
  const parsedBody = parsedOutput.body;
895
- throwDefaultError({
874
+ return throwDefaultError({
896
875
  output,
897
876
  parsedBody,
898
- exceptionCtor: __BaseException,
899
877
  errorCode,
900
878
  });
901
879
  }
@@ -908,15 +886,12 @@ export const de_DeleteConfigCommand = async (output, context) => {
908
886
  $metadata: deserializeMetadata(output),
909
887
  });
910
888
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
911
- if (data.configArn != null) {
912
- contents.configArn = __expectString(data.configArn);
913
- }
914
- if (data.configId != null) {
915
- contents.configId = __expectString(data.configId);
916
- }
917
- if (data.configType != null) {
918
- contents.configType = __expectString(data.configType);
919
- }
889
+ const doc = take(data, {
890
+ configArn: __expectString,
891
+ configId: __expectString,
892
+ configType: __expectString,
893
+ });
894
+ Object.assign(contents, doc);
920
895
  return contents;
921
896
  };
922
897
  const de_DeleteConfigCommandError = async (output, context) => {
@@ -937,10 +912,9 @@ const de_DeleteConfigCommandError = async (output, context) => {
937
912
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
938
913
  default:
939
914
  const parsedBody = parsedOutput.body;
940
- throwDefaultError({
915
+ return throwDefaultError({
941
916
  output,
942
917
  parsedBody,
943
- exceptionCtor: __BaseException,
944
918
  errorCode,
945
919
  });
946
920
  }
@@ -953,9 +927,10 @@ export const de_DeleteDataflowEndpointGroupCommand = async (output, context) =>
953
927
  $metadata: deserializeMetadata(output),
954
928
  });
955
929
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
956
- if (data.dataflowEndpointGroupId != null) {
957
- contents.dataflowEndpointGroupId = __expectString(data.dataflowEndpointGroupId);
958
- }
930
+ const doc = take(data, {
931
+ dataflowEndpointGroupId: __expectString,
932
+ });
933
+ Object.assign(contents, doc);
959
934
  return contents;
960
935
  };
961
936
  const de_DeleteDataflowEndpointGroupCommandError = async (output, context) => {
@@ -976,10 +951,9 @@ const de_DeleteDataflowEndpointGroupCommandError = async (output, context) => {
976
951
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
977
952
  default:
978
953
  const parsedBody = parsedOutput.body;
979
- throwDefaultError({
954
+ return throwDefaultError({
980
955
  output,
981
956
  parsedBody,
982
- exceptionCtor: __BaseException,
983
957
  errorCode,
984
958
  });
985
959
  }
@@ -992,9 +966,10 @@ export const de_DeleteEphemerisCommand = async (output, context) => {
992
966
  $metadata: deserializeMetadata(output),
993
967
  });
994
968
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
995
- if (data.ephemerisId != null) {
996
- contents.ephemerisId = __expectString(data.ephemerisId);
997
- }
969
+ const doc = take(data, {
970
+ ephemerisId: __expectString,
971
+ });
972
+ Object.assign(contents, doc);
998
973
  return contents;
999
974
  };
1000
975
  const de_DeleteEphemerisCommandError = async (output, context) => {
@@ -1015,10 +990,9 @@ const de_DeleteEphemerisCommandError = async (output, context) => {
1015
990
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1016
991
  default:
1017
992
  const parsedBody = parsedOutput.body;
1018
- throwDefaultError({
993
+ return throwDefaultError({
1019
994
  output,
1020
995
  parsedBody,
1021
- exceptionCtor: __BaseException,
1022
996
  errorCode,
1023
997
  });
1024
998
  }
@@ -1031,9 +1005,10 @@ export const de_DeleteMissionProfileCommand = async (output, context) => {
1031
1005
  $metadata: deserializeMetadata(output),
1032
1006
  });
1033
1007
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1034
- if (data.missionProfileId != null) {
1035
- contents.missionProfileId = __expectString(data.missionProfileId);
1036
- }
1008
+ const doc = take(data, {
1009
+ missionProfileId: __expectString,
1010
+ });
1011
+ Object.assign(contents, doc);
1037
1012
  return contents;
1038
1013
  };
1039
1014
  const de_DeleteMissionProfileCommandError = async (output, context) => {
@@ -1054,10 +1029,9 @@ const de_DeleteMissionProfileCommandError = async (output, context) => {
1054
1029
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1055
1030
  default:
1056
1031
  const parsedBody = parsedOutput.body;
1057
- throwDefaultError({
1032
+ return throwDefaultError({
1058
1033
  output,
1059
1034
  parsedBody,
1060
- exceptionCtor: __BaseException,
1061
1035
  errorCode,
1062
1036
  });
1063
1037
  }
@@ -1070,48 +1044,23 @@ export const de_DescribeContactCommand = async (output, context) => {
1070
1044
  $metadata: deserializeMetadata(output),
1071
1045
  });
1072
1046
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1073
- if (data.contactId != null) {
1074
- contents.contactId = __expectString(data.contactId);
1075
- }
1076
- if (data.contactStatus != null) {
1077
- contents.contactStatus = __expectString(data.contactStatus);
1078
- }
1079
- if (data.dataflowList != null) {
1080
- contents.dataflowList = de_DataflowList(data.dataflowList, context);
1081
- }
1082
- if (data.endTime != null) {
1083
- contents.endTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.endTime)));
1084
- }
1085
- if (data.errorMessage != null) {
1086
- contents.errorMessage = __expectString(data.errorMessage);
1087
- }
1088
- if (data.groundStation != null) {
1089
- contents.groundStation = __expectString(data.groundStation);
1090
- }
1091
- if (data.maximumElevation != null) {
1092
- contents.maximumElevation = de_Elevation(data.maximumElevation, context);
1093
- }
1094
- if (data.missionProfileArn != null) {
1095
- contents.missionProfileArn = __expectString(data.missionProfileArn);
1096
- }
1097
- if (data.postPassEndTime != null) {
1098
- contents.postPassEndTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.postPassEndTime)));
1099
- }
1100
- if (data.prePassStartTime != null) {
1101
- contents.prePassStartTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.prePassStartTime)));
1102
- }
1103
- if (data.region != null) {
1104
- contents.region = __expectString(data.region);
1105
- }
1106
- if (data.satelliteArn != null) {
1107
- contents.satelliteArn = __expectString(data.satelliteArn);
1108
- }
1109
- if (data.startTime != null) {
1110
- contents.startTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.startTime)));
1111
- }
1112
- if (data.tags != null) {
1113
- contents.tags = de_TagsMap(data.tags, context);
1114
- }
1047
+ const doc = take(data, {
1048
+ contactId: __expectString,
1049
+ contactStatus: __expectString,
1050
+ dataflowList: _json,
1051
+ endTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1052
+ errorMessage: __expectString,
1053
+ groundStation: __expectString,
1054
+ maximumElevation: (_) => de_Elevation(_, context),
1055
+ missionProfileArn: __expectString,
1056
+ postPassEndTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1057
+ prePassStartTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1058
+ region: __expectString,
1059
+ satelliteArn: __expectString,
1060
+ startTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1061
+ tags: _json,
1062
+ });
1063
+ Object.assign(contents, doc);
1115
1064
  return contents;
1116
1065
  };
1117
1066
  const de_DescribeContactCommandError = async (output, context) => {
@@ -1132,10 +1081,9 @@ const de_DescribeContactCommandError = async (output, context) => {
1132
1081
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1133
1082
  default:
1134
1083
  const parsedBody = parsedOutput.body;
1135
- throwDefaultError({
1084
+ return throwDefaultError({
1136
1085
  output,
1137
1086
  parsedBody,
1138
- exceptionCtor: __BaseException,
1139
1087
  errorCode,
1140
1088
  });
1141
1089
  }
@@ -1148,36 +1096,19 @@ export const de_DescribeEphemerisCommand = async (output, context) => {
1148
1096
  $metadata: deserializeMetadata(output),
1149
1097
  });
1150
1098
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1151
- if (data.creationTime != null) {
1152
- contents.creationTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.creationTime)));
1153
- }
1154
- if (data.enabled != null) {
1155
- contents.enabled = __expectBoolean(data.enabled);
1156
- }
1157
- if (data.ephemerisId != null) {
1158
- contents.ephemerisId = __expectString(data.ephemerisId);
1159
- }
1160
- if (data.invalidReason != null) {
1161
- contents.invalidReason = __expectString(data.invalidReason);
1162
- }
1163
- if (data.name != null) {
1164
- contents.name = __expectString(data.name);
1165
- }
1166
- if (data.priority != null) {
1167
- contents.priority = __expectInt32(data.priority);
1168
- }
1169
- if (data.satelliteId != null) {
1170
- contents.satelliteId = __expectString(data.satelliteId);
1171
- }
1172
- if (data.status != null) {
1173
- contents.status = __expectString(data.status);
1174
- }
1175
- if (data.suppliedData != null) {
1176
- contents.suppliedData = de_EphemerisTypeDescription(__expectUnion(data.suppliedData), context);
1177
- }
1178
- if (data.tags != null) {
1179
- contents.tags = de_TagsMap(data.tags, context);
1180
- }
1099
+ const doc = take(data, {
1100
+ creationTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1101
+ enabled: __expectBoolean,
1102
+ ephemerisId: __expectString,
1103
+ invalidReason: __expectString,
1104
+ name: __expectString,
1105
+ priority: __expectInt32,
1106
+ satelliteId: __expectString,
1107
+ status: __expectString,
1108
+ suppliedData: (_) => _json(__expectUnion(_)),
1109
+ tags: _json,
1110
+ });
1111
+ Object.assign(contents, doc);
1181
1112
  return contents;
1182
1113
  };
1183
1114
  const de_DescribeEphemerisCommandError = async (output, context) => {
@@ -1198,10 +1129,9 @@ const de_DescribeEphemerisCommandError = async (output, context) => {
1198
1129
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1199
1130
  default:
1200
1131
  const parsedBody = parsedOutput.body;
1201
- throwDefaultError({
1132
+ return throwDefaultError({
1202
1133
  output,
1203
1134
  parsedBody,
1204
- exceptionCtor: __BaseException,
1205
1135
  errorCode,
1206
1136
  });
1207
1137
  }
@@ -1214,12 +1144,11 @@ export const de_GetAgentConfigurationCommand = async (output, context) => {
1214
1144
  $metadata: deserializeMetadata(output),
1215
1145
  });
1216
1146
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1217
- if (data.agentId != null) {
1218
- contents.agentId = __expectString(data.agentId);
1219
- }
1220
- if (data.taskingDocument != null) {
1221
- contents.taskingDocument = __expectString(data.taskingDocument);
1222
- }
1147
+ const doc = take(data, {
1148
+ agentId: __expectString,
1149
+ taskingDocument: __expectString,
1150
+ });
1151
+ Object.assign(contents, doc);
1223
1152
  return contents;
1224
1153
  };
1225
1154
  const de_GetAgentConfigurationCommandError = async (output, context) => {
@@ -1240,10 +1169,9 @@ const de_GetAgentConfigurationCommandError = async (output, context) => {
1240
1169
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1241
1170
  default:
1242
1171
  const parsedBody = parsedOutput.body;
1243
- throwDefaultError({
1172
+ return throwDefaultError({
1244
1173
  output,
1245
1174
  parsedBody,
1246
- exceptionCtor: __BaseException,
1247
1175
  errorCode,
1248
1176
  });
1249
1177
  }
@@ -1256,24 +1184,15 @@ export const de_GetConfigCommand = async (output, context) => {
1256
1184
  $metadata: deserializeMetadata(output),
1257
1185
  });
1258
1186
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1259
- if (data.configArn != null) {
1260
- contents.configArn = __expectString(data.configArn);
1261
- }
1262
- if (data.configData != null) {
1263
- contents.configData = de_ConfigTypeData(__expectUnion(data.configData), context);
1264
- }
1265
- if (data.configId != null) {
1266
- contents.configId = __expectString(data.configId);
1267
- }
1268
- if (data.configType != null) {
1269
- contents.configType = __expectString(data.configType);
1270
- }
1271
- if (data.name != null) {
1272
- contents.name = __expectString(data.name);
1273
- }
1274
- if (data.tags != null) {
1275
- contents.tags = de_TagsMap(data.tags, context);
1276
- }
1187
+ const doc = take(data, {
1188
+ configArn: __expectString,
1189
+ configData: (_) => de_ConfigTypeData(__expectUnion(_), context),
1190
+ configId: __expectString,
1191
+ configType: __expectString,
1192
+ name: __expectString,
1193
+ tags: _json,
1194
+ });
1195
+ Object.assign(contents, doc);
1277
1196
  return contents;
1278
1197
  };
1279
1198
  const de_GetConfigCommandError = async (output, context) => {
@@ -1294,10 +1213,9 @@ const de_GetConfigCommandError = async (output, context) => {
1294
1213
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1295
1214
  default:
1296
1215
  const parsedBody = parsedOutput.body;
1297
- throwDefaultError({
1216
+ return throwDefaultError({
1298
1217
  output,
1299
1218
  parsedBody,
1300
- exceptionCtor: __BaseException,
1301
1219
  errorCode,
1302
1220
  });
1303
1221
  }
@@ -1310,24 +1228,15 @@ export const de_GetDataflowEndpointGroupCommand = async (output, context) => {
1310
1228
  $metadata: deserializeMetadata(output),
1311
1229
  });
1312
1230
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1313
- if (data.contactPostPassDurationSeconds != null) {
1314
- contents.contactPostPassDurationSeconds = __expectInt32(data.contactPostPassDurationSeconds);
1315
- }
1316
- if (data.contactPrePassDurationSeconds != null) {
1317
- contents.contactPrePassDurationSeconds = __expectInt32(data.contactPrePassDurationSeconds);
1318
- }
1319
- if (data.dataflowEndpointGroupArn != null) {
1320
- contents.dataflowEndpointGroupArn = __expectString(data.dataflowEndpointGroupArn);
1321
- }
1322
- if (data.dataflowEndpointGroupId != null) {
1323
- contents.dataflowEndpointGroupId = __expectString(data.dataflowEndpointGroupId);
1324
- }
1325
- if (data.endpointsDetails != null) {
1326
- contents.endpointsDetails = de_EndpointDetailsList(data.endpointsDetails, context);
1327
- }
1328
- if (data.tags != null) {
1329
- contents.tags = de_TagsMap(data.tags, context);
1330
- }
1231
+ const doc = take(data, {
1232
+ contactPostPassDurationSeconds: __expectInt32,
1233
+ contactPrePassDurationSeconds: __expectInt32,
1234
+ dataflowEndpointGroupArn: __expectString,
1235
+ dataflowEndpointGroupId: __expectString,
1236
+ endpointsDetails: _json,
1237
+ tags: _json,
1238
+ });
1239
+ Object.assign(contents, doc);
1331
1240
  return contents;
1332
1241
  };
1333
1242
  const de_GetDataflowEndpointGroupCommandError = async (output, context) => {
@@ -1348,10 +1257,9 @@ const de_GetDataflowEndpointGroupCommandError = async (output, context) => {
1348
1257
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1349
1258
  default:
1350
1259
  const parsedBody = parsedOutput.body;
1351
- throwDefaultError({
1260
+ return throwDefaultError({
1352
1261
  output,
1353
1262
  parsedBody,
1354
- exceptionCtor: __BaseException,
1355
1263
  errorCode,
1356
1264
  });
1357
1265
  }
@@ -1364,21 +1272,14 @@ export const de_GetMinuteUsageCommand = async (output, context) => {
1364
1272
  $metadata: deserializeMetadata(output),
1365
1273
  });
1366
1274
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1367
- if (data.estimatedMinutesRemaining != null) {
1368
- contents.estimatedMinutesRemaining = __expectInt32(data.estimatedMinutesRemaining);
1369
- }
1370
- if (data.isReservedMinutesCustomer != null) {
1371
- contents.isReservedMinutesCustomer = __expectBoolean(data.isReservedMinutesCustomer);
1372
- }
1373
- if (data.totalReservedMinuteAllocation != null) {
1374
- contents.totalReservedMinuteAllocation = __expectInt32(data.totalReservedMinuteAllocation);
1375
- }
1376
- if (data.totalScheduledMinutes != null) {
1377
- contents.totalScheduledMinutes = __expectInt32(data.totalScheduledMinutes);
1378
- }
1379
- if (data.upcomingMinutesScheduled != null) {
1380
- contents.upcomingMinutesScheduled = __expectInt32(data.upcomingMinutesScheduled);
1381
- }
1275
+ const doc = take(data, {
1276
+ estimatedMinutesRemaining: __expectInt32,
1277
+ isReservedMinutesCustomer: __expectBoolean,
1278
+ totalReservedMinuteAllocation: __expectInt32,
1279
+ totalScheduledMinutes: __expectInt32,
1280
+ upcomingMinutesScheduled: __expectInt32,
1281
+ });
1282
+ Object.assign(contents, doc);
1382
1283
  return contents;
1383
1284
  };
1384
1285
  const de_GetMinuteUsageCommandError = async (output, context) => {
@@ -1399,10 +1300,9 @@ const de_GetMinuteUsageCommandError = async (output, context) => {
1399
1300
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1400
1301
  default:
1401
1302
  const parsedBody = parsedOutput.body;
1402
- throwDefaultError({
1303
+ return throwDefaultError({
1403
1304
  output,
1404
1305
  parsedBody,
1405
- exceptionCtor: __BaseException,
1406
1306
  errorCode,
1407
1307
  });
1408
1308
  }
@@ -1415,42 +1315,21 @@ export const de_GetMissionProfileCommand = async (output, context) => {
1415
1315
  $metadata: deserializeMetadata(output),
1416
1316
  });
1417
1317
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1418
- if (data.contactPostPassDurationSeconds != null) {
1419
- contents.contactPostPassDurationSeconds = __expectInt32(data.contactPostPassDurationSeconds);
1420
- }
1421
- if (data.contactPrePassDurationSeconds != null) {
1422
- contents.contactPrePassDurationSeconds = __expectInt32(data.contactPrePassDurationSeconds);
1423
- }
1424
- if (data.dataflowEdges != null) {
1425
- contents.dataflowEdges = de_DataflowEdgeList(data.dataflowEdges, context);
1426
- }
1427
- if (data.minimumViableContactDurationSeconds != null) {
1428
- contents.minimumViableContactDurationSeconds = __expectInt32(data.minimumViableContactDurationSeconds);
1429
- }
1430
- if (data.missionProfileArn != null) {
1431
- contents.missionProfileArn = __expectString(data.missionProfileArn);
1432
- }
1433
- if (data.missionProfileId != null) {
1434
- contents.missionProfileId = __expectString(data.missionProfileId);
1435
- }
1436
- if (data.name != null) {
1437
- contents.name = __expectString(data.name);
1438
- }
1439
- if (data.region != null) {
1440
- contents.region = __expectString(data.region);
1441
- }
1442
- if (data.streamsKmsKey != null) {
1443
- contents.streamsKmsKey = de_KmsKey(__expectUnion(data.streamsKmsKey), context);
1444
- }
1445
- if (data.streamsKmsRole != null) {
1446
- contents.streamsKmsRole = __expectString(data.streamsKmsRole);
1447
- }
1448
- if (data.tags != null) {
1449
- contents.tags = de_TagsMap(data.tags, context);
1450
- }
1451
- if (data.trackingConfigArn != null) {
1452
- contents.trackingConfigArn = __expectString(data.trackingConfigArn);
1453
- }
1318
+ const doc = take(data, {
1319
+ contactPostPassDurationSeconds: __expectInt32,
1320
+ contactPrePassDurationSeconds: __expectInt32,
1321
+ dataflowEdges: _json,
1322
+ minimumViableContactDurationSeconds: __expectInt32,
1323
+ missionProfileArn: __expectString,
1324
+ missionProfileId: __expectString,
1325
+ name: __expectString,
1326
+ region: __expectString,
1327
+ streamsKmsKey: (_) => _json(__expectUnion(_)),
1328
+ streamsKmsRole: __expectString,
1329
+ tags: _json,
1330
+ trackingConfigArn: __expectString,
1331
+ });
1332
+ Object.assign(contents, doc);
1454
1333
  return contents;
1455
1334
  };
1456
1335
  const de_GetMissionProfileCommandError = async (output, context) => {
@@ -1471,10 +1350,9 @@ const de_GetMissionProfileCommandError = async (output, context) => {
1471
1350
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1472
1351
  default:
1473
1352
  const parsedBody = parsedOutput.body;
1474
- throwDefaultError({
1353
+ return throwDefaultError({
1475
1354
  output,
1476
1355
  parsedBody,
1477
- exceptionCtor: __BaseException,
1478
1356
  errorCode,
1479
1357
  });
1480
1358
  }
@@ -1487,21 +1365,14 @@ export const de_GetSatelliteCommand = async (output, context) => {
1487
1365
  $metadata: deserializeMetadata(output),
1488
1366
  });
1489
1367
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1490
- if (data.currentEphemeris != null) {
1491
- contents.currentEphemeris = de_EphemerisMetaData(data.currentEphemeris, context);
1492
- }
1493
- if (data.groundStations != null) {
1494
- contents.groundStations = de_GroundStationIdList(data.groundStations, context);
1495
- }
1496
- if (data.noradSatelliteID != null) {
1497
- contents.noradSatelliteID = __expectInt32(data.noradSatelliteID);
1498
- }
1499
- if (data.satelliteArn != null) {
1500
- contents.satelliteArn = __expectString(data.satelliteArn);
1501
- }
1502
- if (data.satelliteId != null) {
1503
- contents.satelliteId = __expectString(data.satelliteId);
1504
- }
1368
+ const doc = take(data, {
1369
+ currentEphemeris: (_) => de_EphemerisMetaData(_, context),
1370
+ groundStations: _json,
1371
+ noradSatelliteID: __expectInt32,
1372
+ satelliteArn: __expectString,
1373
+ satelliteId: __expectString,
1374
+ });
1375
+ Object.assign(contents, doc);
1505
1376
  return contents;
1506
1377
  };
1507
1378
  const de_GetSatelliteCommandError = async (output, context) => {
@@ -1522,10 +1393,9 @@ const de_GetSatelliteCommandError = async (output, context) => {
1522
1393
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1523
1394
  default:
1524
1395
  const parsedBody = parsedOutput.body;
1525
- throwDefaultError({
1396
+ return throwDefaultError({
1526
1397
  output,
1527
1398
  parsedBody,
1528
- exceptionCtor: __BaseException,
1529
1399
  errorCode,
1530
1400
  });
1531
1401
  }
@@ -1538,12 +1408,11 @@ export const de_ListConfigsCommand = async (output, context) => {
1538
1408
  $metadata: deserializeMetadata(output),
1539
1409
  });
1540
1410
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1541
- if (data.configList != null) {
1542
- contents.configList = de_ConfigList(data.configList, context);
1543
- }
1544
- if (data.nextToken != null) {
1545
- contents.nextToken = __expectString(data.nextToken);
1546
- }
1411
+ const doc = take(data, {
1412
+ configList: _json,
1413
+ nextToken: __expectString,
1414
+ });
1415
+ Object.assign(contents, doc);
1547
1416
  return contents;
1548
1417
  };
1549
1418
  const de_ListConfigsCommandError = async (output, context) => {
@@ -1564,10 +1433,9 @@ const de_ListConfigsCommandError = async (output, context) => {
1564
1433
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1565
1434
  default:
1566
1435
  const parsedBody = parsedOutput.body;
1567
- throwDefaultError({
1436
+ return throwDefaultError({
1568
1437
  output,
1569
1438
  parsedBody,
1570
- exceptionCtor: __BaseException,
1571
1439
  errorCode,
1572
1440
  });
1573
1441
  }
@@ -1580,12 +1448,11 @@ export const de_ListContactsCommand = async (output, context) => {
1580
1448
  $metadata: deserializeMetadata(output),
1581
1449
  });
1582
1450
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1583
- if (data.contactList != null) {
1584
- contents.contactList = de_ContactList(data.contactList, context);
1585
- }
1586
- if (data.nextToken != null) {
1587
- contents.nextToken = __expectString(data.nextToken);
1588
- }
1451
+ const doc = take(data, {
1452
+ contactList: (_) => de_ContactList(_, context),
1453
+ nextToken: __expectString,
1454
+ });
1455
+ Object.assign(contents, doc);
1589
1456
  return contents;
1590
1457
  };
1591
1458
  const de_ListContactsCommandError = async (output, context) => {
@@ -1606,10 +1473,9 @@ const de_ListContactsCommandError = async (output, context) => {
1606
1473
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1607
1474
  default:
1608
1475
  const parsedBody = parsedOutput.body;
1609
- throwDefaultError({
1476
+ return throwDefaultError({
1610
1477
  output,
1611
1478
  parsedBody,
1612
- exceptionCtor: __BaseException,
1613
1479
  errorCode,
1614
1480
  });
1615
1481
  }
@@ -1622,12 +1488,11 @@ export const de_ListDataflowEndpointGroupsCommand = async (output, context) => {
1622
1488
  $metadata: deserializeMetadata(output),
1623
1489
  });
1624
1490
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1625
- if (data.dataflowEndpointGroupList != null) {
1626
- contents.dataflowEndpointGroupList = de_DataflowEndpointGroupList(data.dataflowEndpointGroupList, context);
1627
- }
1628
- if (data.nextToken != null) {
1629
- contents.nextToken = __expectString(data.nextToken);
1630
- }
1491
+ const doc = take(data, {
1492
+ dataflowEndpointGroupList: _json,
1493
+ nextToken: __expectString,
1494
+ });
1495
+ Object.assign(contents, doc);
1631
1496
  return contents;
1632
1497
  };
1633
1498
  const de_ListDataflowEndpointGroupsCommandError = async (output, context) => {
@@ -1648,10 +1513,9 @@ const de_ListDataflowEndpointGroupsCommandError = async (output, context) => {
1648
1513
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1649
1514
  default:
1650
1515
  const parsedBody = parsedOutput.body;
1651
- throwDefaultError({
1516
+ return throwDefaultError({
1652
1517
  output,
1653
1518
  parsedBody,
1654
- exceptionCtor: __BaseException,
1655
1519
  errorCode,
1656
1520
  });
1657
1521
  }
@@ -1664,12 +1528,11 @@ export const de_ListEphemeridesCommand = async (output, context) => {
1664
1528
  $metadata: deserializeMetadata(output),
1665
1529
  });
1666
1530
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1667
- if (data.ephemerides != null) {
1668
- contents.ephemerides = de_EphemeridesList(data.ephemerides, context);
1669
- }
1670
- if (data.nextToken != null) {
1671
- contents.nextToken = __expectString(data.nextToken);
1672
- }
1531
+ const doc = take(data, {
1532
+ ephemerides: (_) => de_EphemeridesList(_, context),
1533
+ nextToken: __expectString,
1534
+ });
1535
+ Object.assign(contents, doc);
1673
1536
  return contents;
1674
1537
  };
1675
1538
  const de_ListEphemeridesCommandError = async (output, context) => {
@@ -1690,10 +1553,9 @@ const de_ListEphemeridesCommandError = async (output, context) => {
1690
1553
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1691
1554
  default:
1692
1555
  const parsedBody = parsedOutput.body;
1693
- throwDefaultError({
1556
+ return throwDefaultError({
1694
1557
  output,
1695
1558
  parsedBody,
1696
- exceptionCtor: __BaseException,
1697
1559
  errorCode,
1698
1560
  });
1699
1561
  }
@@ -1706,12 +1568,11 @@ export const de_ListGroundStationsCommand = async (output, context) => {
1706
1568
  $metadata: deserializeMetadata(output),
1707
1569
  });
1708
1570
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1709
- if (data.groundStationList != null) {
1710
- contents.groundStationList = de_GroundStationList(data.groundStationList, context);
1711
- }
1712
- if (data.nextToken != null) {
1713
- contents.nextToken = __expectString(data.nextToken);
1714
- }
1571
+ const doc = take(data, {
1572
+ groundStationList: _json,
1573
+ nextToken: __expectString,
1574
+ });
1575
+ Object.assign(contents, doc);
1715
1576
  return contents;
1716
1577
  };
1717
1578
  const de_ListGroundStationsCommandError = async (output, context) => {
@@ -1732,10 +1593,9 @@ const de_ListGroundStationsCommandError = async (output, context) => {
1732
1593
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1733
1594
  default:
1734
1595
  const parsedBody = parsedOutput.body;
1735
- throwDefaultError({
1596
+ return throwDefaultError({
1736
1597
  output,
1737
1598
  parsedBody,
1738
- exceptionCtor: __BaseException,
1739
1599
  errorCode,
1740
1600
  });
1741
1601
  }
@@ -1748,12 +1608,11 @@ export const de_ListMissionProfilesCommand = async (output, context) => {
1748
1608
  $metadata: deserializeMetadata(output),
1749
1609
  });
1750
1610
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1751
- if (data.missionProfileList != null) {
1752
- contents.missionProfileList = de_MissionProfileList(data.missionProfileList, context);
1753
- }
1754
- if (data.nextToken != null) {
1755
- contents.nextToken = __expectString(data.nextToken);
1756
- }
1611
+ const doc = take(data, {
1612
+ missionProfileList: _json,
1613
+ nextToken: __expectString,
1614
+ });
1615
+ Object.assign(contents, doc);
1757
1616
  return contents;
1758
1617
  };
1759
1618
  const de_ListMissionProfilesCommandError = async (output, context) => {
@@ -1774,10 +1633,9 @@ const de_ListMissionProfilesCommandError = async (output, context) => {
1774
1633
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1775
1634
  default:
1776
1635
  const parsedBody = parsedOutput.body;
1777
- throwDefaultError({
1636
+ return throwDefaultError({
1778
1637
  output,
1779
1638
  parsedBody,
1780
- exceptionCtor: __BaseException,
1781
1639
  errorCode,
1782
1640
  });
1783
1641
  }
@@ -1790,12 +1648,11 @@ export const de_ListSatellitesCommand = async (output, context) => {
1790
1648
  $metadata: deserializeMetadata(output),
1791
1649
  });
1792
1650
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1793
- if (data.nextToken != null) {
1794
- contents.nextToken = __expectString(data.nextToken);
1795
- }
1796
- if (data.satellites != null) {
1797
- contents.satellites = de_SatelliteList(data.satellites, context);
1798
- }
1651
+ const doc = take(data, {
1652
+ nextToken: __expectString,
1653
+ satellites: (_) => de_SatelliteList(_, context),
1654
+ });
1655
+ Object.assign(contents, doc);
1799
1656
  return contents;
1800
1657
  };
1801
1658
  const de_ListSatellitesCommandError = async (output, context) => {
@@ -1816,10 +1673,9 @@ const de_ListSatellitesCommandError = async (output, context) => {
1816
1673
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1817
1674
  default:
1818
1675
  const parsedBody = parsedOutput.body;
1819
- throwDefaultError({
1676
+ return throwDefaultError({
1820
1677
  output,
1821
1678
  parsedBody,
1822
- exceptionCtor: __BaseException,
1823
1679
  errorCode,
1824
1680
  });
1825
1681
  }
@@ -1832,9 +1688,10 @@ export const de_ListTagsForResourceCommand = async (output, context) => {
1832
1688
  $metadata: deserializeMetadata(output),
1833
1689
  });
1834
1690
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1835
- if (data.tags != null) {
1836
- contents.tags = de_TagsMap(data.tags, context);
1837
- }
1691
+ const doc = take(data, {
1692
+ tags: _json,
1693
+ });
1694
+ Object.assign(contents, doc);
1838
1695
  return contents;
1839
1696
  };
1840
1697
  const de_ListTagsForResourceCommandError = async (output, context) => {
@@ -1855,10 +1712,9 @@ const de_ListTagsForResourceCommandError = async (output, context) => {
1855
1712
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1856
1713
  default:
1857
1714
  const parsedBody = parsedOutput.body;
1858
- throwDefaultError({
1715
+ return throwDefaultError({
1859
1716
  output,
1860
1717
  parsedBody,
1861
- exceptionCtor: __BaseException,
1862
1718
  errorCode,
1863
1719
  });
1864
1720
  }
@@ -1871,9 +1727,10 @@ export const de_RegisterAgentCommand = async (output, context) => {
1871
1727
  $metadata: deserializeMetadata(output),
1872
1728
  });
1873
1729
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1874
- if (data.agentId != null) {
1875
- contents.agentId = __expectString(data.agentId);
1876
- }
1730
+ const doc = take(data, {
1731
+ agentId: __expectString,
1732
+ });
1733
+ Object.assign(contents, doc);
1877
1734
  return contents;
1878
1735
  };
1879
1736
  const de_RegisterAgentCommandError = async (output, context) => {
@@ -1894,10 +1751,9 @@ const de_RegisterAgentCommandError = async (output, context) => {
1894
1751
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1895
1752
  default:
1896
1753
  const parsedBody = parsedOutput.body;
1897
- throwDefaultError({
1754
+ return throwDefaultError({
1898
1755
  output,
1899
1756
  parsedBody,
1900
- exceptionCtor: __BaseException,
1901
1757
  errorCode,
1902
1758
  });
1903
1759
  }
@@ -1910,9 +1766,10 @@ export const de_ReserveContactCommand = async (output, context) => {
1910
1766
  $metadata: deserializeMetadata(output),
1911
1767
  });
1912
1768
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1913
- if (data.contactId != null) {
1914
- contents.contactId = __expectString(data.contactId);
1915
- }
1769
+ const doc = take(data, {
1770
+ contactId: __expectString,
1771
+ });
1772
+ Object.assign(contents, doc);
1916
1773
  return contents;
1917
1774
  };
1918
1775
  const de_ReserveContactCommandError = async (output, context) => {
@@ -1933,10 +1790,9 @@ const de_ReserveContactCommandError = async (output, context) => {
1933
1790
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1934
1791
  default:
1935
1792
  const parsedBody = parsedOutput.body;
1936
- throwDefaultError({
1793
+ return throwDefaultError({
1937
1794
  output,
1938
1795
  parsedBody,
1939
- exceptionCtor: __BaseException,
1940
1796
  errorCode,
1941
1797
  });
1942
1798
  }
@@ -1969,10 +1825,9 @@ const de_TagResourceCommandError = async (output, context) => {
1969
1825
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1970
1826
  default:
1971
1827
  const parsedBody = parsedOutput.body;
1972
- throwDefaultError({
1828
+ return throwDefaultError({
1973
1829
  output,
1974
1830
  parsedBody,
1975
- exceptionCtor: __BaseException,
1976
1831
  errorCode,
1977
1832
  });
1978
1833
  }
@@ -2005,10 +1860,9 @@ const de_UntagResourceCommandError = async (output, context) => {
2005
1860
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2006
1861
  default:
2007
1862
  const parsedBody = parsedOutput.body;
2008
- throwDefaultError({
1863
+ return throwDefaultError({
2009
1864
  output,
2010
1865
  parsedBody,
2011
- exceptionCtor: __BaseException,
2012
1866
  errorCode,
2013
1867
  });
2014
1868
  }
@@ -2021,9 +1875,10 @@ export const de_UpdateAgentStatusCommand = async (output, context) => {
2021
1875
  $metadata: deserializeMetadata(output),
2022
1876
  });
2023
1877
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
2024
- if (data.agentId != null) {
2025
- contents.agentId = __expectString(data.agentId);
2026
- }
1878
+ const doc = take(data, {
1879
+ agentId: __expectString,
1880
+ });
1881
+ Object.assign(contents, doc);
2027
1882
  return contents;
2028
1883
  };
2029
1884
  const de_UpdateAgentStatusCommandError = async (output, context) => {
@@ -2044,10 +1899,9 @@ const de_UpdateAgentStatusCommandError = async (output, context) => {
2044
1899
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2045
1900
  default:
2046
1901
  const parsedBody = parsedOutput.body;
2047
- throwDefaultError({
1902
+ return throwDefaultError({
2048
1903
  output,
2049
1904
  parsedBody,
2050
- exceptionCtor: __BaseException,
2051
1905
  errorCode,
2052
1906
  });
2053
1907
  }
@@ -2060,15 +1914,12 @@ export const de_UpdateConfigCommand = async (output, context) => {
2060
1914
  $metadata: deserializeMetadata(output),
2061
1915
  });
2062
1916
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
2063
- if (data.configArn != null) {
2064
- contents.configArn = __expectString(data.configArn);
2065
- }
2066
- if (data.configId != null) {
2067
- contents.configId = __expectString(data.configId);
2068
- }
2069
- if (data.configType != null) {
2070
- contents.configType = __expectString(data.configType);
2071
- }
1917
+ const doc = take(data, {
1918
+ configArn: __expectString,
1919
+ configId: __expectString,
1920
+ configType: __expectString,
1921
+ });
1922
+ Object.assign(contents, doc);
2072
1923
  return contents;
2073
1924
  };
2074
1925
  const de_UpdateConfigCommandError = async (output, context) => {
@@ -2089,10 +1940,9 @@ const de_UpdateConfigCommandError = async (output, context) => {
2089
1940
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2090
1941
  default:
2091
1942
  const parsedBody = parsedOutput.body;
2092
- throwDefaultError({
1943
+ return throwDefaultError({
2093
1944
  output,
2094
1945
  parsedBody,
2095
- exceptionCtor: __BaseException,
2096
1946
  errorCode,
2097
1947
  });
2098
1948
  }
@@ -2105,9 +1955,10 @@ export const de_UpdateEphemerisCommand = async (output, context) => {
2105
1955
  $metadata: deserializeMetadata(output),
2106
1956
  });
2107
1957
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
2108
- if (data.ephemerisId != null) {
2109
- contents.ephemerisId = __expectString(data.ephemerisId);
2110
- }
1958
+ const doc = take(data, {
1959
+ ephemerisId: __expectString,
1960
+ });
1961
+ Object.assign(contents, doc);
2111
1962
  return contents;
2112
1963
  };
2113
1964
  const de_UpdateEphemerisCommandError = async (output, context) => {
@@ -2128,10 +1979,9 @@ const de_UpdateEphemerisCommandError = async (output, context) => {
2128
1979
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2129
1980
  default:
2130
1981
  const parsedBody = parsedOutput.body;
2131
- throwDefaultError({
1982
+ return throwDefaultError({
2132
1983
  output,
2133
1984
  parsedBody,
2134
- exceptionCtor: __BaseException,
2135
1985
  errorCode,
2136
1986
  });
2137
1987
  }
@@ -2144,9 +1994,10 @@ export const de_UpdateMissionProfileCommand = async (output, context) => {
2144
1994
  $metadata: deserializeMetadata(output),
2145
1995
  });
2146
1996
  const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
2147
- if (data.missionProfileId != null) {
2148
- contents.missionProfileId = __expectString(data.missionProfileId);
2149
- }
1997
+ const doc = take(data, {
1998
+ missionProfileId: __expectString,
1999
+ });
2000
+ Object.assign(contents, doc);
2150
2001
  return contents;
2151
2002
  };
2152
2003
  const de_UpdateMissionProfileCommandError = async (output, context) => {
@@ -2167,24 +2018,22 @@ const de_UpdateMissionProfileCommandError = async (output, context) => {
2167
2018
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2168
2019
  default:
2169
2020
  const parsedBody = parsedOutput.body;
2170
- throwDefaultError({
2021
+ return throwDefaultError({
2171
2022
  output,
2172
2023
  parsedBody,
2173
- exceptionCtor: __BaseException,
2174
2024
  errorCode,
2175
2025
  });
2176
2026
  }
2177
2027
  };
2178
- const map = __map;
2028
+ const throwDefaultError = withBaseException(__BaseException);
2179
2029
  const de_DependencyExceptionRes = async (parsedOutput, context) => {
2180
2030
  const contents = map({});
2181
2031
  const data = parsedOutput.body;
2182
- if (data.message != null) {
2183
- contents.message = __expectString(data.message);
2184
- }
2185
- if (data.parameterName != null) {
2186
- contents.parameterName = __expectString(data.parameterName);
2187
- }
2032
+ const doc = take(data, {
2033
+ message: __expectString,
2034
+ parameterName: __expectString,
2035
+ });
2036
+ Object.assign(contents, doc);
2188
2037
  const exception = new DependencyException({
2189
2038
  $metadata: deserializeMetadata(parsedOutput),
2190
2039
  ...contents,
@@ -2194,12 +2043,11 @@ const de_DependencyExceptionRes = async (parsedOutput, context) => {
2194
2043
  const de_InvalidParameterExceptionRes = async (parsedOutput, context) => {
2195
2044
  const contents = map({});
2196
2045
  const data = parsedOutput.body;
2197
- if (data.message != null) {
2198
- contents.message = __expectString(data.message);
2199
- }
2200
- if (data.parameterName != null) {
2201
- contents.parameterName = __expectString(data.parameterName);
2202
- }
2046
+ const doc = take(data, {
2047
+ message: __expectString,
2048
+ parameterName: __expectString,
2049
+ });
2050
+ Object.assign(contents, doc);
2203
2051
  const exception = new InvalidParameterException({
2204
2052
  $metadata: deserializeMetadata(parsedOutput),
2205
2053
  ...contents,
@@ -2209,12 +2057,11 @@ const de_InvalidParameterExceptionRes = async (parsedOutput, context) => {
2209
2057
  const de_ResourceLimitExceededExceptionRes = async (parsedOutput, context) => {
2210
2058
  const contents = map({});
2211
2059
  const data = parsedOutput.body;
2212
- if (data.message != null) {
2213
- contents.message = __expectString(data.message);
2214
- }
2215
- if (data.parameterName != null) {
2216
- contents.parameterName = __expectString(data.parameterName);
2217
- }
2060
+ const doc = take(data, {
2061
+ message: __expectString,
2062
+ parameterName: __expectString,
2063
+ });
2064
+ Object.assign(contents, doc);
2218
2065
  const exception = new ResourceLimitExceededException({
2219
2066
  $metadata: deserializeMetadata(parsedOutput),
2220
2067
  ...contents,
@@ -2224,100 +2071,33 @@ const de_ResourceLimitExceededExceptionRes = async (parsedOutput, context) => {
2224
2071
  const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
2225
2072
  const contents = map({});
2226
2073
  const data = parsedOutput.body;
2227
- if (data.message != null) {
2228
- contents.message = __expectString(data.message);
2229
- }
2074
+ const doc = take(data, {
2075
+ message: __expectString,
2076
+ });
2077
+ Object.assign(contents, doc);
2230
2078
  const exception = new ResourceNotFoundException({
2231
2079
  $metadata: deserializeMetadata(parsedOutput),
2232
2080
  ...contents,
2233
2081
  });
2234
2082
  return __decorateServiceException(exception, parsedOutput.body);
2235
2083
  };
2236
- const se_AgentDetails = (input, context) => {
2237
- return {
2238
- ...(input.agentVersion != null && { agentVersion: input.agentVersion }),
2239
- ...(input.componentVersions != null && {
2240
- componentVersions: se_ComponentVersionList(input.componentVersions, context),
2241
- }),
2242
- ...(input.instanceId != null && { instanceId: input.instanceId }),
2243
- ...(input.instanceType != null && { instanceType: input.instanceType }),
2244
- ...(input.reservedCpuCores != null && {
2245
- reservedCpuCores: se_ReservedCpuCoresList(input.reservedCpuCores, context),
2246
- }),
2247
- };
2248
- };
2249
- const se_AggregateStatus = (input, context) => {
2250
- return {
2251
- ...(input.signatureMap != null && { signatureMap: se_SignatureMap(input.signatureMap, context) }),
2252
- ...(input.status != null && { status: input.status }),
2253
- };
2254
- };
2255
2084
  const se_AntennaDownlinkConfig = (input, context) => {
2256
- return {
2257
- ...(input.spectrumConfig != null && { spectrumConfig: se_SpectrumConfig(input.spectrumConfig, context) }),
2258
- };
2085
+ return take(input, {
2086
+ spectrumConfig: (_) => se_SpectrumConfig(_, context),
2087
+ });
2259
2088
  };
2260
2089
  const se_AntennaDownlinkDemodDecodeConfig = (input, context) => {
2261
- return {
2262
- ...(input.decodeConfig != null && { decodeConfig: se_DecodeConfig(input.decodeConfig, context) }),
2263
- ...(input.demodulationConfig != null && {
2264
- demodulationConfig: se_DemodulationConfig(input.demodulationConfig, context),
2265
- }),
2266
- ...(input.spectrumConfig != null && { spectrumConfig: se_SpectrumConfig(input.spectrumConfig, context) }),
2267
- };
2268
- };
2269
- const se_AntennaUplinkConfig = (input, context) => {
2270
- return {
2271
- ...(input.spectrumConfig != null && { spectrumConfig: se_UplinkSpectrumConfig(input.spectrumConfig, context) }),
2272
- ...(input.targetEirp != null && { targetEirp: se_Eirp(input.targetEirp, context) }),
2273
- ...(input.transmitDisabled != null && { transmitDisabled: input.transmitDisabled }),
2274
- };
2275
- };
2276
- const se_AwsGroundStationAgentEndpoint = (input, context) => {
2277
- return {
2278
- ...(input.agentStatus != null && { agentStatus: input.agentStatus }),
2279
- ...(input.auditResults != null && { auditResults: input.auditResults }),
2280
- ...(input.egressAddress != null && { egressAddress: se_ConnectionDetails(input.egressAddress, context) }),
2281
- ...(input.ingressAddress != null && { ingressAddress: se_RangedConnectionDetails(input.ingressAddress, context) }),
2282
- ...(input.name != null && { name: input.name }),
2283
- };
2284
- };
2285
- const se_CapabilityArnList = (input, context) => {
2286
- return input
2287
- .filter((e) => e != null)
2288
- .map((entry) => {
2289
- return entry;
2290
- });
2291
- };
2292
- const se_ComponentStatusData = (input, context) => {
2293
- return {
2294
- ...(input.bytesReceived != null && { bytesReceived: input.bytesReceived }),
2295
- ...(input.bytesSent != null && { bytesSent: input.bytesSent }),
2296
- ...(input.capabilityArn != null && { capabilityArn: input.capabilityArn }),
2297
- ...(input.componentType != null && { componentType: input.componentType }),
2298
- ...(input.dataflowId != null && { dataflowId: input.dataflowId }),
2299
- ...(input.packetsDropped != null && { packetsDropped: input.packetsDropped }),
2300
- ...(input.status != null && { status: input.status }),
2301
- };
2302
- };
2303
- const se_ComponentStatusList = (input, context) => {
2304
- return input
2305
- .filter((e) => e != null)
2306
- .map((entry) => {
2307
- return se_ComponentStatusData(entry, context);
2090
+ return take(input, {
2091
+ decodeConfig: _json,
2092
+ demodulationConfig: _json,
2093
+ spectrumConfig: (_) => se_SpectrumConfig(_, context),
2308
2094
  });
2309
2095
  };
2310
- const se_ComponentVersion = (input, context) => {
2311
- return {
2312
- ...(input.componentType != null && { componentType: input.componentType }),
2313
- ...(input.versions != null && { versions: se_VersionStringList(input.versions, context) }),
2314
- };
2315
- };
2316
- const se_ComponentVersionList = (input, context) => {
2317
- return input
2318
- .filter((e) => e != null)
2319
- .map((entry) => {
2320
- return se_ComponentVersion(entry, context);
2096
+ const se_AntennaUplinkConfig = (input, context) => {
2097
+ return take(input, {
2098
+ spectrumConfig: (_) => se_UplinkSpectrumConfig(_, context),
2099
+ targetEirp: (_) => se_Eirp(_, context),
2100
+ transmitDisabled: [],
2321
2101
  });
2322
2102
  };
2323
2103
  const se_ConfigTypeData = (input, context) => {
@@ -2327,246 +2107,57 @@ const se_ConfigTypeData = (input, context) => {
2327
2107
  antennaDownlinkDemodDecodeConfig: se_AntennaDownlinkDemodDecodeConfig(value, context),
2328
2108
  }),
2329
2109
  antennaUplinkConfig: (value) => ({ antennaUplinkConfig: se_AntennaUplinkConfig(value, context) }),
2330
- dataflowEndpointConfig: (value) => ({ dataflowEndpointConfig: se_DataflowEndpointConfig(value, context) }),
2331
- s3RecordingConfig: (value) => ({ s3RecordingConfig: se_S3RecordingConfig(value, context) }),
2332
- trackingConfig: (value) => ({ trackingConfig: se_TrackingConfig(value, context) }),
2333
- uplinkEchoConfig: (value) => ({ uplinkEchoConfig: se_UplinkEchoConfig(value, context) }),
2110
+ dataflowEndpointConfig: (value) => ({ dataflowEndpointConfig: _json(value) }),
2111
+ s3RecordingConfig: (value) => ({ s3RecordingConfig: _json(value) }),
2112
+ trackingConfig: (value) => ({ trackingConfig: _json(value) }),
2113
+ uplinkEchoConfig: (value) => ({ uplinkEchoConfig: _json(value) }),
2334
2114
  _: (name, value) => ({ name: value }),
2335
2115
  });
2336
2116
  };
2337
- const se_ConnectionDetails = (input, context) => {
2338
- return {
2339
- ...(input.mtu != null && { mtu: input.mtu }),
2340
- ...(input.socketAddress != null && { socketAddress: se_SocketAddress(input.socketAddress, context) }),
2341
- };
2342
- };
2343
- const se_DataflowEdge = (input, context) => {
2344
- return input
2345
- .filter((e) => e != null)
2346
- .map((entry) => {
2347
- return entry;
2348
- });
2349
- };
2350
- const se_DataflowEdgeList = (input, context) => {
2351
- return input
2352
- .filter((e) => e != null)
2353
- .map((entry) => {
2354
- return se_DataflowEdge(entry, context);
2355
- });
2356
- };
2357
- const se_DataflowEndpoint = (input, context) => {
2358
- return {
2359
- ...(input.address != null && { address: se_SocketAddress(input.address, context) }),
2360
- ...(input.mtu != null && { mtu: input.mtu }),
2361
- ...(input.name != null && { name: input.name }),
2362
- ...(input.status != null && { status: input.status }),
2363
- };
2364
- };
2365
- const se_DataflowEndpointConfig = (input, context) => {
2366
- return {
2367
- ...(input.dataflowEndpointName != null && { dataflowEndpointName: input.dataflowEndpointName }),
2368
- ...(input.dataflowEndpointRegion != null && { dataflowEndpointRegion: input.dataflowEndpointRegion }),
2369
- };
2370
- };
2371
- const se_DecodeConfig = (input, context) => {
2372
- return {
2373
- ...(input.unvalidatedJSON != null && { unvalidatedJSON: input.unvalidatedJSON }),
2374
- };
2375
- };
2376
- const se_DemodulationConfig = (input, context) => {
2377
- return {
2378
- ...(input.unvalidatedJSON != null && { unvalidatedJSON: input.unvalidatedJSON }),
2379
- };
2380
- };
2381
- const se_DiscoveryData = (input, context) => {
2382
- return {
2383
- ...(input.capabilityArns != null && { capabilityArns: se_CapabilityArnList(input.capabilityArns, context) }),
2384
- ...(input.privateIpAddresses != null && {
2385
- privateIpAddresses: se_IpAddressList(input.privateIpAddresses, context),
2386
- }),
2387
- ...(input.publicIpAddresses != null && { publicIpAddresses: se_IpAddressList(input.publicIpAddresses, context) }),
2388
- };
2389
- };
2390
2117
  const se_Eirp = (input, context) => {
2391
- return {
2392
- ...(input.units != null && { units: input.units }),
2393
- ...(input.value != null && { value: __serializeFloat(input.value) }),
2394
- };
2395
- };
2396
- const se_EndpointDetails = (input, context) => {
2397
- return {
2398
- ...(input.awsGroundStationAgentEndpoint != null && {
2399
- awsGroundStationAgentEndpoint: se_AwsGroundStationAgentEndpoint(input.awsGroundStationAgentEndpoint, context),
2400
- }),
2401
- ...(input.endpoint != null && { endpoint: se_DataflowEndpoint(input.endpoint, context) }),
2402
- ...(input.securityDetails != null && { securityDetails: se_SecurityDetails(input.securityDetails, context) }),
2403
- };
2404
- };
2405
- const se_EndpointDetailsList = (input, context) => {
2406
- return input
2407
- .filter((e) => e != null)
2408
- .map((entry) => {
2409
- return se_EndpointDetails(entry, context);
2118
+ return take(input, {
2119
+ units: [],
2120
+ value: __serializeFloat,
2410
2121
  });
2411
2122
  };
2412
2123
  const se_EphemerisData = (input, context) => {
2413
2124
  return EphemerisData.visit(input, {
2414
- oem: (value) => ({ oem: se_OEMEphemeris(value, context) }),
2125
+ oem: (value) => ({ oem: _json(value) }),
2415
2126
  tle: (value) => ({ tle: se_TLEEphemeris(value, context) }),
2416
2127
  _: (name, value) => ({ name: value }),
2417
2128
  });
2418
2129
  };
2419
- const se_EphemerisStatusList = (input, context) => {
2420
- return input
2421
- .filter((e) => e != null)
2422
- .map((entry) => {
2423
- return entry;
2424
- });
2425
- };
2426
2130
  const se_Frequency = (input, context) => {
2427
- return {
2428
- ...(input.units != null && { units: input.units }),
2429
- ...(input.value != null && { value: __serializeFloat(input.value) }),
2430
- };
2431
- };
2432
- const se_FrequencyBandwidth = (input, context) => {
2433
- return {
2434
- ...(input.units != null && { units: input.units }),
2435
- ...(input.value != null && { value: __serializeFloat(input.value) }),
2436
- };
2437
- };
2438
- const se_IntegerRange = (input, context) => {
2439
- return {
2440
- ...(input.maximum != null && { maximum: input.maximum }),
2441
- ...(input.minimum != null && { minimum: input.minimum }),
2442
- };
2443
- };
2444
- const se_IpAddressList = (input, context) => {
2445
- return input
2446
- .filter((e) => e != null)
2447
- .map((entry) => {
2448
- return entry;
2449
- });
2450
- };
2451
- const se_KmsKey = (input, context) => {
2452
- return KmsKey.visit(input, {
2453
- kmsAliasArn: (value) => ({ kmsAliasArn: value }),
2454
- kmsKeyArn: (value) => ({ kmsKeyArn: value }),
2455
- _: (name, value) => ({ name: value }),
2456
- });
2457
- };
2458
- const se_OEMEphemeris = (input, context) => {
2459
- return {
2460
- ...(input.oemData != null && { oemData: input.oemData }),
2461
- ...(input.s3Object != null && { s3Object: se_S3Object(input.s3Object, context) }),
2462
- };
2463
- };
2464
- const se_RangedConnectionDetails = (input, context) => {
2465
- return {
2466
- ...(input.mtu != null && { mtu: input.mtu }),
2467
- ...(input.socketAddress != null && { socketAddress: se_RangedSocketAddress(input.socketAddress, context) }),
2468
- };
2469
- };
2470
- const se_RangedSocketAddress = (input, context) => {
2471
- return {
2472
- ...(input.name != null && { name: input.name }),
2473
- ...(input.portRange != null && { portRange: se_IntegerRange(input.portRange, context) }),
2474
- };
2475
- };
2476
- const se_ReservedCpuCoresList = (input, context) => {
2477
- return input
2478
- .filter((e) => e != null)
2479
- .map((entry) => {
2480
- return entry;
2131
+ return take(input, {
2132
+ units: [],
2133
+ value: __serializeFloat,
2481
2134
  });
2482
2135
  };
2483
- const se_S3Object = (input, context) => {
2484
- return {
2485
- ...(input.bucket != null && { bucket: input.bucket }),
2486
- ...(input.key != null && { key: input.key }),
2487
- ...(input.version != null && { version: input.version }),
2488
- };
2489
- };
2490
- const se_S3RecordingConfig = (input, context) => {
2491
- return {
2492
- ...(input.bucketArn != null && { bucketArn: input.bucketArn }),
2493
- ...(input.prefix != null && { prefix: input.prefix }),
2494
- ...(input.roleArn != null && { roleArn: input.roleArn }),
2495
- };
2496
- };
2497
- const se_SecurityDetails = (input, context) => {
2498
- return {
2499
- ...(input.roleArn != null && { roleArn: input.roleArn }),
2500
- ...(input.securityGroupIds != null && {
2501
- securityGroupIds: se_SecurityGroupIdList(input.securityGroupIds, context),
2502
- }),
2503
- ...(input.subnetIds != null && { subnetIds: se_SubnetList(input.subnetIds, context) }),
2504
- };
2505
- };
2506
- const se_SecurityGroupIdList = (input, context) => {
2507
- return input
2508
- .filter((e) => e != null)
2509
- .map((entry) => {
2510
- return entry;
2136
+ const se_FrequencyBandwidth = (input, context) => {
2137
+ return take(input, {
2138
+ units: [],
2139
+ value: __serializeFloat,
2511
2140
  });
2512
2141
  };
2513
- const se_SignatureMap = (input, context) => {
2514
- return Object.entries(input).reduce((acc, [key, value]) => {
2515
- if (value === null) {
2516
- return acc;
2517
- }
2518
- acc[key] = value;
2519
- return acc;
2520
- }, {});
2521
- };
2522
- const se_SocketAddress = (input, context) => {
2523
- return {
2524
- ...(input.name != null && { name: input.name }),
2525
- ...(input.port != null && { port: input.port }),
2526
- };
2527
- };
2528
2142
  const se_SpectrumConfig = (input, context) => {
2529
- return {
2530
- ...(input.bandwidth != null && { bandwidth: se_FrequencyBandwidth(input.bandwidth, context) }),
2531
- ...(input.centerFrequency != null && { centerFrequency: se_Frequency(input.centerFrequency, context) }),
2532
- ...(input.polarization != null && { polarization: input.polarization }),
2533
- };
2534
- };
2535
- const se_StatusList = (input, context) => {
2536
- return input
2537
- .filter((e) => e != null)
2538
- .map((entry) => {
2539
- return entry;
2143
+ return take(input, {
2144
+ bandwidth: (_) => se_FrequencyBandwidth(_, context),
2145
+ centerFrequency: (_) => se_Frequency(_, context),
2146
+ polarization: [],
2540
2147
  });
2541
2148
  };
2542
- const se_SubnetList = (input, context) => {
2543
- return input
2544
- .filter((e) => e != null)
2545
- .map((entry) => {
2546
- return entry;
2547
- });
2548
- };
2549
- const se_TagsMap = (input, context) => {
2550
- return Object.entries(input).reduce((acc, [key, value]) => {
2551
- if (value === null) {
2552
- return acc;
2553
- }
2554
- acc[key] = value;
2555
- return acc;
2556
- }, {});
2557
- };
2558
2149
  const se_TimeRange = (input, context) => {
2559
- return {
2560
- ...(input.endTime != null && { endTime: Math.round(input.endTime.getTime() / 1000) }),
2561
- ...(input.startTime != null && { startTime: Math.round(input.startTime.getTime() / 1000) }),
2562
- };
2150
+ return take(input, {
2151
+ endTime: (_) => Math.round(_.getTime() / 1000),
2152
+ startTime: (_) => Math.round(_.getTime() / 1000),
2153
+ });
2563
2154
  };
2564
2155
  const se_TLEData = (input, context) => {
2565
- return {
2566
- ...(input.tleLine1 != null && { tleLine1: input.tleLine1 }),
2567
- ...(input.tleLine2 != null && { tleLine2: input.tleLine2 }),
2568
- ...(input.validTimeRange != null && { validTimeRange: se_TimeRange(input.validTimeRange, context) }),
2569
- };
2156
+ return take(input, {
2157
+ tleLine1: [],
2158
+ tleLine2: [],
2159
+ validTimeRange: (_) => se_TimeRange(_, context),
2160
+ });
2570
2161
  };
2571
2162
  const se_TLEDataList = (input, context) => {
2572
2163
  return input
@@ -2576,104 +2167,35 @@ const se_TLEDataList = (input, context) => {
2576
2167
  });
2577
2168
  };
2578
2169
  const se_TLEEphemeris = (input, context) => {
2579
- return {
2580
- ...(input.s3Object != null && { s3Object: se_S3Object(input.s3Object, context) }),
2581
- ...(input.tleData != null && { tleData: se_TLEDataList(input.tleData, context) }),
2582
- };
2583
- };
2584
- const se_TrackingConfig = (input, context) => {
2585
- return {
2586
- ...(input.autotrack != null && { autotrack: input.autotrack }),
2587
- };
2588
- };
2589
- const se_UplinkEchoConfig = (input, context) => {
2590
- return {
2591
- ...(input.antennaUplinkConfigArn != null && { antennaUplinkConfigArn: input.antennaUplinkConfigArn }),
2592
- ...(input.enabled != null && { enabled: input.enabled }),
2593
- };
2170
+ return take(input, {
2171
+ s3Object: _json,
2172
+ tleData: (_) => se_TLEDataList(_, context),
2173
+ });
2594
2174
  };
2595
2175
  const se_UplinkSpectrumConfig = (input, context) => {
2596
- return {
2597
- ...(input.centerFrequency != null && { centerFrequency: se_Frequency(input.centerFrequency, context) }),
2598
- ...(input.polarization != null && { polarization: input.polarization }),
2599
- };
2600
- };
2601
- const se_VersionStringList = (input, context) => {
2602
- return input
2603
- .filter((e) => e != null)
2604
- .map((entry) => {
2605
- return entry;
2176
+ return take(input, {
2177
+ centerFrequency: (_) => se_Frequency(_, context),
2178
+ polarization: [],
2606
2179
  });
2607
2180
  };
2608
- const de_AntennaDemodDecodeDetails = (output, context) => {
2609
- return {
2610
- outputNode: __expectString(output.outputNode),
2611
- };
2612
- };
2613
2181
  const de_AntennaDownlinkConfig = (output, context) => {
2614
- return {
2615
- spectrumConfig: output.spectrumConfig != null ? de_SpectrumConfig(output.spectrumConfig, context) : undefined,
2616
- };
2182
+ return take(output, {
2183
+ spectrumConfig: (_) => de_SpectrumConfig(_, context),
2184
+ });
2617
2185
  };
2618
2186
  const de_AntennaDownlinkDemodDecodeConfig = (output, context) => {
2619
- return {
2620
- decodeConfig: output.decodeConfig != null ? de_DecodeConfig(output.decodeConfig, context) : undefined,
2621
- demodulationConfig: output.demodulationConfig != null ? de_DemodulationConfig(output.demodulationConfig, context) : undefined,
2622
- spectrumConfig: output.spectrumConfig != null ? de_SpectrumConfig(output.spectrumConfig, context) : undefined,
2623
- };
2187
+ return take(output, {
2188
+ decodeConfig: _json,
2189
+ demodulationConfig: _json,
2190
+ spectrumConfig: (_) => de_SpectrumConfig(_, context),
2191
+ });
2624
2192
  };
2625
2193
  const de_AntennaUplinkConfig = (output, context) => {
2626
- return {
2627
- spectrumConfig: output.spectrumConfig != null ? de_UplinkSpectrumConfig(output.spectrumConfig, context) : undefined,
2628
- targetEirp: output.targetEirp != null ? de_Eirp(output.targetEirp, context) : undefined,
2629
- transmitDisabled: __expectBoolean(output.transmitDisabled),
2630
- };
2631
- };
2632
- const de_AwsGroundStationAgentEndpoint = (output, context) => {
2633
- return {
2634
- agentStatus: __expectString(output.agentStatus),
2635
- auditResults: __expectString(output.auditResults),
2636
- egressAddress: output.egressAddress != null ? de_ConnectionDetails(output.egressAddress, context) : undefined,
2637
- ingressAddress: output.ingressAddress != null ? de_RangedConnectionDetails(output.ingressAddress, context) : undefined,
2638
- name: __expectString(output.name),
2639
- };
2640
- };
2641
- const de_ConfigDetails = (output, context) => {
2642
- if (output.antennaDemodDecodeDetails != null) {
2643
- return {
2644
- antennaDemodDecodeDetails: de_AntennaDemodDecodeDetails(output.antennaDemodDecodeDetails, context),
2645
- };
2646
- }
2647
- if (output.endpointDetails != null) {
2648
- return {
2649
- endpointDetails: de_EndpointDetails(output.endpointDetails, context),
2650
- };
2651
- }
2652
- if (output.s3RecordingDetails != null) {
2653
- return {
2654
- s3RecordingDetails: de_S3RecordingDetails(output.s3RecordingDetails, context),
2655
- };
2656
- }
2657
- return { $unknown: Object.entries(output)[0] };
2658
- };
2659
- const de_ConfigList = (output, context) => {
2660
- const retVal = (output || [])
2661
- .filter((e) => e != null)
2662
- .map((entry) => {
2663
- if (entry === null) {
2664
- return null;
2665
- }
2666
- return de_ConfigListItem(entry, context);
2194
+ return take(output, {
2195
+ spectrumConfig: (_) => de_UplinkSpectrumConfig(_, context),
2196
+ targetEirp: (_) => de_Eirp(_, context),
2197
+ transmitDisabled: __expectBoolean,
2667
2198
  });
2668
- return retVal;
2669
- };
2670
- const de_ConfigListItem = (output, context) => {
2671
- return {
2672
- configArn: __expectString(output.configArn),
2673
- configId: __expectString(output.configId),
2674
- configType: __expectString(output.configType),
2675
- name: __expectString(output.name),
2676
- };
2677
2199
  };
2678
2200
  const de_ConfigTypeData = (output, context) => {
2679
2201
  if (output.antennaDownlinkConfig != null) {
@@ -2693,438 +2215,131 @@ const de_ConfigTypeData = (output, context) => {
2693
2215
  }
2694
2216
  if (output.dataflowEndpointConfig != null) {
2695
2217
  return {
2696
- dataflowEndpointConfig: de_DataflowEndpointConfig(output.dataflowEndpointConfig, context),
2218
+ dataflowEndpointConfig: _json(output.dataflowEndpointConfig),
2697
2219
  };
2698
2220
  }
2699
2221
  if (output.s3RecordingConfig != null) {
2700
2222
  return {
2701
- s3RecordingConfig: de_S3RecordingConfig(output.s3RecordingConfig, context),
2223
+ s3RecordingConfig: _json(output.s3RecordingConfig),
2702
2224
  };
2703
2225
  }
2704
2226
  if (output.trackingConfig != null) {
2705
2227
  return {
2706
- trackingConfig: de_TrackingConfig(output.trackingConfig, context),
2228
+ trackingConfig: _json(output.trackingConfig),
2707
2229
  };
2708
2230
  }
2709
2231
  if (output.uplinkEchoConfig != null) {
2710
2232
  return {
2711
- uplinkEchoConfig: de_UplinkEchoConfig(output.uplinkEchoConfig, context),
2233
+ uplinkEchoConfig: _json(output.uplinkEchoConfig),
2712
2234
  };
2713
2235
  }
2714
2236
  return { $unknown: Object.entries(output)[0] };
2715
2237
  };
2716
- const de_ConnectionDetails = (output, context) => {
2717
- return {
2718
- mtu: __expectInt32(output.mtu),
2719
- socketAddress: output.socketAddress != null ? de_SocketAddress(output.socketAddress, context) : undefined,
2720
- };
2721
- };
2722
2238
  const de_ContactData = (output, context) => {
2723
- return {
2724
- contactId: __expectString(output.contactId),
2725
- contactStatus: __expectString(output.contactStatus),
2726
- endTime: output.endTime != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.endTime))) : undefined,
2727
- errorMessage: __expectString(output.errorMessage),
2728
- groundStation: __expectString(output.groundStation),
2729
- maximumElevation: output.maximumElevation != null ? de_Elevation(output.maximumElevation, context) : undefined,
2730
- missionProfileArn: __expectString(output.missionProfileArn),
2731
- postPassEndTime: output.postPassEndTime != null
2732
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.postPassEndTime)))
2733
- : undefined,
2734
- prePassStartTime: output.prePassStartTime != null
2735
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.prePassStartTime)))
2736
- : undefined,
2737
- region: __expectString(output.region),
2738
- satelliteArn: __expectString(output.satelliteArn),
2739
- startTime: output.startTime != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.startTime))) : undefined,
2740
- tags: output.tags != null ? de_TagsMap(output.tags, context) : undefined,
2741
- };
2239
+ return take(output, {
2240
+ contactId: __expectString,
2241
+ contactStatus: __expectString,
2242
+ endTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
2243
+ errorMessage: __expectString,
2244
+ groundStation: __expectString,
2245
+ maximumElevation: (_) => de_Elevation(_, context),
2246
+ missionProfileArn: __expectString,
2247
+ postPassEndTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
2248
+ prePassStartTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
2249
+ region: __expectString,
2250
+ satelliteArn: __expectString,
2251
+ startTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
2252
+ tags: _json,
2253
+ });
2742
2254
  };
2743
2255
  const de_ContactList = (output, context) => {
2744
2256
  const retVal = (output || [])
2745
2257
  .filter((e) => e != null)
2746
2258
  .map((entry) => {
2747
- if (entry === null) {
2748
- return null;
2749
- }
2750
2259
  return de_ContactData(entry, context);
2751
2260
  });
2752
2261
  return retVal;
2753
2262
  };
2754
- const de_DataflowDetail = (output, context) => {
2755
- return {
2756
- destination: output.destination != null ? de_Destination(output.destination, context) : undefined,
2757
- errorMessage: __expectString(output.errorMessage),
2758
- source: output.source != null ? de_Source(output.source, context) : undefined,
2759
- };
2760
- };
2761
- const de_DataflowEdge = (output, context) => {
2762
- const retVal = (output || [])
2763
- .filter((e) => e != null)
2764
- .map((entry) => {
2765
- if (entry === null) {
2766
- return null;
2767
- }
2768
- return __expectString(entry);
2769
- });
2770
- return retVal;
2771
- };
2772
- const de_DataflowEdgeList = (output, context) => {
2773
- const retVal = (output || [])
2774
- .filter((e) => e != null)
2775
- .map((entry) => {
2776
- if (entry === null) {
2777
- return null;
2778
- }
2779
- return de_DataflowEdge(entry, context);
2780
- });
2781
- return retVal;
2782
- };
2783
- const de_DataflowEndpoint = (output, context) => {
2784
- return {
2785
- address: output.address != null ? de_SocketAddress(output.address, context) : undefined,
2786
- mtu: __expectInt32(output.mtu),
2787
- name: __expectString(output.name),
2788
- status: __expectString(output.status),
2789
- };
2790
- };
2791
- const de_DataflowEndpointConfig = (output, context) => {
2792
- return {
2793
- dataflowEndpointName: __expectString(output.dataflowEndpointName),
2794
- dataflowEndpointRegion: __expectString(output.dataflowEndpointRegion),
2795
- };
2796
- };
2797
- const de_DataflowEndpointGroupList = (output, context) => {
2798
- const retVal = (output || [])
2799
- .filter((e) => e != null)
2800
- .map((entry) => {
2801
- if (entry === null) {
2802
- return null;
2803
- }
2804
- return de_DataflowEndpointListItem(entry, context);
2805
- });
2806
- return retVal;
2807
- };
2808
- const de_DataflowEndpointListItem = (output, context) => {
2809
- return {
2810
- dataflowEndpointGroupArn: __expectString(output.dataflowEndpointGroupArn),
2811
- dataflowEndpointGroupId: __expectString(output.dataflowEndpointGroupId),
2812
- };
2813
- };
2814
- const de_DataflowList = (output, context) => {
2815
- const retVal = (output || [])
2816
- .filter((e) => e != null)
2817
- .map((entry) => {
2818
- if (entry === null) {
2819
- return null;
2820
- }
2821
- return de_DataflowDetail(entry, context);
2822
- });
2823
- return retVal;
2824
- };
2825
- const de_DecodeConfig = (output, context) => {
2826
- return {
2827
- unvalidatedJSON: __expectString(output.unvalidatedJSON),
2828
- };
2829
- };
2830
- const de_DemodulationConfig = (output, context) => {
2831
- return {
2832
- unvalidatedJSON: __expectString(output.unvalidatedJSON),
2833
- };
2834
- };
2835
- const de_Destination = (output, context) => {
2836
- return {
2837
- configDetails: output.configDetails != null ? de_ConfigDetails(__expectUnion(output.configDetails), context) : undefined,
2838
- configId: __expectString(output.configId),
2839
- configType: __expectString(output.configType),
2840
- dataflowDestinationRegion: __expectString(output.dataflowDestinationRegion),
2841
- };
2842
- };
2843
2263
  const de_Eirp = (output, context) => {
2844
- return {
2845
- units: __expectString(output.units),
2846
- value: __limitedParseDouble(output.value),
2847
- };
2264
+ return take(output, {
2265
+ units: __expectString,
2266
+ value: __limitedParseDouble,
2267
+ });
2848
2268
  };
2849
2269
  const de_Elevation = (output, context) => {
2850
- return {
2851
- unit: __expectString(output.unit),
2852
- value: __limitedParseDouble(output.value),
2853
- };
2854
- };
2855
- const de_EndpointDetails = (output, context) => {
2856
- return {
2857
- awsGroundStationAgentEndpoint: output.awsGroundStationAgentEndpoint != null
2858
- ? de_AwsGroundStationAgentEndpoint(output.awsGroundStationAgentEndpoint, context)
2859
- : undefined,
2860
- endpoint: output.endpoint != null ? de_DataflowEndpoint(output.endpoint, context) : undefined,
2861
- securityDetails: output.securityDetails != null ? de_SecurityDetails(output.securityDetails, context) : undefined,
2862
- };
2863
- };
2864
- const de_EndpointDetailsList = (output, context) => {
2865
- const retVal = (output || [])
2866
- .filter((e) => e != null)
2867
- .map((entry) => {
2868
- if (entry === null) {
2869
- return null;
2870
- }
2871
- return de_EndpointDetails(entry, context);
2270
+ return take(output, {
2271
+ unit: __expectString,
2272
+ value: __limitedParseDouble,
2872
2273
  });
2873
- return retVal;
2874
2274
  };
2875
2275
  const de_EphemeridesList = (output, context) => {
2876
2276
  const retVal = (output || [])
2877
2277
  .filter((e) => e != null)
2878
2278
  .map((entry) => {
2879
- if (entry === null) {
2880
- return null;
2881
- }
2882
2279
  return de_EphemerisItem(entry, context);
2883
2280
  });
2884
2281
  return retVal;
2885
2282
  };
2886
- const de_EphemerisDescription = (output, context) => {
2887
- return {
2888
- ephemerisData: __expectString(output.ephemerisData),
2889
- sourceS3Object: output.sourceS3Object != null ? de_S3Object(output.sourceS3Object, context) : undefined,
2890
- };
2891
- };
2892
2283
  const de_EphemerisItem = (output, context) => {
2893
- return {
2894
- creationTime: output.creationTime != null
2895
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.creationTime)))
2896
- : undefined,
2897
- enabled: __expectBoolean(output.enabled),
2898
- ephemerisId: __expectString(output.ephemerisId),
2899
- name: __expectString(output.name),
2900
- priority: __expectInt32(output.priority),
2901
- sourceS3Object: output.sourceS3Object != null ? de_S3Object(output.sourceS3Object, context) : undefined,
2902
- status: __expectString(output.status),
2903
- };
2284
+ return take(output, {
2285
+ creationTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
2286
+ enabled: __expectBoolean,
2287
+ ephemerisId: __expectString,
2288
+ name: __expectString,
2289
+ priority: __expectInt32,
2290
+ sourceS3Object: _json,
2291
+ status: __expectString,
2292
+ });
2904
2293
  };
2905
2294
  const de_EphemerisMetaData = (output, context) => {
2906
- return {
2907
- ephemerisId: __expectString(output.ephemerisId),
2908
- epoch: output.epoch != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.epoch))) : undefined,
2909
- name: __expectString(output.name),
2910
- source: __expectString(output.source),
2911
- };
2912
- };
2913
- const de_EphemerisTypeDescription = (output, context) => {
2914
- if (output.oem != null) {
2915
- return {
2916
- oem: de_EphemerisDescription(output.oem, context),
2917
- };
2918
- }
2919
- if (output.tle != null) {
2920
- return {
2921
- tle: de_EphemerisDescription(output.tle, context),
2922
- };
2923
- }
2924
- return { $unknown: Object.entries(output)[0] };
2925
- };
2926
- const de_Frequency = (output, context) => {
2927
- return {
2928
- units: __expectString(output.units),
2929
- value: __limitedParseDouble(output.value),
2930
- };
2931
- };
2932
- const de_FrequencyBandwidth = (output, context) => {
2933
- return {
2934
- units: __expectString(output.units),
2935
- value: __limitedParseDouble(output.value),
2936
- };
2937
- };
2938
- const de_GroundStationData = (output, context) => {
2939
- return {
2940
- groundStationId: __expectString(output.groundStationId),
2941
- groundStationName: __expectString(output.groundStationName),
2942
- region: __expectString(output.region),
2943
- };
2944
- };
2945
- const de_GroundStationIdList = (output, context) => {
2946
- const retVal = (output || [])
2947
- .filter((e) => e != null)
2948
- .map((entry) => {
2949
- if (entry === null) {
2950
- return null;
2951
- }
2952
- return __expectString(entry);
2295
+ return take(output, {
2296
+ ephemerisId: __expectString,
2297
+ epoch: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
2298
+ name: __expectString,
2299
+ source: __expectString,
2953
2300
  });
2954
- return retVal;
2955
2301
  };
2956
- const de_GroundStationList = (output, context) => {
2957
- const retVal = (output || [])
2958
- .filter((e) => e != null)
2959
- .map((entry) => {
2960
- if (entry === null) {
2961
- return null;
2962
- }
2963
- return de_GroundStationData(entry, context);
2302
+ const de_Frequency = (output, context) => {
2303
+ return take(output, {
2304
+ units: __expectString,
2305
+ value: __limitedParseDouble,
2964
2306
  });
2965
- return retVal;
2966
2307
  };
2967
- const de_IntegerRange = (output, context) => {
2968
- return {
2969
- maximum: __expectInt32(output.maximum),
2970
- minimum: __expectInt32(output.minimum),
2971
- };
2972
- };
2973
- const de_KmsKey = (output, context) => {
2974
- if (__expectString(output.kmsAliasArn) !== undefined) {
2975
- return { kmsAliasArn: __expectString(output.kmsAliasArn) };
2976
- }
2977
- if (__expectString(output.kmsKeyArn) !== undefined) {
2978
- return { kmsKeyArn: __expectString(output.kmsKeyArn) };
2979
- }
2980
- return { $unknown: Object.entries(output)[0] };
2981
- };
2982
- const de_MissionProfileList = (output, context) => {
2983
- const retVal = (output || [])
2984
- .filter((e) => e != null)
2985
- .map((entry) => {
2986
- if (entry === null) {
2987
- return null;
2988
- }
2989
- return de_MissionProfileListItem(entry, context);
2308
+ const de_FrequencyBandwidth = (output, context) => {
2309
+ return take(output, {
2310
+ units: __expectString,
2311
+ value: __limitedParseDouble,
2990
2312
  });
2991
- return retVal;
2992
- };
2993
- const de_MissionProfileListItem = (output, context) => {
2994
- return {
2995
- missionProfileArn: __expectString(output.missionProfileArn),
2996
- missionProfileId: __expectString(output.missionProfileId),
2997
- name: __expectString(output.name),
2998
- region: __expectString(output.region),
2999
- };
3000
- };
3001
- const de_RangedConnectionDetails = (output, context) => {
3002
- return {
3003
- mtu: __expectInt32(output.mtu),
3004
- socketAddress: output.socketAddress != null ? de_RangedSocketAddress(output.socketAddress, context) : undefined,
3005
- };
3006
- };
3007
- const de_RangedSocketAddress = (output, context) => {
3008
- return {
3009
- name: __expectString(output.name),
3010
- portRange: output.portRange != null ? de_IntegerRange(output.portRange, context) : undefined,
3011
- };
3012
- };
3013
- const de_S3Object = (output, context) => {
3014
- return {
3015
- bucket: __expectString(output.bucket),
3016
- key: __expectString(output.key),
3017
- version: __expectString(output.version),
3018
- };
3019
- };
3020
- const de_S3RecordingConfig = (output, context) => {
3021
- return {
3022
- bucketArn: __expectString(output.bucketArn),
3023
- prefix: __expectString(output.prefix),
3024
- roleArn: __expectString(output.roleArn),
3025
- };
3026
- };
3027
- const de_S3RecordingDetails = (output, context) => {
3028
- return {
3029
- bucketArn: __expectString(output.bucketArn),
3030
- keyTemplate: __expectString(output.keyTemplate),
3031
- };
3032
2313
  };
3033
2314
  const de_SatelliteList = (output, context) => {
3034
2315
  const retVal = (output || [])
3035
2316
  .filter((e) => e != null)
3036
2317
  .map((entry) => {
3037
- if (entry === null) {
3038
- return null;
3039
- }
3040
2318
  return de_SatelliteListItem(entry, context);
3041
2319
  });
3042
2320
  return retVal;
3043
2321
  };
3044
2322
  const de_SatelliteListItem = (output, context) => {
3045
- return {
3046
- currentEphemeris: output.currentEphemeris != null ? de_EphemerisMetaData(output.currentEphemeris, context) : undefined,
3047
- groundStations: output.groundStations != null ? de_GroundStationIdList(output.groundStations, context) : undefined,
3048
- noradSatelliteID: __expectInt32(output.noradSatelliteID),
3049
- satelliteArn: __expectString(output.satelliteArn),
3050
- satelliteId: __expectString(output.satelliteId),
3051
- };
3052
- };
3053
- const de_SecurityDetails = (output, context) => {
3054
- return {
3055
- roleArn: __expectString(output.roleArn),
3056
- securityGroupIds: output.securityGroupIds != null ? de_SecurityGroupIdList(output.securityGroupIds, context) : undefined,
3057
- subnetIds: output.subnetIds != null ? de_SubnetList(output.subnetIds, context) : undefined,
3058
- };
3059
- };
3060
- const de_SecurityGroupIdList = (output, context) => {
3061
- const retVal = (output || [])
3062
- .filter((e) => e != null)
3063
- .map((entry) => {
3064
- if (entry === null) {
3065
- return null;
3066
- }
3067
- return __expectString(entry);
2323
+ return take(output, {
2324
+ currentEphemeris: (_) => de_EphemerisMetaData(_, context),
2325
+ groundStations: _json,
2326
+ noradSatelliteID: __expectInt32,
2327
+ satelliteArn: __expectString,
2328
+ satelliteId: __expectString,
3068
2329
  });
3069
- return retVal;
3070
- };
3071
- const de_SocketAddress = (output, context) => {
3072
- return {
3073
- name: __expectString(output.name),
3074
- port: __expectInt32(output.port),
3075
- };
3076
- };
3077
- const de_Source = (output, context) => {
3078
- return {
3079
- configDetails: output.configDetails != null ? de_ConfigDetails(__expectUnion(output.configDetails), context) : undefined,
3080
- configId: __expectString(output.configId),
3081
- configType: __expectString(output.configType),
3082
- dataflowSourceRegion: __expectString(output.dataflowSourceRegion),
3083
- };
3084
2330
  };
3085
2331
  const de_SpectrumConfig = (output, context) => {
3086
- return {
3087
- bandwidth: output.bandwidth != null ? de_FrequencyBandwidth(output.bandwidth, context) : undefined,
3088
- centerFrequency: output.centerFrequency != null ? de_Frequency(output.centerFrequency, context) : undefined,
3089
- polarization: __expectString(output.polarization),
3090
- };
3091
- };
3092
- const de_SubnetList = (output, context) => {
3093
- const retVal = (output || [])
3094
- .filter((e) => e != null)
3095
- .map((entry) => {
3096
- if (entry === null) {
3097
- return null;
3098
- }
3099
- return __expectString(entry);
2332
+ return take(output, {
2333
+ bandwidth: (_) => de_FrequencyBandwidth(_, context),
2334
+ centerFrequency: (_) => de_Frequency(_, context),
2335
+ polarization: __expectString,
3100
2336
  });
3101
- return retVal;
3102
- };
3103
- const de_TagsMap = (output, context) => {
3104
- return Object.entries(output).reduce((acc, [key, value]) => {
3105
- if (value === null) {
3106
- return acc;
3107
- }
3108
- acc[key] = __expectString(value);
3109
- return acc;
3110
- }, {});
3111
- };
3112
- const de_TrackingConfig = (output, context) => {
3113
- return {
3114
- autotrack: __expectString(output.autotrack),
3115
- };
3116
- };
3117
- const de_UplinkEchoConfig = (output, context) => {
3118
- return {
3119
- antennaUplinkConfigArn: __expectString(output.antennaUplinkConfigArn),
3120
- enabled: __expectBoolean(output.enabled),
3121
- };
3122
2337
  };
3123
2338
  const de_UplinkSpectrumConfig = (output, context) => {
3124
- return {
3125
- centerFrequency: output.centerFrequency != null ? de_Frequency(output.centerFrequency, context) : undefined,
3126
- polarization: __expectString(output.polarization),
3127
- };
2339
+ return take(output, {
2340
+ centerFrequency: (_) => de_Frequency(_, context),
2341
+ polarization: __expectString,
2342
+ });
3128
2343
  };
3129
2344
  const deserializeMetadata = (output) => ({
3130
2345
  httpStatusCode: output.statusCode,