@aws-sdk/client-rum 3.504.0 → 3.509.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist-cjs/index.js CHANGED
@@ -604,7 +604,7 @@ var se_UpdateRumMetricDefinitionCommand = /* @__PURE__ */ __name(async (input, c
604
604
  }, "se_UpdateRumMetricDefinitionCommand");
605
605
  var de_BatchCreateRumMetricDefinitionsCommand = /* @__PURE__ */ __name(async (output, context) => {
606
606
  if (output.statusCode !== 200 && output.statusCode >= 300) {
607
- return de_BatchCreateRumMetricDefinitionsCommandError(output, context);
607
+ return de_CommandError(output, context);
608
608
  }
609
609
  const contents = (0, import_smithy_client.map)({
610
610
  $metadata: deserializeMetadata(output)
@@ -617,46 +617,9 @@ var de_BatchCreateRumMetricDefinitionsCommand = /* @__PURE__ */ __name(async (ou
617
617
  Object.assign(contents, doc);
618
618
  return contents;
619
619
  }, "de_BatchCreateRumMetricDefinitionsCommand");
620
- var de_BatchCreateRumMetricDefinitionsCommandError = /* @__PURE__ */ __name(async (output, context) => {
621
- const parsedOutput = {
622
- ...output,
623
- body: await parseErrorBody(output.body, context)
624
- };
625
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
626
- switch (errorCode) {
627
- case "AccessDeniedException":
628
- case "com.amazonaws.rum#AccessDeniedException":
629
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
630
- case "ConflictException":
631
- case "com.amazonaws.rum#ConflictException":
632
- throw await de_ConflictExceptionRes(parsedOutput, context);
633
- case "InternalServerException":
634
- case "com.amazonaws.rum#InternalServerException":
635
- throw await de_InternalServerExceptionRes(parsedOutput, context);
636
- case "ResourceNotFoundException":
637
- case "com.amazonaws.rum#ResourceNotFoundException":
638
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
639
- case "ServiceQuotaExceededException":
640
- case "com.amazonaws.rum#ServiceQuotaExceededException":
641
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
642
- case "ThrottlingException":
643
- case "com.amazonaws.rum#ThrottlingException":
644
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
645
- case "ValidationException":
646
- case "com.amazonaws.rum#ValidationException":
647
- throw await de_ValidationExceptionRes(parsedOutput, context);
648
- default:
649
- const parsedBody = parsedOutput.body;
650
- return throwDefaultError({
651
- output,
652
- parsedBody,
653
- errorCode
654
- });
655
- }
656
- }, "de_BatchCreateRumMetricDefinitionsCommandError");
657
620
  var de_BatchDeleteRumMetricDefinitionsCommand = /* @__PURE__ */ __name(async (output, context) => {
658
621
  if (output.statusCode !== 200 && output.statusCode >= 300) {
659
- return de_BatchDeleteRumMetricDefinitionsCommandError(output, context);
622
+ return de_CommandError(output, context);
660
623
  }
661
624
  const contents = (0, import_smithy_client.map)({
662
625
  $metadata: deserializeMetadata(output)
@@ -669,43 +632,9 @@ var de_BatchDeleteRumMetricDefinitionsCommand = /* @__PURE__ */ __name(async (ou
669
632
  Object.assign(contents, doc);
670
633
  return contents;
671
634
  }, "de_BatchDeleteRumMetricDefinitionsCommand");
672
- var de_BatchDeleteRumMetricDefinitionsCommandError = /* @__PURE__ */ __name(async (output, context) => {
673
- const parsedOutput = {
674
- ...output,
675
- body: await parseErrorBody(output.body, context)
676
- };
677
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
678
- switch (errorCode) {
679
- case "AccessDeniedException":
680
- case "com.amazonaws.rum#AccessDeniedException":
681
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
682
- case "ConflictException":
683
- case "com.amazonaws.rum#ConflictException":
684
- throw await de_ConflictExceptionRes(parsedOutput, context);
685
- case "InternalServerException":
686
- case "com.amazonaws.rum#InternalServerException":
687
- throw await de_InternalServerExceptionRes(parsedOutput, context);
688
- case "ResourceNotFoundException":
689
- case "com.amazonaws.rum#ResourceNotFoundException":
690
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
691
- case "ThrottlingException":
692
- case "com.amazonaws.rum#ThrottlingException":
693
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
694
- case "ValidationException":
695
- case "com.amazonaws.rum#ValidationException":
696
- throw await de_ValidationExceptionRes(parsedOutput, context);
697
- default:
698
- const parsedBody = parsedOutput.body;
699
- return throwDefaultError({
700
- output,
701
- parsedBody,
702
- errorCode
703
- });
704
- }
705
- }, "de_BatchDeleteRumMetricDefinitionsCommandError");
706
635
  var de_BatchGetRumMetricDefinitionsCommand = /* @__PURE__ */ __name(async (output, context) => {
707
636
  if (output.statusCode !== 200 && output.statusCode >= 300) {
708
- return de_BatchGetRumMetricDefinitionsCommandError(output, context);
637
+ return de_CommandError(output, context);
709
638
  }
710
639
  const contents = (0, import_smithy_client.map)({
711
640
  $metadata: deserializeMetadata(output)
@@ -718,37 +647,9 @@ var de_BatchGetRumMetricDefinitionsCommand = /* @__PURE__ */ __name(async (outpu
718
647
  Object.assign(contents, doc);
719
648
  return contents;
720
649
  }, "de_BatchGetRumMetricDefinitionsCommand");
721
- var de_BatchGetRumMetricDefinitionsCommandError = /* @__PURE__ */ __name(async (output, context) => {
722
- const parsedOutput = {
723
- ...output,
724
- body: await parseErrorBody(output.body, context)
725
- };
726
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
727
- switch (errorCode) {
728
- case "AccessDeniedException":
729
- case "com.amazonaws.rum#AccessDeniedException":
730
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
731
- case "InternalServerException":
732
- case "com.amazonaws.rum#InternalServerException":
733
- throw await de_InternalServerExceptionRes(parsedOutput, context);
734
- case "ResourceNotFoundException":
735
- case "com.amazonaws.rum#ResourceNotFoundException":
736
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
737
- case "ValidationException":
738
- case "com.amazonaws.rum#ValidationException":
739
- throw await de_ValidationExceptionRes(parsedOutput, context);
740
- default:
741
- const parsedBody = parsedOutput.body;
742
- return throwDefaultError({
743
- output,
744
- parsedBody,
745
- errorCode
746
- });
747
- }
748
- }, "de_BatchGetRumMetricDefinitionsCommandError");
749
650
  var de_CreateAppMonitorCommand = /* @__PURE__ */ __name(async (output, context) => {
750
651
  if (output.statusCode !== 200 && output.statusCode >= 300) {
751
- return de_CreateAppMonitorCommandError(output, context);
652
+ return de_CommandError(output, context);
752
653
  }
753
654
  const contents = (0, import_smithy_client.map)({
754
655
  $metadata: deserializeMetadata(output)
@@ -760,46 +661,9 @@ var de_CreateAppMonitorCommand = /* @__PURE__ */ __name(async (output, context)
760
661
  Object.assign(contents, doc);
761
662
  return contents;
762
663
  }, "de_CreateAppMonitorCommand");
763
- var de_CreateAppMonitorCommandError = /* @__PURE__ */ __name(async (output, context) => {
764
- const parsedOutput = {
765
- ...output,
766
- body: await parseErrorBody(output.body, context)
767
- };
768
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
769
- switch (errorCode) {
770
- case "AccessDeniedException":
771
- case "com.amazonaws.rum#AccessDeniedException":
772
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
773
- case "ConflictException":
774
- case "com.amazonaws.rum#ConflictException":
775
- throw await de_ConflictExceptionRes(parsedOutput, context);
776
- case "InternalServerException":
777
- case "com.amazonaws.rum#InternalServerException":
778
- throw await de_InternalServerExceptionRes(parsedOutput, context);
779
- case "ResourceNotFoundException":
780
- case "com.amazonaws.rum#ResourceNotFoundException":
781
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
782
- case "ServiceQuotaExceededException":
783
- case "com.amazonaws.rum#ServiceQuotaExceededException":
784
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
785
- case "ThrottlingException":
786
- case "com.amazonaws.rum#ThrottlingException":
787
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
788
- case "ValidationException":
789
- case "com.amazonaws.rum#ValidationException":
790
- throw await de_ValidationExceptionRes(parsedOutput, context);
791
- default:
792
- const parsedBody = parsedOutput.body;
793
- return throwDefaultError({
794
- output,
795
- parsedBody,
796
- errorCode
797
- });
798
- }
799
- }, "de_CreateAppMonitorCommandError");
800
664
  var de_DeleteAppMonitorCommand = /* @__PURE__ */ __name(async (output, context) => {
801
665
  if (output.statusCode !== 200 && output.statusCode >= 300) {
802
- return de_DeleteAppMonitorCommandError(output, context);
666
+ return de_CommandError(output, context);
803
667
  }
804
668
  const contents = (0, import_smithy_client.map)({
805
669
  $metadata: deserializeMetadata(output)
@@ -807,43 +671,9 @@ var de_DeleteAppMonitorCommand = /* @__PURE__ */ __name(async (output, context)
807
671
  await (0, import_smithy_client.collectBody)(output.body, context);
808
672
  return contents;
809
673
  }, "de_DeleteAppMonitorCommand");
810
- var de_DeleteAppMonitorCommandError = /* @__PURE__ */ __name(async (output, context) => {
811
- const parsedOutput = {
812
- ...output,
813
- body: await parseErrorBody(output.body, context)
814
- };
815
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
816
- switch (errorCode) {
817
- case "AccessDeniedException":
818
- case "com.amazonaws.rum#AccessDeniedException":
819
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
820
- case "ConflictException":
821
- case "com.amazonaws.rum#ConflictException":
822
- throw await de_ConflictExceptionRes(parsedOutput, context);
823
- case "InternalServerException":
824
- case "com.amazonaws.rum#InternalServerException":
825
- throw await de_InternalServerExceptionRes(parsedOutput, context);
826
- case "ResourceNotFoundException":
827
- case "com.amazonaws.rum#ResourceNotFoundException":
828
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
829
- case "ThrottlingException":
830
- case "com.amazonaws.rum#ThrottlingException":
831
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
832
- case "ValidationException":
833
- case "com.amazonaws.rum#ValidationException":
834
- throw await de_ValidationExceptionRes(parsedOutput, context);
835
- default:
836
- const parsedBody = parsedOutput.body;
837
- return throwDefaultError({
838
- output,
839
- parsedBody,
840
- errorCode
841
- });
842
- }
843
- }, "de_DeleteAppMonitorCommandError");
844
674
  var de_DeleteRumMetricsDestinationCommand = /* @__PURE__ */ __name(async (output, context) => {
845
675
  if (output.statusCode !== 200 && output.statusCode >= 300) {
846
- return de_DeleteRumMetricsDestinationCommandError(output, context);
676
+ return de_CommandError(output, context);
847
677
  }
848
678
  const contents = (0, import_smithy_client.map)({
849
679
  $metadata: deserializeMetadata(output)
@@ -851,43 +681,9 @@ var de_DeleteRumMetricsDestinationCommand = /* @__PURE__ */ __name(async (output
851
681
  await (0, import_smithy_client.collectBody)(output.body, context);
852
682
  return contents;
853
683
  }, "de_DeleteRumMetricsDestinationCommand");
854
- var de_DeleteRumMetricsDestinationCommandError = /* @__PURE__ */ __name(async (output, context) => {
855
- const parsedOutput = {
856
- ...output,
857
- body: await parseErrorBody(output.body, context)
858
- };
859
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
860
- switch (errorCode) {
861
- case "AccessDeniedException":
862
- case "com.amazonaws.rum#AccessDeniedException":
863
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
864
- case "ConflictException":
865
- case "com.amazonaws.rum#ConflictException":
866
- throw await de_ConflictExceptionRes(parsedOutput, context);
867
- case "InternalServerException":
868
- case "com.amazonaws.rum#InternalServerException":
869
- throw await de_InternalServerExceptionRes(parsedOutput, context);
870
- case "ResourceNotFoundException":
871
- case "com.amazonaws.rum#ResourceNotFoundException":
872
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
873
- case "ThrottlingException":
874
- case "com.amazonaws.rum#ThrottlingException":
875
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
876
- case "ValidationException":
877
- case "com.amazonaws.rum#ValidationException":
878
- throw await de_ValidationExceptionRes(parsedOutput, context);
879
- default:
880
- const parsedBody = parsedOutput.body;
881
- return throwDefaultError({
882
- output,
883
- parsedBody,
884
- errorCode
885
- });
886
- }
887
- }, "de_DeleteRumMetricsDestinationCommandError");
888
684
  var de_GetAppMonitorCommand = /* @__PURE__ */ __name(async (output, context) => {
889
685
  if (output.statusCode !== 200 && output.statusCode >= 300) {
890
- return de_GetAppMonitorCommandError(output, context);
686
+ return de_CommandError(output, context);
891
687
  }
892
688
  const contents = (0, import_smithy_client.map)({
893
689
  $metadata: deserializeMetadata(output)
@@ -899,40 +695,9 @@ var de_GetAppMonitorCommand = /* @__PURE__ */ __name(async (output, context) =>
899
695
  Object.assign(contents, doc);
900
696
  return contents;
901
697
  }, "de_GetAppMonitorCommand");
902
- var de_GetAppMonitorCommandError = /* @__PURE__ */ __name(async (output, context) => {
903
- const parsedOutput = {
904
- ...output,
905
- body: await parseErrorBody(output.body, context)
906
- };
907
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
908
- switch (errorCode) {
909
- case "AccessDeniedException":
910
- case "com.amazonaws.rum#AccessDeniedException":
911
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
912
- case "InternalServerException":
913
- case "com.amazonaws.rum#InternalServerException":
914
- throw await de_InternalServerExceptionRes(parsedOutput, context);
915
- case "ResourceNotFoundException":
916
- case "com.amazonaws.rum#ResourceNotFoundException":
917
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
918
- case "ThrottlingException":
919
- case "com.amazonaws.rum#ThrottlingException":
920
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
921
- case "ValidationException":
922
- case "com.amazonaws.rum#ValidationException":
923
- throw await de_ValidationExceptionRes(parsedOutput, context);
924
- default:
925
- const parsedBody = parsedOutput.body;
926
- return throwDefaultError({
927
- output,
928
- parsedBody,
929
- errorCode
930
- });
931
- }
932
- }, "de_GetAppMonitorCommandError");
933
698
  var de_GetAppMonitorDataCommand = /* @__PURE__ */ __name(async (output, context) => {
934
699
  if (output.statusCode !== 200 && output.statusCode >= 300) {
935
- return de_GetAppMonitorDataCommandError(output, context);
700
+ return de_CommandError(output, context);
936
701
  }
937
702
  const contents = (0, import_smithy_client.map)({
938
703
  $metadata: deserializeMetadata(output)
@@ -945,40 +710,9 @@ var de_GetAppMonitorDataCommand = /* @__PURE__ */ __name(async (output, context)
945
710
  Object.assign(contents, doc);
946
711
  return contents;
947
712
  }, "de_GetAppMonitorDataCommand");
948
- var de_GetAppMonitorDataCommandError = /* @__PURE__ */ __name(async (output, context) => {
949
- const parsedOutput = {
950
- ...output,
951
- body: await parseErrorBody(output.body, context)
952
- };
953
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
954
- switch (errorCode) {
955
- case "AccessDeniedException":
956
- case "com.amazonaws.rum#AccessDeniedException":
957
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
958
- case "InternalServerException":
959
- case "com.amazonaws.rum#InternalServerException":
960
- throw await de_InternalServerExceptionRes(parsedOutput, context);
961
- case "ResourceNotFoundException":
962
- case "com.amazonaws.rum#ResourceNotFoundException":
963
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
964
- case "ThrottlingException":
965
- case "com.amazonaws.rum#ThrottlingException":
966
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
967
- case "ValidationException":
968
- case "com.amazonaws.rum#ValidationException":
969
- throw await de_ValidationExceptionRes(parsedOutput, context);
970
- default:
971
- const parsedBody = parsedOutput.body;
972
- return throwDefaultError({
973
- output,
974
- parsedBody,
975
- errorCode
976
- });
977
- }
978
- }, "de_GetAppMonitorDataCommandError");
979
713
  var de_ListAppMonitorsCommand = /* @__PURE__ */ __name(async (output, context) => {
980
714
  if (output.statusCode !== 200 && output.statusCode >= 300) {
981
- return de_ListAppMonitorsCommandError(output, context);
715
+ return de_CommandError(output, context);
982
716
  }
983
717
  const contents = (0, import_smithy_client.map)({
984
718
  $metadata: deserializeMetadata(output)
@@ -991,37 +725,9 @@ var de_ListAppMonitorsCommand = /* @__PURE__ */ __name(async (output, context) =
991
725
  Object.assign(contents, doc);
992
726
  return contents;
993
727
  }, "de_ListAppMonitorsCommand");
994
- var de_ListAppMonitorsCommandError = /* @__PURE__ */ __name(async (output, context) => {
995
- const parsedOutput = {
996
- ...output,
997
- body: await parseErrorBody(output.body, context)
998
- };
999
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1000
- switch (errorCode) {
1001
- case "AccessDeniedException":
1002
- case "com.amazonaws.rum#AccessDeniedException":
1003
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1004
- case "InternalServerException":
1005
- case "com.amazonaws.rum#InternalServerException":
1006
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1007
- case "ThrottlingException":
1008
- case "com.amazonaws.rum#ThrottlingException":
1009
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1010
- case "ValidationException":
1011
- case "com.amazonaws.rum#ValidationException":
1012
- throw await de_ValidationExceptionRes(parsedOutput, context);
1013
- default:
1014
- const parsedBody = parsedOutput.body;
1015
- return throwDefaultError({
1016
- output,
1017
- parsedBody,
1018
- errorCode
1019
- });
1020
- }
1021
- }, "de_ListAppMonitorsCommandError");
1022
728
  var de_ListRumMetricsDestinationsCommand = /* @__PURE__ */ __name(async (output, context) => {
1023
729
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1024
- return de_ListRumMetricsDestinationsCommandError(output, context);
730
+ return de_CommandError(output, context);
1025
731
  }
1026
732
  const contents = (0, import_smithy_client.map)({
1027
733
  $metadata: deserializeMetadata(output)
@@ -1034,37 +740,9 @@ var de_ListRumMetricsDestinationsCommand = /* @__PURE__ */ __name(async (output,
1034
740
  Object.assign(contents, doc);
1035
741
  return contents;
1036
742
  }, "de_ListRumMetricsDestinationsCommand");
1037
- var de_ListRumMetricsDestinationsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1038
- const parsedOutput = {
1039
- ...output,
1040
- body: await parseErrorBody(output.body, context)
1041
- };
1042
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1043
- switch (errorCode) {
1044
- case "AccessDeniedException":
1045
- case "com.amazonaws.rum#AccessDeniedException":
1046
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1047
- case "InternalServerException":
1048
- case "com.amazonaws.rum#InternalServerException":
1049
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1050
- case "ResourceNotFoundException":
1051
- case "com.amazonaws.rum#ResourceNotFoundException":
1052
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1053
- case "ValidationException":
1054
- case "com.amazonaws.rum#ValidationException":
1055
- throw await de_ValidationExceptionRes(parsedOutput, context);
1056
- default:
1057
- const parsedBody = parsedOutput.body;
1058
- return throwDefaultError({
1059
- output,
1060
- parsedBody,
1061
- errorCode
1062
- });
1063
- }
1064
- }, "de_ListRumMetricsDestinationsCommandError");
1065
743
  var de_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1066
744
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1067
- return de_ListTagsForResourceCommandError(output, context);
745
+ return de_CommandError(output, context);
1068
746
  }
1069
747
  const contents = (0, import_smithy_client.map)({
1070
748
  $metadata: deserializeMetadata(output)
@@ -1077,34 +755,9 @@ var de_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (output, contex
1077
755
  Object.assign(contents, doc);
1078
756
  return contents;
1079
757
  }, "de_ListTagsForResourceCommand");
1080
- var de_ListTagsForResourceCommandError = /* @__PURE__ */ __name(async (output, context) => {
1081
- const parsedOutput = {
1082
- ...output,
1083
- body: await parseErrorBody(output.body, context)
1084
- };
1085
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1086
- switch (errorCode) {
1087
- case "InternalServerException":
1088
- case "com.amazonaws.rum#InternalServerException":
1089
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1090
- case "ResourceNotFoundException":
1091
- case "com.amazonaws.rum#ResourceNotFoundException":
1092
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1093
- case "ValidationException":
1094
- case "com.amazonaws.rum#ValidationException":
1095
- throw await de_ValidationExceptionRes(parsedOutput, context);
1096
- default:
1097
- const parsedBody = parsedOutput.body;
1098
- return throwDefaultError({
1099
- output,
1100
- parsedBody,
1101
- errorCode
1102
- });
1103
- }
1104
- }, "de_ListTagsForResourceCommandError");
1105
758
  var de_PutRumEventsCommand = /* @__PURE__ */ __name(async (output, context) => {
1106
759
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1107
- return de_PutRumEventsCommandError(output, context);
760
+ return de_CommandError(output, context);
1108
761
  }
1109
762
  const contents = (0, import_smithy_client.map)({
1110
763
  $metadata: deserializeMetadata(output)
@@ -1112,40 +765,9 @@ var de_PutRumEventsCommand = /* @__PURE__ */ __name(async (output, context) => {
1112
765
  await (0, import_smithy_client.collectBody)(output.body, context);
1113
766
  return contents;
1114
767
  }, "de_PutRumEventsCommand");
1115
- var de_PutRumEventsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1116
- const parsedOutput = {
1117
- ...output,
1118
- body: await parseErrorBody(output.body, context)
1119
- };
1120
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1121
- switch (errorCode) {
1122
- case "AccessDeniedException":
1123
- case "com.amazonaws.rum#AccessDeniedException":
1124
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1125
- case "InternalServerException":
1126
- case "com.amazonaws.rum#InternalServerException":
1127
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1128
- case "ResourceNotFoundException":
1129
- case "com.amazonaws.rum#ResourceNotFoundException":
1130
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1131
- case "ThrottlingException":
1132
- case "com.amazonaws.rum#ThrottlingException":
1133
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1134
- case "ValidationException":
1135
- case "com.amazonaws.rum#ValidationException":
1136
- throw await de_ValidationExceptionRes(parsedOutput, context);
1137
- default:
1138
- const parsedBody = parsedOutput.body;
1139
- return throwDefaultError({
1140
- output,
1141
- parsedBody,
1142
- errorCode
1143
- });
1144
- }
1145
- }, "de_PutRumEventsCommandError");
1146
768
  var de_PutRumMetricsDestinationCommand = /* @__PURE__ */ __name(async (output, context) => {
1147
769
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1148
- return de_PutRumMetricsDestinationCommandError(output, context);
770
+ return de_CommandError(output, context);
1149
771
  }
1150
772
  const contents = (0, import_smithy_client.map)({
1151
773
  $metadata: deserializeMetadata(output)
@@ -1153,43 +775,9 @@ var de_PutRumMetricsDestinationCommand = /* @__PURE__ */ __name(async (output, c
1153
775
  await (0, import_smithy_client.collectBody)(output.body, context);
1154
776
  return contents;
1155
777
  }, "de_PutRumMetricsDestinationCommand");
1156
- var de_PutRumMetricsDestinationCommandError = /* @__PURE__ */ __name(async (output, context) => {
1157
- const parsedOutput = {
1158
- ...output,
1159
- body: await parseErrorBody(output.body, context)
1160
- };
1161
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1162
- switch (errorCode) {
1163
- case "AccessDeniedException":
1164
- case "com.amazonaws.rum#AccessDeniedException":
1165
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1166
- case "ConflictException":
1167
- case "com.amazonaws.rum#ConflictException":
1168
- throw await de_ConflictExceptionRes(parsedOutput, context);
1169
- case "InternalServerException":
1170
- case "com.amazonaws.rum#InternalServerException":
1171
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1172
- case "ResourceNotFoundException":
1173
- case "com.amazonaws.rum#ResourceNotFoundException":
1174
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1175
- case "ThrottlingException":
1176
- case "com.amazonaws.rum#ThrottlingException":
1177
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1178
- case "ValidationException":
1179
- case "com.amazonaws.rum#ValidationException":
1180
- throw await de_ValidationExceptionRes(parsedOutput, context);
1181
- default:
1182
- const parsedBody = parsedOutput.body;
1183
- return throwDefaultError({
1184
- output,
1185
- parsedBody,
1186
- errorCode
1187
- });
1188
- }
1189
- }, "de_PutRumMetricsDestinationCommandError");
1190
778
  var de_TagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1191
779
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1192
- return de_TagResourceCommandError(output, context);
780
+ return de_CommandError(output, context);
1193
781
  }
1194
782
  const contents = (0, import_smithy_client.map)({
1195
783
  $metadata: deserializeMetadata(output)
@@ -1197,34 +785,9 @@ var de_TagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1197
785
  await (0, import_smithy_client.collectBody)(output.body, context);
1198
786
  return contents;
1199
787
  }, "de_TagResourceCommand");
1200
- var de_TagResourceCommandError = /* @__PURE__ */ __name(async (output, context) => {
1201
- const parsedOutput = {
1202
- ...output,
1203
- body: await parseErrorBody(output.body, context)
1204
- };
1205
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1206
- switch (errorCode) {
1207
- case "InternalServerException":
1208
- case "com.amazonaws.rum#InternalServerException":
1209
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1210
- case "ResourceNotFoundException":
1211
- case "com.amazonaws.rum#ResourceNotFoundException":
1212
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1213
- case "ValidationException":
1214
- case "com.amazonaws.rum#ValidationException":
1215
- throw await de_ValidationExceptionRes(parsedOutput, context);
1216
- default:
1217
- const parsedBody = parsedOutput.body;
1218
- return throwDefaultError({
1219
- output,
1220
- parsedBody,
1221
- errorCode
1222
- });
1223
- }
1224
- }, "de_TagResourceCommandError");
1225
788
  var de_UntagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1226
789
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1227
- return de_UntagResourceCommandError(output, context);
790
+ return de_CommandError(output, context);
1228
791
  }
1229
792
  const contents = (0, import_smithy_client.map)({
1230
793
  $metadata: deserializeMetadata(output)
@@ -1232,34 +795,9 @@ var de_UntagResourceCommand = /* @__PURE__ */ __name(async (output, context) =>
1232
795
  await (0, import_smithy_client.collectBody)(output.body, context);
1233
796
  return contents;
1234
797
  }, "de_UntagResourceCommand");
1235
- var de_UntagResourceCommandError = /* @__PURE__ */ __name(async (output, context) => {
1236
- const parsedOutput = {
1237
- ...output,
1238
- body: await parseErrorBody(output.body, context)
1239
- };
1240
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1241
- switch (errorCode) {
1242
- case "InternalServerException":
1243
- case "com.amazonaws.rum#InternalServerException":
1244
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1245
- case "ResourceNotFoundException":
1246
- case "com.amazonaws.rum#ResourceNotFoundException":
1247
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1248
- case "ValidationException":
1249
- case "com.amazonaws.rum#ValidationException":
1250
- throw await de_ValidationExceptionRes(parsedOutput, context);
1251
- default:
1252
- const parsedBody = parsedOutput.body;
1253
- return throwDefaultError({
1254
- output,
1255
- parsedBody,
1256
- errorCode
1257
- });
1258
- }
1259
- }, "de_UntagResourceCommandError");
1260
798
  var de_UpdateAppMonitorCommand = /* @__PURE__ */ __name(async (output, context) => {
1261
799
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1262
- return de_UpdateAppMonitorCommandError(output, context);
800
+ return de_CommandError(output, context);
1263
801
  }
1264
802
  const contents = (0, import_smithy_client.map)({
1265
803
  $metadata: deserializeMetadata(output)
@@ -1267,43 +805,9 @@ var de_UpdateAppMonitorCommand = /* @__PURE__ */ __name(async (output, context)
1267
805
  await (0, import_smithy_client.collectBody)(output.body, context);
1268
806
  return contents;
1269
807
  }, "de_UpdateAppMonitorCommand");
1270
- var de_UpdateAppMonitorCommandError = /* @__PURE__ */ __name(async (output, context) => {
1271
- const parsedOutput = {
1272
- ...output,
1273
- body: await parseErrorBody(output.body, context)
1274
- };
1275
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1276
- switch (errorCode) {
1277
- case "AccessDeniedException":
1278
- case "com.amazonaws.rum#AccessDeniedException":
1279
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1280
- case "ConflictException":
1281
- case "com.amazonaws.rum#ConflictException":
1282
- throw await de_ConflictExceptionRes(parsedOutput, context);
1283
- case "InternalServerException":
1284
- case "com.amazonaws.rum#InternalServerException":
1285
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1286
- case "ResourceNotFoundException":
1287
- case "com.amazonaws.rum#ResourceNotFoundException":
1288
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1289
- case "ThrottlingException":
1290
- case "com.amazonaws.rum#ThrottlingException":
1291
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1292
- case "ValidationException":
1293
- case "com.amazonaws.rum#ValidationException":
1294
- throw await de_ValidationExceptionRes(parsedOutput, context);
1295
- default:
1296
- const parsedBody = parsedOutput.body;
1297
- return throwDefaultError({
1298
- output,
1299
- parsedBody,
1300
- errorCode
1301
- });
1302
- }
1303
- }, "de_UpdateAppMonitorCommandError");
1304
808
  var de_UpdateRumMetricDefinitionCommand = /* @__PURE__ */ __name(async (output, context) => {
1305
809
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1306
- return de_UpdateRumMetricDefinitionCommandError(output, context);
810
+ return de_CommandError(output, context);
1307
811
  }
1308
812
  const contents = (0, import_smithy_client.map)({
1309
813
  $metadata: deserializeMetadata(output)
@@ -1311,7 +815,7 @@ var de_UpdateRumMetricDefinitionCommand = /* @__PURE__ */ __name(async (output,
1311
815
  await (0, import_smithy_client.collectBody)(output.body, context);
1312
816
  return contents;
1313
817
  }, "de_UpdateRumMetricDefinitionCommand");
1314
- var de_UpdateRumMetricDefinitionCommandError = /* @__PURE__ */ __name(async (output, context) => {
818
+ var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
1315
819
  const parsedOutput = {
1316
820
  ...output,
1317
821
  body: await parseErrorBody(output.body, context)
@@ -1347,7 +851,7 @@ var de_UpdateRumMetricDefinitionCommandError = /* @__PURE__ */ __name(async (out
1347
851
  errorCode
1348
852
  });
1349
853
  }
1350
- }, "de_UpdateRumMetricDefinitionCommandError");
854
+ }, "de_CommandError");
1351
855
  var throwDefaultError = (0, import_smithy_client.withBaseException)(RUMServiceException);
1352
856
  var de_AccessDeniedExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1353
857
  const contents = (0, import_smithy_client.map)({});