@aws-sdk/client-amplifyuibuilder 3.503.1 → 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.
package/dist-cjs/index.js CHANGED
@@ -877,7 +877,7 @@ var se_UpdateThemeCommand = /* @__PURE__ */ __name(async (input, context) => {
877
877
  }, "se_UpdateThemeCommand");
878
878
  var de_CreateComponentCommand = /* @__PURE__ */ __name(async (output, context) => {
879
879
  if (output.statusCode !== 200 && output.statusCode >= 300) {
880
- return de_CreateComponentCommandError(output, context);
880
+ return de_CommandError(output, context);
881
881
  }
882
882
  const contents = (0, import_smithy_client.map)({
883
883
  $metadata: deserializeMetadata(output)
@@ -886,37 +886,9 @@ var de_CreateComponentCommand = /* @__PURE__ */ __name(async (output, context) =
886
886
  contents.entity = de_Component(data, context);
887
887
  return contents;
888
888
  }, "de_CreateComponentCommand");
889
- var de_CreateComponentCommandError = /* @__PURE__ */ __name(async (output, context) => {
890
- const parsedOutput = {
891
- ...output,
892
- body: await parseErrorBody(output.body, context)
893
- };
894
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
895
- switch (errorCode) {
896
- case "InternalServerException":
897
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
898
- throw await de_InternalServerExceptionRes(parsedOutput, context);
899
- case "InvalidParameterException":
900
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
901
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
902
- case "ResourceConflictException":
903
- case "com.amazonaws.amplifyuibuilder#ResourceConflictException":
904
- throw await de_ResourceConflictExceptionRes(parsedOutput, context);
905
- case "ServiceQuotaExceededException":
906
- case "com.amazonaws.amplifyuibuilder#ServiceQuotaExceededException":
907
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
908
- default:
909
- const parsedBody = parsedOutput.body;
910
- return throwDefaultError({
911
- output,
912
- parsedBody,
913
- errorCode
914
- });
915
- }
916
- }, "de_CreateComponentCommandError");
917
889
  var de_CreateFormCommand = /* @__PURE__ */ __name(async (output, context) => {
918
890
  if (output.statusCode !== 200 && output.statusCode >= 300) {
919
- return de_CreateFormCommandError(output, context);
891
+ return de_CommandError(output, context);
920
892
  }
921
893
  const contents = (0, import_smithy_client.map)({
922
894
  $metadata: deserializeMetadata(output)
@@ -925,37 +897,9 @@ var de_CreateFormCommand = /* @__PURE__ */ __name(async (output, context) => {
925
897
  contents.entity = de_Form(data, context);
926
898
  return contents;
927
899
  }, "de_CreateFormCommand");
928
- var de_CreateFormCommandError = /* @__PURE__ */ __name(async (output, context) => {
929
- const parsedOutput = {
930
- ...output,
931
- body: await parseErrorBody(output.body, context)
932
- };
933
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
934
- switch (errorCode) {
935
- case "InternalServerException":
936
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
937
- throw await de_InternalServerExceptionRes(parsedOutput, context);
938
- case "InvalidParameterException":
939
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
940
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
941
- case "ResourceConflictException":
942
- case "com.amazonaws.amplifyuibuilder#ResourceConflictException":
943
- throw await de_ResourceConflictExceptionRes(parsedOutput, context);
944
- case "ServiceQuotaExceededException":
945
- case "com.amazonaws.amplifyuibuilder#ServiceQuotaExceededException":
946
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
947
- default:
948
- const parsedBody = parsedOutput.body;
949
- return throwDefaultError({
950
- output,
951
- parsedBody,
952
- errorCode
953
- });
954
- }
955
- }, "de_CreateFormCommandError");
956
900
  var de_CreateThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
957
901
  if (output.statusCode !== 200 && output.statusCode >= 300) {
958
- return de_CreateThemeCommandError(output, context);
902
+ return de_CommandError(output, context);
959
903
  }
960
904
  const contents = (0, import_smithy_client.map)({
961
905
  $metadata: deserializeMetadata(output)
@@ -964,37 +908,9 @@ var de_CreateThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
964
908
  contents.entity = de_Theme(data, context);
965
909
  return contents;
966
910
  }, "de_CreateThemeCommand");
967
- var de_CreateThemeCommandError = /* @__PURE__ */ __name(async (output, context) => {
968
- const parsedOutput = {
969
- ...output,
970
- body: await parseErrorBody(output.body, context)
971
- };
972
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
973
- switch (errorCode) {
974
- case "InternalServerException":
975
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
976
- throw await de_InternalServerExceptionRes(parsedOutput, context);
977
- case "InvalidParameterException":
978
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
979
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
980
- case "ResourceConflictException":
981
- case "com.amazonaws.amplifyuibuilder#ResourceConflictException":
982
- throw await de_ResourceConflictExceptionRes(parsedOutput, context);
983
- case "ServiceQuotaExceededException":
984
- case "com.amazonaws.amplifyuibuilder#ServiceQuotaExceededException":
985
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
986
- default:
987
- const parsedBody = parsedOutput.body;
988
- return throwDefaultError({
989
- output,
990
- parsedBody,
991
- errorCode
992
- });
993
- }
994
- }, "de_CreateThemeCommandError");
995
911
  var de_DeleteComponentCommand = /* @__PURE__ */ __name(async (output, context) => {
996
912
  if (output.statusCode !== 200 && output.statusCode >= 300) {
997
- return de_DeleteComponentCommandError(output, context);
913
+ return de_CommandError(output, context);
998
914
  }
999
915
  const contents = (0, import_smithy_client.map)({
1000
916
  $metadata: deserializeMetadata(output)
@@ -1002,34 +918,9 @@ var de_DeleteComponentCommand = /* @__PURE__ */ __name(async (output, context) =
1002
918
  await (0, import_smithy_client.collectBody)(output.body, context);
1003
919
  return contents;
1004
920
  }, "de_DeleteComponentCommand");
1005
- var de_DeleteComponentCommandError = /* @__PURE__ */ __name(async (output, context) => {
1006
- const parsedOutput = {
1007
- ...output,
1008
- body: await parseErrorBody(output.body, context)
1009
- };
1010
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1011
- switch (errorCode) {
1012
- case "InternalServerException":
1013
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1014
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1015
- case "InvalidParameterException":
1016
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1017
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1018
- case "ResourceNotFoundException":
1019
- case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1020
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1021
- default:
1022
- const parsedBody = parsedOutput.body;
1023
- return throwDefaultError({
1024
- output,
1025
- parsedBody,
1026
- errorCode
1027
- });
1028
- }
1029
- }, "de_DeleteComponentCommandError");
1030
921
  var de_DeleteFormCommand = /* @__PURE__ */ __name(async (output, context) => {
1031
922
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1032
- return de_DeleteFormCommandError(output, context);
923
+ return de_CommandError(output, context);
1033
924
  }
1034
925
  const contents = (0, import_smithy_client.map)({
1035
926
  $metadata: deserializeMetadata(output)
@@ -1037,34 +928,9 @@ var de_DeleteFormCommand = /* @__PURE__ */ __name(async (output, context) => {
1037
928
  await (0, import_smithy_client.collectBody)(output.body, context);
1038
929
  return contents;
1039
930
  }, "de_DeleteFormCommand");
1040
- var de_DeleteFormCommandError = /* @__PURE__ */ __name(async (output, context) => {
1041
- const parsedOutput = {
1042
- ...output,
1043
- body: await parseErrorBody(output.body, context)
1044
- };
1045
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1046
- switch (errorCode) {
1047
- case "InternalServerException":
1048
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1049
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1050
- case "InvalidParameterException":
1051
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1052
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1053
- case "ResourceNotFoundException":
1054
- case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1055
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1056
- default:
1057
- const parsedBody = parsedOutput.body;
1058
- return throwDefaultError({
1059
- output,
1060
- parsedBody,
1061
- errorCode
1062
- });
1063
- }
1064
- }, "de_DeleteFormCommandError");
1065
931
  var de_DeleteThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
1066
932
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1067
- return de_DeleteThemeCommandError(output, context);
933
+ return de_CommandError(output, context);
1068
934
  }
1069
935
  const contents = (0, import_smithy_client.map)({
1070
936
  $metadata: deserializeMetadata(output)
@@ -1072,34 +938,9 @@ var de_DeleteThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
1072
938
  await (0, import_smithy_client.collectBody)(output.body, context);
1073
939
  return contents;
1074
940
  }, "de_DeleteThemeCommand");
1075
- var de_DeleteThemeCommandError = /* @__PURE__ */ __name(async (output, context) => {
1076
- const parsedOutput = {
1077
- ...output,
1078
- body: await parseErrorBody(output.body, context)
1079
- };
1080
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1081
- switch (errorCode) {
1082
- case "InternalServerException":
1083
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1084
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1085
- case "InvalidParameterException":
1086
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1087
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1088
- case "ResourceNotFoundException":
1089
- case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1090
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1091
- default:
1092
- const parsedBody = parsedOutput.body;
1093
- return throwDefaultError({
1094
- output,
1095
- parsedBody,
1096
- errorCode
1097
- });
1098
- }
1099
- }, "de_DeleteThemeCommandError");
1100
941
  var de_ExchangeCodeForTokenCommand = /* @__PURE__ */ __name(async (output, context) => {
1101
942
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1102
- return de_ExchangeCodeForTokenCommandError(output, context);
943
+ return de_CommandError(output, context);
1103
944
  }
1104
945
  const contents = (0, import_smithy_client.map)({
1105
946
  $metadata: deserializeMetadata(output)
@@ -1113,28 +954,9 @@ var de_ExchangeCodeForTokenCommand = /* @__PURE__ */ __name(async (output, conte
1113
954
  Object.assign(contents, doc);
1114
955
  return contents;
1115
956
  }, "de_ExchangeCodeForTokenCommand");
1116
- var de_ExchangeCodeForTokenCommandError = /* @__PURE__ */ __name(async (output, context) => {
1117
- const parsedOutput = {
1118
- ...output,
1119
- body: await parseErrorBody(output.body, context)
1120
- };
1121
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1122
- switch (errorCode) {
1123
- case "InvalidParameterException":
1124
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1125
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1126
- default:
1127
- const parsedBody = parsedOutput.body;
1128
- return throwDefaultError({
1129
- output,
1130
- parsedBody,
1131
- errorCode
1132
- });
1133
- }
1134
- }, "de_ExchangeCodeForTokenCommandError");
1135
957
  var de_ExportComponentsCommand = /* @__PURE__ */ __name(async (output, context) => {
1136
958
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1137
- return de_ExportComponentsCommandError(output, context);
959
+ return de_CommandError(output, context);
1138
960
  }
1139
961
  const contents = (0, import_smithy_client.map)({
1140
962
  $metadata: deserializeMetadata(output)
@@ -1147,31 +969,9 @@ var de_ExportComponentsCommand = /* @__PURE__ */ __name(async (output, context)
1147
969
  Object.assign(contents, doc);
1148
970
  return contents;
1149
971
  }, "de_ExportComponentsCommand");
1150
- var de_ExportComponentsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1151
- const parsedOutput = {
1152
- ...output,
1153
- body: await parseErrorBody(output.body, context)
1154
- };
1155
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1156
- switch (errorCode) {
1157
- case "InternalServerException":
1158
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1159
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1160
- case "InvalidParameterException":
1161
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1162
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1163
- default:
1164
- const parsedBody = parsedOutput.body;
1165
- return throwDefaultError({
1166
- output,
1167
- parsedBody,
1168
- errorCode
1169
- });
1170
- }
1171
- }, "de_ExportComponentsCommandError");
1172
972
  var de_ExportFormsCommand = /* @__PURE__ */ __name(async (output, context) => {
1173
973
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1174
- return de_ExportFormsCommandError(output, context);
974
+ return de_CommandError(output, context);
1175
975
  }
1176
976
  const contents = (0, import_smithy_client.map)({
1177
977
  $metadata: deserializeMetadata(output)
@@ -1184,31 +984,9 @@ var de_ExportFormsCommand = /* @__PURE__ */ __name(async (output, context) => {
1184
984
  Object.assign(contents, doc);
1185
985
  return contents;
1186
986
  }, "de_ExportFormsCommand");
1187
- var de_ExportFormsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1188
- const parsedOutput = {
1189
- ...output,
1190
- body: await parseErrorBody(output.body, context)
1191
- };
1192
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1193
- switch (errorCode) {
1194
- case "InternalServerException":
1195
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1196
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1197
- case "InvalidParameterException":
1198
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1199
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1200
- default:
1201
- const parsedBody = parsedOutput.body;
1202
- return throwDefaultError({
1203
- output,
1204
- parsedBody,
1205
- errorCode
1206
- });
1207
- }
1208
- }, "de_ExportFormsCommandError");
1209
987
  var de_ExportThemesCommand = /* @__PURE__ */ __name(async (output, context) => {
1210
988
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1211
- return de_ExportThemesCommandError(output, context);
989
+ return de_CommandError(output, context);
1212
990
  }
1213
991
  const contents = (0, import_smithy_client.map)({
1214
992
  $metadata: deserializeMetadata(output)
@@ -1221,31 +999,9 @@ var de_ExportThemesCommand = /* @__PURE__ */ __name(async (output, context) => {
1221
999
  Object.assign(contents, doc);
1222
1000
  return contents;
1223
1001
  }, "de_ExportThemesCommand");
1224
- var de_ExportThemesCommandError = /* @__PURE__ */ __name(async (output, context) => {
1225
- const parsedOutput = {
1226
- ...output,
1227
- body: await parseErrorBody(output.body, context)
1228
- };
1229
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1230
- switch (errorCode) {
1231
- case "InternalServerException":
1232
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1233
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1234
- case "InvalidParameterException":
1235
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1236
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1237
- default:
1238
- const parsedBody = parsedOutput.body;
1239
- return throwDefaultError({
1240
- output,
1241
- parsedBody,
1242
- errorCode
1243
- });
1244
- }
1245
- }, "de_ExportThemesCommandError");
1246
1002
  var de_GetCodegenJobCommand = /* @__PURE__ */ __name(async (output, context) => {
1247
1003
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1248
- return de_GetCodegenJobCommandError(output, context);
1004
+ return de_CommandError(output, context);
1249
1005
  }
1250
1006
  const contents = (0, import_smithy_client.map)({
1251
1007
  $metadata: deserializeMetadata(output)
@@ -1254,109 +1010,31 @@ var de_GetCodegenJobCommand = /* @__PURE__ */ __name(async (output, context) =>
1254
1010
  contents.job = de_CodegenJob(data, context);
1255
1011
  return contents;
1256
1012
  }, "de_GetCodegenJobCommand");
1257
- var de_GetCodegenJobCommandError = /* @__PURE__ */ __name(async (output, context) => {
1258
- const parsedOutput = {
1259
- ...output,
1260
- body: await parseErrorBody(output.body, context)
1261
- };
1262
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1263
- switch (errorCode) {
1264
- case "InternalServerException":
1265
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1266
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1267
- case "InvalidParameterException":
1268
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1269
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1270
- case "ResourceNotFoundException":
1271
- case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1272
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1273
- case "ThrottlingException":
1274
- case "com.amazonaws.amplifyuibuilder#ThrottlingException":
1275
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1276
- default:
1277
- const parsedBody = parsedOutput.body;
1278
- return throwDefaultError({
1279
- output,
1280
- parsedBody,
1281
- errorCode
1282
- });
1283
- }
1284
- }, "de_GetCodegenJobCommandError");
1285
1013
  var de_GetComponentCommand = /* @__PURE__ */ __name(async (output, context) => {
1286
1014
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1287
- return de_GetComponentCommandError(output, context);
1015
+ return de_CommandError(output, context);
1288
1016
  }
1289
1017
  const contents = (0, import_smithy_client.map)({
1290
1018
  $metadata: deserializeMetadata(output)
1291
1019
  });
1292
1020
  const data = (0, import_smithy_client.expectObject)(await parseBody(output.body, context));
1293
- contents.component = de_Component(data, context);
1294
- return contents;
1295
- }, "de_GetComponentCommand");
1296
- var de_GetComponentCommandError = /* @__PURE__ */ __name(async (output, context) => {
1297
- const parsedOutput = {
1298
- ...output,
1299
- body: await parseErrorBody(output.body, context)
1300
- };
1301
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1302
- switch (errorCode) {
1303
- case "InternalServerException":
1304
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1305
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1306
- case "InvalidParameterException":
1307
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1308
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1309
- case "ResourceNotFoundException":
1310
- case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1311
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1312
- default:
1313
- const parsedBody = parsedOutput.body;
1314
- return throwDefaultError({
1315
- output,
1316
- parsedBody,
1317
- errorCode
1318
- });
1319
- }
1320
- }, "de_GetComponentCommandError");
1321
- var de_GetFormCommand = /* @__PURE__ */ __name(async (output, context) => {
1322
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1323
- return de_GetFormCommandError(output, context);
1324
- }
1325
- const contents = (0, import_smithy_client.map)({
1326
- $metadata: deserializeMetadata(output)
1327
- });
1328
- const data = (0, import_smithy_client.expectObject)(await parseBody(output.body, context));
1329
- contents.form = de_Form(data, context);
1330
- return contents;
1331
- }, "de_GetFormCommand");
1332
- var de_GetFormCommandError = /* @__PURE__ */ __name(async (output, context) => {
1333
- const parsedOutput = {
1334
- ...output,
1335
- body: await parseErrorBody(output.body, context)
1336
- };
1337
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1338
- switch (errorCode) {
1339
- case "InternalServerException":
1340
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1341
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1342
- case "InvalidParameterException":
1343
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1344
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1345
- case "ResourceNotFoundException":
1346
- case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1347
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1348
- default:
1349
- const parsedBody = parsedOutput.body;
1350
- return throwDefaultError({
1351
- output,
1352
- parsedBody,
1353
- errorCode
1354
- });
1021
+ contents.component = de_Component(data, context);
1022
+ return contents;
1023
+ }, "de_GetComponentCommand");
1024
+ var de_GetFormCommand = /* @__PURE__ */ __name(async (output, context) => {
1025
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1026
+ return de_CommandError(output, context);
1355
1027
  }
1356
- }, "de_GetFormCommandError");
1028
+ const contents = (0, import_smithy_client.map)({
1029
+ $metadata: deserializeMetadata(output)
1030
+ });
1031
+ const data = (0, import_smithy_client.expectObject)(await parseBody(output.body, context));
1032
+ contents.form = de_Form(data, context);
1033
+ return contents;
1034
+ }, "de_GetFormCommand");
1357
1035
  var de_GetMetadataCommand = /* @__PURE__ */ __name(async (output, context) => {
1358
1036
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1359
- return de_GetMetadataCommandError(output, context);
1037
+ return de_CommandError(output, context);
1360
1038
  }
1361
1039
  const contents = (0, import_smithy_client.map)({
1362
1040
  $metadata: deserializeMetadata(output)
@@ -1368,31 +1046,9 @@ var de_GetMetadataCommand = /* @__PURE__ */ __name(async (output, context) => {
1368
1046
  Object.assign(contents, doc);
1369
1047
  return contents;
1370
1048
  }, "de_GetMetadataCommand");
1371
- var de_GetMetadataCommandError = /* @__PURE__ */ __name(async (output, context) => {
1372
- const parsedOutput = {
1373
- ...output,
1374
- body: await parseErrorBody(output.body, context)
1375
- };
1376
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1377
- switch (errorCode) {
1378
- case "InvalidParameterException":
1379
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1380
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1381
- case "UnauthorizedException":
1382
- case "com.amazonaws.amplifyuibuilder#UnauthorizedException":
1383
- throw await de_UnauthorizedExceptionRes(parsedOutput, context);
1384
- default:
1385
- const parsedBody = parsedOutput.body;
1386
- return throwDefaultError({
1387
- output,
1388
- parsedBody,
1389
- errorCode
1390
- });
1391
- }
1392
- }, "de_GetMetadataCommandError");
1393
1049
  var de_GetThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
1394
1050
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1395
- return de_GetThemeCommandError(output, context);
1051
+ return de_CommandError(output, context);
1396
1052
  }
1397
1053
  const contents = (0, import_smithy_client.map)({
1398
1054
  $metadata: deserializeMetadata(output)
@@ -1401,34 +1057,9 @@ var de_GetThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
1401
1057
  contents.theme = de_Theme(data, context);
1402
1058
  return contents;
1403
1059
  }, "de_GetThemeCommand");
1404
- var de_GetThemeCommandError = /* @__PURE__ */ __name(async (output, context) => {
1405
- const parsedOutput = {
1406
- ...output,
1407
- body: await parseErrorBody(output.body, context)
1408
- };
1409
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1410
- switch (errorCode) {
1411
- case "InternalServerException":
1412
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1413
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1414
- case "InvalidParameterException":
1415
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1416
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1417
- case "ResourceNotFoundException":
1418
- case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1419
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1420
- default:
1421
- const parsedBody = parsedOutput.body;
1422
- return throwDefaultError({
1423
- output,
1424
- parsedBody,
1425
- errorCode
1426
- });
1427
- }
1428
- }, "de_GetThemeCommandError");
1429
1060
  var de_ListCodegenJobsCommand = /* @__PURE__ */ __name(async (output, context) => {
1430
1061
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1431
- return de_ListCodegenJobsCommandError(output, context);
1062
+ return de_CommandError(output, context);
1432
1063
  }
1433
1064
  const contents = (0, import_smithy_client.map)({
1434
1065
  $metadata: deserializeMetadata(output)
@@ -1441,34 +1072,9 @@ var de_ListCodegenJobsCommand = /* @__PURE__ */ __name(async (output, context) =
1441
1072
  Object.assign(contents, doc);
1442
1073
  return contents;
1443
1074
  }, "de_ListCodegenJobsCommand");
1444
- var de_ListCodegenJobsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1445
- const parsedOutput = {
1446
- ...output,
1447
- body: await parseErrorBody(output.body, context)
1448
- };
1449
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1450
- switch (errorCode) {
1451
- case "InternalServerException":
1452
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1453
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1454
- case "InvalidParameterException":
1455
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1456
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1457
- case "ThrottlingException":
1458
- case "com.amazonaws.amplifyuibuilder#ThrottlingException":
1459
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1460
- default:
1461
- const parsedBody = parsedOutput.body;
1462
- return throwDefaultError({
1463
- output,
1464
- parsedBody,
1465
- errorCode
1466
- });
1467
- }
1468
- }, "de_ListCodegenJobsCommandError");
1469
1075
  var de_ListComponentsCommand = /* @__PURE__ */ __name(async (output, context) => {
1470
1076
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1471
- return de_ListComponentsCommandError(output, context);
1077
+ return de_CommandError(output, context);
1472
1078
  }
1473
1079
  const contents = (0, import_smithy_client.map)({
1474
1080
  $metadata: deserializeMetadata(output)
@@ -1481,31 +1087,9 @@ var de_ListComponentsCommand = /* @__PURE__ */ __name(async (output, context) =>
1481
1087
  Object.assign(contents, doc);
1482
1088
  return contents;
1483
1089
  }, "de_ListComponentsCommand");
1484
- var de_ListComponentsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1485
- const parsedOutput = {
1486
- ...output,
1487
- body: await parseErrorBody(output.body, context)
1488
- };
1489
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1490
- switch (errorCode) {
1491
- case "InternalServerException":
1492
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1493
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1494
- case "InvalidParameterException":
1495
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1496
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1497
- default:
1498
- const parsedBody = parsedOutput.body;
1499
- return throwDefaultError({
1500
- output,
1501
- parsedBody,
1502
- errorCode
1503
- });
1504
- }
1505
- }, "de_ListComponentsCommandError");
1506
1090
  var de_ListFormsCommand = /* @__PURE__ */ __name(async (output, context) => {
1507
1091
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1508
- return de_ListFormsCommandError(output, context);
1092
+ return de_CommandError(output, context);
1509
1093
  }
1510
1094
  const contents = (0, import_smithy_client.map)({
1511
1095
  $metadata: deserializeMetadata(output)
@@ -1518,31 +1102,9 @@ var de_ListFormsCommand = /* @__PURE__ */ __name(async (output, context) => {
1518
1102
  Object.assign(contents, doc);
1519
1103
  return contents;
1520
1104
  }, "de_ListFormsCommand");
1521
- var de_ListFormsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1522
- const parsedOutput = {
1523
- ...output,
1524
- body: await parseErrorBody(output.body, context)
1525
- };
1526
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1527
- switch (errorCode) {
1528
- case "InternalServerException":
1529
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1530
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1531
- case "InvalidParameterException":
1532
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1533
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1534
- default:
1535
- const parsedBody = parsedOutput.body;
1536
- return throwDefaultError({
1537
- output,
1538
- parsedBody,
1539
- errorCode
1540
- });
1541
- }
1542
- }, "de_ListFormsCommandError");
1543
1105
  var de_ListThemesCommand = /* @__PURE__ */ __name(async (output, context) => {
1544
1106
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1545
- return de_ListThemesCommandError(output, context);
1107
+ return de_CommandError(output, context);
1546
1108
  }
1547
1109
  const contents = (0, import_smithy_client.map)({
1548
1110
  $metadata: deserializeMetadata(output)
@@ -1555,31 +1117,9 @@ var de_ListThemesCommand = /* @__PURE__ */ __name(async (output, context) => {
1555
1117
  Object.assign(contents, doc);
1556
1118
  return contents;
1557
1119
  }, "de_ListThemesCommand");
1558
- var de_ListThemesCommandError = /* @__PURE__ */ __name(async (output, context) => {
1559
- const parsedOutput = {
1560
- ...output,
1561
- body: await parseErrorBody(output.body, context)
1562
- };
1563
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1564
- switch (errorCode) {
1565
- case "InternalServerException":
1566
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1567
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1568
- case "InvalidParameterException":
1569
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1570
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1571
- default:
1572
- const parsedBody = parsedOutput.body;
1573
- return throwDefaultError({
1574
- output,
1575
- parsedBody,
1576
- errorCode
1577
- });
1578
- }
1579
- }, "de_ListThemesCommandError");
1580
1120
  var de_PutMetadataFlagCommand = /* @__PURE__ */ __name(async (output, context) => {
1581
1121
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1582
- return de_PutMetadataFlagCommandError(output, context);
1122
+ return de_CommandError(output, context);
1583
1123
  }
1584
1124
  const contents = (0, import_smithy_client.map)({
1585
1125
  $metadata: deserializeMetadata(output)
@@ -1587,31 +1127,9 @@ var de_PutMetadataFlagCommand = /* @__PURE__ */ __name(async (output, context) =
1587
1127
  await (0, import_smithy_client.collectBody)(output.body, context);
1588
1128
  return contents;
1589
1129
  }, "de_PutMetadataFlagCommand");
1590
- var de_PutMetadataFlagCommandError = /* @__PURE__ */ __name(async (output, context) => {
1591
- const parsedOutput = {
1592
- ...output,
1593
- body: await parseErrorBody(output.body, context)
1594
- };
1595
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1596
- switch (errorCode) {
1597
- case "InvalidParameterException":
1598
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1599
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1600
- case "UnauthorizedException":
1601
- case "com.amazonaws.amplifyuibuilder#UnauthorizedException":
1602
- throw await de_UnauthorizedExceptionRes(parsedOutput, context);
1603
- default:
1604
- const parsedBody = parsedOutput.body;
1605
- return throwDefaultError({
1606
- output,
1607
- parsedBody,
1608
- errorCode
1609
- });
1610
- }
1611
- }, "de_PutMetadataFlagCommandError");
1612
1130
  var de_RefreshTokenCommand = /* @__PURE__ */ __name(async (output, context) => {
1613
1131
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1614
- return de_RefreshTokenCommandError(output, context);
1132
+ return de_CommandError(output, context);
1615
1133
  }
1616
1134
  const contents = (0, import_smithy_client.map)({
1617
1135
  $metadata: deserializeMetadata(output)
@@ -1624,28 +1142,9 @@ var de_RefreshTokenCommand = /* @__PURE__ */ __name(async (output, context) => {
1624
1142
  Object.assign(contents, doc);
1625
1143
  return contents;
1626
1144
  }, "de_RefreshTokenCommand");
1627
- var de_RefreshTokenCommandError = /* @__PURE__ */ __name(async (output, context) => {
1628
- const parsedOutput = {
1629
- ...output,
1630
- body: await parseErrorBody(output.body, context)
1631
- };
1632
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1633
- switch (errorCode) {
1634
- case "InvalidParameterException":
1635
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1636
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1637
- default:
1638
- const parsedBody = parsedOutput.body;
1639
- return throwDefaultError({
1640
- output,
1641
- parsedBody,
1642
- errorCode
1643
- });
1644
- }
1645
- }, "de_RefreshTokenCommandError");
1646
1145
  var de_StartCodegenJobCommand = /* @__PURE__ */ __name(async (output, context) => {
1647
1146
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1648
- return de_StartCodegenJobCommandError(output, context);
1147
+ return de_CommandError(output, context);
1649
1148
  }
1650
1149
  const contents = (0, import_smithy_client.map)({
1651
1150
  $metadata: deserializeMetadata(output)
@@ -1654,34 +1153,9 @@ var de_StartCodegenJobCommand = /* @__PURE__ */ __name(async (output, context) =
1654
1153
  contents.entity = de_CodegenJob(data, context);
1655
1154
  return contents;
1656
1155
  }, "de_StartCodegenJobCommand");
1657
- var de_StartCodegenJobCommandError = /* @__PURE__ */ __name(async (output, context) => {
1658
- const parsedOutput = {
1659
- ...output,
1660
- body: await parseErrorBody(output.body, context)
1661
- };
1662
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1663
- switch (errorCode) {
1664
- case "InternalServerException":
1665
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1666
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1667
- case "InvalidParameterException":
1668
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1669
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1670
- case "ThrottlingException":
1671
- case "com.amazonaws.amplifyuibuilder#ThrottlingException":
1672
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1673
- default:
1674
- const parsedBody = parsedOutput.body;
1675
- return throwDefaultError({
1676
- output,
1677
- parsedBody,
1678
- errorCode
1679
- });
1680
- }
1681
- }, "de_StartCodegenJobCommandError");
1682
1156
  var de_UpdateComponentCommand = /* @__PURE__ */ __name(async (output, context) => {
1683
1157
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1684
- return de_UpdateComponentCommandError(output, context);
1158
+ return de_CommandError(output, context);
1685
1159
  }
1686
1160
  const contents = (0, import_smithy_client.map)({
1687
1161
  $metadata: deserializeMetadata(output)
@@ -1690,34 +1164,9 @@ var de_UpdateComponentCommand = /* @__PURE__ */ __name(async (output, context) =
1690
1164
  contents.entity = de_Component(data, context);
1691
1165
  return contents;
1692
1166
  }, "de_UpdateComponentCommand");
1693
- var de_UpdateComponentCommandError = /* @__PURE__ */ __name(async (output, context) => {
1694
- const parsedOutput = {
1695
- ...output,
1696
- body: await parseErrorBody(output.body, context)
1697
- };
1698
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1699
- switch (errorCode) {
1700
- case "InternalServerException":
1701
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1702
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1703
- case "InvalidParameterException":
1704
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1705
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1706
- case "ResourceConflictException":
1707
- case "com.amazonaws.amplifyuibuilder#ResourceConflictException":
1708
- throw await de_ResourceConflictExceptionRes(parsedOutput, context);
1709
- default:
1710
- const parsedBody = parsedOutput.body;
1711
- return throwDefaultError({
1712
- output,
1713
- parsedBody,
1714
- errorCode
1715
- });
1716
- }
1717
- }, "de_UpdateComponentCommandError");
1718
1167
  var de_UpdateFormCommand = /* @__PURE__ */ __name(async (output, context) => {
1719
1168
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1720
- return de_UpdateFormCommandError(output, context);
1169
+ return de_CommandError(output, context);
1721
1170
  }
1722
1171
  const contents = (0, import_smithy_client.map)({
1723
1172
  $metadata: deserializeMetadata(output)
@@ -1726,34 +1175,9 @@ var de_UpdateFormCommand = /* @__PURE__ */ __name(async (output, context) => {
1726
1175
  contents.entity = de_Form(data, context);
1727
1176
  return contents;
1728
1177
  }, "de_UpdateFormCommand");
1729
- var de_UpdateFormCommandError = /* @__PURE__ */ __name(async (output, context) => {
1730
- const parsedOutput = {
1731
- ...output,
1732
- body: await parseErrorBody(output.body, context)
1733
- };
1734
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1735
- switch (errorCode) {
1736
- case "InternalServerException":
1737
- case "com.amazonaws.amplifyuibuilder#InternalServerException":
1738
- throw await de_InternalServerExceptionRes(parsedOutput, context);
1739
- case "InvalidParameterException":
1740
- case "com.amazonaws.amplifyuibuilder#InvalidParameterException":
1741
- throw await de_InvalidParameterExceptionRes(parsedOutput, context);
1742
- case "ResourceConflictException":
1743
- case "com.amazonaws.amplifyuibuilder#ResourceConflictException":
1744
- throw await de_ResourceConflictExceptionRes(parsedOutput, context);
1745
- default:
1746
- const parsedBody = parsedOutput.body;
1747
- return throwDefaultError({
1748
- output,
1749
- parsedBody,
1750
- errorCode
1751
- });
1752
- }
1753
- }, "de_UpdateFormCommandError");
1754
1178
  var de_UpdateThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
1755
1179
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1756
- return de_UpdateThemeCommandError(output, context);
1180
+ return de_CommandError(output, context);
1757
1181
  }
1758
1182
  const contents = (0, import_smithy_client.map)({
1759
1183
  $metadata: deserializeMetadata(output)
@@ -1762,7 +1186,7 @@ var de_UpdateThemeCommand = /* @__PURE__ */ __name(async (output, context) => {
1762
1186
  contents.entity = de_Theme(data, context);
1763
1187
  return contents;
1764
1188
  }, "de_UpdateThemeCommand");
1765
- var de_UpdateThemeCommandError = /* @__PURE__ */ __name(async (output, context) => {
1189
+ var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
1766
1190
  const parsedOutput = {
1767
1191
  ...output,
1768
1192
  body: await parseErrorBody(output.body, context)
@@ -1778,6 +1202,18 @@ var de_UpdateThemeCommandError = /* @__PURE__ */ __name(async (output, context)
1778
1202
  case "ResourceConflictException":
1779
1203
  case "com.amazonaws.amplifyuibuilder#ResourceConflictException":
1780
1204
  throw await de_ResourceConflictExceptionRes(parsedOutput, context);
1205
+ case "ServiceQuotaExceededException":
1206
+ case "com.amazonaws.amplifyuibuilder#ServiceQuotaExceededException":
1207
+ throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
1208
+ case "ResourceNotFoundException":
1209
+ case "com.amazonaws.amplifyuibuilder#ResourceNotFoundException":
1210
+ throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1211
+ case "ThrottlingException":
1212
+ case "com.amazonaws.amplifyuibuilder#ThrottlingException":
1213
+ throw await de_ThrottlingExceptionRes(parsedOutput, context);
1214
+ case "UnauthorizedException":
1215
+ case "com.amazonaws.amplifyuibuilder#UnauthorizedException":
1216
+ throw await de_UnauthorizedExceptionRes(parsedOutput, context);
1781
1217
  default:
1782
1218
  const parsedBody = parsedOutput.body;
1783
1219
  return throwDefaultError({
@@ -1786,7 +1222,7 @@ var de_UpdateThemeCommandError = /* @__PURE__ */ __name(async (output, context)
1786
1222
  errorCode
1787
1223
  });
1788
1224
  }
1789
- }, "de_UpdateThemeCommandError");
1225
+ }, "de_CommandError");
1790
1226
  var throwDefaultError = (0, import_smithy_client.withBaseException)(AmplifyUIBuilderServiceException);
1791
1227
  var de_InternalServerExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1792
1228
  const contents = (0, import_smithy_client.map)({});