@aws-sdk/client-finspace 3.504.0 → 3.507.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.
@@ -714,7 +714,7 @@ export const se_UpdateKxVolumeCommand = async (input, context) => {
714
714
  };
715
715
  export const de_CreateEnvironmentCommand = async (output, context) => {
716
716
  if (output.statusCode !== 200 && output.statusCode >= 300) {
717
- return de_CreateEnvironmentCommandError(output, context);
717
+ return de_CommandError(output, context);
718
718
  }
719
719
  const contents = map({
720
720
  $metadata: deserializeMetadata(output),
@@ -728,43 +728,9 @@ export const de_CreateEnvironmentCommand = async (output, context) => {
728
728
  Object.assign(contents, doc);
729
729
  return contents;
730
730
  };
731
- const de_CreateEnvironmentCommandError = async (output, context) => {
732
- const parsedOutput = {
733
- ...output,
734
- body: await parseErrorBody(output.body, context),
735
- };
736
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
737
- switch (errorCode) {
738
- case "AccessDeniedException":
739
- case "com.amazonaws.finspace#AccessDeniedException":
740
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
741
- case "InternalServerException":
742
- case "com.amazonaws.finspace#InternalServerException":
743
- throw await de_InternalServerExceptionRes(parsedOutput, context);
744
- case "LimitExceededException":
745
- case "com.amazonaws.finspace#LimitExceededException":
746
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
747
- case "ServiceQuotaExceededException":
748
- case "com.amazonaws.finspace#ServiceQuotaExceededException":
749
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
750
- case "ThrottlingException":
751
- case "com.amazonaws.finspace#ThrottlingException":
752
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
753
- case "ValidationException":
754
- case "com.amazonaws.finspace#ValidationException":
755
- throw await de_ValidationExceptionRes(parsedOutput, context);
756
- default:
757
- const parsedBody = parsedOutput.body;
758
- return throwDefaultError({
759
- output,
760
- parsedBody,
761
- errorCode,
762
- });
763
- }
764
- };
765
731
  export const de_CreateKxChangesetCommand = async (output, context) => {
766
732
  if (output.statusCode !== 200 && output.statusCode >= 300) {
767
- return de_CreateKxChangesetCommandError(output, context);
733
+ return de_CommandError(output, context);
768
734
  }
769
735
  const contents = map({
770
736
  $metadata: deserializeMetadata(output),
@@ -783,46 +749,9 @@ export const de_CreateKxChangesetCommand = async (output, context) => {
783
749
  Object.assign(contents, doc);
784
750
  return contents;
785
751
  };
786
- const de_CreateKxChangesetCommandError = async (output, context) => {
787
- const parsedOutput = {
788
- ...output,
789
- body: await parseErrorBody(output.body, context),
790
- };
791
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
792
- switch (errorCode) {
793
- case "AccessDeniedException":
794
- case "com.amazonaws.finspace#AccessDeniedException":
795
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
796
- case "ConflictException":
797
- case "com.amazonaws.finspace#ConflictException":
798
- throw await de_ConflictExceptionRes(parsedOutput, context);
799
- case "InternalServerException":
800
- case "com.amazonaws.finspace#InternalServerException":
801
- throw await de_InternalServerExceptionRes(parsedOutput, context);
802
- case "LimitExceededException":
803
- case "com.amazonaws.finspace#LimitExceededException":
804
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
805
- case "ResourceNotFoundException":
806
- case "com.amazonaws.finspace#ResourceNotFoundException":
807
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
808
- case "ThrottlingException":
809
- case "com.amazonaws.finspace#ThrottlingException":
810
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
811
- case "ValidationException":
812
- case "com.amazonaws.finspace#ValidationException":
813
- throw await de_ValidationExceptionRes(parsedOutput, context);
814
- default:
815
- const parsedBody = parsedOutput.body;
816
- return throwDefaultError({
817
- output,
818
- parsedBody,
819
- errorCode,
820
- });
821
- }
822
- };
823
752
  export const de_CreateKxClusterCommand = async (output, context) => {
824
753
  if (output.statusCode !== 200 && output.statusCode >= 300) {
825
- return de_CreateKxClusterCommandError(output, context);
754
+ return de_CommandError(output, context);
826
755
  }
827
756
  const contents = map({
828
757
  $metadata: deserializeMetadata(output),
@@ -857,46 +786,9 @@ export const de_CreateKxClusterCommand = async (output, context) => {
857
786
  Object.assign(contents, doc);
858
787
  return contents;
859
788
  };
860
- const de_CreateKxClusterCommandError = async (output, context) => {
861
- const parsedOutput = {
862
- ...output,
863
- body: await parseErrorBody(output.body, context),
864
- };
865
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
866
- switch (errorCode) {
867
- case "AccessDeniedException":
868
- case "com.amazonaws.finspace#AccessDeniedException":
869
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
870
- case "ConflictException":
871
- case "com.amazonaws.finspace#ConflictException":
872
- throw await de_ConflictExceptionRes(parsedOutput, context);
873
- case "InternalServerException":
874
- case "com.amazonaws.finspace#InternalServerException":
875
- throw await de_InternalServerExceptionRes(parsedOutput, context);
876
- case "LimitExceededException":
877
- case "com.amazonaws.finspace#LimitExceededException":
878
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
879
- case "ResourceNotFoundException":
880
- case "com.amazonaws.finspace#ResourceNotFoundException":
881
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
882
- case "ThrottlingException":
883
- case "com.amazonaws.finspace#ThrottlingException":
884
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
885
- case "ValidationException":
886
- case "com.amazonaws.finspace#ValidationException":
887
- throw await de_ValidationExceptionRes(parsedOutput, context);
888
- default:
889
- const parsedBody = parsedOutput.body;
890
- return throwDefaultError({
891
- output,
892
- parsedBody,
893
- errorCode,
894
- });
895
- }
896
- };
897
789
  export const de_CreateKxDatabaseCommand = async (output, context) => {
898
790
  if (output.statusCode !== 200 && output.statusCode >= 300) {
899
- return de_CreateKxDatabaseCommandError(output, context);
791
+ return de_CommandError(output, context);
900
792
  }
901
793
  const contents = map({
902
794
  $metadata: deserializeMetadata(output),
@@ -913,49 +805,9 @@ export const de_CreateKxDatabaseCommand = async (output, context) => {
913
805
  Object.assign(contents, doc);
914
806
  return contents;
915
807
  };
916
- const de_CreateKxDatabaseCommandError = async (output, context) => {
917
- const parsedOutput = {
918
- ...output,
919
- body: await parseErrorBody(output.body, context),
920
- };
921
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
922
- switch (errorCode) {
923
- case "AccessDeniedException":
924
- case "com.amazonaws.finspace#AccessDeniedException":
925
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
926
- case "ConflictException":
927
- case "com.amazonaws.finspace#ConflictException":
928
- throw await de_ConflictExceptionRes(parsedOutput, context);
929
- case "InternalServerException":
930
- case "com.amazonaws.finspace#InternalServerException":
931
- throw await de_InternalServerExceptionRes(parsedOutput, context);
932
- case "LimitExceededException":
933
- case "com.amazonaws.finspace#LimitExceededException":
934
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
935
- case "ResourceAlreadyExistsException":
936
- case "com.amazonaws.finspace#ResourceAlreadyExistsException":
937
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
938
- case "ResourceNotFoundException":
939
- case "com.amazonaws.finspace#ResourceNotFoundException":
940
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
941
- case "ThrottlingException":
942
- case "com.amazonaws.finspace#ThrottlingException":
943
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
944
- case "ValidationException":
945
- case "com.amazonaws.finspace#ValidationException":
946
- throw await de_ValidationExceptionRes(parsedOutput, context);
947
- default:
948
- const parsedBody = parsedOutput.body;
949
- return throwDefaultError({
950
- output,
951
- parsedBody,
952
- errorCode,
953
- });
954
- }
955
- };
956
808
  export const de_CreateKxDataviewCommand = async (output, context) => {
957
809
  if (output.statusCode !== 200 && output.statusCode >= 300) {
958
- return de_CreateKxDataviewCommandError(output, context);
810
+ return de_CommandError(output, context);
959
811
  }
960
812
  const contents = map({
961
813
  $metadata: deserializeMetadata(output),
@@ -978,49 +830,9 @@ export const de_CreateKxDataviewCommand = async (output, context) => {
978
830
  Object.assign(contents, doc);
979
831
  return contents;
980
832
  };
981
- const de_CreateKxDataviewCommandError = async (output, context) => {
982
- const parsedOutput = {
983
- ...output,
984
- body: await parseErrorBody(output.body, context),
985
- };
986
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
987
- switch (errorCode) {
988
- case "AccessDeniedException":
989
- case "com.amazonaws.finspace#AccessDeniedException":
990
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
991
- case "ConflictException":
992
- case "com.amazonaws.finspace#ConflictException":
993
- throw await de_ConflictExceptionRes(parsedOutput, context);
994
- case "InternalServerException":
995
- case "com.amazonaws.finspace#InternalServerException":
996
- throw await de_InternalServerExceptionRes(parsedOutput, context);
997
- case "LimitExceededException":
998
- case "com.amazonaws.finspace#LimitExceededException":
999
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1000
- case "ResourceAlreadyExistsException":
1001
- case "com.amazonaws.finspace#ResourceAlreadyExistsException":
1002
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
1003
- case "ResourceNotFoundException":
1004
- case "com.amazonaws.finspace#ResourceNotFoundException":
1005
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1006
- case "ThrottlingException":
1007
- case "com.amazonaws.finspace#ThrottlingException":
1008
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1009
- case "ValidationException":
1010
- case "com.amazonaws.finspace#ValidationException":
1011
- throw await de_ValidationExceptionRes(parsedOutput, context);
1012
- default:
1013
- const parsedBody = parsedOutput.body;
1014
- return throwDefaultError({
1015
- output,
1016
- parsedBody,
1017
- errorCode,
1018
- });
1019
- }
1020
- };
1021
833
  export const de_CreateKxEnvironmentCommand = async (output, context) => {
1022
834
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1023
- return de_CreateKxEnvironmentCommandError(output, context);
835
+ return de_CommandError(output, context);
1024
836
  }
1025
837
  const contents = map({
1026
838
  $metadata: deserializeMetadata(output),
@@ -1038,46 +850,9 @@ export const de_CreateKxEnvironmentCommand = async (output, context) => {
1038
850
  Object.assign(contents, doc);
1039
851
  return contents;
1040
852
  };
1041
- const de_CreateKxEnvironmentCommandError = async (output, context) => {
1042
- const parsedOutput = {
1043
- ...output,
1044
- body: await parseErrorBody(output.body, context),
1045
- };
1046
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1047
- switch (errorCode) {
1048
- case "AccessDeniedException":
1049
- case "com.amazonaws.finspace#AccessDeniedException":
1050
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1051
- case "ConflictException":
1052
- case "com.amazonaws.finspace#ConflictException":
1053
- throw await de_ConflictExceptionRes(parsedOutput, context);
1054
- case "InternalServerException":
1055
- case "com.amazonaws.finspace#InternalServerException":
1056
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1057
- case "LimitExceededException":
1058
- case "com.amazonaws.finspace#LimitExceededException":
1059
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1060
- case "ServiceQuotaExceededException":
1061
- case "com.amazonaws.finspace#ServiceQuotaExceededException":
1062
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
1063
- case "ThrottlingException":
1064
- case "com.amazonaws.finspace#ThrottlingException":
1065
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1066
- case "ValidationException":
1067
- case "com.amazonaws.finspace#ValidationException":
1068
- throw await de_ValidationExceptionRes(parsedOutput, context);
1069
- default:
1070
- const parsedBody = parsedOutput.body;
1071
- return throwDefaultError({
1072
- output,
1073
- parsedBody,
1074
- errorCode,
1075
- });
1076
- }
1077
- };
1078
853
  export const de_CreateKxScalingGroupCommand = async (output, context) => {
1079
854
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1080
- return de_CreateKxScalingGroupCommandError(output, context);
855
+ return de_CommandError(output, context);
1081
856
  }
1082
857
  const contents = map({
1083
858
  $metadata: deserializeMetadata(output),
@@ -1095,46 +870,9 @@ export const de_CreateKxScalingGroupCommand = async (output, context) => {
1095
870
  Object.assign(contents, doc);
1096
871
  return contents;
1097
872
  };
1098
- const de_CreateKxScalingGroupCommandError = async (output, context) => {
1099
- const parsedOutput = {
1100
- ...output,
1101
- body: await parseErrorBody(output.body, context),
1102
- };
1103
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1104
- switch (errorCode) {
1105
- case "AccessDeniedException":
1106
- case "com.amazonaws.finspace#AccessDeniedException":
1107
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1108
- case "ConflictException":
1109
- case "com.amazonaws.finspace#ConflictException":
1110
- throw await de_ConflictExceptionRes(parsedOutput, context);
1111
- case "InternalServerException":
1112
- case "com.amazonaws.finspace#InternalServerException":
1113
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1114
- case "LimitExceededException":
1115
- case "com.amazonaws.finspace#LimitExceededException":
1116
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1117
- case "ResourceNotFoundException":
1118
- case "com.amazonaws.finspace#ResourceNotFoundException":
1119
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1120
- case "ThrottlingException":
1121
- case "com.amazonaws.finspace#ThrottlingException":
1122
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1123
- case "ValidationException":
1124
- case "com.amazonaws.finspace#ValidationException":
1125
- throw await de_ValidationExceptionRes(parsedOutput, context);
1126
- default:
1127
- const parsedBody = parsedOutput.body;
1128
- return throwDefaultError({
1129
- output,
1130
- parsedBody,
1131
- errorCode,
1132
- });
1133
- }
1134
- };
1135
873
  export const de_CreateKxUserCommand = async (output, context) => {
1136
874
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1137
- return de_CreateKxUserCommandError(output, context);
875
+ return de_CommandError(output, context);
1138
876
  }
1139
877
  const contents = map({
1140
878
  $metadata: deserializeMetadata(output),
@@ -1149,49 +887,9 @@ export const de_CreateKxUserCommand = async (output, context) => {
1149
887
  Object.assign(contents, doc);
1150
888
  return contents;
1151
889
  };
1152
- const de_CreateKxUserCommandError = async (output, context) => {
1153
- const parsedOutput = {
1154
- ...output,
1155
- body: await parseErrorBody(output.body, context),
1156
- };
1157
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1158
- switch (errorCode) {
1159
- case "AccessDeniedException":
1160
- case "com.amazonaws.finspace#AccessDeniedException":
1161
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1162
- case "ConflictException":
1163
- case "com.amazonaws.finspace#ConflictException":
1164
- throw await de_ConflictExceptionRes(parsedOutput, context);
1165
- case "InternalServerException":
1166
- case "com.amazonaws.finspace#InternalServerException":
1167
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1168
- case "LimitExceededException":
1169
- case "com.amazonaws.finspace#LimitExceededException":
1170
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1171
- case "ResourceAlreadyExistsException":
1172
- case "com.amazonaws.finspace#ResourceAlreadyExistsException":
1173
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
1174
- case "ResourceNotFoundException":
1175
- case "com.amazonaws.finspace#ResourceNotFoundException":
1176
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1177
- case "ThrottlingException":
1178
- case "com.amazonaws.finspace#ThrottlingException":
1179
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1180
- case "ValidationException":
1181
- case "com.amazonaws.finspace#ValidationException":
1182
- throw await de_ValidationExceptionRes(parsedOutput, context);
1183
- default:
1184
- const parsedBody = parsedOutput.body;
1185
- return throwDefaultError({
1186
- output,
1187
- parsedBody,
1188
- errorCode,
1189
- });
1190
- }
1191
- };
1192
890
  export const de_CreateKxVolumeCommand = async (output, context) => {
1193
891
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1194
- return de_CreateKxVolumeCommandError(output, context);
892
+ return de_CommandError(output, context);
1195
893
  }
1196
894
  const contents = map({
1197
895
  $metadata: deserializeMetadata(output),
@@ -1213,49 +911,9 @@ export const de_CreateKxVolumeCommand = async (output, context) => {
1213
911
  Object.assign(contents, doc);
1214
912
  return contents;
1215
913
  };
1216
- const de_CreateKxVolumeCommandError = async (output, context) => {
1217
- const parsedOutput = {
1218
- ...output,
1219
- body: await parseErrorBody(output.body, context),
1220
- };
1221
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1222
- switch (errorCode) {
1223
- case "AccessDeniedException":
1224
- case "com.amazonaws.finspace#AccessDeniedException":
1225
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1226
- case "ConflictException":
1227
- case "com.amazonaws.finspace#ConflictException":
1228
- throw await de_ConflictExceptionRes(parsedOutput, context);
1229
- case "InternalServerException":
1230
- case "com.amazonaws.finspace#InternalServerException":
1231
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1232
- case "LimitExceededException":
1233
- case "com.amazonaws.finspace#LimitExceededException":
1234
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1235
- case "ResourceAlreadyExistsException":
1236
- case "com.amazonaws.finspace#ResourceAlreadyExistsException":
1237
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
1238
- case "ResourceNotFoundException":
1239
- case "com.amazonaws.finspace#ResourceNotFoundException":
1240
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1241
- case "ThrottlingException":
1242
- case "com.amazonaws.finspace#ThrottlingException":
1243
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1244
- case "ValidationException":
1245
- case "com.amazonaws.finspace#ValidationException":
1246
- throw await de_ValidationExceptionRes(parsedOutput, context);
1247
- default:
1248
- const parsedBody = parsedOutput.body;
1249
- return throwDefaultError({
1250
- output,
1251
- parsedBody,
1252
- errorCode,
1253
- });
1254
- }
1255
- };
1256
914
  export const de_DeleteEnvironmentCommand = async (output, context) => {
1257
915
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1258
- return de_DeleteEnvironmentCommandError(output, context);
916
+ return de_CommandError(output, context);
1259
917
  }
1260
918
  const contents = map({
1261
919
  $metadata: deserializeMetadata(output),
@@ -1263,40 +921,9 @@ export const de_DeleteEnvironmentCommand = async (output, context) => {
1263
921
  await collectBody(output.body, context);
1264
922
  return contents;
1265
923
  };
1266
- const de_DeleteEnvironmentCommandError = async (output, context) => {
1267
- const parsedOutput = {
1268
- ...output,
1269
- body: await parseErrorBody(output.body, context),
1270
- };
1271
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1272
- switch (errorCode) {
1273
- case "AccessDeniedException":
1274
- case "com.amazonaws.finspace#AccessDeniedException":
1275
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1276
- case "InternalServerException":
1277
- case "com.amazonaws.finspace#InternalServerException":
1278
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1279
- case "ResourceNotFoundException":
1280
- case "com.amazonaws.finspace#ResourceNotFoundException":
1281
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1282
- case "ThrottlingException":
1283
- case "com.amazonaws.finspace#ThrottlingException":
1284
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1285
- case "ValidationException":
1286
- case "com.amazonaws.finspace#ValidationException":
1287
- throw await de_ValidationExceptionRes(parsedOutput, context);
1288
- default:
1289
- const parsedBody = parsedOutput.body;
1290
- return throwDefaultError({
1291
- output,
1292
- parsedBody,
1293
- errorCode,
1294
- });
1295
- }
1296
- };
1297
924
  export const de_DeleteKxClusterCommand = async (output, context) => {
1298
925
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1299
- return de_DeleteKxClusterCommandError(output, context);
926
+ return de_CommandError(output, context);
1300
927
  }
1301
928
  const contents = map({
1302
929
  $metadata: deserializeMetadata(output),
@@ -1304,46 +931,9 @@ export const de_DeleteKxClusterCommand = async (output, context) => {
1304
931
  await collectBody(output.body, context);
1305
932
  return contents;
1306
933
  };
1307
- const de_DeleteKxClusterCommandError = async (output, context) => {
1308
- const parsedOutput = {
1309
- ...output,
1310
- body: await parseErrorBody(output.body, context),
1311
- };
1312
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1313
- switch (errorCode) {
1314
- case "AccessDeniedException":
1315
- case "com.amazonaws.finspace#AccessDeniedException":
1316
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1317
- case "ConflictException":
1318
- case "com.amazonaws.finspace#ConflictException":
1319
- throw await de_ConflictExceptionRes(parsedOutput, context);
1320
- case "InternalServerException":
1321
- case "com.amazonaws.finspace#InternalServerException":
1322
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1323
- case "LimitExceededException":
1324
- case "com.amazonaws.finspace#LimitExceededException":
1325
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1326
- case "ResourceNotFoundException":
1327
- case "com.amazonaws.finspace#ResourceNotFoundException":
1328
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1329
- case "ThrottlingException":
1330
- case "com.amazonaws.finspace#ThrottlingException":
1331
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1332
- case "ValidationException":
1333
- case "com.amazonaws.finspace#ValidationException":
1334
- throw await de_ValidationExceptionRes(parsedOutput, context);
1335
- default:
1336
- const parsedBody = parsedOutput.body;
1337
- return throwDefaultError({
1338
- output,
1339
- parsedBody,
1340
- errorCode,
1341
- });
1342
- }
1343
- };
1344
934
  export const de_DeleteKxDatabaseCommand = async (output, context) => {
1345
935
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1346
- return de_DeleteKxDatabaseCommandError(output, context);
936
+ return de_CommandError(output, context);
1347
937
  }
1348
938
  const contents = map({
1349
939
  $metadata: deserializeMetadata(output),
@@ -1351,43 +941,9 @@ export const de_DeleteKxDatabaseCommand = async (output, context) => {
1351
941
  await collectBody(output.body, context);
1352
942
  return contents;
1353
943
  };
1354
- const de_DeleteKxDatabaseCommandError = async (output, context) => {
1355
- const parsedOutput = {
1356
- ...output,
1357
- body: await parseErrorBody(output.body, context),
1358
- };
1359
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1360
- switch (errorCode) {
1361
- case "AccessDeniedException":
1362
- case "com.amazonaws.finspace#AccessDeniedException":
1363
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1364
- case "ConflictException":
1365
- case "com.amazonaws.finspace#ConflictException":
1366
- throw await de_ConflictExceptionRes(parsedOutput, context);
1367
- case "InternalServerException":
1368
- case "com.amazonaws.finspace#InternalServerException":
1369
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1370
- case "ResourceNotFoundException":
1371
- case "com.amazonaws.finspace#ResourceNotFoundException":
1372
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1373
- case "ThrottlingException":
1374
- case "com.amazonaws.finspace#ThrottlingException":
1375
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1376
- case "ValidationException":
1377
- case "com.amazonaws.finspace#ValidationException":
1378
- throw await de_ValidationExceptionRes(parsedOutput, context);
1379
- default:
1380
- const parsedBody = parsedOutput.body;
1381
- return throwDefaultError({
1382
- output,
1383
- parsedBody,
1384
- errorCode,
1385
- });
1386
- }
1387
- };
1388
944
  export const de_DeleteKxDataviewCommand = async (output, context) => {
1389
945
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1390
- return de_DeleteKxDataviewCommandError(output, context);
946
+ return de_CommandError(output, context);
1391
947
  }
1392
948
  const contents = map({
1393
949
  $metadata: deserializeMetadata(output),
@@ -1395,43 +951,19 @@ export const de_DeleteKxDataviewCommand = async (output, context) => {
1395
951
  await collectBody(output.body, context);
1396
952
  return contents;
1397
953
  };
1398
- const de_DeleteKxDataviewCommandError = async (output, context) => {
1399
- const parsedOutput = {
1400
- ...output,
1401
- body: await parseErrorBody(output.body, context),
1402
- };
1403
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1404
- switch (errorCode) {
1405
- case "AccessDeniedException":
1406
- case "com.amazonaws.finspace#AccessDeniedException":
1407
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1408
- case "ConflictException":
1409
- case "com.amazonaws.finspace#ConflictException":
1410
- throw await de_ConflictExceptionRes(parsedOutput, context);
1411
- case "InternalServerException":
1412
- case "com.amazonaws.finspace#InternalServerException":
1413
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1414
- case "ResourceNotFoundException":
1415
- case "com.amazonaws.finspace#ResourceNotFoundException":
1416
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1417
- case "ThrottlingException":
1418
- case "com.amazonaws.finspace#ThrottlingException":
1419
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1420
- case "ValidationException":
1421
- case "com.amazonaws.finspace#ValidationException":
1422
- throw await de_ValidationExceptionRes(parsedOutput, context);
1423
- default:
1424
- const parsedBody = parsedOutput.body;
1425
- return throwDefaultError({
1426
- output,
1427
- parsedBody,
1428
- errorCode,
1429
- });
954
+ export const de_DeleteKxEnvironmentCommand = async (output, context) => {
955
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
956
+ return de_CommandError(output, context);
1430
957
  }
958
+ const contents = map({
959
+ $metadata: deserializeMetadata(output),
960
+ });
961
+ await collectBody(output.body, context);
962
+ return contents;
1431
963
  };
1432
- export const de_DeleteKxEnvironmentCommand = async (output, context) => {
964
+ export const de_DeleteKxScalingGroupCommand = async (output, context) => {
1433
965
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1434
- return de_DeleteKxEnvironmentCommandError(output, context);
966
+ return de_CommandError(output, context);
1435
967
  }
1436
968
  const contents = map({
1437
969
  $metadata: deserializeMetadata(output),
@@ -1439,43 +971,19 @@ export const de_DeleteKxEnvironmentCommand = async (output, context) => {
1439
971
  await collectBody(output.body, context);
1440
972
  return contents;
1441
973
  };
1442
- const de_DeleteKxEnvironmentCommandError = async (output, context) => {
1443
- const parsedOutput = {
1444
- ...output,
1445
- body: await parseErrorBody(output.body, context),
1446
- };
1447
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1448
- switch (errorCode) {
1449
- case "AccessDeniedException":
1450
- case "com.amazonaws.finspace#AccessDeniedException":
1451
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1452
- case "ConflictException":
1453
- case "com.amazonaws.finspace#ConflictException":
1454
- throw await de_ConflictExceptionRes(parsedOutput, context);
1455
- case "InternalServerException":
1456
- case "com.amazonaws.finspace#InternalServerException":
1457
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1458
- case "ResourceNotFoundException":
1459
- case "com.amazonaws.finspace#ResourceNotFoundException":
1460
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1461
- case "ThrottlingException":
1462
- case "com.amazonaws.finspace#ThrottlingException":
1463
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1464
- case "ValidationException":
1465
- case "com.amazonaws.finspace#ValidationException":
1466
- throw await de_ValidationExceptionRes(parsedOutput, context);
1467
- default:
1468
- const parsedBody = parsedOutput.body;
1469
- return throwDefaultError({
1470
- output,
1471
- parsedBody,
1472
- errorCode,
1473
- });
974
+ export const de_DeleteKxUserCommand = async (output, context) => {
975
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
976
+ return de_CommandError(output, context);
1474
977
  }
978
+ const contents = map({
979
+ $metadata: deserializeMetadata(output),
980
+ });
981
+ await collectBody(output.body, context);
982
+ return contents;
1475
983
  };
1476
- export const de_DeleteKxScalingGroupCommand = async (output, context) => {
984
+ export const de_DeleteKxVolumeCommand = async (output, context) => {
1477
985
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1478
- return de_DeleteKxScalingGroupCommandError(output, context);
986
+ return de_CommandError(output, context);
1479
987
  }
1480
988
  const contents = map({
1481
989
  $metadata: deserializeMetadata(output),
@@ -1483,137 +991,9 @@ export const de_DeleteKxScalingGroupCommand = async (output, context) => {
1483
991
  await collectBody(output.body, context);
1484
992
  return contents;
1485
993
  };
1486
- const de_DeleteKxScalingGroupCommandError = async (output, context) => {
1487
- const parsedOutput = {
1488
- ...output,
1489
- body: await parseErrorBody(output.body, context),
1490
- };
1491
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1492
- switch (errorCode) {
1493
- case "AccessDeniedException":
1494
- case "com.amazonaws.finspace#AccessDeniedException":
1495
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1496
- case "ConflictException":
1497
- case "com.amazonaws.finspace#ConflictException":
1498
- throw await de_ConflictExceptionRes(parsedOutput, context);
1499
- case "InternalServerException":
1500
- case "com.amazonaws.finspace#InternalServerException":
1501
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1502
- case "LimitExceededException":
1503
- case "com.amazonaws.finspace#LimitExceededException":
1504
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1505
- case "ResourceNotFoundException":
1506
- case "com.amazonaws.finspace#ResourceNotFoundException":
1507
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1508
- case "ThrottlingException":
1509
- case "com.amazonaws.finspace#ThrottlingException":
1510
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1511
- case "ValidationException":
1512
- case "com.amazonaws.finspace#ValidationException":
1513
- throw await de_ValidationExceptionRes(parsedOutput, context);
1514
- default:
1515
- const parsedBody = parsedOutput.body;
1516
- return throwDefaultError({
1517
- output,
1518
- parsedBody,
1519
- errorCode,
1520
- });
1521
- }
1522
- };
1523
- export const de_DeleteKxUserCommand = async (output, context) => {
1524
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1525
- return de_DeleteKxUserCommandError(output, context);
1526
- }
1527
- const contents = map({
1528
- $metadata: deserializeMetadata(output),
1529
- });
1530
- await collectBody(output.body, context);
1531
- return contents;
1532
- };
1533
- const de_DeleteKxUserCommandError = async (output, context) => {
1534
- const parsedOutput = {
1535
- ...output,
1536
- body: await parseErrorBody(output.body, context),
1537
- };
1538
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1539
- switch (errorCode) {
1540
- case "AccessDeniedException":
1541
- case "com.amazonaws.finspace#AccessDeniedException":
1542
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1543
- case "ConflictException":
1544
- case "com.amazonaws.finspace#ConflictException":
1545
- throw await de_ConflictExceptionRes(parsedOutput, context);
1546
- case "InternalServerException":
1547
- case "com.amazonaws.finspace#InternalServerException":
1548
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1549
- case "ResourceNotFoundException":
1550
- case "com.amazonaws.finspace#ResourceNotFoundException":
1551
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1552
- case "ThrottlingException":
1553
- case "com.amazonaws.finspace#ThrottlingException":
1554
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1555
- case "ValidationException":
1556
- case "com.amazonaws.finspace#ValidationException":
1557
- throw await de_ValidationExceptionRes(parsedOutput, context);
1558
- default:
1559
- const parsedBody = parsedOutput.body;
1560
- return throwDefaultError({
1561
- output,
1562
- parsedBody,
1563
- errorCode,
1564
- });
1565
- }
1566
- };
1567
- export const de_DeleteKxVolumeCommand = async (output, context) => {
1568
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1569
- return de_DeleteKxVolumeCommandError(output, context);
1570
- }
1571
- const contents = map({
1572
- $metadata: deserializeMetadata(output),
1573
- });
1574
- await collectBody(output.body, context);
1575
- return contents;
1576
- };
1577
- const de_DeleteKxVolumeCommandError = async (output, context) => {
1578
- const parsedOutput = {
1579
- ...output,
1580
- body: await parseErrorBody(output.body, context),
1581
- };
1582
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1583
- switch (errorCode) {
1584
- case "AccessDeniedException":
1585
- case "com.amazonaws.finspace#AccessDeniedException":
1586
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1587
- case "ConflictException":
1588
- case "com.amazonaws.finspace#ConflictException":
1589
- throw await de_ConflictExceptionRes(parsedOutput, context);
1590
- case "InternalServerException":
1591
- case "com.amazonaws.finspace#InternalServerException":
1592
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1593
- case "LimitExceededException":
1594
- case "com.amazonaws.finspace#LimitExceededException":
1595
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1596
- case "ResourceNotFoundException":
1597
- case "com.amazonaws.finspace#ResourceNotFoundException":
1598
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1599
- case "ThrottlingException":
1600
- case "com.amazonaws.finspace#ThrottlingException":
1601
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1602
- case "ValidationException":
1603
- case "com.amazonaws.finspace#ValidationException":
1604
- throw await de_ValidationExceptionRes(parsedOutput, context);
1605
- default:
1606
- const parsedBody = parsedOutput.body;
1607
- return throwDefaultError({
1608
- output,
1609
- parsedBody,
1610
- errorCode,
1611
- });
1612
- }
1613
- };
1614
994
  export const de_GetEnvironmentCommand = async (output, context) => {
1615
995
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1616
- return de_GetEnvironmentCommandError(output, context);
996
+ return de_CommandError(output, context);
1617
997
  }
1618
998
  const contents = map({
1619
999
  $metadata: deserializeMetadata(output),
@@ -1625,37 +1005,9 @@ export const de_GetEnvironmentCommand = async (output, context) => {
1625
1005
  Object.assign(contents, doc);
1626
1006
  return contents;
1627
1007
  };
1628
- const de_GetEnvironmentCommandError = async (output, context) => {
1629
- const parsedOutput = {
1630
- ...output,
1631
- body: await parseErrorBody(output.body, context),
1632
- };
1633
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1634
- switch (errorCode) {
1635
- case "AccessDeniedException":
1636
- case "com.amazonaws.finspace#AccessDeniedException":
1637
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1638
- case "InternalServerException":
1639
- case "com.amazonaws.finspace#InternalServerException":
1640
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1641
- case "ResourceNotFoundException":
1642
- case "com.amazonaws.finspace#ResourceNotFoundException":
1643
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1644
- case "ValidationException":
1645
- case "com.amazonaws.finspace#ValidationException":
1646
- throw await de_ValidationExceptionRes(parsedOutput, context);
1647
- default:
1648
- const parsedBody = parsedOutput.body;
1649
- return throwDefaultError({
1650
- output,
1651
- parsedBody,
1652
- errorCode,
1653
- });
1654
- }
1655
- };
1656
1008
  export const de_GetKxChangesetCommand = async (output, context) => {
1657
1009
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1658
- return de_GetKxChangesetCommandError(output, context);
1010
+ return de_CommandError(output, context);
1659
1011
  }
1660
1012
  const contents = map({
1661
1013
  $metadata: deserializeMetadata(output),
@@ -1675,40 +1027,9 @@ export const de_GetKxChangesetCommand = async (output, context) => {
1675
1027
  Object.assign(contents, doc);
1676
1028
  return contents;
1677
1029
  };
1678
- const de_GetKxChangesetCommandError = async (output, context) => {
1679
- const parsedOutput = {
1680
- ...output,
1681
- body: await parseErrorBody(output.body, context),
1682
- };
1683
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1684
- switch (errorCode) {
1685
- case "AccessDeniedException":
1686
- case "com.amazonaws.finspace#AccessDeniedException":
1687
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1688
- case "InternalServerException":
1689
- case "com.amazonaws.finspace#InternalServerException":
1690
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1691
- case "ResourceNotFoundException":
1692
- case "com.amazonaws.finspace#ResourceNotFoundException":
1693
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1694
- case "ThrottlingException":
1695
- case "com.amazonaws.finspace#ThrottlingException":
1696
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1697
- case "ValidationException":
1698
- case "com.amazonaws.finspace#ValidationException":
1699
- throw await de_ValidationExceptionRes(parsedOutput, context);
1700
- default:
1701
- const parsedBody = parsedOutput.body;
1702
- return throwDefaultError({
1703
- output,
1704
- parsedBody,
1705
- errorCode,
1706
- });
1707
- }
1708
- };
1709
1030
  export const de_GetKxClusterCommand = async (output, context) => {
1710
1031
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1711
- return de_GetKxClusterCommandError(output, context);
1032
+ return de_CommandError(output, context);
1712
1033
  }
1713
1034
  const contents = map({
1714
1035
  $metadata: deserializeMetadata(output),
@@ -1742,46 +1063,9 @@ export const de_GetKxClusterCommand = async (output, context) => {
1742
1063
  Object.assign(contents, doc);
1743
1064
  return contents;
1744
1065
  };
1745
- const de_GetKxClusterCommandError = async (output, context) => {
1746
- const parsedOutput = {
1747
- ...output,
1748
- body: await parseErrorBody(output.body, context),
1749
- };
1750
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1751
- switch (errorCode) {
1752
- case "AccessDeniedException":
1753
- case "com.amazonaws.finspace#AccessDeniedException":
1754
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1755
- case "ConflictException":
1756
- case "com.amazonaws.finspace#ConflictException":
1757
- throw await de_ConflictExceptionRes(parsedOutput, context);
1758
- case "InternalServerException":
1759
- case "com.amazonaws.finspace#InternalServerException":
1760
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1761
- case "LimitExceededException":
1762
- case "com.amazonaws.finspace#LimitExceededException":
1763
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
1764
- case "ResourceNotFoundException":
1765
- case "com.amazonaws.finspace#ResourceNotFoundException":
1766
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1767
- case "ThrottlingException":
1768
- case "com.amazonaws.finspace#ThrottlingException":
1769
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1770
- case "ValidationException":
1771
- case "com.amazonaws.finspace#ValidationException":
1772
- throw await de_ValidationExceptionRes(parsedOutput, context);
1773
- default:
1774
- const parsedBody = parsedOutput.body;
1775
- return throwDefaultError({
1776
- output,
1777
- parsedBody,
1778
- errorCode,
1779
- });
1780
- }
1781
- };
1782
1066
  export const de_GetKxConnectionStringCommand = async (output, context) => {
1783
1067
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1784
- return de_GetKxConnectionStringCommandError(output, context);
1068
+ return de_CommandError(output, context);
1785
1069
  }
1786
1070
  const contents = map({
1787
1071
  $metadata: deserializeMetadata(output),
@@ -1793,40 +1077,9 @@ export const de_GetKxConnectionStringCommand = async (output, context) => {
1793
1077
  Object.assign(contents, doc);
1794
1078
  return contents;
1795
1079
  };
1796
- const de_GetKxConnectionStringCommandError = async (output, context) => {
1797
- const parsedOutput = {
1798
- ...output,
1799
- body: await parseErrorBody(output.body, context),
1800
- };
1801
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1802
- switch (errorCode) {
1803
- case "AccessDeniedException":
1804
- case "com.amazonaws.finspace#AccessDeniedException":
1805
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1806
- case "InternalServerException":
1807
- case "com.amazonaws.finspace#InternalServerException":
1808
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1809
- case "ResourceNotFoundException":
1810
- case "com.amazonaws.finspace#ResourceNotFoundException":
1811
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1812
- case "ThrottlingException":
1813
- case "com.amazonaws.finspace#ThrottlingException":
1814
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1815
- case "ValidationException":
1816
- case "com.amazonaws.finspace#ValidationException":
1817
- throw await de_ValidationExceptionRes(parsedOutput, context);
1818
- default:
1819
- const parsedBody = parsedOutput.body;
1820
- return throwDefaultError({
1821
- output,
1822
- parsedBody,
1823
- errorCode,
1824
- });
1825
- }
1826
- };
1827
1080
  export const de_GetKxDatabaseCommand = async (output, context) => {
1828
1081
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1829
- return de_GetKxDatabaseCommandError(output, context);
1082
+ return de_CommandError(output, context);
1830
1083
  }
1831
1084
  const contents = map({
1832
1085
  $metadata: deserializeMetadata(output),
@@ -1847,40 +1100,9 @@ export const de_GetKxDatabaseCommand = async (output, context) => {
1847
1100
  Object.assign(contents, doc);
1848
1101
  return contents;
1849
1102
  };
1850
- const de_GetKxDatabaseCommandError = async (output, context) => {
1851
- const parsedOutput = {
1852
- ...output,
1853
- body: await parseErrorBody(output.body, context),
1854
- };
1855
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1856
- switch (errorCode) {
1857
- case "AccessDeniedException":
1858
- case "com.amazonaws.finspace#AccessDeniedException":
1859
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1860
- case "InternalServerException":
1861
- case "com.amazonaws.finspace#InternalServerException":
1862
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1863
- case "ResourceNotFoundException":
1864
- case "com.amazonaws.finspace#ResourceNotFoundException":
1865
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1866
- case "ThrottlingException":
1867
- case "com.amazonaws.finspace#ThrottlingException":
1868
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1869
- case "ValidationException":
1870
- case "com.amazonaws.finspace#ValidationException":
1871
- throw await de_ValidationExceptionRes(parsedOutput, context);
1872
- default:
1873
- const parsedBody = parsedOutput.body;
1874
- return throwDefaultError({
1875
- output,
1876
- parsedBody,
1877
- errorCode,
1878
- });
1879
- }
1880
- };
1881
1103
  export const de_GetKxDataviewCommand = async (output, context) => {
1882
1104
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1883
- return de_GetKxDataviewCommandError(output, context);
1105
+ return de_CommandError(output, context);
1884
1106
  }
1885
1107
  const contents = map({
1886
1108
  $metadata: deserializeMetadata(output),
@@ -1905,40 +1127,9 @@ export const de_GetKxDataviewCommand = async (output, context) => {
1905
1127
  Object.assign(contents, doc);
1906
1128
  return contents;
1907
1129
  };
1908
- const de_GetKxDataviewCommandError = async (output, context) => {
1909
- const parsedOutput = {
1910
- ...output,
1911
- body: await parseErrorBody(output.body, context),
1912
- };
1913
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1914
- switch (errorCode) {
1915
- case "AccessDeniedException":
1916
- case "com.amazonaws.finspace#AccessDeniedException":
1917
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1918
- case "InternalServerException":
1919
- case "com.amazonaws.finspace#InternalServerException":
1920
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1921
- case "ResourceNotFoundException":
1922
- case "com.amazonaws.finspace#ResourceNotFoundException":
1923
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1924
- case "ThrottlingException":
1925
- case "com.amazonaws.finspace#ThrottlingException":
1926
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1927
- case "ValidationException":
1928
- case "com.amazonaws.finspace#ValidationException":
1929
- throw await de_ValidationExceptionRes(parsedOutput, context);
1930
- default:
1931
- const parsedBody = parsedOutput.body;
1932
- return throwDefaultError({
1933
- output,
1934
- parsedBody,
1935
- errorCode,
1936
- });
1937
- }
1938
- };
1939
1130
  export const de_GetKxEnvironmentCommand = async (output, context) => {
1940
1131
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1941
- return de_GetKxEnvironmentCommandError(output, context);
1132
+ return de_CommandError(output, context);
1942
1133
  }
1943
1134
  const contents = map({
1944
1135
  $metadata: deserializeMetadata(output),
@@ -1966,40 +1157,9 @@ export const de_GetKxEnvironmentCommand = async (output, context) => {
1966
1157
  Object.assign(contents, doc);
1967
1158
  return contents;
1968
1159
  };
1969
- const de_GetKxEnvironmentCommandError = async (output, context) => {
1970
- const parsedOutput = {
1971
- ...output,
1972
- body: await parseErrorBody(output.body, context),
1973
- };
1974
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1975
- switch (errorCode) {
1976
- case "AccessDeniedException":
1977
- case "com.amazonaws.finspace#AccessDeniedException":
1978
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1979
- case "ConflictException":
1980
- case "com.amazonaws.finspace#ConflictException":
1981
- throw await de_ConflictExceptionRes(parsedOutput, context);
1982
- case "InternalServerException":
1983
- case "com.amazonaws.finspace#InternalServerException":
1984
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1985
- case "ResourceNotFoundException":
1986
- case "com.amazonaws.finspace#ResourceNotFoundException":
1987
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1988
- case "ValidationException":
1989
- case "com.amazonaws.finspace#ValidationException":
1990
- throw await de_ValidationExceptionRes(parsedOutput, context);
1991
- default:
1992
- const parsedBody = parsedOutput.body;
1993
- return throwDefaultError({
1994
- output,
1995
- parsedBody,
1996
- errorCode,
1997
- });
1998
- }
1999
- };
2000
1160
  export const de_GetKxScalingGroupCommand = async (output, context) => {
2001
1161
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2002
- return de_GetKxScalingGroupCommandError(output, context);
1162
+ return de_CommandError(output, context);
2003
1163
  }
2004
1164
  const contents = map({
2005
1165
  $metadata: deserializeMetadata(output),
@@ -2019,46 +1179,9 @@ export const de_GetKxScalingGroupCommand = async (output, context) => {
2019
1179
  Object.assign(contents, doc);
2020
1180
  return contents;
2021
1181
  };
2022
- const de_GetKxScalingGroupCommandError = async (output, context) => {
2023
- const parsedOutput = {
2024
- ...output,
2025
- body: await parseErrorBody(output.body, context),
2026
- };
2027
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2028
- switch (errorCode) {
2029
- case "AccessDeniedException":
2030
- case "com.amazonaws.finspace#AccessDeniedException":
2031
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2032
- case "ConflictException":
2033
- case "com.amazonaws.finspace#ConflictException":
2034
- throw await de_ConflictExceptionRes(parsedOutput, context);
2035
- case "InternalServerException":
2036
- case "com.amazonaws.finspace#InternalServerException":
2037
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2038
- case "LimitExceededException":
2039
- case "com.amazonaws.finspace#LimitExceededException":
2040
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2041
- case "ResourceNotFoundException":
2042
- case "com.amazonaws.finspace#ResourceNotFoundException":
2043
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2044
- case "ThrottlingException":
2045
- case "com.amazonaws.finspace#ThrottlingException":
2046
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2047
- case "ValidationException":
2048
- case "com.amazonaws.finspace#ValidationException":
2049
- throw await de_ValidationExceptionRes(parsedOutput, context);
2050
- default:
2051
- const parsedBody = parsedOutput.body;
2052
- return throwDefaultError({
2053
- output,
2054
- parsedBody,
2055
- errorCode,
2056
- });
2057
- }
2058
- };
2059
1182
  export const de_GetKxUserCommand = async (output, context) => {
2060
1183
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2061
- return de_GetKxUserCommandError(output, context);
1184
+ return de_CommandError(output, context);
2062
1185
  }
2063
1186
  const contents = map({
2064
1187
  $metadata: deserializeMetadata(output),
@@ -2073,40 +1196,9 @@ export const de_GetKxUserCommand = async (output, context) => {
2073
1196
  Object.assign(contents, doc);
2074
1197
  return contents;
2075
1198
  };
2076
- const de_GetKxUserCommandError = async (output, context) => {
2077
- const parsedOutput = {
2078
- ...output,
2079
- body: await parseErrorBody(output.body, context),
2080
- };
2081
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2082
- switch (errorCode) {
2083
- case "AccessDeniedException":
2084
- case "com.amazonaws.finspace#AccessDeniedException":
2085
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2086
- case "InternalServerException":
2087
- case "com.amazonaws.finspace#InternalServerException":
2088
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2089
- case "ResourceNotFoundException":
2090
- case "com.amazonaws.finspace#ResourceNotFoundException":
2091
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2092
- case "ThrottlingException":
2093
- case "com.amazonaws.finspace#ThrottlingException":
2094
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2095
- case "ValidationException":
2096
- case "com.amazonaws.finspace#ValidationException":
2097
- throw await de_ValidationExceptionRes(parsedOutput, context);
2098
- default:
2099
- const parsedBody = parsedOutput.body;
2100
- return throwDefaultError({
2101
- output,
2102
- parsedBody,
2103
- errorCode,
2104
- });
2105
- }
2106
- };
2107
1199
  export const de_GetKxVolumeCommand = async (output, context) => {
2108
1200
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2109
- return de_GetKxVolumeCommandError(output, context);
1201
+ return de_CommandError(output, context);
2110
1202
  }
2111
1203
  const contents = map({
2112
1204
  $metadata: deserializeMetadata(output),
@@ -2130,46 +1222,9 @@ export const de_GetKxVolumeCommand = async (output, context) => {
2130
1222
  Object.assign(contents, doc);
2131
1223
  return contents;
2132
1224
  };
2133
- const de_GetKxVolumeCommandError = async (output, context) => {
2134
- const parsedOutput = {
2135
- ...output,
2136
- body: await parseErrorBody(output.body, context),
2137
- };
2138
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2139
- switch (errorCode) {
2140
- case "AccessDeniedException":
2141
- case "com.amazonaws.finspace#AccessDeniedException":
2142
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2143
- case "ConflictException":
2144
- case "com.amazonaws.finspace#ConflictException":
2145
- throw await de_ConflictExceptionRes(parsedOutput, context);
2146
- case "InternalServerException":
2147
- case "com.amazonaws.finspace#InternalServerException":
2148
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2149
- case "LimitExceededException":
2150
- case "com.amazonaws.finspace#LimitExceededException":
2151
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2152
- case "ResourceNotFoundException":
2153
- case "com.amazonaws.finspace#ResourceNotFoundException":
2154
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2155
- case "ThrottlingException":
2156
- case "com.amazonaws.finspace#ThrottlingException":
2157
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2158
- case "ValidationException":
2159
- case "com.amazonaws.finspace#ValidationException":
2160
- throw await de_ValidationExceptionRes(parsedOutput, context);
2161
- default:
2162
- const parsedBody = parsedOutput.body;
2163
- return throwDefaultError({
2164
- output,
2165
- parsedBody,
2166
- errorCode,
2167
- });
2168
- }
2169
- };
2170
1225
  export const de_ListEnvironmentsCommand = async (output, context) => {
2171
1226
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2172
- return de_ListEnvironmentsCommandError(output, context);
1227
+ return de_CommandError(output, context);
2173
1228
  }
2174
1229
  const contents = map({
2175
1230
  $metadata: deserializeMetadata(output),
@@ -2182,34 +1237,9 @@ export const de_ListEnvironmentsCommand = async (output, context) => {
2182
1237
  Object.assign(contents, doc);
2183
1238
  return contents;
2184
1239
  };
2185
- const de_ListEnvironmentsCommandError = async (output, context) => {
2186
- const parsedOutput = {
2187
- ...output,
2188
- body: await parseErrorBody(output.body, context),
2189
- };
2190
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2191
- switch (errorCode) {
2192
- case "AccessDeniedException":
2193
- case "com.amazonaws.finspace#AccessDeniedException":
2194
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2195
- case "InternalServerException":
2196
- case "com.amazonaws.finspace#InternalServerException":
2197
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2198
- case "ValidationException":
2199
- case "com.amazonaws.finspace#ValidationException":
2200
- throw await de_ValidationExceptionRes(parsedOutput, context);
2201
- default:
2202
- const parsedBody = parsedOutput.body;
2203
- return throwDefaultError({
2204
- output,
2205
- parsedBody,
2206
- errorCode,
2207
- });
2208
- }
2209
- };
2210
1240
  export const de_ListKxChangesetsCommand = async (output, context) => {
2211
1241
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2212
- return de_ListKxChangesetsCommandError(output, context);
1242
+ return de_CommandError(output, context);
2213
1243
  }
2214
1244
  const contents = map({
2215
1245
  $metadata: deserializeMetadata(output),
@@ -2222,40 +1252,9 @@ export const de_ListKxChangesetsCommand = async (output, context) => {
2222
1252
  Object.assign(contents, doc);
2223
1253
  return contents;
2224
1254
  };
2225
- const de_ListKxChangesetsCommandError = async (output, context) => {
2226
- const parsedOutput = {
2227
- ...output,
2228
- body: await parseErrorBody(output.body, context),
2229
- };
2230
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2231
- switch (errorCode) {
2232
- case "AccessDeniedException":
2233
- case "com.amazonaws.finspace#AccessDeniedException":
2234
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2235
- case "InternalServerException":
2236
- case "com.amazonaws.finspace#InternalServerException":
2237
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2238
- case "ResourceNotFoundException":
2239
- case "com.amazonaws.finspace#ResourceNotFoundException":
2240
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2241
- case "ThrottlingException":
2242
- case "com.amazonaws.finspace#ThrottlingException":
2243
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2244
- case "ValidationException":
2245
- case "com.amazonaws.finspace#ValidationException":
2246
- throw await de_ValidationExceptionRes(parsedOutput, context);
2247
- default:
2248
- const parsedBody = parsedOutput.body;
2249
- return throwDefaultError({
2250
- output,
2251
- parsedBody,
2252
- errorCode,
2253
- });
2254
- }
2255
- };
2256
1255
  export const de_ListKxClusterNodesCommand = async (output, context) => {
2257
1256
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2258
- return de_ListKxClusterNodesCommandError(output, context);
1257
+ return de_CommandError(output, context);
2259
1258
  }
2260
1259
  const contents = map({
2261
1260
  $metadata: deserializeMetadata(output),
@@ -2268,43 +1267,9 @@ export const de_ListKxClusterNodesCommand = async (output, context) => {
2268
1267
  Object.assign(contents, doc);
2269
1268
  return contents;
2270
1269
  };
2271
- const de_ListKxClusterNodesCommandError = async (output, context) => {
2272
- const parsedOutput = {
2273
- ...output,
2274
- body: await parseErrorBody(output.body, context),
2275
- };
2276
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2277
- switch (errorCode) {
2278
- case "AccessDeniedException":
2279
- case "com.amazonaws.finspace#AccessDeniedException":
2280
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2281
- case "InternalServerException":
2282
- case "com.amazonaws.finspace#InternalServerException":
2283
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2284
- case "LimitExceededException":
2285
- case "com.amazonaws.finspace#LimitExceededException":
2286
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2287
- case "ResourceNotFoundException":
2288
- case "com.amazonaws.finspace#ResourceNotFoundException":
2289
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2290
- case "ThrottlingException":
2291
- case "com.amazonaws.finspace#ThrottlingException":
2292
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2293
- case "ValidationException":
2294
- case "com.amazonaws.finspace#ValidationException":
2295
- throw await de_ValidationExceptionRes(parsedOutput, context);
2296
- default:
2297
- const parsedBody = parsedOutput.body;
2298
- return throwDefaultError({
2299
- output,
2300
- parsedBody,
2301
- errorCode,
2302
- });
2303
- }
2304
- };
2305
1270
  export const de_ListKxClustersCommand = async (output, context) => {
2306
1271
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2307
- return de_ListKxClustersCommandError(output, context);
1272
+ return de_CommandError(output, context);
2308
1273
  }
2309
1274
  const contents = map({
2310
1275
  $metadata: deserializeMetadata(output),
@@ -2317,46 +1282,9 @@ export const de_ListKxClustersCommand = async (output, context) => {
2317
1282
  Object.assign(contents, doc);
2318
1283
  return contents;
2319
1284
  };
2320
- const de_ListKxClustersCommandError = async (output, context) => {
2321
- const parsedOutput = {
2322
- ...output,
2323
- body: await parseErrorBody(output.body, context),
2324
- };
2325
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2326
- switch (errorCode) {
2327
- case "AccessDeniedException":
2328
- case "com.amazonaws.finspace#AccessDeniedException":
2329
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2330
- case "ConflictException":
2331
- case "com.amazonaws.finspace#ConflictException":
2332
- throw await de_ConflictExceptionRes(parsedOutput, context);
2333
- case "InternalServerException":
2334
- case "com.amazonaws.finspace#InternalServerException":
2335
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2336
- case "LimitExceededException":
2337
- case "com.amazonaws.finspace#LimitExceededException":
2338
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2339
- case "ResourceNotFoundException":
2340
- case "com.amazonaws.finspace#ResourceNotFoundException":
2341
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2342
- case "ThrottlingException":
2343
- case "com.amazonaws.finspace#ThrottlingException":
2344
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2345
- case "ValidationException":
2346
- case "com.amazonaws.finspace#ValidationException":
2347
- throw await de_ValidationExceptionRes(parsedOutput, context);
2348
- default:
2349
- const parsedBody = parsedOutput.body;
2350
- return throwDefaultError({
2351
- output,
2352
- parsedBody,
2353
- errorCode,
2354
- });
2355
- }
2356
- };
2357
1285
  export const de_ListKxDatabasesCommand = async (output, context) => {
2358
1286
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2359
- return de_ListKxDatabasesCommandError(output, context);
1287
+ return de_CommandError(output, context);
2360
1288
  }
2361
1289
  const contents = map({
2362
1290
  $metadata: deserializeMetadata(output),
@@ -2369,40 +1297,9 @@ export const de_ListKxDatabasesCommand = async (output, context) => {
2369
1297
  Object.assign(contents, doc);
2370
1298
  return contents;
2371
1299
  };
2372
- const de_ListKxDatabasesCommandError = async (output, context) => {
2373
- const parsedOutput = {
2374
- ...output,
2375
- body: await parseErrorBody(output.body, context),
2376
- };
2377
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2378
- switch (errorCode) {
2379
- case "AccessDeniedException":
2380
- case "com.amazonaws.finspace#AccessDeniedException":
2381
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2382
- case "InternalServerException":
2383
- case "com.amazonaws.finspace#InternalServerException":
2384
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2385
- case "ResourceNotFoundException":
2386
- case "com.amazonaws.finspace#ResourceNotFoundException":
2387
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2388
- case "ThrottlingException":
2389
- case "com.amazonaws.finspace#ThrottlingException":
2390
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2391
- case "ValidationException":
2392
- case "com.amazonaws.finspace#ValidationException":
2393
- throw await de_ValidationExceptionRes(parsedOutput, context);
2394
- default:
2395
- const parsedBody = parsedOutput.body;
2396
- return throwDefaultError({
2397
- output,
2398
- parsedBody,
2399
- errorCode,
2400
- });
2401
- }
2402
- };
2403
1300
  export const de_ListKxDataviewsCommand = async (output, context) => {
2404
1301
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2405
- return de_ListKxDataviewsCommandError(output, context);
1302
+ return de_CommandError(output, context);
2406
1303
  }
2407
1304
  const contents = map({
2408
1305
  $metadata: deserializeMetadata(output),
@@ -2415,40 +1312,9 @@ export const de_ListKxDataviewsCommand = async (output, context) => {
2415
1312
  Object.assign(contents, doc);
2416
1313
  return contents;
2417
1314
  };
2418
- const de_ListKxDataviewsCommandError = async (output, context) => {
2419
- const parsedOutput = {
2420
- ...output,
2421
- body: await parseErrorBody(output.body, context),
2422
- };
2423
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2424
- switch (errorCode) {
2425
- case "AccessDeniedException":
2426
- case "com.amazonaws.finspace#AccessDeniedException":
2427
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2428
- case "InternalServerException":
2429
- case "com.amazonaws.finspace#InternalServerException":
2430
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2431
- case "ResourceNotFoundException":
2432
- case "com.amazonaws.finspace#ResourceNotFoundException":
2433
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2434
- case "ThrottlingException":
2435
- case "com.amazonaws.finspace#ThrottlingException":
2436
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2437
- case "ValidationException":
2438
- case "com.amazonaws.finspace#ValidationException":
2439
- throw await de_ValidationExceptionRes(parsedOutput, context);
2440
- default:
2441
- const parsedBody = parsedOutput.body;
2442
- return throwDefaultError({
2443
- output,
2444
- parsedBody,
2445
- errorCode,
2446
- });
2447
- }
2448
- };
2449
1315
  export const de_ListKxEnvironmentsCommand = async (output, context) => {
2450
1316
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2451
- return de_ListKxEnvironmentsCommandError(output, context);
1317
+ return de_CommandError(output, context);
2452
1318
  }
2453
1319
  const contents = map({
2454
1320
  $metadata: deserializeMetadata(output),
@@ -2461,34 +1327,9 @@ export const de_ListKxEnvironmentsCommand = async (output, context) => {
2461
1327
  Object.assign(contents, doc);
2462
1328
  return contents;
2463
1329
  };
2464
- const de_ListKxEnvironmentsCommandError = async (output, context) => {
2465
- const parsedOutput = {
2466
- ...output,
2467
- body: await parseErrorBody(output.body, context),
2468
- };
2469
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2470
- switch (errorCode) {
2471
- case "AccessDeniedException":
2472
- case "com.amazonaws.finspace#AccessDeniedException":
2473
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2474
- case "InternalServerException":
2475
- case "com.amazonaws.finspace#InternalServerException":
2476
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2477
- case "ValidationException":
2478
- case "com.amazonaws.finspace#ValidationException":
2479
- throw await de_ValidationExceptionRes(parsedOutput, context);
2480
- default:
2481
- const parsedBody = parsedOutput.body;
2482
- return throwDefaultError({
2483
- output,
2484
- parsedBody,
2485
- errorCode,
2486
- });
2487
- }
2488
- };
2489
1330
  export const de_ListKxScalingGroupsCommand = async (output, context) => {
2490
1331
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2491
- return de_ListKxScalingGroupsCommandError(output, context);
1332
+ return de_CommandError(output, context);
2492
1333
  }
2493
1334
  const contents = map({
2494
1335
  $metadata: deserializeMetadata(output),
@@ -2501,46 +1342,9 @@ export const de_ListKxScalingGroupsCommand = async (output, context) => {
2501
1342
  Object.assign(contents, doc);
2502
1343
  return contents;
2503
1344
  };
2504
- const de_ListKxScalingGroupsCommandError = async (output, context) => {
2505
- const parsedOutput = {
2506
- ...output,
2507
- body: await parseErrorBody(output.body, context),
2508
- };
2509
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2510
- switch (errorCode) {
2511
- case "AccessDeniedException":
2512
- case "com.amazonaws.finspace#AccessDeniedException":
2513
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2514
- case "ConflictException":
2515
- case "com.amazonaws.finspace#ConflictException":
2516
- throw await de_ConflictExceptionRes(parsedOutput, context);
2517
- case "InternalServerException":
2518
- case "com.amazonaws.finspace#InternalServerException":
2519
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2520
- case "LimitExceededException":
2521
- case "com.amazonaws.finspace#LimitExceededException":
2522
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2523
- case "ResourceNotFoundException":
2524
- case "com.amazonaws.finspace#ResourceNotFoundException":
2525
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2526
- case "ThrottlingException":
2527
- case "com.amazonaws.finspace#ThrottlingException":
2528
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2529
- case "ValidationException":
2530
- case "com.amazonaws.finspace#ValidationException":
2531
- throw await de_ValidationExceptionRes(parsedOutput, context);
2532
- default:
2533
- const parsedBody = parsedOutput.body;
2534
- return throwDefaultError({
2535
- output,
2536
- parsedBody,
2537
- errorCode,
2538
- });
2539
- }
2540
- };
2541
1345
  export const de_ListKxUsersCommand = async (output, context) => {
2542
1346
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2543
- return de_ListKxUsersCommandError(output, context);
1347
+ return de_CommandError(output, context);
2544
1348
  }
2545
1349
  const contents = map({
2546
1350
  $metadata: deserializeMetadata(output),
@@ -2553,40 +1357,9 @@ export const de_ListKxUsersCommand = async (output, context) => {
2553
1357
  Object.assign(contents, doc);
2554
1358
  return contents;
2555
1359
  };
2556
- const de_ListKxUsersCommandError = async (output, context) => {
2557
- const parsedOutput = {
2558
- ...output,
2559
- body: await parseErrorBody(output.body, context),
2560
- };
2561
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2562
- switch (errorCode) {
2563
- case "AccessDeniedException":
2564
- case "com.amazonaws.finspace#AccessDeniedException":
2565
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2566
- case "InternalServerException":
2567
- case "com.amazonaws.finspace#InternalServerException":
2568
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2569
- case "ResourceNotFoundException":
2570
- case "com.amazonaws.finspace#ResourceNotFoundException":
2571
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2572
- case "ThrottlingException":
2573
- case "com.amazonaws.finspace#ThrottlingException":
2574
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2575
- case "ValidationException":
2576
- case "com.amazonaws.finspace#ValidationException":
2577
- throw await de_ValidationExceptionRes(parsedOutput, context);
2578
- default:
2579
- const parsedBody = parsedOutput.body;
2580
- return throwDefaultError({
2581
- output,
2582
- parsedBody,
2583
- errorCode,
2584
- });
2585
- }
2586
- };
2587
1360
  export const de_ListKxVolumesCommand = async (output, context) => {
2588
1361
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2589
- return de_ListKxVolumesCommandError(output, context);
1362
+ return de_CommandError(output, context);
2590
1363
  }
2591
1364
  const contents = map({
2592
1365
  $metadata: deserializeMetadata(output),
@@ -2599,46 +1372,9 @@ export const de_ListKxVolumesCommand = async (output, context) => {
2599
1372
  Object.assign(contents, doc);
2600
1373
  return contents;
2601
1374
  };
2602
- const de_ListKxVolumesCommandError = async (output, context) => {
2603
- const parsedOutput = {
2604
- ...output,
2605
- body: await parseErrorBody(output.body, context),
2606
- };
2607
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2608
- switch (errorCode) {
2609
- case "AccessDeniedException":
2610
- case "com.amazonaws.finspace#AccessDeniedException":
2611
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2612
- case "ConflictException":
2613
- case "com.amazonaws.finspace#ConflictException":
2614
- throw await de_ConflictExceptionRes(parsedOutput, context);
2615
- case "InternalServerException":
2616
- case "com.amazonaws.finspace#InternalServerException":
2617
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2618
- case "LimitExceededException":
2619
- case "com.amazonaws.finspace#LimitExceededException":
2620
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2621
- case "ResourceNotFoundException":
2622
- case "com.amazonaws.finspace#ResourceNotFoundException":
2623
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2624
- case "ThrottlingException":
2625
- case "com.amazonaws.finspace#ThrottlingException":
2626
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2627
- case "ValidationException":
2628
- case "com.amazonaws.finspace#ValidationException":
2629
- throw await de_ValidationExceptionRes(parsedOutput, context);
2630
- default:
2631
- const parsedBody = parsedOutput.body;
2632
- return throwDefaultError({
2633
- output,
2634
- parsedBody,
2635
- errorCode,
2636
- });
2637
- }
2638
- };
2639
1375
  export const de_ListTagsForResourceCommand = async (output, context) => {
2640
1376
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2641
- return de_ListTagsForResourceCommandError(output, context);
1377
+ return de_CommandError(output, context);
2642
1378
  }
2643
1379
  const contents = map({
2644
1380
  $metadata: deserializeMetadata(output),
@@ -2650,196 +1386,43 @@ export const de_ListTagsForResourceCommand = async (output, context) => {
2650
1386
  Object.assign(contents, doc);
2651
1387
  return contents;
2652
1388
  };
2653
- const de_ListTagsForResourceCommandError = async (output, context) => {
2654
- const parsedOutput = {
2655
- ...output,
2656
- body: await parseErrorBody(output.body, context),
2657
- };
2658
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2659
- switch (errorCode) {
2660
- case "InternalServerException":
2661
- case "com.amazonaws.finspace#InternalServerException":
2662
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2663
- case "InvalidRequestException":
2664
- case "com.amazonaws.finspace#InvalidRequestException":
2665
- throw await de_InvalidRequestExceptionRes(parsedOutput, context);
2666
- case "ResourceNotFoundException":
2667
- case "com.amazonaws.finspace#ResourceNotFoundException":
2668
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2669
- default:
2670
- const parsedBody = parsedOutput.body;
2671
- return throwDefaultError({
2672
- output,
2673
- parsedBody,
2674
- errorCode,
2675
- });
2676
- }
2677
- };
2678
1389
  export const de_TagResourceCommand = async (output, context) => {
2679
1390
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2680
- return de_TagResourceCommandError(output, context);
2681
- }
2682
- const contents = map({
2683
- $metadata: deserializeMetadata(output),
2684
- });
2685
- await collectBody(output.body, context);
2686
- return contents;
2687
- };
2688
- const de_TagResourceCommandError = async (output, context) => {
2689
- const parsedOutput = {
2690
- ...output,
2691
- body: await parseErrorBody(output.body, context),
2692
- };
2693
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2694
- switch (errorCode) {
2695
- case "InternalServerException":
2696
- case "com.amazonaws.finspace#InternalServerException":
2697
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2698
- case "InvalidRequestException":
2699
- case "com.amazonaws.finspace#InvalidRequestException":
2700
- throw await de_InvalidRequestExceptionRes(parsedOutput, context);
2701
- case "ResourceNotFoundException":
2702
- case "com.amazonaws.finspace#ResourceNotFoundException":
2703
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2704
- default:
2705
- const parsedBody = parsedOutput.body;
2706
- return throwDefaultError({
2707
- output,
2708
- parsedBody,
2709
- errorCode,
2710
- });
2711
- }
2712
- };
2713
- export const de_UntagResourceCommand = async (output, context) => {
2714
- if (output.statusCode !== 200 && output.statusCode >= 300) {
2715
- return de_UntagResourceCommandError(output, context);
1391
+ return de_CommandError(output, context);
2716
1392
  }
2717
1393
  const contents = map({
2718
1394
  $metadata: deserializeMetadata(output),
2719
1395
  });
2720
1396
  await collectBody(output.body, context);
2721
1397
  return contents;
2722
- };
2723
- const de_UntagResourceCommandError = async (output, context) => {
2724
- const parsedOutput = {
2725
- ...output,
2726
- body: await parseErrorBody(output.body, context),
2727
- };
2728
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2729
- switch (errorCode) {
2730
- case "InternalServerException":
2731
- case "com.amazonaws.finspace#InternalServerException":
2732
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2733
- case "InvalidRequestException":
2734
- case "com.amazonaws.finspace#InvalidRequestException":
2735
- throw await de_InvalidRequestExceptionRes(parsedOutput, context);
2736
- case "ResourceNotFoundException":
2737
- case "com.amazonaws.finspace#ResourceNotFoundException":
2738
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2739
- default:
2740
- const parsedBody = parsedOutput.body;
2741
- return throwDefaultError({
2742
- output,
2743
- parsedBody,
2744
- errorCode,
2745
- });
2746
- }
2747
- };
2748
- export const de_UpdateEnvironmentCommand = async (output, context) => {
2749
- if (output.statusCode !== 200 && output.statusCode >= 300) {
2750
- return de_UpdateEnvironmentCommandError(output, context);
2751
- }
2752
- const contents = map({
2753
- $metadata: deserializeMetadata(output),
2754
- });
2755
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
2756
- const doc = take(data, {
2757
- environment: _json,
2758
- });
2759
- Object.assign(contents, doc);
2760
- return contents;
2761
- };
2762
- const de_UpdateEnvironmentCommandError = async (output, context) => {
2763
- const parsedOutput = {
2764
- ...output,
2765
- body: await parseErrorBody(output.body, context),
2766
- };
2767
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2768
- switch (errorCode) {
2769
- case "AccessDeniedException":
2770
- case "com.amazonaws.finspace#AccessDeniedException":
2771
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2772
- case "InternalServerException":
2773
- case "com.amazonaws.finspace#InternalServerException":
2774
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2775
- case "ResourceNotFoundException":
2776
- case "com.amazonaws.finspace#ResourceNotFoundException":
2777
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2778
- case "ThrottlingException":
2779
- case "com.amazonaws.finspace#ThrottlingException":
2780
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2781
- case "ValidationException":
2782
- case "com.amazonaws.finspace#ValidationException":
2783
- throw await de_ValidationExceptionRes(parsedOutput, context);
2784
- default:
2785
- const parsedBody = parsedOutput.body;
2786
- return throwDefaultError({
2787
- output,
2788
- parsedBody,
2789
- errorCode,
2790
- });
2791
- }
2792
- };
2793
- export const de_UpdateKxClusterCodeConfigurationCommand = async (output, context) => {
2794
- if (output.statusCode !== 200 && output.statusCode >= 300) {
2795
- return de_UpdateKxClusterCodeConfigurationCommandError(output, context);
2796
- }
2797
- const contents = map({
2798
- $metadata: deserializeMetadata(output),
2799
- });
2800
- await collectBody(output.body, context);
2801
- return contents;
2802
- };
2803
- const de_UpdateKxClusterCodeConfigurationCommandError = async (output, context) => {
2804
- const parsedOutput = {
2805
- ...output,
2806
- body: await parseErrorBody(output.body, context),
2807
- };
2808
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2809
- switch (errorCode) {
2810
- case "AccessDeniedException":
2811
- case "com.amazonaws.finspace#AccessDeniedException":
2812
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2813
- case "ConflictException":
2814
- case "com.amazonaws.finspace#ConflictException":
2815
- throw await de_ConflictExceptionRes(parsedOutput, context);
2816
- case "InternalServerException":
2817
- case "com.amazonaws.finspace#InternalServerException":
2818
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2819
- case "LimitExceededException":
2820
- case "com.amazonaws.finspace#LimitExceededException":
2821
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2822
- case "ResourceNotFoundException":
2823
- case "com.amazonaws.finspace#ResourceNotFoundException":
2824
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2825
- case "ThrottlingException":
2826
- case "com.amazonaws.finspace#ThrottlingException":
2827
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2828
- case "ValidationException":
2829
- case "com.amazonaws.finspace#ValidationException":
2830
- throw await de_ValidationExceptionRes(parsedOutput, context);
2831
- default:
2832
- const parsedBody = parsedOutput.body;
2833
- return throwDefaultError({
2834
- output,
2835
- parsedBody,
2836
- errorCode,
2837
- });
1398
+ };
1399
+ export const de_UntagResourceCommand = async (output, context) => {
1400
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1401
+ return de_CommandError(output, context);
2838
1402
  }
1403
+ const contents = map({
1404
+ $metadata: deserializeMetadata(output),
1405
+ });
1406
+ await collectBody(output.body, context);
1407
+ return contents;
2839
1408
  };
2840
- export const de_UpdateKxClusterDatabasesCommand = async (output, context) => {
1409
+ export const de_UpdateEnvironmentCommand = async (output, context) => {
1410
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1411
+ return de_CommandError(output, context);
1412
+ }
1413
+ const contents = map({
1414
+ $metadata: deserializeMetadata(output),
1415
+ });
1416
+ const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
1417
+ const doc = take(data, {
1418
+ environment: _json,
1419
+ });
1420
+ Object.assign(contents, doc);
1421
+ return contents;
1422
+ };
1423
+ export const de_UpdateKxClusterCodeConfigurationCommand = async (output, context) => {
2841
1424
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2842
- return de_UpdateKxClusterDatabasesCommandError(output, context);
1425
+ return de_CommandError(output, context);
2843
1426
  }
2844
1427
  const contents = map({
2845
1428
  $metadata: deserializeMetadata(output),
@@ -2847,46 +1430,19 @@ export const de_UpdateKxClusterDatabasesCommand = async (output, context) => {
2847
1430
  await collectBody(output.body, context);
2848
1431
  return contents;
2849
1432
  };
2850
- const de_UpdateKxClusterDatabasesCommandError = async (output, context) => {
2851
- const parsedOutput = {
2852
- ...output,
2853
- body: await parseErrorBody(output.body, context),
2854
- };
2855
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2856
- switch (errorCode) {
2857
- case "AccessDeniedException":
2858
- case "com.amazonaws.finspace#AccessDeniedException":
2859
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2860
- case "ConflictException":
2861
- case "com.amazonaws.finspace#ConflictException":
2862
- throw await de_ConflictExceptionRes(parsedOutput, context);
2863
- case "InternalServerException":
2864
- case "com.amazonaws.finspace#InternalServerException":
2865
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2866
- case "LimitExceededException":
2867
- case "com.amazonaws.finspace#LimitExceededException":
2868
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
2869
- case "ResourceNotFoundException":
2870
- case "com.amazonaws.finspace#ResourceNotFoundException":
2871
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2872
- case "ThrottlingException":
2873
- case "com.amazonaws.finspace#ThrottlingException":
2874
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2875
- case "ValidationException":
2876
- case "com.amazonaws.finspace#ValidationException":
2877
- throw await de_ValidationExceptionRes(parsedOutput, context);
2878
- default:
2879
- const parsedBody = parsedOutput.body;
2880
- return throwDefaultError({
2881
- output,
2882
- parsedBody,
2883
- errorCode,
2884
- });
1433
+ export const de_UpdateKxClusterDatabasesCommand = async (output, context) => {
1434
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1435
+ return de_CommandError(output, context);
2885
1436
  }
1437
+ const contents = map({
1438
+ $metadata: deserializeMetadata(output),
1439
+ });
1440
+ await collectBody(output.body, context);
1441
+ return contents;
2886
1442
  };
2887
1443
  export const de_UpdateKxDatabaseCommand = async (output, context) => {
2888
1444
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2889
- return de_UpdateKxDatabaseCommandError(output, context);
1445
+ return de_CommandError(output, context);
2890
1446
  }
2891
1447
  const contents = map({
2892
1448
  $metadata: deserializeMetadata(output),
@@ -2901,43 +1457,9 @@ export const de_UpdateKxDatabaseCommand = async (output, context) => {
2901
1457
  Object.assign(contents, doc);
2902
1458
  return contents;
2903
1459
  };
2904
- const de_UpdateKxDatabaseCommandError = async (output, context) => {
2905
- const parsedOutput = {
2906
- ...output,
2907
- body: await parseErrorBody(output.body, context),
2908
- };
2909
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2910
- switch (errorCode) {
2911
- case "AccessDeniedException":
2912
- case "com.amazonaws.finspace#AccessDeniedException":
2913
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2914
- case "ConflictException":
2915
- case "com.amazonaws.finspace#ConflictException":
2916
- throw await de_ConflictExceptionRes(parsedOutput, context);
2917
- case "InternalServerException":
2918
- case "com.amazonaws.finspace#InternalServerException":
2919
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2920
- case "ResourceNotFoundException":
2921
- case "com.amazonaws.finspace#ResourceNotFoundException":
2922
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2923
- case "ThrottlingException":
2924
- case "com.amazonaws.finspace#ThrottlingException":
2925
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2926
- case "ValidationException":
2927
- case "com.amazonaws.finspace#ValidationException":
2928
- throw await de_ValidationExceptionRes(parsedOutput, context);
2929
- default:
2930
- const parsedBody = parsedOutput.body;
2931
- return throwDefaultError({
2932
- output,
2933
- parsedBody,
2934
- errorCode,
2935
- });
2936
- }
2937
- };
2938
1460
  export const de_UpdateKxDataviewCommand = async (output, context) => {
2939
1461
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2940
- return de_UpdateKxDataviewCommandError(output, context);
1462
+ return de_CommandError(output, context);
2941
1463
  }
2942
1464
  const contents = map({
2943
1465
  $metadata: deserializeMetadata(output),
@@ -2961,46 +1483,9 @@ export const de_UpdateKxDataviewCommand = async (output, context) => {
2961
1483
  Object.assign(contents, doc);
2962
1484
  return contents;
2963
1485
  };
2964
- const de_UpdateKxDataviewCommandError = async (output, context) => {
2965
- const parsedOutput = {
2966
- ...output,
2967
- body: await parseErrorBody(output.body, context),
2968
- };
2969
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2970
- switch (errorCode) {
2971
- case "AccessDeniedException":
2972
- case "com.amazonaws.finspace#AccessDeniedException":
2973
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2974
- case "ConflictException":
2975
- case "com.amazonaws.finspace#ConflictException":
2976
- throw await de_ConflictExceptionRes(parsedOutput, context);
2977
- case "InternalServerException":
2978
- case "com.amazonaws.finspace#InternalServerException":
2979
- throw await de_InternalServerExceptionRes(parsedOutput, context);
2980
- case "ResourceAlreadyExistsException":
2981
- case "com.amazonaws.finspace#ResourceAlreadyExistsException":
2982
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
2983
- case "ResourceNotFoundException":
2984
- case "com.amazonaws.finspace#ResourceNotFoundException":
2985
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2986
- case "ThrottlingException":
2987
- case "com.amazonaws.finspace#ThrottlingException":
2988
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
2989
- case "ValidationException":
2990
- case "com.amazonaws.finspace#ValidationException":
2991
- throw await de_ValidationExceptionRes(parsedOutput, context);
2992
- default:
2993
- const parsedBody = parsedOutput.body;
2994
- return throwDefaultError({
2995
- output,
2996
- parsedBody,
2997
- errorCode,
2998
- });
2999
- }
3000
- };
3001
1486
  export const de_UpdateKxEnvironmentCommand = async (output, context) => {
3002
1487
  if (output.statusCode !== 200 && output.statusCode >= 300) {
3003
- return de_UpdateKxEnvironmentCommandError(output, context);
1488
+ return de_CommandError(output, context);
3004
1489
  }
3005
1490
  const contents = map({
3006
1491
  $metadata: deserializeMetadata(output),
@@ -3027,43 +1512,9 @@ export const de_UpdateKxEnvironmentCommand = async (output, context) => {
3027
1512
  Object.assign(contents, doc);
3028
1513
  return contents;
3029
1514
  };
3030
- const de_UpdateKxEnvironmentCommandError = async (output, context) => {
3031
- const parsedOutput = {
3032
- ...output,
3033
- body: await parseErrorBody(output.body, context),
3034
- };
3035
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3036
- switch (errorCode) {
3037
- case "AccessDeniedException":
3038
- case "com.amazonaws.finspace#AccessDeniedException":
3039
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3040
- case "ConflictException":
3041
- case "com.amazonaws.finspace#ConflictException":
3042
- throw await de_ConflictExceptionRes(parsedOutput, context);
3043
- case "InternalServerException":
3044
- case "com.amazonaws.finspace#InternalServerException":
3045
- throw await de_InternalServerExceptionRes(parsedOutput, context);
3046
- case "ResourceNotFoundException":
3047
- case "com.amazonaws.finspace#ResourceNotFoundException":
3048
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3049
- case "ThrottlingException":
3050
- case "com.amazonaws.finspace#ThrottlingException":
3051
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
3052
- case "ValidationException":
3053
- case "com.amazonaws.finspace#ValidationException":
3054
- throw await de_ValidationExceptionRes(parsedOutput, context);
3055
- default:
3056
- const parsedBody = parsedOutput.body;
3057
- return throwDefaultError({
3058
- output,
3059
- parsedBody,
3060
- errorCode,
3061
- });
3062
- }
3063
- };
3064
1515
  export const de_UpdateKxEnvironmentNetworkCommand = async (output, context) => {
3065
1516
  if (output.statusCode !== 200 && output.statusCode >= 300) {
3066
- return de_UpdateKxEnvironmentNetworkCommandError(output, context);
1517
+ return de_CommandError(output, context);
3067
1518
  }
3068
1519
  const contents = map({
3069
1520
  $metadata: deserializeMetadata(output),
@@ -3090,43 +1541,9 @@ export const de_UpdateKxEnvironmentNetworkCommand = async (output, context) => {
3090
1541
  Object.assign(contents, doc);
3091
1542
  return contents;
3092
1543
  };
3093
- const de_UpdateKxEnvironmentNetworkCommandError = async (output, context) => {
3094
- const parsedOutput = {
3095
- ...output,
3096
- body: await parseErrorBody(output.body, context),
3097
- };
3098
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3099
- switch (errorCode) {
3100
- case "AccessDeniedException":
3101
- case "com.amazonaws.finspace#AccessDeniedException":
3102
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3103
- case "ConflictException":
3104
- case "com.amazonaws.finspace#ConflictException":
3105
- throw await de_ConflictExceptionRes(parsedOutput, context);
3106
- case "InternalServerException":
3107
- case "com.amazonaws.finspace#InternalServerException":
3108
- throw await de_InternalServerExceptionRes(parsedOutput, context);
3109
- case "ResourceNotFoundException":
3110
- case "com.amazonaws.finspace#ResourceNotFoundException":
3111
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3112
- case "ThrottlingException":
3113
- case "com.amazonaws.finspace#ThrottlingException":
3114
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
3115
- case "ValidationException":
3116
- case "com.amazonaws.finspace#ValidationException":
3117
- throw await de_ValidationExceptionRes(parsedOutput, context);
3118
- default:
3119
- const parsedBody = parsedOutput.body;
3120
- return throwDefaultError({
3121
- output,
3122
- parsedBody,
3123
- errorCode,
3124
- });
3125
- }
3126
- };
3127
1544
  export const de_UpdateKxUserCommand = async (output, context) => {
3128
1545
  if (output.statusCode !== 200 && output.statusCode >= 300) {
3129
- return de_UpdateKxUserCommandError(output, context);
1546
+ return de_CommandError(output, context);
3130
1547
  }
3131
1548
  const contents = map({
3132
1549
  $metadata: deserializeMetadata(output),
@@ -3141,46 +1558,9 @@ export const de_UpdateKxUserCommand = async (output, context) => {
3141
1558
  Object.assign(contents, doc);
3142
1559
  return contents;
3143
1560
  };
3144
- const de_UpdateKxUserCommandError = async (output, context) => {
3145
- const parsedOutput = {
3146
- ...output,
3147
- body: await parseErrorBody(output.body, context),
3148
- };
3149
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3150
- switch (errorCode) {
3151
- case "AccessDeniedException":
3152
- case "com.amazonaws.finspace#AccessDeniedException":
3153
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3154
- case "ConflictException":
3155
- case "com.amazonaws.finspace#ConflictException":
3156
- throw await de_ConflictExceptionRes(parsedOutput, context);
3157
- case "InternalServerException":
3158
- case "com.amazonaws.finspace#InternalServerException":
3159
- throw await de_InternalServerExceptionRes(parsedOutput, context);
3160
- case "LimitExceededException":
3161
- case "com.amazonaws.finspace#LimitExceededException":
3162
- throw await de_LimitExceededExceptionRes(parsedOutput, context);
3163
- case "ResourceNotFoundException":
3164
- case "com.amazonaws.finspace#ResourceNotFoundException":
3165
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3166
- case "ThrottlingException":
3167
- case "com.amazonaws.finspace#ThrottlingException":
3168
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
3169
- case "ValidationException":
3170
- case "com.amazonaws.finspace#ValidationException":
3171
- throw await de_ValidationExceptionRes(parsedOutput, context);
3172
- default:
3173
- const parsedBody = parsedOutput.body;
3174
- return throwDefaultError({
3175
- output,
3176
- parsedBody,
3177
- errorCode,
3178
- });
3179
- }
3180
- };
3181
1561
  export const de_UpdateKxVolumeCommand = async (output, context) => {
3182
1562
  if (output.statusCode !== 200 && output.statusCode >= 300) {
3183
- return de_UpdateKxVolumeCommandError(output, context);
1563
+ return de_CommandError(output, context);
3184
1564
  }
3185
1565
  const contents = map({
3186
1566
  $metadata: deserializeMetadata(output),
@@ -3204,7 +1584,7 @@ export const de_UpdateKxVolumeCommand = async (output, context) => {
3204
1584
  Object.assign(contents, doc);
3205
1585
  return contents;
3206
1586
  };
3207
- const de_UpdateKxVolumeCommandError = async (output, context) => {
1587
+ const de_CommandError = async (output, context) => {
3208
1588
  const parsedOutput = {
3209
1589
  ...output,
3210
1590
  body: await parseErrorBody(output.body, context),
@@ -3214,24 +1594,33 @@ const de_UpdateKxVolumeCommandError = async (output, context) => {
3214
1594
  case "AccessDeniedException":
3215
1595
  case "com.amazonaws.finspace#AccessDeniedException":
3216
1596
  throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3217
- case "ConflictException":
3218
- case "com.amazonaws.finspace#ConflictException":
3219
- throw await de_ConflictExceptionRes(parsedOutput, context);
3220
1597
  case "InternalServerException":
3221
1598
  case "com.amazonaws.finspace#InternalServerException":
3222
1599
  throw await de_InternalServerExceptionRes(parsedOutput, context);
3223
1600
  case "LimitExceededException":
3224
1601
  case "com.amazonaws.finspace#LimitExceededException":
3225
1602
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
3226
- case "ResourceNotFoundException":
3227
- case "com.amazonaws.finspace#ResourceNotFoundException":
3228
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1603
+ case "ServiceQuotaExceededException":
1604
+ case "com.amazonaws.finspace#ServiceQuotaExceededException":
1605
+ throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
3229
1606
  case "ThrottlingException":
3230
1607
  case "com.amazonaws.finspace#ThrottlingException":
3231
1608
  throw await de_ThrottlingExceptionRes(parsedOutput, context);
3232
1609
  case "ValidationException":
3233
1610
  case "com.amazonaws.finspace#ValidationException":
3234
1611
  throw await de_ValidationExceptionRes(parsedOutput, context);
1612
+ case "ConflictException":
1613
+ case "com.amazonaws.finspace#ConflictException":
1614
+ throw await de_ConflictExceptionRes(parsedOutput, context);
1615
+ case "ResourceNotFoundException":
1616
+ case "com.amazonaws.finspace#ResourceNotFoundException":
1617
+ throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1618
+ case "ResourceAlreadyExistsException":
1619
+ case "com.amazonaws.finspace#ResourceAlreadyExistsException":
1620
+ throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
1621
+ case "InvalidRequestException":
1622
+ case "com.amazonaws.finspace#InvalidRequestException":
1623
+ throw await de_InvalidRequestExceptionRes(parsedOutput, context);
3235
1624
  default:
3236
1625
  const parsedBody = parsedOutput.body;
3237
1626
  return throwDefaultError({