@aws-sdk/client-schemas 3.180.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 +12 -0
- package/dist-cjs/protocols/Aws_restJson1.js +37 -31
- package/dist-es/protocols/Aws_restJson1.js +44 -31
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,18 @@
|
|
|
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
|
+
|
|
6
18
|
# [3.180.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.179.0...v3.180.0) (2022-09-27)
|
|
7
19
|
|
|
8
20
|
**Note:** Version bump only for package @aws-sdk/client-schemas
|
|
@@ -717,7 +717,7 @@ exports.deserializeAws_restJson1CreateDiscovererCommand = deserializeAws_restJso
|
|
|
717
717
|
const deserializeAws_restJson1CreateDiscovererCommandError = async (output, context) => {
|
|
718
718
|
const parsedOutput = {
|
|
719
719
|
...output,
|
|
720
|
-
body: await
|
|
720
|
+
body: await parseErrorBody(output.body, context),
|
|
721
721
|
};
|
|
722
722
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
723
723
|
switch (errorCode) {
|
|
@@ -775,7 +775,7 @@ exports.deserializeAws_restJson1CreateRegistryCommand = deserializeAws_restJson1
|
|
|
775
775
|
const deserializeAws_restJson1CreateRegistryCommandError = async (output, context) => {
|
|
776
776
|
const parsedOutput = {
|
|
777
777
|
...output,
|
|
778
|
-
body: await
|
|
778
|
+
body: await parseErrorBody(output.body, context),
|
|
779
779
|
};
|
|
780
780
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
781
781
|
switch (errorCode) {
|
|
@@ -845,7 +845,7 @@ exports.deserializeAws_restJson1CreateSchemaCommand = deserializeAws_restJson1Cr
|
|
|
845
845
|
const deserializeAws_restJson1CreateSchemaCommandError = async (output, context) => {
|
|
846
846
|
const parsedOutput = {
|
|
847
847
|
...output,
|
|
848
|
-
body: await
|
|
848
|
+
body: await parseErrorBody(output.body, context),
|
|
849
849
|
};
|
|
850
850
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
851
851
|
switch (errorCode) {
|
|
@@ -885,7 +885,7 @@ exports.deserializeAws_restJson1DeleteDiscovererCommand = deserializeAws_restJso
|
|
|
885
885
|
const deserializeAws_restJson1DeleteDiscovererCommandError = async (output, context) => {
|
|
886
886
|
const parsedOutput = {
|
|
887
887
|
...output,
|
|
888
|
-
body: await
|
|
888
|
+
body: await parseErrorBody(output.body, context),
|
|
889
889
|
};
|
|
890
890
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
891
891
|
switch (errorCode) {
|
|
@@ -931,7 +931,7 @@ exports.deserializeAws_restJson1DeleteRegistryCommand = deserializeAws_restJson1
|
|
|
931
931
|
const deserializeAws_restJson1DeleteRegistryCommandError = async (output, context) => {
|
|
932
932
|
const parsedOutput = {
|
|
933
933
|
...output,
|
|
934
|
-
body: await
|
|
934
|
+
body: await parseErrorBody(output.body, context),
|
|
935
935
|
};
|
|
936
936
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
937
937
|
switch (errorCode) {
|
|
@@ -977,7 +977,7 @@ exports.deserializeAws_restJson1DeleteResourcePolicyCommand = deserializeAws_res
|
|
|
977
977
|
const deserializeAws_restJson1DeleteResourcePolicyCommandError = async (output, context) => {
|
|
978
978
|
const parsedOutput = {
|
|
979
979
|
...output,
|
|
980
|
-
body: await
|
|
980
|
+
body: await parseErrorBody(output.body, context),
|
|
981
981
|
};
|
|
982
982
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
983
983
|
switch (errorCode) {
|
|
@@ -1023,7 +1023,7 @@ exports.deserializeAws_restJson1DeleteSchemaCommand = deserializeAws_restJson1De
|
|
|
1023
1023
|
const deserializeAws_restJson1DeleteSchemaCommandError = async (output, context) => {
|
|
1024
1024
|
const parsedOutput = {
|
|
1025
1025
|
...output,
|
|
1026
|
-
body: await
|
|
1026
|
+
body: await parseErrorBody(output.body, context),
|
|
1027
1027
|
};
|
|
1028
1028
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1029
1029
|
switch (errorCode) {
|
|
@@ -1069,7 +1069,7 @@ exports.deserializeAws_restJson1DeleteSchemaVersionCommand = deserializeAws_rest
|
|
|
1069
1069
|
const deserializeAws_restJson1DeleteSchemaVersionCommandError = async (output, context) => {
|
|
1070
1070
|
const parsedOutput = {
|
|
1071
1071
|
...output,
|
|
1072
|
-
body: await
|
|
1072
|
+
body: await parseErrorBody(output.body, context),
|
|
1073
1073
|
};
|
|
1074
1074
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1075
1075
|
switch (errorCode) {
|
|
@@ -1127,7 +1127,7 @@ exports.deserializeAws_restJson1DescribeCodeBindingCommand = deserializeAws_rest
|
|
|
1127
1127
|
const deserializeAws_restJson1DescribeCodeBindingCommandError = async (output, context) => {
|
|
1128
1128
|
const parsedOutput = {
|
|
1129
1129
|
...output,
|
|
1130
|
-
body: await
|
|
1130
|
+
body: await parseErrorBody(output.body, context),
|
|
1131
1131
|
};
|
|
1132
1132
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1133
1133
|
switch (errorCode) {
|
|
@@ -1194,7 +1194,7 @@ exports.deserializeAws_restJson1DescribeDiscovererCommand = deserializeAws_restJ
|
|
|
1194
1194
|
const deserializeAws_restJson1DescribeDiscovererCommandError = async (output, context) => {
|
|
1195
1195
|
const parsedOutput = {
|
|
1196
1196
|
...output,
|
|
1197
|
-
body: await
|
|
1197
|
+
body: await parseErrorBody(output.body, context),
|
|
1198
1198
|
};
|
|
1199
1199
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1200
1200
|
switch (errorCode) {
|
|
@@ -1252,7 +1252,7 @@ exports.deserializeAws_restJson1DescribeRegistryCommand = deserializeAws_restJso
|
|
|
1252
1252
|
const deserializeAws_restJson1DescribeRegistryCommandError = async (output, context) => {
|
|
1253
1253
|
const parsedOutput = {
|
|
1254
1254
|
...output,
|
|
1255
|
-
body: await
|
|
1255
|
+
body: await parseErrorBody(output.body, context),
|
|
1256
1256
|
};
|
|
1257
1257
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1258
1258
|
switch (errorCode) {
|
|
@@ -1325,7 +1325,7 @@ exports.deserializeAws_restJson1DescribeSchemaCommand = deserializeAws_restJson1
|
|
|
1325
1325
|
const deserializeAws_restJson1DescribeSchemaCommandError = async (output, context) => {
|
|
1326
1326
|
const parsedOutput = {
|
|
1327
1327
|
...output,
|
|
1328
|
-
body: await
|
|
1328
|
+
body: await parseErrorBody(output.body, context),
|
|
1329
1329
|
};
|
|
1330
1330
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1331
1331
|
switch (errorCode) {
|
|
@@ -1386,7 +1386,7 @@ exports.deserializeAws_restJson1ExportSchemaCommand = deserializeAws_restJson1Ex
|
|
|
1386
1386
|
const deserializeAws_restJson1ExportSchemaCommandError = async (output, context) => {
|
|
1387
1387
|
const parsedOutput = {
|
|
1388
1388
|
...output,
|
|
1389
|
-
body: await
|
|
1389
|
+
body: await parseErrorBody(output.body, context),
|
|
1390
1390
|
};
|
|
1391
1391
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1392
1392
|
switch (errorCode) {
|
|
@@ -1436,7 +1436,7 @@ exports.deserializeAws_restJson1GetCodeBindingSourceCommand = deserializeAws_res
|
|
|
1436
1436
|
const deserializeAws_restJson1GetCodeBindingSourceCommandError = async (output, context) => {
|
|
1437
1437
|
const parsedOutput = {
|
|
1438
1438
|
...output,
|
|
1439
|
-
body: await
|
|
1439
|
+
body: await parseErrorBody(output.body, context),
|
|
1440
1440
|
};
|
|
1441
1441
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1442
1442
|
switch (errorCode) {
|
|
@@ -1485,7 +1485,7 @@ exports.deserializeAws_restJson1GetDiscoveredSchemaCommand = deserializeAws_rest
|
|
|
1485
1485
|
const deserializeAws_restJson1GetDiscoveredSchemaCommandError = async (output, context) => {
|
|
1486
1486
|
const parsedOutput = {
|
|
1487
1487
|
...output,
|
|
1488
|
-
body: await
|
|
1488
|
+
body: await parseErrorBody(output.body, context),
|
|
1489
1489
|
};
|
|
1490
1490
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1491
1491
|
switch (errorCode) {
|
|
@@ -1534,7 +1534,7 @@ exports.deserializeAws_restJson1GetResourcePolicyCommand = deserializeAws_restJs
|
|
|
1534
1534
|
const deserializeAws_restJson1GetResourcePolicyCommandError = async (output, context) => {
|
|
1535
1535
|
const parsedOutput = {
|
|
1536
1536
|
...output,
|
|
1537
|
-
body: await
|
|
1537
|
+
body: await parseErrorBody(output.body, context),
|
|
1538
1538
|
};
|
|
1539
1539
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1540
1540
|
switch (errorCode) {
|
|
@@ -1586,7 +1586,7 @@ exports.deserializeAws_restJson1ListDiscoverersCommand = deserializeAws_restJson
|
|
|
1586
1586
|
const deserializeAws_restJson1ListDiscoverersCommandError = async (output, context) => {
|
|
1587
1587
|
const parsedOutput = {
|
|
1588
1588
|
...output,
|
|
1589
|
-
body: await
|
|
1589
|
+
body: await parseErrorBody(output.body, context),
|
|
1590
1590
|
};
|
|
1591
1591
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1592
1592
|
switch (errorCode) {
|
|
@@ -1635,7 +1635,7 @@ exports.deserializeAws_restJson1ListRegistriesCommand = deserializeAws_restJson1
|
|
|
1635
1635
|
const deserializeAws_restJson1ListRegistriesCommandError = async (output, context) => {
|
|
1636
1636
|
const parsedOutput = {
|
|
1637
1637
|
...output,
|
|
1638
|
-
body: await
|
|
1638
|
+
body: await parseErrorBody(output.body, context),
|
|
1639
1639
|
};
|
|
1640
1640
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1641
1641
|
switch (errorCode) {
|
|
@@ -1684,7 +1684,7 @@ exports.deserializeAws_restJson1ListSchemasCommand = deserializeAws_restJson1Lis
|
|
|
1684
1684
|
const deserializeAws_restJson1ListSchemasCommandError = async (output, context) => {
|
|
1685
1685
|
const parsedOutput = {
|
|
1686
1686
|
...output,
|
|
1687
|
-
body: await
|
|
1687
|
+
body: await parseErrorBody(output.body, context),
|
|
1688
1688
|
};
|
|
1689
1689
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1690
1690
|
switch (errorCode) {
|
|
@@ -1733,7 +1733,7 @@ exports.deserializeAws_restJson1ListSchemaVersionsCommand = deserializeAws_restJ
|
|
|
1733
1733
|
const deserializeAws_restJson1ListSchemaVersionsCommandError = async (output, context) => {
|
|
1734
1734
|
const parsedOutput = {
|
|
1735
1735
|
...output,
|
|
1736
|
-
body: await
|
|
1736
|
+
body: await parseErrorBody(output.body, context),
|
|
1737
1737
|
};
|
|
1738
1738
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1739
1739
|
switch (errorCode) {
|
|
@@ -1782,7 +1782,7 @@ exports.deserializeAws_restJson1ListTagsForResourceCommand = deserializeAws_rest
|
|
|
1782
1782
|
const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, context) => {
|
|
1783
1783
|
const parsedOutput = {
|
|
1784
1784
|
...output,
|
|
1785
|
-
body: await
|
|
1785
|
+
body: await parseErrorBody(output.body, context),
|
|
1786
1786
|
};
|
|
1787
1787
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1788
1788
|
switch (errorCode) {
|
|
@@ -1834,7 +1834,7 @@ exports.deserializeAws_restJson1PutCodeBindingCommand = deserializeAws_restJson1
|
|
|
1834
1834
|
const deserializeAws_restJson1PutCodeBindingCommandError = async (output, context) => {
|
|
1835
1835
|
const parsedOutput = {
|
|
1836
1836
|
...output,
|
|
1837
|
-
body: await
|
|
1837
|
+
body: await parseErrorBody(output.body, context),
|
|
1838
1838
|
};
|
|
1839
1839
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1840
1840
|
switch (errorCode) {
|
|
@@ -1889,7 +1889,7 @@ exports.deserializeAws_restJson1PutResourcePolicyCommand = deserializeAws_restJs
|
|
|
1889
1889
|
const deserializeAws_restJson1PutResourcePolicyCommandError = async (output, context) => {
|
|
1890
1890
|
const parsedOutput = {
|
|
1891
1891
|
...output,
|
|
1892
|
-
body: await
|
|
1892
|
+
body: await parseErrorBody(output.body, context),
|
|
1893
1893
|
};
|
|
1894
1894
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1895
1895
|
switch (errorCode) {
|
|
@@ -1944,7 +1944,7 @@ exports.deserializeAws_restJson1SearchSchemasCommand = deserializeAws_restJson1S
|
|
|
1944
1944
|
const deserializeAws_restJson1SearchSchemasCommandError = async (output, context) => {
|
|
1945
1945
|
const parsedOutput = {
|
|
1946
1946
|
...output,
|
|
1947
|
-
body: await
|
|
1947
|
+
body: await parseErrorBody(output.body, context),
|
|
1948
1948
|
};
|
|
1949
1949
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1950
1950
|
switch (errorCode) {
|
|
@@ -1993,7 +1993,7 @@ exports.deserializeAws_restJson1StartDiscovererCommand = deserializeAws_restJson
|
|
|
1993
1993
|
const deserializeAws_restJson1StartDiscovererCommandError = async (output, context) => {
|
|
1994
1994
|
const parsedOutput = {
|
|
1995
1995
|
...output,
|
|
1996
|
-
body: await
|
|
1996
|
+
body: await parseErrorBody(output.body, context),
|
|
1997
1997
|
};
|
|
1998
1998
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1999
1999
|
switch (errorCode) {
|
|
@@ -2045,7 +2045,7 @@ exports.deserializeAws_restJson1StopDiscovererCommand = deserializeAws_restJson1
|
|
|
2045
2045
|
const deserializeAws_restJson1StopDiscovererCommandError = async (output, context) => {
|
|
2046
2046
|
const parsedOutput = {
|
|
2047
2047
|
...output,
|
|
2048
|
-
body: await
|
|
2048
|
+
body: await parseErrorBody(output.body, context),
|
|
2049
2049
|
};
|
|
2050
2050
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2051
2051
|
switch (errorCode) {
|
|
@@ -2091,7 +2091,7 @@ exports.deserializeAws_restJson1TagResourceCommand = deserializeAws_restJson1Tag
|
|
|
2091
2091
|
const deserializeAws_restJson1TagResourceCommandError = async (output, context) => {
|
|
2092
2092
|
const parsedOutput = {
|
|
2093
2093
|
...output,
|
|
2094
|
-
body: await
|
|
2094
|
+
body: await parseErrorBody(output.body, context),
|
|
2095
2095
|
};
|
|
2096
2096
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2097
2097
|
switch (errorCode) {
|
|
@@ -2131,7 +2131,7 @@ exports.deserializeAws_restJson1UntagResourceCommand = deserializeAws_restJson1U
|
|
|
2131
2131
|
const deserializeAws_restJson1UntagResourceCommandError = async (output, context) => {
|
|
2132
2132
|
const parsedOutput = {
|
|
2133
2133
|
...output,
|
|
2134
|
-
body: await
|
|
2134
|
+
body: await parseErrorBody(output.body, context),
|
|
2135
2135
|
};
|
|
2136
2136
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2137
2137
|
switch (errorCode) {
|
|
@@ -2192,7 +2192,7 @@ exports.deserializeAws_restJson1UpdateDiscovererCommand = deserializeAws_restJso
|
|
|
2192
2192
|
const deserializeAws_restJson1UpdateDiscovererCommandError = async (output, context) => {
|
|
2193
2193
|
const parsedOutput = {
|
|
2194
2194
|
...output,
|
|
2195
|
-
body: await
|
|
2195
|
+
body: await parseErrorBody(output.body, context),
|
|
2196
2196
|
};
|
|
2197
2197
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2198
2198
|
switch (errorCode) {
|
|
@@ -2250,7 +2250,7 @@ exports.deserializeAws_restJson1UpdateRegistryCommand = deserializeAws_restJson1
|
|
|
2250
2250
|
const deserializeAws_restJson1UpdateRegistryCommandError = async (output, context) => {
|
|
2251
2251
|
const parsedOutput = {
|
|
2252
2252
|
...output,
|
|
2253
|
-
body: await
|
|
2253
|
+
body: await parseErrorBody(output.body, context),
|
|
2254
2254
|
};
|
|
2255
2255
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2256
2256
|
switch (errorCode) {
|
|
@@ -2320,7 +2320,7 @@ exports.deserializeAws_restJson1UpdateSchemaCommand = deserializeAws_restJson1Up
|
|
|
2320
2320
|
const deserializeAws_restJson1UpdateSchemaCommandError = async (output, context) => {
|
|
2321
2321
|
const parsedOutput = {
|
|
2322
2322
|
...output,
|
|
2323
|
-
body: await
|
|
2323
|
+
body: await parseErrorBody(output.body, context),
|
|
2324
2324
|
};
|
|
2325
2325
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2326
2326
|
switch (errorCode) {
|
|
@@ -2673,6 +2673,12 @@ const parseBody = (streamBody, context) => collectBodyString(streamBody, context
|
|
|
2673
2673
|
}
|
|
2674
2674
|
return {};
|
|
2675
2675
|
});
|
|
2676
|
+
const parseErrorBody = async (errorBody, context) => {
|
|
2677
|
+
var _a;
|
|
2678
|
+
const value = await parseBody(errorBody, context);
|
|
2679
|
+
value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
|
|
2680
|
+
return value;
|
|
2681
|
+
};
|
|
2676
2682
|
const loadRestJsonErrorCode = (output, data) => {
|
|
2677
2683
|
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
2678
2684
|
const sanitizeErrorCode = (rawValue) => {
|
|
@@ -852,7 +852,7 @@ var deserializeAws_restJson1CreateDiscovererCommandError = function (output, con
|
|
|
852
852
|
case 0:
|
|
853
853
|
_a = [__assign({}, output)];
|
|
854
854
|
_c = {};
|
|
855
|
-
return [4,
|
|
855
|
+
return [4, parseErrorBody(output.body, context)];
|
|
856
856
|
case 1:
|
|
857
857
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
858
858
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -937,7 +937,7 @@ var deserializeAws_restJson1CreateRegistryCommandError = function (output, conte
|
|
|
937
937
|
case 0:
|
|
938
938
|
_a = [__assign({}, output)];
|
|
939
939
|
_c = {};
|
|
940
|
-
return [4,
|
|
940
|
+
return [4, parseErrorBody(output.body, context)];
|
|
941
941
|
case 1:
|
|
942
942
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
943
943
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1034,7 +1034,7 @@ var deserializeAws_restJson1CreateSchemaCommandError = function (output, context
|
|
|
1034
1034
|
case 0:
|
|
1035
1035
|
_a = [__assign({}, output)];
|
|
1036
1036
|
_c = {};
|
|
1037
|
-
return [4,
|
|
1037
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1038
1038
|
case 1:
|
|
1039
1039
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1040
1040
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1097,7 +1097,7 @@ var deserializeAws_restJson1DeleteDiscovererCommandError = function (output, con
|
|
|
1097
1097
|
case 0:
|
|
1098
1098
|
_a = [__assign({}, output)];
|
|
1099
1099
|
_c = {};
|
|
1100
|
-
return [4,
|
|
1100
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1101
1101
|
case 1:
|
|
1102
1102
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1103
1103
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1168,7 +1168,7 @@ var deserializeAws_restJson1DeleteRegistryCommandError = function (output, conte
|
|
|
1168
1168
|
case 0:
|
|
1169
1169
|
_a = [__assign({}, output)];
|
|
1170
1170
|
_c = {};
|
|
1171
|
-
return [4,
|
|
1171
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1172
1172
|
case 1:
|
|
1173
1173
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1174
1174
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1239,7 +1239,7 @@ var deserializeAws_restJson1DeleteResourcePolicyCommandError = function (output,
|
|
|
1239
1239
|
case 0:
|
|
1240
1240
|
_a = [__assign({}, output)];
|
|
1241
1241
|
_c = {};
|
|
1242
|
-
return [4,
|
|
1242
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1243
1243
|
case 1:
|
|
1244
1244
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1245
1245
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1310,7 +1310,7 @@ var deserializeAws_restJson1DeleteSchemaCommandError = function (output, context
|
|
|
1310
1310
|
case 0:
|
|
1311
1311
|
_a = [__assign({}, output)];
|
|
1312
1312
|
_c = {};
|
|
1313
|
-
return [4,
|
|
1313
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1314
1314
|
case 1:
|
|
1315
1315
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1316
1316
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1381,7 +1381,7 @@ var deserializeAws_restJson1DeleteSchemaVersionCommandError = function (output,
|
|
|
1381
1381
|
case 0:
|
|
1382
1382
|
_a = [__assign({}, output)];
|
|
1383
1383
|
_c = {};
|
|
1384
|
-
return [4,
|
|
1384
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1385
1385
|
case 1:
|
|
1386
1386
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1387
1387
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1466,7 +1466,7 @@ var deserializeAws_restJson1DescribeCodeBindingCommandError = function (output,
|
|
|
1466
1466
|
case 0:
|
|
1467
1467
|
_a = [__assign({}, output)];
|
|
1468
1468
|
_c = {};
|
|
1469
|
-
return [4,
|
|
1469
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1470
1470
|
case 1:
|
|
1471
1471
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1472
1472
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1560,7 +1560,7 @@ var deserializeAws_restJson1DescribeDiscovererCommandError = function (output, c
|
|
|
1560
1560
|
case 0:
|
|
1561
1561
|
_a = [__assign({}, output)];
|
|
1562
1562
|
_c = {};
|
|
1563
|
-
return [4,
|
|
1563
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1564
1564
|
case 1:
|
|
1565
1565
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1566
1566
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1645,7 +1645,7 @@ var deserializeAws_restJson1DescribeRegistryCommandError = function (output, con
|
|
|
1645
1645
|
case 0:
|
|
1646
1646
|
_a = [__assign({}, output)];
|
|
1647
1647
|
_c = {};
|
|
1648
|
-
return [4,
|
|
1648
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1649
1649
|
case 1:
|
|
1650
1650
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1651
1651
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1745,7 +1745,7 @@ var deserializeAws_restJson1DescribeSchemaCommandError = function (output, conte
|
|
|
1745
1745
|
case 0:
|
|
1746
1746
|
_a = [__assign({}, output)];
|
|
1747
1747
|
_c = {};
|
|
1748
|
-
return [4,
|
|
1748
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1749
1749
|
case 1:
|
|
1750
1750
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1751
1751
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1833,7 +1833,7 @@ var deserializeAws_restJson1ExportSchemaCommandError = function (output, context
|
|
|
1833
1833
|
case 0:
|
|
1834
1834
|
_a = [__assign({}, output)];
|
|
1835
1835
|
_c = {};
|
|
1836
|
-
return [4,
|
|
1836
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1837
1837
|
case 1:
|
|
1838
1838
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1839
1839
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1909,7 +1909,7 @@ var deserializeAws_restJson1GetCodeBindingSourceCommandError = function (output,
|
|
|
1909
1909
|
case 0:
|
|
1910
1910
|
_a = [__assign({}, output)];
|
|
1911
1911
|
_c = {};
|
|
1912
|
-
return [4,
|
|
1912
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1913
1913
|
case 1:
|
|
1914
1914
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1915
1915
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -1985,7 +1985,7 @@ var deserializeAws_restJson1GetDiscoveredSchemaCommandError = function (output,
|
|
|
1985
1985
|
case 0:
|
|
1986
1986
|
_a = [__assign({}, output)];
|
|
1987
1987
|
_c = {};
|
|
1988
|
-
return [4,
|
|
1988
|
+
return [4, parseErrorBody(output.body, context)];
|
|
1989
1989
|
case 1:
|
|
1990
1990
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1991
1991
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2060,7 +2060,7 @@ var deserializeAws_restJson1GetResourcePolicyCommandError = function (output, co
|
|
|
2060
2060
|
case 0:
|
|
2061
2061
|
_a = [__assign({}, output)];
|
|
2062
2062
|
_c = {};
|
|
2063
|
-
return [4,
|
|
2063
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2064
2064
|
case 1:
|
|
2065
2065
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2066
2066
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2139,7 +2139,7 @@ var deserializeAws_restJson1ListDiscoverersCommandError = function (output, cont
|
|
|
2139
2139
|
case 0:
|
|
2140
2140
|
_a = [__assign({}, output)];
|
|
2141
2141
|
_c = {};
|
|
2142
|
-
return [4,
|
|
2142
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2143
2143
|
case 1:
|
|
2144
2144
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2145
2145
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2214,7 +2214,7 @@ var deserializeAws_restJson1ListRegistriesCommandError = function (output, conte
|
|
|
2214
2214
|
case 0:
|
|
2215
2215
|
_a = [__assign({}, output)];
|
|
2216
2216
|
_c = {};
|
|
2217
|
-
return [4,
|
|
2217
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2218
2218
|
case 1:
|
|
2219
2219
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2220
2220
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2289,7 +2289,7 @@ var deserializeAws_restJson1ListSchemasCommandError = function (output, context)
|
|
|
2289
2289
|
case 0:
|
|
2290
2290
|
_a = [__assign({}, output)];
|
|
2291
2291
|
_c = {};
|
|
2292
|
-
return [4,
|
|
2292
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2293
2293
|
case 1:
|
|
2294
2294
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2295
2295
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2364,7 +2364,7 @@ var deserializeAws_restJson1ListSchemaVersionsCommandError = function (output, c
|
|
|
2364
2364
|
case 0:
|
|
2365
2365
|
_a = [__assign({}, output)];
|
|
2366
2366
|
_c = {};
|
|
2367
|
-
return [4,
|
|
2367
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2368
2368
|
case 1:
|
|
2369
2369
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2370
2370
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2440,7 +2440,7 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
|
|
|
2440
2440
|
case 0:
|
|
2441
2441
|
_a = [__assign({}, output)];
|
|
2442
2442
|
_c = {};
|
|
2443
|
-
return [4,
|
|
2443
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2444
2444
|
case 1:
|
|
2445
2445
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2446
2446
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2517,7 +2517,7 @@ var deserializeAws_restJson1PutCodeBindingCommandError = function (output, conte
|
|
|
2517
2517
|
case 0:
|
|
2518
2518
|
_a = [__assign({}, output)];
|
|
2519
2519
|
_c = {};
|
|
2520
|
-
return [4,
|
|
2520
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2521
2521
|
case 1:
|
|
2522
2522
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2523
2523
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2600,7 +2600,7 @@ var deserializeAws_restJson1PutResourcePolicyCommandError = function (output, co
|
|
|
2600
2600
|
case 0:
|
|
2601
2601
|
_a = [__assign({}, output)];
|
|
2602
2602
|
_c = {};
|
|
2603
|
-
return [4,
|
|
2603
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2604
2604
|
case 1:
|
|
2605
2605
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2606
2606
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2683,7 +2683,7 @@ var deserializeAws_restJson1SearchSchemasCommandError = function (output, contex
|
|
|
2683
2683
|
case 0:
|
|
2684
2684
|
_a = [__assign({}, output)];
|
|
2685
2685
|
_c = {};
|
|
2686
|
-
return [4,
|
|
2686
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2687
2687
|
case 1:
|
|
2688
2688
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2689
2689
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2758,7 +2758,7 @@ var deserializeAws_restJson1StartDiscovererCommandError = function (output, cont
|
|
|
2758
2758
|
case 0:
|
|
2759
2759
|
_a = [__assign({}, output)];
|
|
2760
2760
|
_c = {};
|
|
2761
|
-
return [4,
|
|
2761
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2762
2762
|
case 1:
|
|
2763
2763
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2764
2764
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2837,7 +2837,7 @@ var deserializeAws_restJson1StopDiscovererCommandError = function (output, conte
|
|
|
2837
2837
|
case 0:
|
|
2838
2838
|
_a = [__assign({}, output)];
|
|
2839
2839
|
_c = {};
|
|
2840
|
-
return [4,
|
|
2840
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2841
2841
|
case 1:
|
|
2842
2842
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2843
2843
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2908,7 +2908,7 @@ var deserializeAws_restJson1TagResourceCommandError = function (output, context)
|
|
|
2908
2908
|
case 0:
|
|
2909
2909
|
_a = [__assign({}, output)];
|
|
2910
2910
|
_c = {};
|
|
2911
|
-
return [4,
|
|
2911
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2912
2912
|
case 1:
|
|
2913
2913
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2914
2914
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -2971,7 +2971,7 @@ var deserializeAws_restJson1UntagResourceCommandError = function (output, contex
|
|
|
2971
2971
|
case 0:
|
|
2972
2972
|
_a = [__assign({}, output)];
|
|
2973
2973
|
_c = {};
|
|
2974
|
-
return [4,
|
|
2974
|
+
return [4, parseErrorBody(output.body, context)];
|
|
2975
2975
|
case 1:
|
|
2976
2976
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2977
2977
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -3057,7 +3057,7 @@ var deserializeAws_restJson1UpdateDiscovererCommandError = function (output, con
|
|
|
3057
3057
|
case 0:
|
|
3058
3058
|
_a = [__assign({}, output)];
|
|
3059
3059
|
_c = {};
|
|
3060
|
-
return [4,
|
|
3060
|
+
return [4, parseErrorBody(output.body, context)];
|
|
3061
3061
|
case 1:
|
|
3062
3062
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
3063
3063
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -3142,7 +3142,7 @@ var deserializeAws_restJson1UpdateRegistryCommandError = function (output, conte
|
|
|
3142
3142
|
case 0:
|
|
3143
3143
|
_a = [__assign({}, output)];
|
|
3144
3144
|
_c = {};
|
|
3145
|
-
return [4,
|
|
3145
|
+
return [4, parseErrorBody(output.body, context)];
|
|
3146
3146
|
case 1:
|
|
3147
3147
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
3148
3148
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -3239,7 +3239,7 @@ var deserializeAws_restJson1UpdateSchemaCommandError = function (output, context
|
|
|
3239
3239
|
case 0:
|
|
3240
3240
|
_a = [__assign({}, output)];
|
|
3241
3241
|
_c = {};
|
|
3242
|
-
return [4,
|
|
3242
|
+
return [4, parseErrorBody(output.body, context)];
|
|
3243
3243
|
case 1:
|
|
3244
3244
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
3245
3245
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
@@ -3609,6 +3609,19 @@ var parseBody = function (streamBody, context) {
|
|
|
3609
3609
|
return {};
|
|
3610
3610
|
});
|
|
3611
3611
|
};
|
|
3612
|
+
var parseErrorBody = function (errorBody, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3613
|
+
var value;
|
|
3614
|
+
var _a;
|
|
3615
|
+
return __generator(this, function (_b) {
|
|
3616
|
+
switch (_b.label) {
|
|
3617
|
+
case 0: return [4, parseBody(errorBody, context)];
|
|
3618
|
+
case 1:
|
|
3619
|
+
value = _b.sent();
|
|
3620
|
+
value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
|
|
3621
|
+
return [2, value];
|
|
3622
|
+
}
|
|
3623
|
+
});
|
|
3624
|
+
}); };
|
|
3612
3625
|
var loadRestJsonErrorCode = function (output, data) {
|
|
3613
3626
|
var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
|
|
3614
3627
|
var sanitizeErrorCode = function (rawValue) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-schemas",
|
|
3
3
|
"description": "AWS SDK for JavaScript Schemas Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
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.
|
|
22
|
+
"@aws-sdk/client-sts": "3.181.0",
|
|
23
23
|
"@aws-sdk/config-resolver": "3.178.0",
|
|
24
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
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",
|