@aws-sdk/client-braket 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.
package/dist-cjs/index.js CHANGED
@@ -667,7 +667,7 @@ var se_UntagResourceCommand = /* @__PURE__ */ __name(async (input, context) => {
667
667
  }, "se_UntagResourceCommand");
668
668
  var de_CancelJobCommand = /* @__PURE__ */ __name(async (output, context) => {
669
669
  if (output.statusCode !== 200 && output.statusCode >= 300) {
670
- return de_CancelJobCommandError(output, context);
670
+ return de_CommandError(output, context);
671
671
  }
672
672
  const contents = (0, import_smithy_client.map)({
673
673
  $metadata: deserializeMetadata(output)
@@ -680,43 +680,9 @@ var de_CancelJobCommand = /* @__PURE__ */ __name(async (output, context) => {
680
680
  Object.assign(contents, doc);
681
681
  return contents;
682
682
  }, "de_CancelJobCommand");
683
- var de_CancelJobCommandError = /* @__PURE__ */ __name(async (output, context) => {
684
- const parsedOutput = {
685
- ...output,
686
- body: await parseErrorBody(output.body, context)
687
- };
688
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
689
- switch (errorCode) {
690
- case "AccessDeniedException":
691
- case "com.amazonaws.braket#AccessDeniedException":
692
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
693
- case "ConflictException":
694
- case "com.amazonaws.braket#ConflictException":
695
- throw await de_ConflictExceptionRes(parsedOutput, context);
696
- case "InternalServiceException":
697
- case "com.amazonaws.braket#InternalServiceException":
698
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
699
- case "ResourceNotFoundException":
700
- case "com.amazonaws.braket#ResourceNotFoundException":
701
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
702
- case "ThrottlingException":
703
- case "com.amazonaws.braket#ThrottlingException":
704
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
705
- case "ValidationException":
706
- case "com.amazonaws.braket#ValidationException":
707
- throw await de_ValidationExceptionRes(parsedOutput, context);
708
- default:
709
- const parsedBody = parsedOutput.body;
710
- return throwDefaultError({
711
- output,
712
- parsedBody,
713
- errorCode
714
- });
715
- }
716
- }, "de_CancelJobCommandError");
717
683
  var de_CancelQuantumTaskCommand = /* @__PURE__ */ __name(async (output, context) => {
718
684
  if (output.statusCode !== 200 && output.statusCode >= 300) {
719
- return de_CancelQuantumTaskCommandError(output, context);
685
+ return de_CommandError(output, context);
720
686
  }
721
687
  const contents = (0, import_smithy_client.map)({
722
688
  $metadata: deserializeMetadata(output)
@@ -729,43 +695,9 @@ var de_CancelQuantumTaskCommand = /* @__PURE__ */ __name(async (output, context)
729
695
  Object.assign(contents, doc);
730
696
  return contents;
731
697
  }, "de_CancelQuantumTaskCommand");
732
- var de_CancelQuantumTaskCommandError = /* @__PURE__ */ __name(async (output, context) => {
733
- const parsedOutput = {
734
- ...output,
735
- body: await parseErrorBody(output.body, context)
736
- };
737
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
738
- switch (errorCode) {
739
- case "AccessDeniedException":
740
- case "com.amazonaws.braket#AccessDeniedException":
741
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
742
- case "ConflictException":
743
- case "com.amazonaws.braket#ConflictException":
744
- throw await de_ConflictExceptionRes(parsedOutput, context);
745
- case "InternalServiceException":
746
- case "com.amazonaws.braket#InternalServiceException":
747
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
748
- case "ResourceNotFoundException":
749
- case "com.amazonaws.braket#ResourceNotFoundException":
750
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
751
- case "ThrottlingException":
752
- case "com.amazonaws.braket#ThrottlingException":
753
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
754
- case "ValidationException":
755
- case "com.amazonaws.braket#ValidationException":
756
- throw await de_ValidationExceptionRes(parsedOutput, context);
757
- default:
758
- const parsedBody = parsedOutput.body;
759
- return throwDefaultError({
760
- output,
761
- parsedBody,
762
- errorCode
763
- });
764
- }
765
- }, "de_CancelQuantumTaskCommandError");
766
698
  var de_CreateJobCommand = /* @__PURE__ */ __name(async (output, context) => {
767
699
  if (output.statusCode !== 201 && output.statusCode >= 300) {
768
- return de_CreateJobCommandError(output, context);
700
+ return de_CommandError(output, context);
769
701
  }
770
702
  const contents = (0, import_smithy_client.map)({
771
703
  $metadata: deserializeMetadata(output)
@@ -777,46 +709,9 @@ var de_CreateJobCommand = /* @__PURE__ */ __name(async (output, context) => {
777
709
  Object.assign(contents, doc);
778
710
  return contents;
779
711
  }, "de_CreateJobCommand");
780
- var de_CreateJobCommandError = /* @__PURE__ */ __name(async (output, context) => {
781
- const parsedOutput = {
782
- ...output,
783
- body: await parseErrorBody(output.body, context)
784
- };
785
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
786
- switch (errorCode) {
787
- case "AccessDeniedException":
788
- case "com.amazonaws.braket#AccessDeniedException":
789
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
790
- case "ConflictException":
791
- case "com.amazonaws.braket#ConflictException":
792
- throw await de_ConflictExceptionRes(parsedOutput, context);
793
- case "DeviceRetiredException":
794
- case "com.amazonaws.braket#DeviceRetiredException":
795
- throw await de_DeviceRetiredExceptionRes(parsedOutput, context);
796
- case "InternalServiceException":
797
- case "com.amazonaws.braket#InternalServiceException":
798
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
799
- case "ServiceQuotaExceededException":
800
- case "com.amazonaws.braket#ServiceQuotaExceededException":
801
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
802
- case "ThrottlingException":
803
- case "com.amazonaws.braket#ThrottlingException":
804
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
805
- case "ValidationException":
806
- case "com.amazonaws.braket#ValidationException":
807
- throw await de_ValidationExceptionRes(parsedOutput, context);
808
- default:
809
- const parsedBody = parsedOutput.body;
810
- return throwDefaultError({
811
- output,
812
- parsedBody,
813
- errorCode
814
- });
815
- }
816
- }, "de_CreateJobCommandError");
817
712
  var de_CreateQuantumTaskCommand = /* @__PURE__ */ __name(async (output, context) => {
818
713
  if (output.statusCode !== 201 && output.statusCode >= 300) {
819
- return de_CreateQuantumTaskCommandError(output, context);
714
+ return de_CommandError(output, context);
820
715
  }
821
716
  const contents = (0, import_smithy_client.map)({
822
717
  $metadata: deserializeMetadata(output)
@@ -828,46 +723,9 @@ var de_CreateQuantumTaskCommand = /* @__PURE__ */ __name(async (output, context)
828
723
  Object.assign(contents, doc);
829
724
  return contents;
830
725
  }, "de_CreateQuantumTaskCommand");
831
- var de_CreateQuantumTaskCommandError = /* @__PURE__ */ __name(async (output, context) => {
832
- const parsedOutput = {
833
- ...output,
834
- body: await parseErrorBody(output.body, context)
835
- };
836
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
837
- switch (errorCode) {
838
- case "AccessDeniedException":
839
- case "com.amazonaws.braket#AccessDeniedException":
840
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
841
- case "DeviceOfflineException":
842
- case "com.amazonaws.braket#DeviceOfflineException":
843
- throw await de_DeviceOfflineExceptionRes(parsedOutput, context);
844
- case "DeviceRetiredException":
845
- case "com.amazonaws.braket#DeviceRetiredException":
846
- throw await de_DeviceRetiredExceptionRes(parsedOutput, context);
847
- case "InternalServiceException":
848
- case "com.amazonaws.braket#InternalServiceException":
849
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
850
- case "ServiceQuotaExceededException":
851
- case "com.amazonaws.braket#ServiceQuotaExceededException":
852
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
853
- case "ThrottlingException":
854
- case "com.amazonaws.braket#ThrottlingException":
855
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
856
- case "ValidationException":
857
- case "com.amazonaws.braket#ValidationException":
858
- throw await de_ValidationExceptionRes(parsedOutput, context);
859
- default:
860
- const parsedBody = parsedOutput.body;
861
- return throwDefaultError({
862
- output,
863
- parsedBody,
864
- errorCode
865
- });
866
- }
867
- }, "de_CreateQuantumTaskCommandError");
868
726
  var de_GetDeviceCommand = /* @__PURE__ */ __name(async (output, context) => {
869
727
  if (output.statusCode !== 200 && output.statusCode >= 300) {
870
- return de_GetDeviceCommandError(output, context);
728
+ return de_CommandError(output, context);
871
729
  }
872
730
  const contents = (0, import_smithy_client.map)({
873
731
  $metadata: deserializeMetadata(output)
@@ -885,40 +743,9 @@ var de_GetDeviceCommand = /* @__PURE__ */ __name(async (output, context) => {
885
743
  Object.assign(contents, doc);
886
744
  return contents;
887
745
  }, "de_GetDeviceCommand");
888
- var de_GetDeviceCommandError = /* @__PURE__ */ __name(async (output, context) => {
889
- const parsedOutput = {
890
- ...output,
891
- body: await parseErrorBody(output.body, context)
892
- };
893
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
894
- switch (errorCode) {
895
- case "AccessDeniedException":
896
- case "com.amazonaws.braket#AccessDeniedException":
897
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
898
- case "InternalServiceException":
899
- case "com.amazonaws.braket#InternalServiceException":
900
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
901
- case "ResourceNotFoundException":
902
- case "com.amazonaws.braket#ResourceNotFoundException":
903
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
904
- case "ThrottlingException":
905
- case "com.amazonaws.braket#ThrottlingException":
906
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
907
- case "ValidationException":
908
- case "com.amazonaws.braket#ValidationException":
909
- throw await de_ValidationExceptionRes(parsedOutput, context);
910
- default:
911
- const parsedBody = parsedOutput.body;
912
- return throwDefaultError({
913
- output,
914
- parsedBody,
915
- errorCode
916
- });
917
- }
918
- }, "de_GetDeviceCommandError");
919
746
  var de_GetJobCommand = /* @__PURE__ */ __name(async (output, context) => {
920
747
  if (output.statusCode !== 200 && output.statusCode >= 300) {
921
- return de_GetJobCommandError(output, context);
748
+ return de_CommandError(output, context);
922
749
  }
923
750
  const contents = (0, import_smithy_client.map)({
924
751
  $metadata: deserializeMetadata(output)
@@ -950,40 +777,9 @@ var de_GetJobCommand = /* @__PURE__ */ __name(async (output, context) => {
950
777
  Object.assign(contents, doc);
951
778
  return contents;
952
779
  }, "de_GetJobCommand");
953
- var de_GetJobCommandError = /* @__PURE__ */ __name(async (output, context) => {
954
- const parsedOutput = {
955
- ...output,
956
- body: await parseErrorBody(output.body, context)
957
- };
958
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
959
- switch (errorCode) {
960
- case "AccessDeniedException":
961
- case "com.amazonaws.braket#AccessDeniedException":
962
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
963
- case "InternalServiceException":
964
- case "com.amazonaws.braket#InternalServiceException":
965
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
966
- case "ResourceNotFoundException":
967
- case "com.amazonaws.braket#ResourceNotFoundException":
968
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
969
- case "ThrottlingException":
970
- case "com.amazonaws.braket#ThrottlingException":
971
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
972
- case "ValidationException":
973
- case "com.amazonaws.braket#ValidationException":
974
- throw await de_ValidationExceptionRes(parsedOutput, context);
975
- default:
976
- const parsedBody = parsedOutput.body;
977
- return throwDefaultError({
978
- output,
979
- parsedBody,
980
- errorCode
981
- });
982
- }
983
- }, "de_GetJobCommandError");
984
780
  var de_GetQuantumTaskCommand = /* @__PURE__ */ __name(async (output, context) => {
985
781
  if (output.statusCode !== 200 && output.statusCode >= 300) {
986
- return de_GetQuantumTaskCommandError(output, context);
782
+ return de_CommandError(output, context);
987
783
  }
988
784
  const contents = (0, import_smithy_client.map)({
989
785
  $metadata: deserializeMetadata(output)
@@ -1008,40 +804,9 @@ var de_GetQuantumTaskCommand = /* @__PURE__ */ __name(async (output, context) =>
1008
804
  Object.assign(contents, doc);
1009
805
  return contents;
1010
806
  }, "de_GetQuantumTaskCommand");
1011
- var de_GetQuantumTaskCommandError = /* @__PURE__ */ __name(async (output, context) => {
1012
- const parsedOutput = {
1013
- ...output,
1014
- body: await parseErrorBody(output.body, context)
1015
- };
1016
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1017
- switch (errorCode) {
1018
- case "AccessDeniedException":
1019
- case "com.amazonaws.braket#AccessDeniedException":
1020
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1021
- case "InternalServiceException":
1022
- case "com.amazonaws.braket#InternalServiceException":
1023
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
1024
- case "ResourceNotFoundException":
1025
- case "com.amazonaws.braket#ResourceNotFoundException":
1026
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1027
- case "ThrottlingException":
1028
- case "com.amazonaws.braket#ThrottlingException":
1029
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1030
- case "ValidationException":
1031
- case "com.amazonaws.braket#ValidationException":
1032
- throw await de_ValidationExceptionRes(parsedOutput, context);
1033
- default:
1034
- const parsedBody = parsedOutput.body;
1035
- return throwDefaultError({
1036
- output,
1037
- parsedBody,
1038
- errorCode
1039
- });
1040
- }
1041
- }, "de_GetQuantumTaskCommandError");
1042
807
  var de_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1043
808
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1044
- return de_ListTagsForResourceCommandError(output, context);
809
+ return de_CommandError(output, context);
1045
810
  }
1046
811
  const contents = (0, import_smithy_client.map)({
1047
812
  $metadata: deserializeMetadata(output)
@@ -1053,34 +818,9 @@ var de_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (output, contex
1053
818
  Object.assign(contents, doc);
1054
819
  return contents;
1055
820
  }, "de_ListTagsForResourceCommand");
1056
- var de_ListTagsForResourceCommandError = /* @__PURE__ */ __name(async (output, context) => {
1057
- const parsedOutput = {
1058
- ...output,
1059
- body: await parseErrorBody(output.body, context)
1060
- };
1061
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1062
- switch (errorCode) {
1063
- case "InternalServiceException":
1064
- case "com.amazonaws.braket#InternalServiceException":
1065
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
1066
- case "ResourceNotFoundException":
1067
- case "com.amazonaws.braket#ResourceNotFoundException":
1068
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1069
- case "ValidationException":
1070
- case "com.amazonaws.braket#ValidationException":
1071
- throw await de_ValidationExceptionRes(parsedOutput, context);
1072
- default:
1073
- const parsedBody = parsedOutput.body;
1074
- return throwDefaultError({
1075
- output,
1076
- parsedBody,
1077
- errorCode
1078
- });
1079
- }
1080
- }, "de_ListTagsForResourceCommandError");
1081
821
  var de_SearchDevicesCommand = /* @__PURE__ */ __name(async (output, context) => {
1082
822
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1083
- return de_SearchDevicesCommandError(output, context);
823
+ return de_CommandError(output, context);
1084
824
  }
1085
825
  const contents = (0, import_smithy_client.map)({
1086
826
  $metadata: deserializeMetadata(output)
@@ -1093,37 +833,9 @@ var de_SearchDevicesCommand = /* @__PURE__ */ __name(async (output, context) =>
1093
833
  Object.assign(contents, doc);
1094
834
  return contents;
1095
835
  }, "de_SearchDevicesCommand");
1096
- var de_SearchDevicesCommandError = /* @__PURE__ */ __name(async (output, context) => {
1097
- const parsedOutput = {
1098
- ...output,
1099
- body: await parseErrorBody(output.body, context)
1100
- };
1101
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1102
- switch (errorCode) {
1103
- case "AccessDeniedException":
1104
- case "com.amazonaws.braket#AccessDeniedException":
1105
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1106
- case "InternalServiceException":
1107
- case "com.amazonaws.braket#InternalServiceException":
1108
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
1109
- case "ThrottlingException":
1110
- case "com.amazonaws.braket#ThrottlingException":
1111
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1112
- case "ValidationException":
1113
- case "com.amazonaws.braket#ValidationException":
1114
- throw await de_ValidationExceptionRes(parsedOutput, context);
1115
- default:
1116
- const parsedBody = parsedOutput.body;
1117
- return throwDefaultError({
1118
- output,
1119
- parsedBody,
1120
- errorCode
1121
- });
1122
- }
1123
- }, "de_SearchDevicesCommandError");
1124
836
  var de_SearchJobsCommand = /* @__PURE__ */ __name(async (output, context) => {
1125
837
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1126
- return de_SearchJobsCommandError(output, context);
838
+ return de_CommandError(output, context);
1127
839
  }
1128
840
  const contents = (0, import_smithy_client.map)({
1129
841
  $metadata: deserializeMetadata(output)
@@ -1136,37 +848,9 @@ var de_SearchJobsCommand = /* @__PURE__ */ __name(async (output, context) => {
1136
848
  Object.assign(contents, doc);
1137
849
  return contents;
1138
850
  }, "de_SearchJobsCommand");
1139
- var de_SearchJobsCommandError = /* @__PURE__ */ __name(async (output, context) => {
1140
- const parsedOutput = {
1141
- ...output,
1142
- body: await parseErrorBody(output.body, context)
1143
- };
1144
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1145
- switch (errorCode) {
1146
- case "AccessDeniedException":
1147
- case "com.amazonaws.braket#AccessDeniedException":
1148
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1149
- case "InternalServiceException":
1150
- case "com.amazonaws.braket#InternalServiceException":
1151
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
1152
- case "ThrottlingException":
1153
- case "com.amazonaws.braket#ThrottlingException":
1154
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1155
- case "ValidationException":
1156
- case "com.amazonaws.braket#ValidationException":
1157
- throw await de_ValidationExceptionRes(parsedOutput, context);
1158
- default:
1159
- const parsedBody = parsedOutput.body;
1160
- return throwDefaultError({
1161
- output,
1162
- parsedBody,
1163
- errorCode
1164
- });
1165
- }
1166
- }, "de_SearchJobsCommandError");
1167
851
  var de_SearchQuantumTasksCommand = /* @__PURE__ */ __name(async (output, context) => {
1168
852
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1169
- return de_SearchQuantumTasksCommandError(output, context);
853
+ return de_CommandError(output, context);
1170
854
  }
1171
855
  const contents = (0, import_smithy_client.map)({
1172
856
  $metadata: deserializeMetadata(output)
@@ -1179,37 +863,9 @@ var de_SearchQuantumTasksCommand = /* @__PURE__ */ __name(async (output, context
1179
863
  Object.assign(contents, doc);
1180
864
  return contents;
1181
865
  }, "de_SearchQuantumTasksCommand");
1182
- var de_SearchQuantumTasksCommandError = /* @__PURE__ */ __name(async (output, context) => {
1183
- const parsedOutput = {
1184
- ...output,
1185
- body: await parseErrorBody(output.body, context)
1186
- };
1187
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1188
- switch (errorCode) {
1189
- case "AccessDeniedException":
1190
- case "com.amazonaws.braket#AccessDeniedException":
1191
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1192
- case "InternalServiceException":
1193
- case "com.amazonaws.braket#InternalServiceException":
1194
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
1195
- case "ThrottlingException":
1196
- case "com.amazonaws.braket#ThrottlingException":
1197
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
1198
- case "ValidationException":
1199
- case "com.amazonaws.braket#ValidationException":
1200
- throw await de_ValidationExceptionRes(parsedOutput, context);
1201
- default:
1202
- const parsedBody = parsedOutput.body;
1203
- return throwDefaultError({
1204
- output,
1205
- parsedBody,
1206
- errorCode
1207
- });
1208
- }
1209
- }, "de_SearchQuantumTasksCommandError");
1210
866
  var de_TagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1211
867
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1212
- return de_TagResourceCommandError(output, context);
868
+ return de_CommandError(output, context);
1213
869
  }
1214
870
  const contents = (0, import_smithy_client.map)({
1215
871
  $metadata: deserializeMetadata(output)
@@ -1217,34 +873,9 @@ var de_TagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1217
873
  await (0, import_smithy_client.collectBody)(output.body, context);
1218
874
  return contents;
1219
875
  }, "de_TagResourceCommand");
1220
- var de_TagResourceCommandError = /* @__PURE__ */ __name(async (output, context) => {
1221
- const parsedOutput = {
1222
- ...output,
1223
- body: await parseErrorBody(output.body, context)
1224
- };
1225
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1226
- switch (errorCode) {
1227
- case "InternalServiceException":
1228
- case "com.amazonaws.braket#InternalServiceException":
1229
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
1230
- case "ResourceNotFoundException":
1231
- case "com.amazonaws.braket#ResourceNotFoundException":
1232
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1233
- case "ValidationException":
1234
- case "com.amazonaws.braket#ValidationException":
1235
- throw await de_ValidationExceptionRes(parsedOutput, context);
1236
- default:
1237
- const parsedBody = parsedOutput.body;
1238
- return throwDefaultError({
1239
- output,
1240
- parsedBody,
1241
- errorCode
1242
- });
1243
- }
1244
- }, "de_TagResourceCommandError");
1245
876
  var de_UntagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1246
877
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1247
- return de_UntagResourceCommandError(output, context);
878
+ return de_CommandError(output, context);
1248
879
  }
1249
880
  const contents = (0, import_smithy_client.map)({
1250
881
  $metadata: deserializeMetadata(output)
@@ -1252,22 +883,40 @@ var de_UntagResourceCommand = /* @__PURE__ */ __name(async (output, context) =>
1252
883
  await (0, import_smithy_client.collectBody)(output.body, context);
1253
884
  return contents;
1254
885
  }, "de_UntagResourceCommand");
1255
- var de_UntagResourceCommandError = /* @__PURE__ */ __name(async (output, context) => {
886
+ var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
1256
887
  const parsedOutput = {
1257
888
  ...output,
1258
889
  body: await parseErrorBody(output.body, context)
1259
890
  };
1260
891
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1261
892
  switch (errorCode) {
893
+ case "AccessDeniedException":
894
+ case "com.amazonaws.braket#AccessDeniedException":
895
+ throw await de_AccessDeniedExceptionRes(parsedOutput, context);
896
+ case "ConflictException":
897
+ case "com.amazonaws.braket#ConflictException":
898
+ throw await de_ConflictExceptionRes(parsedOutput, context);
1262
899
  case "InternalServiceException":
1263
900
  case "com.amazonaws.braket#InternalServiceException":
1264
901
  throw await de_InternalServiceExceptionRes(parsedOutput, context);
1265
902
  case "ResourceNotFoundException":
1266
903
  case "com.amazonaws.braket#ResourceNotFoundException":
1267
904
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
905
+ case "ThrottlingException":
906
+ case "com.amazonaws.braket#ThrottlingException":
907
+ throw await de_ThrottlingExceptionRes(parsedOutput, context);
1268
908
  case "ValidationException":
1269
909
  case "com.amazonaws.braket#ValidationException":
1270
910
  throw await de_ValidationExceptionRes(parsedOutput, context);
911
+ case "DeviceRetiredException":
912
+ case "com.amazonaws.braket#DeviceRetiredException":
913
+ throw await de_DeviceRetiredExceptionRes(parsedOutput, context);
914
+ case "ServiceQuotaExceededException":
915
+ case "com.amazonaws.braket#ServiceQuotaExceededException":
916
+ throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
917
+ case "DeviceOfflineException":
918
+ case "com.amazonaws.braket#DeviceOfflineException":
919
+ throw await de_DeviceOfflineExceptionRes(parsedOutput, context);
1271
920
  default:
1272
921
  const parsedBody = parsedOutput.body;
1273
922
  return throwDefaultError({
@@ -1276,7 +925,7 @@ var de_UntagResourceCommandError = /* @__PURE__ */ __name(async (output, context
1276
925
  errorCode
1277
926
  });
1278
927
  }
1279
- }, "de_UntagResourceCommandError");
928
+ }, "de_CommandError");
1280
929
  var throwDefaultError = (0, import_smithy_client.withBaseException)(BraketServiceException);
1281
930
  var de_AccessDeniedExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1282
931
  const contents = (0, import_smithy_client.map)({});
@@ -197,7 +197,7 @@ export const se_UntagResourceCommand = async (input, context) => {
197
197
  };
198
198
  export const de_CancelJobCommand = async (output, context) => {
199
199
  if (output.statusCode !== 200 && output.statusCode >= 300) {
200
- return de_CancelJobCommandError(output, context);
200
+ return de_CommandError(output, context);
201
201
  }
202
202
  const contents = map({
203
203
  $metadata: deserializeMetadata(output),
@@ -210,43 +210,9 @@ export const de_CancelJobCommand = async (output, context) => {
210
210
  Object.assign(contents, doc);
211
211
  return contents;
212
212
  };
213
- const de_CancelJobCommandError = async (output, context) => {
214
- const parsedOutput = {
215
- ...output,
216
- body: await parseErrorBody(output.body, context),
217
- };
218
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
219
- switch (errorCode) {
220
- case "AccessDeniedException":
221
- case "com.amazonaws.braket#AccessDeniedException":
222
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
223
- case "ConflictException":
224
- case "com.amazonaws.braket#ConflictException":
225
- throw await de_ConflictExceptionRes(parsedOutput, context);
226
- case "InternalServiceException":
227
- case "com.amazonaws.braket#InternalServiceException":
228
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
229
- case "ResourceNotFoundException":
230
- case "com.amazonaws.braket#ResourceNotFoundException":
231
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
232
- case "ThrottlingException":
233
- case "com.amazonaws.braket#ThrottlingException":
234
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
235
- case "ValidationException":
236
- case "com.amazonaws.braket#ValidationException":
237
- throw await de_ValidationExceptionRes(parsedOutput, context);
238
- default:
239
- const parsedBody = parsedOutput.body;
240
- return throwDefaultError({
241
- output,
242
- parsedBody,
243
- errorCode,
244
- });
245
- }
246
- };
247
213
  export const de_CancelQuantumTaskCommand = async (output, context) => {
248
214
  if (output.statusCode !== 200 && output.statusCode >= 300) {
249
- return de_CancelQuantumTaskCommandError(output, context);
215
+ return de_CommandError(output, context);
250
216
  }
251
217
  const contents = map({
252
218
  $metadata: deserializeMetadata(output),
@@ -259,43 +225,9 @@ export const de_CancelQuantumTaskCommand = async (output, context) => {
259
225
  Object.assign(contents, doc);
260
226
  return contents;
261
227
  };
262
- const de_CancelQuantumTaskCommandError = async (output, context) => {
263
- const parsedOutput = {
264
- ...output,
265
- body: await parseErrorBody(output.body, context),
266
- };
267
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
268
- switch (errorCode) {
269
- case "AccessDeniedException":
270
- case "com.amazonaws.braket#AccessDeniedException":
271
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
272
- case "ConflictException":
273
- case "com.amazonaws.braket#ConflictException":
274
- throw await de_ConflictExceptionRes(parsedOutput, context);
275
- case "InternalServiceException":
276
- case "com.amazonaws.braket#InternalServiceException":
277
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
278
- case "ResourceNotFoundException":
279
- case "com.amazonaws.braket#ResourceNotFoundException":
280
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
281
- case "ThrottlingException":
282
- case "com.amazonaws.braket#ThrottlingException":
283
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
284
- case "ValidationException":
285
- case "com.amazonaws.braket#ValidationException":
286
- throw await de_ValidationExceptionRes(parsedOutput, context);
287
- default:
288
- const parsedBody = parsedOutput.body;
289
- return throwDefaultError({
290
- output,
291
- parsedBody,
292
- errorCode,
293
- });
294
- }
295
- };
296
228
  export const de_CreateJobCommand = async (output, context) => {
297
229
  if (output.statusCode !== 201 && output.statusCode >= 300) {
298
- return de_CreateJobCommandError(output, context);
230
+ return de_CommandError(output, context);
299
231
  }
300
232
  const contents = map({
301
233
  $metadata: deserializeMetadata(output),
@@ -307,46 +239,9 @@ export const de_CreateJobCommand = async (output, context) => {
307
239
  Object.assign(contents, doc);
308
240
  return contents;
309
241
  };
310
- const de_CreateJobCommandError = async (output, context) => {
311
- const parsedOutput = {
312
- ...output,
313
- body: await parseErrorBody(output.body, context),
314
- };
315
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
316
- switch (errorCode) {
317
- case "AccessDeniedException":
318
- case "com.amazonaws.braket#AccessDeniedException":
319
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
320
- case "ConflictException":
321
- case "com.amazonaws.braket#ConflictException":
322
- throw await de_ConflictExceptionRes(parsedOutput, context);
323
- case "DeviceRetiredException":
324
- case "com.amazonaws.braket#DeviceRetiredException":
325
- throw await de_DeviceRetiredExceptionRes(parsedOutput, context);
326
- case "InternalServiceException":
327
- case "com.amazonaws.braket#InternalServiceException":
328
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
329
- case "ServiceQuotaExceededException":
330
- case "com.amazonaws.braket#ServiceQuotaExceededException":
331
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
332
- case "ThrottlingException":
333
- case "com.amazonaws.braket#ThrottlingException":
334
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
335
- case "ValidationException":
336
- case "com.amazonaws.braket#ValidationException":
337
- throw await de_ValidationExceptionRes(parsedOutput, context);
338
- default:
339
- const parsedBody = parsedOutput.body;
340
- return throwDefaultError({
341
- output,
342
- parsedBody,
343
- errorCode,
344
- });
345
- }
346
- };
347
242
  export const de_CreateQuantumTaskCommand = async (output, context) => {
348
243
  if (output.statusCode !== 201 && output.statusCode >= 300) {
349
- return de_CreateQuantumTaskCommandError(output, context);
244
+ return de_CommandError(output, context);
350
245
  }
351
246
  const contents = map({
352
247
  $metadata: deserializeMetadata(output),
@@ -358,46 +253,9 @@ export const de_CreateQuantumTaskCommand = async (output, context) => {
358
253
  Object.assign(contents, doc);
359
254
  return contents;
360
255
  };
361
- const de_CreateQuantumTaskCommandError = async (output, context) => {
362
- const parsedOutput = {
363
- ...output,
364
- body: await parseErrorBody(output.body, context),
365
- };
366
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
367
- switch (errorCode) {
368
- case "AccessDeniedException":
369
- case "com.amazonaws.braket#AccessDeniedException":
370
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
371
- case "DeviceOfflineException":
372
- case "com.amazonaws.braket#DeviceOfflineException":
373
- throw await de_DeviceOfflineExceptionRes(parsedOutput, context);
374
- case "DeviceRetiredException":
375
- case "com.amazonaws.braket#DeviceRetiredException":
376
- throw await de_DeviceRetiredExceptionRes(parsedOutput, context);
377
- case "InternalServiceException":
378
- case "com.amazonaws.braket#InternalServiceException":
379
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
380
- case "ServiceQuotaExceededException":
381
- case "com.amazonaws.braket#ServiceQuotaExceededException":
382
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
383
- case "ThrottlingException":
384
- case "com.amazonaws.braket#ThrottlingException":
385
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
386
- case "ValidationException":
387
- case "com.amazonaws.braket#ValidationException":
388
- throw await de_ValidationExceptionRes(parsedOutput, context);
389
- default:
390
- const parsedBody = parsedOutput.body;
391
- return throwDefaultError({
392
- output,
393
- parsedBody,
394
- errorCode,
395
- });
396
- }
397
- };
398
256
  export const de_GetDeviceCommand = async (output, context) => {
399
257
  if (output.statusCode !== 200 && output.statusCode >= 300) {
400
- return de_GetDeviceCommandError(output, context);
258
+ return de_CommandError(output, context);
401
259
  }
402
260
  const contents = map({
403
261
  $metadata: deserializeMetadata(output),
@@ -415,40 +273,9 @@ export const de_GetDeviceCommand = async (output, context) => {
415
273
  Object.assign(contents, doc);
416
274
  return contents;
417
275
  };
418
- const de_GetDeviceCommandError = async (output, context) => {
419
- const parsedOutput = {
420
- ...output,
421
- body: await parseErrorBody(output.body, context),
422
- };
423
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
424
- switch (errorCode) {
425
- case "AccessDeniedException":
426
- case "com.amazonaws.braket#AccessDeniedException":
427
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
428
- case "InternalServiceException":
429
- case "com.amazonaws.braket#InternalServiceException":
430
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
431
- case "ResourceNotFoundException":
432
- case "com.amazonaws.braket#ResourceNotFoundException":
433
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
434
- case "ThrottlingException":
435
- case "com.amazonaws.braket#ThrottlingException":
436
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
437
- case "ValidationException":
438
- case "com.amazonaws.braket#ValidationException":
439
- throw await de_ValidationExceptionRes(parsedOutput, context);
440
- default:
441
- const parsedBody = parsedOutput.body;
442
- return throwDefaultError({
443
- output,
444
- parsedBody,
445
- errorCode,
446
- });
447
- }
448
- };
449
276
  export const de_GetJobCommand = async (output, context) => {
450
277
  if (output.statusCode !== 200 && output.statusCode >= 300) {
451
- return de_GetJobCommandError(output, context);
278
+ return de_CommandError(output, context);
452
279
  }
453
280
  const contents = map({
454
281
  $metadata: deserializeMetadata(output),
@@ -480,40 +307,9 @@ export const de_GetJobCommand = async (output, context) => {
480
307
  Object.assign(contents, doc);
481
308
  return contents;
482
309
  };
483
- const de_GetJobCommandError = async (output, context) => {
484
- const parsedOutput = {
485
- ...output,
486
- body: await parseErrorBody(output.body, context),
487
- };
488
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
489
- switch (errorCode) {
490
- case "AccessDeniedException":
491
- case "com.amazonaws.braket#AccessDeniedException":
492
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
493
- case "InternalServiceException":
494
- case "com.amazonaws.braket#InternalServiceException":
495
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
496
- case "ResourceNotFoundException":
497
- case "com.amazonaws.braket#ResourceNotFoundException":
498
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
499
- case "ThrottlingException":
500
- case "com.amazonaws.braket#ThrottlingException":
501
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
502
- case "ValidationException":
503
- case "com.amazonaws.braket#ValidationException":
504
- throw await de_ValidationExceptionRes(parsedOutput, context);
505
- default:
506
- const parsedBody = parsedOutput.body;
507
- return throwDefaultError({
508
- output,
509
- parsedBody,
510
- errorCode,
511
- });
512
- }
513
- };
514
310
  export const de_GetQuantumTaskCommand = async (output, context) => {
515
311
  if (output.statusCode !== 200 && output.statusCode >= 300) {
516
- return de_GetQuantumTaskCommandError(output, context);
312
+ return de_CommandError(output, context);
517
313
  }
518
314
  const contents = map({
519
315
  $metadata: deserializeMetadata(output),
@@ -538,40 +334,9 @@ export const de_GetQuantumTaskCommand = async (output, context) => {
538
334
  Object.assign(contents, doc);
539
335
  return contents;
540
336
  };
541
- const de_GetQuantumTaskCommandError = async (output, context) => {
542
- const parsedOutput = {
543
- ...output,
544
- body: await parseErrorBody(output.body, context),
545
- };
546
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
547
- switch (errorCode) {
548
- case "AccessDeniedException":
549
- case "com.amazonaws.braket#AccessDeniedException":
550
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
551
- case "InternalServiceException":
552
- case "com.amazonaws.braket#InternalServiceException":
553
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
554
- case "ResourceNotFoundException":
555
- case "com.amazonaws.braket#ResourceNotFoundException":
556
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
557
- case "ThrottlingException":
558
- case "com.amazonaws.braket#ThrottlingException":
559
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
560
- case "ValidationException":
561
- case "com.amazonaws.braket#ValidationException":
562
- throw await de_ValidationExceptionRes(parsedOutput, context);
563
- default:
564
- const parsedBody = parsedOutput.body;
565
- return throwDefaultError({
566
- output,
567
- parsedBody,
568
- errorCode,
569
- });
570
- }
571
- };
572
337
  export const de_ListTagsForResourceCommand = async (output, context) => {
573
338
  if (output.statusCode !== 200 && output.statusCode >= 300) {
574
- return de_ListTagsForResourceCommandError(output, context);
339
+ return de_CommandError(output, context);
575
340
  }
576
341
  const contents = map({
577
342
  $metadata: deserializeMetadata(output),
@@ -583,34 +348,9 @@ export const de_ListTagsForResourceCommand = async (output, context) => {
583
348
  Object.assign(contents, doc);
584
349
  return contents;
585
350
  };
586
- const de_ListTagsForResourceCommandError = async (output, context) => {
587
- const parsedOutput = {
588
- ...output,
589
- body: await parseErrorBody(output.body, context),
590
- };
591
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
592
- switch (errorCode) {
593
- case "InternalServiceException":
594
- case "com.amazonaws.braket#InternalServiceException":
595
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
596
- case "ResourceNotFoundException":
597
- case "com.amazonaws.braket#ResourceNotFoundException":
598
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
599
- case "ValidationException":
600
- case "com.amazonaws.braket#ValidationException":
601
- throw await de_ValidationExceptionRes(parsedOutput, context);
602
- default:
603
- const parsedBody = parsedOutput.body;
604
- return throwDefaultError({
605
- output,
606
- parsedBody,
607
- errorCode,
608
- });
609
- }
610
- };
611
351
  export const de_SearchDevicesCommand = async (output, context) => {
612
352
  if (output.statusCode !== 200 && output.statusCode >= 300) {
613
- return de_SearchDevicesCommandError(output, context);
353
+ return de_CommandError(output, context);
614
354
  }
615
355
  const contents = map({
616
356
  $metadata: deserializeMetadata(output),
@@ -623,37 +363,9 @@ export const de_SearchDevicesCommand = async (output, context) => {
623
363
  Object.assign(contents, doc);
624
364
  return contents;
625
365
  };
626
- const de_SearchDevicesCommandError = async (output, context) => {
627
- const parsedOutput = {
628
- ...output,
629
- body: await parseErrorBody(output.body, context),
630
- };
631
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
632
- switch (errorCode) {
633
- case "AccessDeniedException":
634
- case "com.amazonaws.braket#AccessDeniedException":
635
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
636
- case "InternalServiceException":
637
- case "com.amazonaws.braket#InternalServiceException":
638
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
639
- case "ThrottlingException":
640
- case "com.amazonaws.braket#ThrottlingException":
641
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
642
- case "ValidationException":
643
- case "com.amazonaws.braket#ValidationException":
644
- throw await de_ValidationExceptionRes(parsedOutput, context);
645
- default:
646
- const parsedBody = parsedOutput.body;
647
- return throwDefaultError({
648
- output,
649
- parsedBody,
650
- errorCode,
651
- });
652
- }
653
- };
654
366
  export const de_SearchJobsCommand = async (output, context) => {
655
367
  if (output.statusCode !== 200 && output.statusCode >= 300) {
656
- return de_SearchJobsCommandError(output, context);
368
+ return de_CommandError(output, context);
657
369
  }
658
370
  const contents = map({
659
371
  $metadata: deserializeMetadata(output),
@@ -666,37 +378,9 @@ export const de_SearchJobsCommand = async (output, context) => {
666
378
  Object.assign(contents, doc);
667
379
  return contents;
668
380
  };
669
- const de_SearchJobsCommandError = async (output, context) => {
670
- const parsedOutput = {
671
- ...output,
672
- body: await parseErrorBody(output.body, context),
673
- };
674
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
675
- switch (errorCode) {
676
- case "AccessDeniedException":
677
- case "com.amazonaws.braket#AccessDeniedException":
678
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
679
- case "InternalServiceException":
680
- case "com.amazonaws.braket#InternalServiceException":
681
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
682
- case "ThrottlingException":
683
- case "com.amazonaws.braket#ThrottlingException":
684
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
685
- case "ValidationException":
686
- case "com.amazonaws.braket#ValidationException":
687
- throw await de_ValidationExceptionRes(parsedOutput, context);
688
- default:
689
- const parsedBody = parsedOutput.body;
690
- return throwDefaultError({
691
- output,
692
- parsedBody,
693
- errorCode,
694
- });
695
- }
696
- };
697
381
  export const de_SearchQuantumTasksCommand = async (output, context) => {
698
382
  if (output.statusCode !== 200 && output.statusCode >= 300) {
699
- return de_SearchQuantumTasksCommandError(output, context);
383
+ return de_CommandError(output, context);
700
384
  }
701
385
  const contents = map({
702
386
  $metadata: deserializeMetadata(output),
@@ -709,37 +393,9 @@ export const de_SearchQuantumTasksCommand = async (output, context) => {
709
393
  Object.assign(contents, doc);
710
394
  return contents;
711
395
  };
712
- const de_SearchQuantumTasksCommandError = async (output, context) => {
713
- const parsedOutput = {
714
- ...output,
715
- body: await parseErrorBody(output.body, context),
716
- };
717
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
718
- switch (errorCode) {
719
- case "AccessDeniedException":
720
- case "com.amazonaws.braket#AccessDeniedException":
721
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
722
- case "InternalServiceException":
723
- case "com.amazonaws.braket#InternalServiceException":
724
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
725
- case "ThrottlingException":
726
- case "com.amazonaws.braket#ThrottlingException":
727
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
728
- case "ValidationException":
729
- case "com.amazonaws.braket#ValidationException":
730
- throw await de_ValidationExceptionRes(parsedOutput, context);
731
- default:
732
- const parsedBody = parsedOutput.body;
733
- return throwDefaultError({
734
- output,
735
- parsedBody,
736
- errorCode,
737
- });
738
- }
739
- };
740
396
  export const de_TagResourceCommand = async (output, context) => {
741
397
  if (output.statusCode !== 200 && output.statusCode >= 300) {
742
- return de_TagResourceCommandError(output, context);
398
+ return de_CommandError(output, context);
743
399
  }
744
400
  const contents = map({
745
401
  $metadata: deserializeMetadata(output),
@@ -747,34 +403,9 @@ export const de_TagResourceCommand = async (output, context) => {
747
403
  await collectBody(output.body, context);
748
404
  return contents;
749
405
  };
750
- const de_TagResourceCommandError = async (output, context) => {
751
- const parsedOutput = {
752
- ...output,
753
- body: await parseErrorBody(output.body, context),
754
- };
755
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
756
- switch (errorCode) {
757
- case "InternalServiceException":
758
- case "com.amazonaws.braket#InternalServiceException":
759
- throw await de_InternalServiceExceptionRes(parsedOutput, context);
760
- case "ResourceNotFoundException":
761
- case "com.amazonaws.braket#ResourceNotFoundException":
762
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
763
- case "ValidationException":
764
- case "com.amazonaws.braket#ValidationException":
765
- throw await de_ValidationExceptionRes(parsedOutput, context);
766
- default:
767
- const parsedBody = parsedOutput.body;
768
- return throwDefaultError({
769
- output,
770
- parsedBody,
771
- errorCode,
772
- });
773
- }
774
- };
775
406
  export const de_UntagResourceCommand = async (output, context) => {
776
407
  if (output.statusCode !== 200 && output.statusCode >= 300) {
777
- return de_UntagResourceCommandError(output, context);
408
+ return de_CommandError(output, context);
778
409
  }
779
410
  const contents = map({
780
411
  $metadata: deserializeMetadata(output),
@@ -782,22 +413,40 @@ export const de_UntagResourceCommand = async (output, context) => {
782
413
  await collectBody(output.body, context);
783
414
  return contents;
784
415
  };
785
- const de_UntagResourceCommandError = async (output, context) => {
416
+ const de_CommandError = async (output, context) => {
786
417
  const parsedOutput = {
787
418
  ...output,
788
419
  body: await parseErrorBody(output.body, context),
789
420
  };
790
421
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
791
422
  switch (errorCode) {
423
+ case "AccessDeniedException":
424
+ case "com.amazonaws.braket#AccessDeniedException":
425
+ throw await de_AccessDeniedExceptionRes(parsedOutput, context);
426
+ case "ConflictException":
427
+ case "com.amazonaws.braket#ConflictException":
428
+ throw await de_ConflictExceptionRes(parsedOutput, context);
792
429
  case "InternalServiceException":
793
430
  case "com.amazonaws.braket#InternalServiceException":
794
431
  throw await de_InternalServiceExceptionRes(parsedOutput, context);
795
432
  case "ResourceNotFoundException":
796
433
  case "com.amazonaws.braket#ResourceNotFoundException":
797
434
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
435
+ case "ThrottlingException":
436
+ case "com.amazonaws.braket#ThrottlingException":
437
+ throw await de_ThrottlingExceptionRes(parsedOutput, context);
798
438
  case "ValidationException":
799
439
  case "com.amazonaws.braket#ValidationException":
800
440
  throw await de_ValidationExceptionRes(parsedOutput, context);
441
+ case "DeviceRetiredException":
442
+ case "com.amazonaws.braket#DeviceRetiredException":
443
+ throw await de_DeviceRetiredExceptionRes(parsedOutput, context);
444
+ case "ServiceQuotaExceededException":
445
+ case "com.amazonaws.braket#ServiceQuotaExceededException":
446
+ throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
447
+ case "DeviceOfflineException":
448
+ case "com.amazonaws.braket#DeviceOfflineException":
449
+ throw await de_DeviceOfflineExceptionRes(parsedOutput, context);
801
450
  default:
802
451
  const parsedBody = parsedOutput.body;
803
452
  return throwDefaultError({
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-braket",
3
3
  "description": "AWS SDK for JavaScript Braket Client for Node.js, Browser and React Native",
4
- "version": "3.504.0",
4
+ "version": "3.507.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "node ../../scripts/compilation/inline client-braket",
@@ -20,9 +20,9 @@
20
20
  "dependencies": {
21
21
  "@aws-crypto/sha256-browser": "3.0.0",
22
22
  "@aws-crypto/sha256-js": "3.0.0",
23
- "@aws-sdk/client-sts": "3.504.0",
23
+ "@aws-sdk/client-sts": "3.507.0",
24
24
  "@aws-sdk/core": "3.496.0",
25
- "@aws-sdk/credential-provider-node": "3.504.0",
25
+ "@aws-sdk/credential-provider-node": "3.507.0",
26
26
  "@aws-sdk/middleware-host-header": "3.502.0",
27
27
  "@aws-sdk/middleware-logger": "3.502.0",
28
28
  "@aws-sdk/middleware-recursion-detection": "3.502.0",