@aws-sdk/client-dataexchange 3.179.0 → 3.181.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/CHANGELOG.md CHANGED
@@ -3,6 +3,26 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.181.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.180.0...v3.181.0) (2022-09-29)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **clients:** make parseErrorBody async ([#3999](https://github.com/aws/aws-sdk-js-v3/issues/3999)) ([2558c93](https://github.com/aws/aws-sdk-js-v3/commit/2558c93c050357ac6dc47aa0452b15b12ebfd676))
12
+ * **clients:** populate message field when parsing errors ([#3995](https://github.com/aws/aws-sdk-js-v3/issues/3995)) ([02e47f1](https://github.com/aws/aws-sdk-js-v3/commit/02e47f14397ae0a5d2e2883350d038b307fdcdb4))
13
+
14
+
15
+
16
+
17
+
18
+ # [3.180.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.179.0...v3.180.0) (2022-09-27)
19
+
20
+ **Note:** Version bump only for package @aws-sdk/client-dataexchange
21
+
22
+
23
+
24
+
25
+
6
26
  # [3.179.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.178.0...v3.179.0) (2022-09-26)
7
27
 
8
28
  **Note:** Version bump only for package @aws-sdk/client-dataexchange
@@ -642,7 +642,7 @@ exports.deserializeAws_restJson1CancelJobCommand = deserializeAws_restJson1Cance
642
642
  const deserializeAws_restJson1CancelJobCommandError = async (output, context) => {
643
643
  const parsedOutput = {
644
644
  ...output,
645
- body: await parseBody(output.body, context),
645
+ body: await parseErrorBody(output.body, context),
646
646
  };
647
647
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
648
648
  switch (errorCode) {
@@ -718,7 +718,7 @@ exports.deserializeAws_restJson1CreateDataSetCommand = deserializeAws_restJson1C
718
718
  const deserializeAws_restJson1CreateDataSetCommandError = async (output, context) => {
719
719
  const parsedOutput = {
720
720
  ...output,
721
- body: await parseBody(output.body, context),
721
+ body: await parseErrorBody(output.body, context),
722
722
  };
723
723
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
724
724
  switch (errorCode) {
@@ -779,7 +779,7 @@ exports.deserializeAws_restJson1CreateEventActionCommand = deserializeAws_restJs
779
779
  const deserializeAws_restJson1CreateEventActionCommandError = async (output, context) => {
780
780
  const parsedOutput = {
781
781
  ...output,
782
- body: await parseBody(output.body, context),
782
+ body: await parseErrorBody(output.body, context),
783
783
  };
784
784
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
785
785
  switch (errorCode) {
@@ -846,7 +846,7 @@ exports.deserializeAws_restJson1CreateJobCommand = deserializeAws_restJson1Creat
846
846
  const deserializeAws_restJson1CreateJobCommandError = async (output, context) => {
847
847
  const parsedOutput = {
848
848
  ...output,
849
- body: await parseBody(output.body, context),
849
+ body: await parseErrorBody(output.body, context),
850
850
  };
851
851
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
852
852
  switch (errorCode) {
@@ -928,7 +928,7 @@ exports.deserializeAws_restJson1CreateRevisionCommand = deserializeAws_restJson1
928
928
  const deserializeAws_restJson1CreateRevisionCommandError = async (output, context) => {
929
929
  const parsedOutput = {
930
930
  ...output,
931
- body: await parseBody(output.body, context),
931
+ body: await parseErrorBody(output.body, context),
932
932
  };
933
933
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
934
934
  switch (errorCode) {
@@ -971,7 +971,7 @@ exports.deserializeAws_restJson1DeleteAssetCommand = deserializeAws_restJson1Del
971
971
  const deserializeAws_restJson1DeleteAssetCommandError = async (output, context) => {
972
972
  const parsedOutput = {
973
973
  ...output,
974
- body: await parseBody(output.body, context),
974
+ body: await parseErrorBody(output.body, context),
975
975
  };
976
976
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
977
977
  switch (errorCode) {
@@ -1017,7 +1017,7 @@ exports.deserializeAws_restJson1DeleteDataSetCommand = deserializeAws_restJson1D
1017
1017
  const deserializeAws_restJson1DeleteDataSetCommandError = async (output, context) => {
1018
1018
  const parsedOutput = {
1019
1019
  ...output,
1020
- body: await parseBody(output.body, context),
1020
+ body: await parseErrorBody(output.body, context),
1021
1021
  };
1022
1022
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1023
1023
  switch (errorCode) {
@@ -1063,7 +1063,7 @@ exports.deserializeAws_restJson1DeleteEventActionCommand = deserializeAws_restJs
1063
1063
  const deserializeAws_restJson1DeleteEventActionCommandError = async (output, context) => {
1064
1064
  const parsedOutput = {
1065
1065
  ...output,
1066
- body: await parseBody(output.body, context),
1066
+ body: await parseErrorBody(output.body, context),
1067
1067
  };
1068
1068
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1069
1069
  switch (errorCode) {
@@ -1103,7 +1103,7 @@ exports.deserializeAws_restJson1DeleteRevisionCommand = deserializeAws_restJson1
1103
1103
  const deserializeAws_restJson1DeleteRevisionCommandError = async (output, context) => {
1104
1104
  const parsedOutput = {
1105
1105
  ...output,
1106
- body: await parseBody(output.body, context),
1106
+ body: await parseErrorBody(output.body, context),
1107
1107
  };
1108
1108
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1109
1109
  switch (errorCode) {
@@ -1179,7 +1179,7 @@ exports.deserializeAws_restJson1GetAssetCommand = deserializeAws_restJson1GetAss
1179
1179
  const deserializeAws_restJson1GetAssetCommandError = async (output, context) => {
1180
1180
  const parsedOutput = {
1181
1181
  ...output,
1182
- body: await parseBody(output.body, context),
1182
+ body: await parseErrorBody(output.body, context),
1183
1183
  };
1184
1184
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1185
1185
  switch (errorCode) {
@@ -1252,7 +1252,7 @@ exports.deserializeAws_restJson1GetDataSetCommand = deserializeAws_restJson1GetD
1252
1252
  const deserializeAws_restJson1GetDataSetCommandError = async (output, context) => {
1253
1253
  const parsedOutput = {
1254
1254
  ...output,
1255
- body: await parseBody(output.body, context),
1255
+ body: await parseErrorBody(output.body, context),
1256
1256
  };
1257
1257
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1258
1258
  switch (errorCode) {
@@ -1310,7 +1310,7 @@ exports.deserializeAws_restJson1GetEventActionCommand = deserializeAws_restJson1
1310
1310
  const deserializeAws_restJson1GetEventActionCommandError = async (output, context) => {
1311
1311
  const parsedOutput = {
1312
1312
  ...output,
1313
- body: await parseBody(output.body, context),
1313
+ body: await parseErrorBody(output.body, context),
1314
1314
  };
1315
1315
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1316
1316
  switch (errorCode) {
@@ -1374,7 +1374,7 @@ exports.deserializeAws_restJson1GetJobCommand = deserializeAws_restJson1GetJobCo
1374
1374
  const deserializeAws_restJson1GetJobCommandError = async (output, context) => {
1375
1375
  const parsedOutput = {
1376
1376
  ...output,
1377
- body: await parseBody(output.body, context),
1377
+ body: await parseErrorBody(output.body, context),
1378
1378
  };
1379
1379
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1380
1380
  switch (errorCode) {
@@ -1450,7 +1450,7 @@ exports.deserializeAws_restJson1GetRevisionCommand = deserializeAws_restJson1Get
1450
1450
  const deserializeAws_restJson1GetRevisionCommandError = async (output, context) => {
1451
1451
  const parsedOutput = {
1452
1452
  ...output,
1453
- body: await parseBody(output.body, context),
1453
+ body: await parseErrorBody(output.body, context),
1454
1454
  };
1455
1455
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1456
1456
  switch (errorCode) {
@@ -1496,7 +1496,7 @@ exports.deserializeAws_restJson1ListDataSetRevisionsCommand = deserializeAws_res
1496
1496
  const deserializeAws_restJson1ListDataSetRevisionsCommandError = async (output, context) => {
1497
1497
  const parsedOutput = {
1498
1498
  ...output,
1499
- body: await parseBody(output.body, context),
1499
+ body: await parseErrorBody(output.body, context),
1500
1500
  };
1501
1501
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1502
1502
  switch (errorCode) {
@@ -1542,7 +1542,7 @@ exports.deserializeAws_restJson1ListDataSetsCommand = deserializeAws_restJson1Li
1542
1542
  const deserializeAws_restJson1ListDataSetsCommandError = async (output, context) => {
1543
1543
  const parsedOutput = {
1544
1544
  ...output,
1545
- body: await parseBody(output.body, context),
1545
+ body: await parseErrorBody(output.body, context),
1546
1546
  };
1547
1547
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1548
1548
  switch (errorCode) {
@@ -1588,7 +1588,7 @@ exports.deserializeAws_restJson1ListEventActionsCommand = deserializeAws_restJso
1588
1588
  const deserializeAws_restJson1ListEventActionsCommandError = async (output, context) => {
1589
1589
  const parsedOutput = {
1590
1590
  ...output,
1591
- body: await parseBody(output.body, context),
1591
+ body: await parseErrorBody(output.body, context),
1592
1592
  };
1593
1593
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1594
1594
  switch (errorCode) {
@@ -1634,7 +1634,7 @@ exports.deserializeAws_restJson1ListJobsCommand = deserializeAws_restJson1ListJo
1634
1634
  const deserializeAws_restJson1ListJobsCommandError = async (output, context) => {
1635
1635
  const parsedOutput = {
1636
1636
  ...output,
1637
- body: await parseBody(output.body, context),
1637
+ body: await parseErrorBody(output.body, context),
1638
1638
  };
1639
1639
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1640
1640
  switch (errorCode) {
@@ -1680,7 +1680,7 @@ exports.deserializeAws_restJson1ListRevisionAssetsCommand = deserializeAws_restJ
1680
1680
  const deserializeAws_restJson1ListRevisionAssetsCommandError = async (output, context) => {
1681
1681
  const parsedOutput = {
1682
1682
  ...output,
1683
- body: await parseBody(output.body, context),
1683
+ body: await parseErrorBody(output.body, context),
1684
1684
  };
1685
1685
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1686
1686
  switch (errorCode) {
@@ -1723,7 +1723,7 @@ exports.deserializeAws_restJson1ListTagsForResourceCommand = deserializeAws_rest
1723
1723
  const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, context) => {
1724
1724
  const parsedOutput = {
1725
1725
  ...output,
1726
- body: await parseBody(output.body, context),
1726
+ body: await parseErrorBody(output.body, context),
1727
1727
  };
1728
1728
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1729
1729
  const parsedBody = parsedOutput.body;
@@ -1781,7 +1781,7 @@ exports.deserializeAws_restJson1RevokeRevisionCommand = deserializeAws_restJson1
1781
1781
  const deserializeAws_restJson1RevokeRevisionCommandError = async (output, context) => {
1782
1782
  const parsedOutput = {
1783
1783
  ...output,
1784
- body: await parseBody(output.body, context),
1784
+ body: await parseErrorBody(output.body, context),
1785
1785
  };
1786
1786
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1787
1787
  switch (errorCode) {
@@ -1837,7 +1837,7 @@ exports.deserializeAws_restJson1SendApiAssetCommand = deserializeAws_restJson1Se
1837
1837
  const deserializeAws_restJson1SendApiAssetCommandError = async (output, context) => {
1838
1838
  const parsedOutput = {
1839
1839
  ...output,
1840
- body: await parseBody(output.body, context),
1840
+ body: await parseErrorBody(output.body, context),
1841
1841
  };
1842
1842
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1843
1843
  switch (errorCode) {
@@ -1880,7 +1880,7 @@ exports.deserializeAws_restJson1StartJobCommand = deserializeAws_restJson1StartJ
1880
1880
  const deserializeAws_restJson1StartJobCommandError = async (output, context) => {
1881
1881
  const parsedOutput = {
1882
1882
  ...output,
1883
- body: await parseBody(output.body, context),
1883
+ body: await parseErrorBody(output.body, context),
1884
1884
  };
1885
1885
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1886
1886
  switch (errorCode) {
@@ -1926,7 +1926,7 @@ exports.deserializeAws_restJson1TagResourceCommand = deserializeAws_restJson1Tag
1926
1926
  const deserializeAws_restJson1TagResourceCommandError = async (output, context) => {
1927
1927
  const parsedOutput = {
1928
1928
  ...output,
1929
- body: await parseBody(output.body, context),
1929
+ body: await parseErrorBody(output.body, context),
1930
1930
  };
1931
1931
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1932
1932
  const parsedBody = parsedOutput.body;
@@ -1951,7 +1951,7 @@ exports.deserializeAws_restJson1UntagResourceCommand = deserializeAws_restJson1U
1951
1951
  const deserializeAws_restJson1UntagResourceCommandError = async (output, context) => {
1952
1952
  const parsedOutput = {
1953
1953
  ...output,
1954
- body: await parseBody(output.body, context),
1954
+ body: await parseErrorBody(output.body, context),
1955
1955
  };
1956
1956
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1957
1957
  const parsedBody = parsedOutput.body;
@@ -2006,7 +2006,7 @@ exports.deserializeAws_restJson1UpdateAssetCommand = deserializeAws_restJson1Upd
2006
2006
  const deserializeAws_restJson1UpdateAssetCommandError = async (output, context) => {
2007
2007
  const parsedOutput = {
2008
2008
  ...output,
2009
- body: await parseBody(output.body, context),
2009
+ body: await parseErrorBody(output.body, context),
2010
2010
  };
2011
2011
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2012
2012
  switch (errorCode) {
@@ -2082,7 +2082,7 @@ exports.deserializeAws_restJson1UpdateDataSetCommand = deserializeAws_restJson1U
2082
2082
  const deserializeAws_restJson1UpdateDataSetCommandError = async (output, context) => {
2083
2083
  const parsedOutput = {
2084
2084
  ...output,
2085
- body: await parseBody(output.body, context),
2085
+ body: await parseErrorBody(output.body, context),
2086
2086
  };
2087
2087
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2088
2088
  switch (errorCode) {
@@ -2143,7 +2143,7 @@ exports.deserializeAws_restJson1UpdateEventActionCommand = deserializeAws_restJs
2143
2143
  const deserializeAws_restJson1UpdateEventActionCommandError = async (output, context) => {
2144
2144
  const parsedOutput = {
2145
2145
  ...output,
2146
- body: await parseBody(output.body, context),
2146
+ body: await parseErrorBody(output.body, context),
2147
2147
  };
2148
2148
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2149
2149
  switch (errorCode) {
@@ -2219,7 +2219,7 @@ exports.deserializeAws_restJson1UpdateRevisionCommand = deserializeAws_restJson1
2219
2219
  const deserializeAws_restJson1UpdateRevisionCommandError = async (output, context) => {
2220
2220
  const parsedOutput = {
2221
2221
  ...output,
2222
- body: await parseBody(output.body, context),
2222
+ body: await parseErrorBody(output.body, context),
2223
2223
  };
2224
2224
  const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2225
2225
  switch (errorCode) {
@@ -3011,6 +3011,12 @@ const parseBody = (streamBody, context) => collectBodyString(streamBody, context
3011
3011
  }
3012
3012
  return {};
3013
3013
  });
3014
+ const parseErrorBody = async (errorBody, context) => {
3015
+ var _a;
3016
+ const value = await parseBody(errorBody, context);
3017
+ value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
3018
+ return value;
3019
+ };
3014
3020
  const loadRestJsonErrorCode = (output, data) => {
3015
3021
  const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
3016
3022
  const sanitizeErrorCode = (rawValue) => {
@@ -760,7 +760,7 @@ var deserializeAws_restJson1CancelJobCommandError = function (output, context) {
760
760
  case 0:
761
761
  _a = [__assign({}, output)];
762
762
  _c = {};
763
- return [4, parseBody(output.body, context)];
763
+ return [4, parseErrorBody(output.body, context)];
764
764
  case 1:
765
765
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
766
766
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -862,7 +862,7 @@ var deserializeAws_restJson1CreateDataSetCommandError = function (output, contex
862
862
  case 0:
863
863
  _a = [__assign({}, output)];
864
864
  _c = {};
865
- return [4, parseBody(output.body, context)];
865
+ return [4, parseErrorBody(output.body, context)];
866
866
  case 1:
867
867
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
868
868
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -949,7 +949,7 @@ var deserializeAws_restJson1CreateEventActionCommandError = function (output, co
949
949
  case 0:
950
950
  _a = [__assign({}, output)];
951
951
  _c = {};
952
- return [4, parseBody(output.body, context)];
952
+ return [4, parseErrorBody(output.body, context)];
953
953
  case 1:
954
954
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
955
955
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1042,7 +1042,7 @@ var deserializeAws_restJson1CreateJobCommandError = function (output, context) {
1042
1042
  case 0:
1043
1043
  _a = [__assign({}, output)];
1044
1044
  _c = {};
1045
- return [4, parseBody(output.body, context)];
1045
+ return [4, parseErrorBody(output.body, context)];
1046
1046
  case 1:
1047
1047
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1048
1048
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1151,7 +1151,7 @@ var deserializeAws_restJson1CreateRevisionCommandError = function (output, conte
1151
1151
  case 0:
1152
1152
  _a = [__assign({}, output)];
1153
1153
  _c = {};
1154
- return [4, parseBody(output.body, context)];
1154
+ return [4, parseErrorBody(output.body, context)];
1155
1155
  case 1:
1156
1156
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1157
1157
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1218,7 +1218,7 @@ var deserializeAws_restJson1DeleteAssetCommandError = function (output, context)
1218
1218
  case 0:
1219
1219
  _a = [__assign({}, output)];
1220
1220
  _c = {};
1221
- return [4, parseBody(output.body, context)];
1221
+ return [4, parseErrorBody(output.body, context)];
1222
1222
  case 1:
1223
1223
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1224
1224
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1289,7 +1289,7 @@ var deserializeAws_restJson1DeleteDataSetCommandError = function (output, contex
1289
1289
  case 0:
1290
1290
  _a = [__assign({}, output)];
1291
1291
  _c = {};
1292
- return [4, parseBody(output.body, context)];
1292
+ return [4, parseErrorBody(output.body, context)];
1293
1293
  case 1:
1294
1294
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1295
1295
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1360,7 +1360,7 @@ var deserializeAws_restJson1DeleteEventActionCommandError = function (output, co
1360
1360
  case 0:
1361
1361
  _a = [__assign({}, output)];
1362
1362
  _c = {};
1363
- return [4, parseBody(output.body, context)];
1363
+ return [4, parseErrorBody(output.body, context)];
1364
1364
  case 1:
1365
1365
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1366
1366
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1423,7 +1423,7 @@ var deserializeAws_restJson1DeleteRevisionCommandError = function (output, conte
1423
1423
  case 0:
1424
1424
  _a = [__assign({}, output)];
1425
1425
  _c = {};
1426
- return [4, parseBody(output.body, context)];
1426
+ return [4, parseErrorBody(output.body, context)];
1427
1427
  case 1:
1428
1428
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1429
1429
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1526,7 +1526,7 @@ var deserializeAws_restJson1GetAssetCommandError = function (output, context) {
1526
1526
  case 0:
1527
1527
  _a = [__assign({}, output)];
1528
1528
  _c = {};
1529
- return [4, parseBody(output.body, context)];
1529
+ return [4, parseErrorBody(output.body, context)];
1530
1530
  case 1:
1531
1531
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1532
1532
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1624,7 +1624,7 @@ var deserializeAws_restJson1GetDataSetCommandError = function (output, context)
1624
1624
  case 0:
1625
1625
  _a = [__assign({}, output)];
1626
1626
  _c = {};
1627
- return [4, parseBody(output.body, context)];
1627
+ return [4, parseErrorBody(output.body, context)];
1628
1628
  case 1:
1629
1629
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1630
1630
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1707,7 +1707,7 @@ var deserializeAws_restJson1GetEventActionCommandError = function (output, conte
1707
1707
  case 0:
1708
1708
  _a = [__assign({}, output)];
1709
1709
  _c = {};
1710
- return [4, parseBody(output.body, context)];
1710
+ return [4, parseErrorBody(output.body, context)];
1711
1711
  case 1:
1712
1712
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1713
1713
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1796,7 +1796,7 @@ var deserializeAws_restJson1GetJobCommandError = function (output, context) { re
1796
1796
  case 0:
1797
1797
  _a = [__assign({}, output)];
1798
1798
  _c = {};
1799
- return [4, parseBody(output.body, context)];
1799
+ return [4, parseErrorBody(output.body, context)];
1800
1800
  case 1:
1801
1801
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1802
1802
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1897,7 +1897,7 @@ var deserializeAws_restJson1GetRevisionCommandError = function (output, context)
1897
1897
  case 0:
1898
1898
  _a = [__assign({}, output)];
1899
1899
  _c = {};
1900
- return [4, parseBody(output.body, context)];
1900
+ return [4, parseErrorBody(output.body, context)];
1901
1901
  case 1:
1902
1902
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1903
1903
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -1968,7 +1968,7 @@ var deserializeAws_restJson1ListDataSetRevisionsCommandError = function (output,
1968
1968
  case 0:
1969
1969
  _a = [__assign({}, output)];
1970
1970
  _c = {};
1971
- return [4, parseBody(output.body, context)];
1971
+ return [4, parseErrorBody(output.body, context)];
1972
1972
  case 1:
1973
1973
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
1974
1974
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2039,7 +2039,7 @@ var deserializeAws_restJson1ListDataSetsCommandError = function (output, context
2039
2039
  case 0:
2040
2040
  _a = [__assign({}, output)];
2041
2041
  _c = {};
2042
- return [4, parseBody(output.body, context)];
2042
+ return [4, parseErrorBody(output.body, context)];
2043
2043
  case 1:
2044
2044
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2045
2045
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2110,7 +2110,7 @@ var deserializeAws_restJson1ListEventActionsCommandError = function (output, con
2110
2110
  case 0:
2111
2111
  _a = [__assign({}, output)];
2112
2112
  _c = {};
2113
- return [4, parseBody(output.body, context)];
2113
+ return [4, parseErrorBody(output.body, context)];
2114
2114
  case 1:
2115
2115
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2116
2116
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2181,7 +2181,7 @@ var deserializeAws_restJson1ListJobsCommandError = function (output, context) {
2181
2181
  case 0:
2182
2182
  _a = [__assign({}, output)];
2183
2183
  _c = {};
2184
- return [4, parseBody(output.body, context)];
2184
+ return [4, parseErrorBody(output.body, context)];
2185
2185
  case 1:
2186
2186
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2187
2187
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2252,7 +2252,7 @@ var deserializeAws_restJson1ListRevisionAssetsCommandError = function (output, c
2252
2252
  case 0:
2253
2253
  _a = [__assign({}, output)];
2254
2254
  _c = {};
2255
- return [4, parseBody(output.body, context)];
2255
+ return [4, parseErrorBody(output.body, context)];
2256
2256
  case 1:
2257
2257
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2258
2258
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2320,7 +2320,7 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
2320
2320
  case 0:
2321
2321
  _a = [__assign({}, output)];
2322
2322
  _b = {};
2323
- return [4, parseBody(output.body, context)];
2323
+ return [4, parseErrorBody(output.body, context)];
2324
2324
  case 1:
2325
2325
  parsedOutput = __assign.apply(void 0, _a.concat([(_b.body = _c.sent(), _b)]));
2326
2326
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2396,7 +2396,7 @@ var deserializeAws_restJson1RevokeRevisionCommandError = function (output, conte
2396
2396
  case 0:
2397
2397
  _a = [__assign({}, output)];
2398
2398
  _c = {};
2399
- return [4, parseBody(output.body, context)];
2399
+ return [4, parseErrorBody(output.body, context)];
2400
2400
  case 1:
2401
2401
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2402
2402
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2477,7 +2477,7 @@ var deserializeAws_restJson1SendApiAssetCommandError = function (output, context
2477
2477
  case 0:
2478
2478
  _a = [__assign({}, output)];
2479
2479
  _c = {};
2480
- return [4, parseBody(output.body, context)];
2480
+ return [4, parseErrorBody(output.body, context)];
2481
2481
  case 1:
2482
2482
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2483
2483
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2544,7 +2544,7 @@ var deserializeAws_restJson1StartJobCommandError = function (output, context) {
2544
2544
  case 0:
2545
2545
  _a = [__assign({}, output)];
2546
2546
  _c = {};
2547
- return [4, parseBody(output.body, context)];
2547
+ return [4, parseErrorBody(output.body, context)];
2548
2548
  case 1:
2549
2549
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2550
2550
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2615,7 +2615,7 @@ var deserializeAws_restJson1TagResourceCommandError = function (output, context)
2615
2615
  case 0:
2616
2616
  _a = [__assign({}, output)];
2617
2617
  _b = {};
2618
- return [4, parseBody(output.body, context)];
2618
+ return [4, parseErrorBody(output.body, context)];
2619
2619
  case 1:
2620
2620
  parsedOutput = __assign.apply(void 0, _a.concat([(_b.body = _c.sent(), _b)]));
2621
2621
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2656,7 +2656,7 @@ var deserializeAws_restJson1UntagResourceCommandError = function (output, contex
2656
2656
  case 0:
2657
2657
  _a = [__assign({}, output)];
2658
2658
  _b = {};
2659
- return [4, parseBody(output.body, context)];
2659
+ return [4, parseErrorBody(output.body, context)];
2660
2660
  case 1:
2661
2661
  parsedOutput = __assign.apply(void 0, _a.concat([(_b.body = _c.sent(), _b)]));
2662
2662
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2729,7 +2729,7 @@ var deserializeAws_restJson1UpdateAssetCommandError = function (output, context)
2729
2729
  case 0:
2730
2730
  _a = [__assign({}, output)];
2731
2731
  _c = {};
2732
- return [4, parseBody(output.body, context)];
2732
+ return [4, parseErrorBody(output.body, context)];
2733
2733
  case 1:
2734
2734
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2735
2735
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2832,7 +2832,7 @@ var deserializeAws_restJson1UpdateDataSetCommandError = function (output, contex
2832
2832
  case 0:
2833
2833
  _a = [__assign({}, output)];
2834
2834
  _c = {};
2835
- return [4, parseBody(output.body, context)];
2835
+ return [4, parseErrorBody(output.body, context)];
2836
2836
  case 1:
2837
2837
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2838
2838
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -2919,7 +2919,7 @@ var deserializeAws_restJson1UpdateEventActionCommandError = function (output, co
2919
2919
  case 0:
2920
2920
  _a = [__assign({}, output)];
2921
2921
  _c = {};
2922
- return [4, parseBody(output.body, context)];
2922
+ return [4, parseErrorBody(output.body, context)];
2923
2923
  case 1:
2924
2924
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
2925
2925
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -3021,7 +3021,7 @@ var deserializeAws_restJson1UpdateRevisionCommandError = function (output, conte
3021
3021
  case 0:
3022
3022
  _a = [__assign({}, output)];
3023
3023
  _c = {};
3024
- return [4, parseBody(output.body, context)];
3024
+ return [4, parseErrorBody(output.body, context)];
3025
3025
  case 1:
3026
3026
  parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
3027
3027
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
@@ -3759,6 +3759,19 @@ var parseBody = function (streamBody, context) {
3759
3759
  return {};
3760
3760
  });
3761
3761
  };
3762
+ var parseErrorBody = function (errorBody, context) { return __awaiter(void 0, void 0, void 0, function () {
3763
+ var value;
3764
+ var _a;
3765
+ return __generator(this, function (_b) {
3766
+ switch (_b.label) {
3767
+ case 0: return [4, parseBody(errorBody, context)];
3768
+ case 1:
3769
+ value = _b.sent();
3770
+ value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
3771
+ return [2, value];
3772
+ }
3773
+ });
3774
+ }); };
3762
3775
  var loadRestJsonErrorCode = function (output, data) {
3763
3776
  var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
3764
3777
  var sanitizeErrorCode = function (rawValue) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-dataexchange",
3
3
  "description": "AWS SDK for JavaScript Dataexchange Client for Node.js, Browser and React Native",
4
- "version": "3.179.0",
4
+ "version": "3.181.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -19,9 +19,9 @@
19
19
  "dependencies": {
20
20
  "@aws-crypto/sha256-browser": "2.0.0",
21
21
  "@aws-crypto/sha256-js": "2.0.0",
22
- "@aws-sdk/client-sts": "3.179.0",
22
+ "@aws-sdk/client-sts": "3.181.0",
23
23
  "@aws-sdk/config-resolver": "3.178.0",
24
- "@aws-sdk/credential-provider-node": "3.178.0",
24
+ "@aws-sdk/credential-provider-node": "3.181.0",
25
25
  "@aws-sdk/fetch-http-handler": "3.178.0",
26
26
  "@aws-sdk/hash-node": "3.178.0",
27
27
  "@aws-sdk/invalid-dependency": "3.178.0",
@@ -37,15 +37,15 @@
37
37
  "@aws-sdk/node-config-provider": "3.178.0",
38
38
  "@aws-sdk/node-http-handler": "3.178.0",
39
39
  "@aws-sdk/protocol-http": "3.178.0",
40
- "@aws-sdk/smithy-client": "3.178.0",
40
+ "@aws-sdk/smithy-client": "3.180.0",
41
41
  "@aws-sdk/types": "3.178.0",
42
42
  "@aws-sdk/url-parser": "3.178.0",
43
43
  "@aws-sdk/util-base64-browser": "3.170.0",
44
44
  "@aws-sdk/util-base64-node": "3.170.0",
45
45
  "@aws-sdk/util-body-length-browser": "3.170.0",
46
46
  "@aws-sdk/util-body-length-node": "3.170.0",
47
- "@aws-sdk/util-defaults-mode-browser": "3.178.0",
48
- "@aws-sdk/util-defaults-mode-node": "3.178.0",
47
+ "@aws-sdk/util-defaults-mode-browser": "3.180.0",
48
+ "@aws-sdk/util-defaults-mode-node": "3.180.0",
49
49
  "@aws-sdk/util-user-agent-browser": "3.178.0",
50
50
  "@aws-sdk/util-user-agent-node": "3.178.0",
51
51
  "@aws-sdk/util-utf8-browser": "3.170.0",