@aws-sdk/client-migration-hub-refactor-spaces 3.118.0 → 3.127.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 +27 -0
- package/dist-cjs/protocols/Aws_restJson1.js +181 -194
- package/dist-es/protocols/Aws_restJson1.js +162 -175
- package/package.json +26 -26
|
@@ -26,15 +26,14 @@ const serializeAws_restJson1CreateApplicationCommand = async (input, context) =>
|
|
|
26
26
|
}
|
|
27
27
|
let body;
|
|
28
28
|
body = JSON.stringify({
|
|
29
|
-
...(input.ApiGatewayProxy
|
|
30
|
-
input.ApiGatewayProxy !== null && {
|
|
29
|
+
...(input.ApiGatewayProxy != null && {
|
|
31
30
|
ApiGatewayProxy: serializeAws_restJson1ApiGatewayProxyInput(input.ApiGatewayProxy, context),
|
|
32
31
|
}),
|
|
33
32
|
ClientToken: (_a = input.ClientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
|
|
34
|
-
...(input.Name
|
|
35
|
-
...(input.ProxyType
|
|
36
|
-
...(input.Tags
|
|
37
|
-
...(input.VpcId
|
|
33
|
+
...(input.Name != null && { Name: input.Name }),
|
|
34
|
+
...(input.ProxyType != null && { ProxyType: input.ProxyType }),
|
|
35
|
+
...(input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) }),
|
|
36
|
+
...(input.VpcId != null && { VpcId: input.VpcId }),
|
|
38
37
|
});
|
|
39
38
|
return new protocol_http_1.HttpRequest({
|
|
40
39
|
protocol,
|
|
@@ -57,11 +56,10 @@ const serializeAws_restJson1CreateEnvironmentCommand = async (input, context) =>
|
|
|
57
56
|
let body;
|
|
58
57
|
body = JSON.stringify({
|
|
59
58
|
ClientToken: (_a = input.ClientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
|
|
60
|
-
...(input.Description
|
|
61
|
-
...(input.Name
|
|
62
|
-
...(input.NetworkFabricType
|
|
63
|
-
|
|
64
|
-
...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) }),
|
|
59
|
+
...(input.Description != null && { Description: input.Description }),
|
|
60
|
+
...(input.Name != null && { Name: input.Name }),
|
|
61
|
+
...(input.NetworkFabricType != null && { NetworkFabricType: input.NetworkFabricType }),
|
|
62
|
+
...(input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) }),
|
|
65
63
|
});
|
|
66
64
|
return new protocol_http_1.HttpRequest({
|
|
67
65
|
protocol,
|
|
@@ -105,16 +103,13 @@ const serializeAws_restJson1CreateRouteCommand = async (input, context) => {
|
|
|
105
103
|
let body;
|
|
106
104
|
body = JSON.stringify({
|
|
107
105
|
ClientToken: (_a = input.ClientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
|
|
108
|
-
...(input.DefaultRoute
|
|
109
|
-
input.DefaultRoute !== null && {
|
|
106
|
+
...(input.DefaultRoute != null && {
|
|
110
107
|
DefaultRoute: serializeAws_restJson1DefaultRouteInput(input.DefaultRoute, context),
|
|
111
108
|
}),
|
|
112
|
-
...(input.RouteType
|
|
113
|
-
...(input.ServiceIdentifier
|
|
114
|
-
|
|
115
|
-
...(input.
|
|
116
|
-
...(input.UriPathRoute !== undefined &&
|
|
117
|
-
input.UriPathRoute !== null && {
|
|
109
|
+
...(input.RouteType != null && { RouteType: input.RouteType }),
|
|
110
|
+
...(input.ServiceIdentifier != null && { ServiceIdentifier: input.ServiceIdentifier }),
|
|
111
|
+
...(input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) }),
|
|
112
|
+
...(input.UriPathRoute != null && {
|
|
118
113
|
UriPathRoute: serializeAws_restJson1UriPathRouteInput(input.UriPathRoute, context),
|
|
119
114
|
}),
|
|
120
115
|
});
|
|
@@ -160,19 +155,17 @@ const serializeAws_restJson1CreateServiceCommand = async (input, context) => {
|
|
|
160
155
|
let body;
|
|
161
156
|
body = JSON.stringify({
|
|
162
157
|
ClientToken: (_a = input.ClientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
|
|
163
|
-
...(input.Description
|
|
164
|
-
...(input.EndpointType
|
|
165
|
-
...(input.LambdaEndpoint
|
|
166
|
-
input.LambdaEndpoint !== null && {
|
|
158
|
+
...(input.Description != null && { Description: input.Description }),
|
|
159
|
+
...(input.EndpointType != null && { EndpointType: input.EndpointType }),
|
|
160
|
+
...(input.LambdaEndpoint != null && {
|
|
167
161
|
LambdaEndpoint: serializeAws_restJson1LambdaEndpointInput(input.LambdaEndpoint, context),
|
|
168
162
|
}),
|
|
169
|
-
...(input.Name
|
|
170
|
-
...(input.Tags
|
|
171
|
-
...(input.UrlEndpoint
|
|
172
|
-
input.UrlEndpoint !== null && {
|
|
163
|
+
...(input.Name != null && { Name: input.Name }),
|
|
164
|
+
...(input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) }),
|
|
165
|
+
...(input.UrlEndpoint != null && {
|
|
173
166
|
UrlEndpoint: serializeAws_restJson1UrlEndpointInput(input.UrlEndpoint, context),
|
|
174
167
|
}),
|
|
175
|
-
...(input.VpcId
|
|
168
|
+
...(input.VpcId != null && { VpcId: input.VpcId }),
|
|
176
169
|
});
|
|
177
170
|
return new protocol_http_1.HttpRequest({
|
|
178
171
|
protocol,
|
|
@@ -754,8 +747,8 @@ const serializeAws_restJson1PutResourcePolicyCommand = async (input, context) =>
|
|
|
754
747
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/resourcepolicy";
|
|
755
748
|
let body;
|
|
756
749
|
body = JSON.stringify({
|
|
757
|
-
...(input.Policy
|
|
758
|
-
...(input.ResourceArn
|
|
750
|
+
...(input.Policy != null && { Policy: input.Policy }),
|
|
751
|
+
...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
|
|
759
752
|
});
|
|
760
753
|
return new protocol_http_1.HttpRequest({
|
|
761
754
|
protocol,
|
|
@@ -786,7 +779,7 @@ const serializeAws_restJson1TagResourceCommand = async (input, context) => {
|
|
|
786
779
|
}
|
|
787
780
|
let body;
|
|
788
781
|
body = JSON.stringify({
|
|
789
|
-
...(input.Tags
|
|
782
|
+
...(input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) }),
|
|
790
783
|
});
|
|
791
784
|
return new protocol_http_1.HttpRequest({
|
|
792
785
|
protocol,
|
|
@@ -868,8 +861,7 @@ const serializeAws_restJson1UpdateRouteCommand = async (input, context) => {
|
|
|
868
861
|
}
|
|
869
862
|
let body;
|
|
870
863
|
body = JSON.stringify({
|
|
871
|
-
...(input.ActivationState
|
|
872
|
-
input.ActivationState !== null && { ActivationState: input.ActivationState }),
|
|
864
|
+
...(input.ActivationState != null && { ActivationState: input.ActivationState }),
|
|
873
865
|
});
|
|
874
866
|
return new protocol_http_1.HttpRequest({
|
|
875
867
|
protocol,
|
|
@@ -951,8 +943,7 @@ const deserializeAws_restJson1CreateApplicationCommandError = async (output, con
|
|
|
951
943
|
body: await parseBody(output.body, context),
|
|
952
944
|
};
|
|
953
945
|
let response;
|
|
954
|
-
|
|
955
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
946
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
956
947
|
switch (errorCode) {
|
|
957
948
|
case "AccessDeniedException":
|
|
958
949
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -977,10 +968,12 @@ const deserializeAws_restJson1CreateApplicationCommandError = async (output, con
|
|
|
977
968
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
978
969
|
default:
|
|
979
970
|
const parsedBody = parsedOutput.body;
|
|
971
|
+
const $metadata = deserializeMetadata(output);
|
|
972
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
980
973
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
981
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
974
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
982
975
|
$fault: "client",
|
|
983
|
-
$metadata
|
|
976
|
+
$metadata,
|
|
984
977
|
});
|
|
985
978
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
986
979
|
}
|
|
@@ -1042,8 +1035,7 @@ const deserializeAws_restJson1CreateEnvironmentCommandError = async (output, con
|
|
|
1042
1035
|
body: await parseBody(output.body, context),
|
|
1043
1036
|
};
|
|
1044
1037
|
let response;
|
|
1045
|
-
|
|
1046
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1038
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1047
1039
|
switch (errorCode) {
|
|
1048
1040
|
case "AccessDeniedException":
|
|
1049
1041
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1068,10 +1060,12 @@ const deserializeAws_restJson1CreateEnvironmentCommandError = async (output, con
|
|
|
1068
1060
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1069
1061
|
default:
|
|
1070
1062
|
const parsedBody = parsedOutput.body;
|
|
1063
|
+
const $metadata = deserializeMetadata(output);
|
|
1064
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1071
1065
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1072
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1066
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1073
1067
|
$fault: "client",
|
|
1074
|
-
$metadata
|
|
1068
|
+
$metadata,
|
|
1075
1069
|
});
|
|
1076
1070
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1077
1071
|
}
|
|
@@ -1141,8 +1135,7 @@ const deserializeAws_restJson1CreateRouteCommandError = async (output, context)
|
|
|
1141
1135
|
body: await parseBody(output.body, context),
|
|
1142
1136
|
};
|
|
1143
1137
|
let response;
|
|
1144
|
-
|
|
1145
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1138
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1146
1139
|
switch (errorCode) {
|
|
1147
1140
|
case "AccessDeniedException":
|
|
1148
1141
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1167,10 +1160,12 @@ const deserializeAws_restJson1CreateRouteCommandError = async (output, context)
|
|
|
1167
1160
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1168
1161
|
default:
|
|
1169
1162
|
const parsedBody = parsedOutput.body;
|
|
1163
|
+
const $metadata = deserializeMetadata(output);
|
|
1164
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1170
1165
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1171
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1166
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1172
1167
|
$fault: "client",
|
|
1173
|
-
$metadata
|
|
1168
|
+
$metadata,
|
|
1174
1169
|
});
|
|
1175
1170
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1176
1171
|
}
|
|
@@ -1256,8 +1251,7 @@ const deserializeAws_restJson1CreateServiceCommandError = async (output, context
|
|
|
1256
1251
|
body: await parseBody(output.body, context),
|
|
1257
1252
|
};
|
|
1258
1253
|
let response;
|
|
1259
|
-
|
|
1260
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1254
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1261
1255
|
switch (errorCode) {
|
|
1262
1256
|
case "AccessDeniedException":
|
|
1263
1257
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1282,10 +1276,12 @@ const deserializeAws_restJson1CreateServiceCommandError = async (output, context
|
|
|
1282
1276
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1283
1277
|
default:
|
|
1284
1278
|
const parsedBody = parsedOutput.body;
|
|
1279
|
+
const $metadata = deserializeMetadata(output);
|
|
1280
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1285
1281
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1286
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1282
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1287
1283
|
$fault: "client",
|
|
1288
|
-
$metadata
|
|
1284
|
+
$metadata,
|
|
1289
1285
|
});
|
|
1290
1286
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1291
1287
|
}
|
|
@@ -1331,8 +1327,7 @@ const deserializeAws_restJson1DeleteApplicationCommandError = async (output, con
|
|
|
1331
1327
|
body: await parseBody(output.body, context),
|
|
1332
1328
|
};
|
|
1333
1329
|
let response;
|
|
1334
|
-
|
|
1335
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1330
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1336
1331
|
switch (errorCode) {
|
|
1337
1332
|
case "AccessDeniedException":
|
|
1338
1333
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1354,10 +1349,12 @@ const deserializeAws_restJson1DeleteApplicationCommandError = async (output, con
|
|
|
1354
1349
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1355
1350
|
default:
|
|
1356
1351
|
const parsedBody = parsedOutput.body;
|
|
1352
|
+
const $metadata = deserializeMetadata(output);
|
|
1353
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1357
1354
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1358
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1355
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1359
1356
|
$fault: "client",
|
|
1360
|
-
$metadata
|
|
1357
|
+
$metadata,
|
|
1361
1358
|
});
|
|
1362
1359
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1363
1360
|
}
|
|
@@ -1399,8 +1396,7 @@ const deserializeAws_restJson1DeleteEnvironmentCommandError = async (output, con
|
|
|
1399
1396
|
body: await parseBody(output.body, context),
|
|
1400
1397
|
};
|
|
1401
1398
|
let response;
|
|
1402
|
-
|
|
1403
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1399
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1404
1400
|
switch (errorCode) {
|
|
1405
1401
|
case "AccessDeniedException":
|
|
1406
1402
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1422,10 +1418,12 @@ const deserializeAws_restJson1DeleteEnvironmentCommandError = async (output, con
|
|
|
1422
1418
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1423
1419
|
default:
|
|
1424
1420
|
const parsedBody = parsedOutput.body;
|
|
1421
|
+
const $metadata = deserializeMetadata(output);
|
|
1422
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1425
1423
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1426
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1424
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1427
1425
|
$fault: "client",
|
|
1428
|
-
$metadata
|
|
1426
|
+
$metadata,
|
|
1429
1427
|
});
|
|
1430
1428
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1431
1429
|
}
|
|
@@ -1447,8 +1445,7 @@ const deserializeAws_restJson1DeleteResourcePolicyCommandError = async (output,
|
|
|
1447
1445
|
body: await parseBody(output.body, context),
|
|
1448
1446
|
};
|
|
1449
1447
|
let response;
|
|
1450
|
-
|
|
1451
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1448
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1452
1449
|
switch (errorCode) {
|
|
1453
1450
|
case "AccessDeniedException":
|
|
1454
1451
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1467,10 +1464,12 @@ const deserializeAws_restJson1DeleteResourcePolicyCommandError = async (output,
|
|
|
1467
1464
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1468
1465
|
default:
|
|
1469
1466
|
const parsedBody = parsedOutput.body;
|
|
1467
|
+
const $metadata = deserializeMetadata(output);
|
|
1468
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1470
1469
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1471
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1470
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1472
1471
|
$fault: "client",
|
|
1473
|
-
$metadata
|
|
1472
|
+
$metadata,
|
|
1474
1473
|
});
|
|
1475
1474
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1476
1475
|
}
|
|
@@ -1516,8 +1515,7 @@ const deserializeAws_restJson1DeleteRouteCommandError = async (output, context)
|
|
|
1516
1515
|
body: await parseBody(output.body, context),
|
|
1517
1516
|
};
|
|
1518
1517
|
let response;
|
|
1519
|
-
|
|
1520
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1518
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1521
1519
|
switch (errorCode) {
|
|
1522
1520
|
case "AccessDeniedException":
|
|
1523
1521
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1539,10 +1537,12 @@ const deserializeAws_restJson1DeleteRouteCommandError = async (output, context)
|
|
|
1539
1537
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1540
1538
|
default:
|
|
1541
1539
|
const parsedBody = parsedOutput.body;
|
|
1540
|
+
const $metadata = deserializeMetadata(output);
|
|
1541
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1542
1542
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1543
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1543
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1544
1544
|
$fault: "client",
|
|
1545
|
-
$metadata
|
|
1545
|
+
$metadata,
|
|
1546
1546
|
});
|
|
1547
1547
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1548
1548
|
}
|
|
@@ -1592,8 +1592,7 @@ const deserializeAws_restJson1DeleteServiceCommandError = async (output, context
|
|
|
1592
1592
|
body: await parseBody(output.body, context),
|
|
1593
1593
|
};
|
|
1594
1594
|
let response;
|
|
1595
|
-
|
|
1596
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1595
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1597
1596
|
switch (errorCode) {
|
|
1598
1597
|
case "AccessDeniedException":
|
|
1599
1598
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1615,10 +1614,12 @@ const deserializeAws_restJson1DeleteServiceCommandError = async (output, context
|
|
|
1615
1614
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1616
1615
|
default:
|
|
1617
1616
|
const parsedBody = parsedOutput.body;
|
|
1617
|
+
const $metadata = deserializeMetadata(output);
|
|
1618
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1618
1619
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1619
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1620
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1620
1621
|
$fault: "client",
|
|
1621
|
-
$metadata
|
|
1622
|
+
$metadata,
|
|
1622
1623
|
});
|
|
1623
1624
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1624
1625
|
}
|
|
@@ -1696,8 +1697,7 @@ const deserializeAws_restJson1GetApplicationCommandError = async (output, contex
|
|
|
1696
1697
|
body: await parseBody(output.body, context),
|
|
1697
1698
|
};
|
|
1698
1699
|
let response;
|
|
1699
|
-
|
|
1700
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1700
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1701
1701
|
switch (errorCode) {
|
|
1702
1702
|
case "AccessDeniedException":
|
|
1703
1703
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1716,10 +1716,12 @@ const deserializeAws_restJson1GetApplicationCommandError = async (output, contex
|
|
|
1716
1716
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1717
1717
|
default:
|
|
1718
1718
|
const parsedBody = parsedOutput.body;
|
|
1719
|
+
const $metadata = deserializeMetadata(output);
|
|
1720
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1719
1721
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1720
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1722
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1721
1723
|
$fault: "client",
|
|
1722
|
-
$metadata
|
|
1724
|
+
$metadata,
|
|
1723
1725
|
});
|
|
1724
1726
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1725
1727
|
}
|
|
@@ -1789,8 +1791,7 @@ const deserializeAws_restJson1GetEnvironmentCommandError = async (output, contex
|
|
|
1789
1791
|
body: await parseBody(output.body, context),
|
|
1790
1792
|
};
|
|
1791
1793
|
let response;
|
|
1792
|
-
|
|
1793
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1794
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1794
1795
|
switch (errorCode) {
|
|
1795
1796
|
case "AccessDeniedException":
|
|
1796
1797
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1809,10 +1810,12 @@ const deserializeAws_restJson1GetEnvironmentCommandError = async (output, contex
|
|
|
1809
1810
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1810
1811
|
default:
|
|
1811
1812
|
const parsedBody = parsedOutput.body;
|
|
1813
|
+
const $metadata = deserializeMetadata(output);
|
|
1814
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1812
1815
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1813
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1816
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1814
1817
|
$fault: "client",
|
|
1815
|
-
$metadata
|
|
1818
|
+
$metadata,
|
|
1816
1819
|
});
|
|
1817
1820
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1818
1821
|
}
|
|
@@ -1838,8 +1841,7 @@ const deserializeAws_restJson1GetResourcePolicyCommandError = async (output, con
|
|
|
1838
1841
|
body: await parseBody(output.body, context),
|
|
1839
1842
|
};
|
|
1840
1843
|
let response;
|
|
1841
|
-
|
|
1842
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1844
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1843
1845
|
switch (errorCode) {
|
|
1844
1846
|
case "AccessDeniedException":
|
|
1845
1847
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1858,10 +1860,12 @@ const deserializeAws_restJson1GetResourcePolicyCommandError = async (output, con
|
|
|
1858
1860
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1859
1861
|
default:
|
|
1860
1862
|
const parsedBody = parsedOutput.body;
|
|
1863
|
+
const $metadata = deserializeMetadata(output);
|
|
1864
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1861
1865
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1862
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1866
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1863
1867
|
$fault: "client",
|
|
1864
|
-
$metadata
|
|
1868
|
+
$metadata,
|
|
1865
1869
|
});
|
|
1866
1870
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1867
1871
|
}
|
|
@@ -1951,8 +1955,7 @@ const deserializeAws_restJson1GetRouteCommandError = async (output, context) =>
|
|
|
1951
1955
|
body: await parseBody(output.body, context),
|
|
1952
1956
|
};
|
|
1953
1957
|
let response;
|
|
1954
|
-
|
|
1955
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1958
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1956
1959
|
switch (errorCode) {
|
|
1957
1960
|
case "AccessDeniedException":
|
|
1958
1961
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -1971,10 +1974,12 @@ const deserializeAws_restJson1GetRouteCommandError = async (output, context) =>
|
|
|
1971
1974
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1972
1975
|
default:
|
|
1973
1976
|
const parsedBody = parsedOutput.body;
|
|
1977
|
+
const $metadata = deserializeMetadata(output);
|
|
1978
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1974
1979
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
1975
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1980
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1976
1981
|
$fault: "client",
|
|
1977
|
-
$metadata
|
|
1982
|
+
$metadata,
|
|
1978
1983
|
});
|
|
1979
1984
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1980
1985
|
}
|
|
@@ -2064,8 +2069,7 @@ const deserializeAws_restJson1GetServiceCommandError = async (output, context) =
|
|
|
2064
2069
|
body: await parseBody(output.body, context),
|
|
2065
2070
|
};
|
|
2066
2071
|
let response;
|
|
2067
|
-
|
|
2068
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2072
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2069
2073
|
switch (errorCode) {
|
|
2070
2074
|
case "AccessDeniedException":
|
|
2071
2075
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2084,10 +2088,12 @@ const deserializeAws_restJson1GetServiceCommandError = async (output, context) =
|
|
|
2084
2088
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2085
2089
|
default:
|
|
2086
2090
|
const parsedBody = parsedOutput.body;
|
|
2091
|
+
const $metadata = deserializeMetadata(output);
|
|
2092
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2087
2093
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2088
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2094
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2089
2095
|
$fault: "client",
|
|
2090
|
-
$metadata
|
|
2096
|
+
$metadata,
|
|
2091
2097
|
});
|
|
2092
2098
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2093
2099
|
}
|
|
@@ -2117,8 +2123,7 @@ const deserializeAws_restJson1ListApplicationsCommandError = async (output, cont
|
|
|
2117
2123
|
body: await parseBody(output.body, context),
|
|
2118
2124
|
};
|
|
2119
2125
|
let response;
|
|
2120
|
-
|
|
2121
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2126
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2122
2127
|
switch (errorCode) {
|
|
2123
2128
|
case "AccessDeniedException":
|
|
2124
2129
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2143,10 +2148,12 @@ const deserializeAws_restJson1ListApplicationsCommandError = async (output, cont
|
|
|
2143
2148
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2144
2149
|
default:
|
|
2145
2150
|
const parsedBody = parsedOutput.body;
|
|
2151
|
+
const $metadata = deserializeMetadata(output);
|
|
2152
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2146
2153
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2147
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2154
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2148
2155
|
$fault: "client",
|
|
2149
|
-
$metadata
|
|
2156
|
+
$metadata,
|
|
2150
2157
|
});
|
|
2151
2158
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2152
2159
|
}
|
|
@@ -2176,8 +2183,7 @@ const deserializeAws_restJson1ListEnvironmentsCommandError = async (output, cont
|
|
|
2176
2183
|
body: await parseBody(output.body, context),
|
|
2177
2184
|
};
|
|
2178
2185
|
let response;
|
|
2179
|
-
|
|
2180
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2186
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2181
2187
|
switch (errorCode) {
|
|
2182
2188
|
case "AccessDeniedException":
|
|
2183
2189
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2196,10 +2202,12 @@ const deserializeAws_restJson1ListEnvironmentsCommandError = async (output, cont
|
|
|
2196
2202
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2197
2203
|
default:
|
|
2198
2204
|
const parsedBody = parsedOutput.body;
|
|
2205
|
+
const $metadata = deserializeMetadata(output);
|
|
2206
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2199
2207
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2200
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2208
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2201
2209
|
$fault: "client",
|
|
2202
|
-
$metadata
|
|
2210
|
+
$metadata,
|
|
2203
2211
|
});
|
|
2204
2212
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2205
2213
|
}
|
|
@@ -2229,8 +2237,7 @@ const deserializeAws_restJson1ListEnvironmentVpcsCommandError = async (output, c
|
|
|
2229
2237
|
body: await parseBody(output.body, context),
|
|
2230
2238
|
};
|
|
2231
2239
|
let response;
|
|
2232
|
-
|
|
2233
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2240
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2234
2241
|
switch (errorCode) {
|
|
2235
2242
|
case "AccessDeniedException":
|
|
2236
2243
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2249,10 +2256,12 @@ const deserializeAws_restJson1ListEnvironmentVpcsCommandError = async (output, c
|
|
|
2249
2256
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2250
2257
|
default:
|
|
2251
2258
|
const parsedBody = parsedOutput.body;
|
|
2259
|
+
const $metadata = deserializeMetadata(output);
|
|
2260
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2252
2261
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2253
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2262
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2254
2263
|
$fault: "client",
|
|
2255
|
-
$metadata
|
|
2264
|
+
$metadata,
|
|
2256
2265
|
});
|
|
2257
2266
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2258
2267
|
}
|
|
@@ -2282,8 +2291,7 @@ const deserializeAws_restJson1ListRoutesCommandError = async (output, context) =
|
|
|
2282
2291
|
body: await parseBody(output.body, context),
|
|
2283
2292
|
};
|
|
2284
2293
|
let response;
|
|
2285
|
-
|
|
2286
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2294
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2287
2295
|
switch (errorCode) {
|
|
2288
2296
|
case "AccessDeniedException":
|
|
2289
2297
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2308,10 +2316,12 @@ const deserializeAws_restJson1ListRoutesCommandError = async (output, context) =
|
|
|
2308
2316
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2309
2317
|
default:
|
|
2310
2318
|
const parsedBody = parsedOutput.body;
|
|
2319
|
+
const $metadata = deserializeMetadata(output);
|
|
2320
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2311
2321
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2312
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2322
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2313
2323
|
$fault: "client",
|
|
2314
|
-
$metadata
|
|
2324
|
+
$metadata,
|
|
2315
2325
|
});
|
|
2316
2326
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2317
2327
|
}
|
|
@@ -2341,8 +2351,7 @@ const deserializeAws_restJson1ListServicesCommandError = async (output, context)
|
|
|
2341
2351
|
body: await parseBody(output.body, context),
|
|
2342
2352
|
};
|
|
2343
2353
|
let response;
|
|
2344
|
-
|
|
2345
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2354
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2346
2355
|
switch (errorCode) {
|
|
2347
2356
|
case "AccessDeniedException":
|
|
2348
2357
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2367,10 +2376,12 @@ const deserializeAws_restJson1ListServicesCommandError = async (output, context)
|
|
|
2367
2376
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2368
2377
|
default:
|
|
2369
2378
|
const parsedBody = parsedOutput.body;
|
|
2379
|
+
const $metadata = deserializeMetadata(output);
|
|
2380
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2370
2381
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2371
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2382
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2372
2383
|
$fault: "client",
|
|
2373
|
-
$metadata
|
|
2384
|
+
$metadata,
|
|
2374
2385
|
});
|
|
2375
2386
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2376
2387
|
}
|
|
@@ -2396,8 +2407,7 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
|
|
|
2396
2407
|
body: await parseBody(output.body, context),
|
|
2397
2408
|
};
|
|
2398
2409
|
let response;
|
|
2399
|
-
|
|
2400
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2410
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2401
2411
|
switch (errorCode) {
|
|
2402
2412
|
case "InternalServerException":
|
|
2403
2413
|
case "com.amazonaws.migrationhubrefactorspaces#InternalServerException":
|
|
@@ -2410,10 +2420,12 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
|
|
|
2410
2420
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2411
2421
|
default:
|
|
2412
2422
|
const parsedBody = parsedOutput.body;
|
|
2423
|
+
const $metadata = deserializeMetadata(output);
|
|
2424
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2413
2425
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2414
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2426
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2415
2427
|
$fault: "client",
|
|
2416
|
-
$metadata
|
|
2428
|
+
$metadata,
|
|
2417
2429
|
});
|
|
2418
2430
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2419
2431
|
}
|
|
@@ -2435,8 +2447,7 @@ const deserializeAws_restJson1PutResourcePolicyCommandError = async (output, con
|
|
|
2435
2447
|
body: await parseBody(output.body, context),
|
|
2436
2448
|
};
|
|
2437
2449
|
let response;
|
|
2438
|
-
|
|
2439
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2450
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2440
2451
|
switch (errorCode) {
|
|
2441
2452
|
case "AccessDeniedException":
|
|
2442
2453
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2458,10 +2469,12 @@ const deserializeAws_restJson1PutResourcePolicyCommandError = async (output, con
|
|
|
2458
2469
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2459
2470
|
default:
|
|
2460
2471
|
const parsedBody = parsedOutput.body;
|
|
2472
|
+
const $metadata = deserializeMetadata(output);
|
|
2473
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2461
2474
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2462
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2475
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2463
2476
|
$fault: "client",
|
|
2464
|
-
$metadata
|
|
2477
|
+
$metadata,
|
|
2465
2478
|
});
|
|
2466
2479
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2467
2480
|
}
|
|
@@ -2483,8 +2496,7 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
|
|
|
2483
2496
|
body: await parseBody(output.body, context),
|
|
2484
2497
|
};
|
|
2485
2498
|
let response;
|
|
2486
|
-
|
|
2487
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2499
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2488
2500
|
switch (errorCode) {
|
|
2489
2501
|
case "InternalServerException":
|
|
2490
2502
|
case "com.amazonaws.migrationhubrefactorspaces#InternalServerException":
|
|
@@ -2497,10 +2509,12 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
|
|
|
2497
2509
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2498
2510
|
default:
|
|
2499
2511
|
const parsedBody = parsedOutput.body;
|
|
2512
|
+
const $metadata = deserializeMetadata(output);
|
|
2513
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2500
2514
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2501
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2515
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2502
2516
|
$fault: "client",
|
|
2503
|
-
$metadata
|
|
2517
|
+
$metadata,
|
|
2504
2518
|
});
|
|
2505
2519
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2506
2520
|
}
|
|
@@ -2522,8 +2536,7 @@ const deserializeAws_restJson1UntagResourceCommandError = async (output, context
|
|
|
2522
2536
|
body: await parseBody(output.body, context),
|
|
2523
2537
|
};
|
|
2524
2538
|
let response;
|
|
2525
|
-
|
|
2526
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2539
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2527
2540
|
switch (errorCode) {
|
|
2528
2541
|
case "InternalServerException":
|
|
2529
2542
|
case "com.amazonaws.migrationhubrefactorspaces#InternalServerException":
|
|
@@ -2536,10 +2549,12 @@ const deserializeAws_restJson1UntagResourceCommandError = async (output, context
|
|
|
2536
2549
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2537
2550
|
default:
|
|
2538
2551
|
const parsedBody = parsedOutput.body;
|
|
2552
|
+
const $metadata = deserializeMetadata(output);
|
|
2553
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2539
2554
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2540
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2555
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2541
2556
|
$fault: "client",
|
|
2542
|
-
$metadata
|
|
2557
|
+
$metadata,
|
|
2543
2558
|
});
|
|
2544
2559
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2545
2560
|
}
|
|
@@ -2585,8 +2600,7 @@ const deserializeAws_restJson1UpdateRouteCommandError = async (output, context)
|
|
|
2585
2600
|
body: await parseBody(output.body, context),
|
|
2586
2601
|
};
|
|
2587
2602
|
let response;
|
|
2588
|
-
|
|
2589
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2603
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2590
2604
|
switch (errorCode) {
|
|
2591
2605
|
case "AccessDeniedException":
|
|
2592
2606
|
case "com.amazonaws.migrationhubrefactorspaces#AccessDeniedException":
|
|
@@ -2605,10 +2619,12 @@ const deserializeAws_restJson1UpdateRouteCommandError = async (output, context)
|
|
|
2605
2619
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
2606
2620
|
default:
|
|
2607
2621
|
const parsedBody = parsedOutput.body;
|
|
2622
|
+
const $metadata = deserializeMetadata(output);
|
|
2623
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2608
2624
|
response = new MigrationHubRefactorSpacesServiceException_1.MigrationHubRefactorSpacesServiceException({
|
|
2609
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2625
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2610
2626
|
$fault: "client",
|
|
2611
|
-
$metadata
|
|
2627
|
+
$metadata,
|
|
2612
2628
|
});
|
|
2613
2629
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
2614
2630
|
}
|
|
@@ -2744,14 +2760,13 @@ const deserializeAws_restJson1ValidationExceptionResponse = async (parsedOutput,
|
|
|
2744
2760
|
};
|
|
2745
2761
|
const serializeAws_restJson1ApiGatewayProxyInput = (input, context) => {
|
|
2746
2762
|
return {
|
|
2747
|
-
...(input.EndpointType
|
|
2748
|
-
...(input.StageName
|
|
2763
|
+
...(input.EndpointType != null && { EndpointType: input.EndpointType }),
|
|
2764
|
+
...(input.StageName != null && { StageName: input.StageName }),
|
|
2749
2765
|
};
|
|
2750
2766
|
};
|
|
2751
2767
|
const serializeAws_restJson1DefaultRouteInput = (input, context) => {
|
|
2752
2768
|
return {
|
|
2753
|
-
...(input.ActivationState
|
|
2754
|
-
input.ActivationState !== null && { ActivationState: input.ActivationState }),
|
|
2769
|
+
...(input.ActivationState != null && { ActivationState: input.ActivationState }),
|
|
2755
2770
|
};
|
|
2756
2771
|
};
|
|
2757
2772
|
const serializeAws_restJson1HttpMethods = (input, context) => {
|
|
@@ -2766,7 +2781,7 @@ const serializeAws_restJson1HttpMethods = (input, context) => {
|
|
|
2766
2781
|
};
|
|
2767
2782
|
const serializeAws_restJson1LambdaEndpointInput = (input, context) => {
|
|
2768
2783
|
return {
|
|
2769
|
-
...(input.Arn
|
|
2784
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
2770
2785
|
};
|
|
2771
2786
|
};
|
|
2772
2787
|
const serializeAws_restJson1TagMap = (input, context) => {
|
|
@@ -2782,19 +2797,16 @@ const serializeAws_restJson1TagMap = (input, context) => {
|
|
|
2782
2797
|
};
|
|
2783
2798
|
const serializeAws_restJson1UriPathRouteInput = (input, context) => {
|
|
2784
2799
|
return {
|
|
2785
|
-
...(input.ActivationState
|
|
2786
|
-
|
|
2787
|
-
...(input.
|
|
2788
|
-
|
|
2789
|
-
...(input.Methods !== undefined &&
|
|
2790
|
-
input.Methods !== null && { Methods: serializeAws_restJson1HttpMethods(input.Methods, context) }),
|
|
2791
|
-
...(input.SourcePath !== undefined && input.SourcePath !== null && { SourcePath: input.SourcePath }),
|
|
2800
|
+
...(input.ActivationState != null && { ActivationState: input.ActivationState }),
|
|
2801
|
+
...(input.IncludeChildPaths != null && { IncludeChildPaths: input.IncludeChildPaths }),
|
|
2802
|
+
...(input.Methods != null && { Methods: serializeAws_restJson1HttpMethods(input.Methods, context) }),
|
|
2803
|
+
...(input.SourcePath != null && { SourcePath: input.SourcePath }),
|
|
2792
2804
|
};
|
|
2793
2805
|
};
|
|
2794
2806
|
const serializeAws_restJson1UrlEndpointInput = (input, context) => {
|
|
2795
2807
|
return {
|
|
2796
|
-
...(input.HealthUrl
|
|
2797
|
-
...(input.Url
|
|
2808
|
+
...(input.HealthUrl != null && { HealthUrl: input.HealthUrl }),
|
|
2809
|
+
...(input.Url != null && { Url: input.Url }),
|
|
2798
2810
|
};
|
|
2799
2811
|
};
|
|
2800
2812
|
const deserializeAws_restJson1AdditionalDetails = (output, context) => {
|
|
@@ -2849,29 +2861,25 @@ const deserializeAws_restJson1ApplicationSummaries = (output, context) => {
|
|
|
2849
2861
|
};
|
|
2850
2862
|
const deserializeAws_restJson1ApplicationSummary = (output, context) => {
|
|
2851
2863
|
return {
|
|
2852
|
-
ApiGatewayProxy: output.ApiGatewayProxy
|
|
2864
|
+
ApiGatewayProxy: output.ApiGatewayProxy != null
|
|
2853
2865
|
? deserializeAws_restJson1ApiGatewayProxySummary(output.ApiGatewayProxy, context)
|
|
2854
2866
|
: undefined,
|
|
2855
2867
|
ApplicationId: (0, smithy_client_1.expectString)(output.ApplicationId),
|
|
2856
2868
|
Arn: (0, smithy_client_1.expectString)(output.Arn),
|
|
2857
2869
|
CreatedByAccountId: (0, smithy_client_1.expectString)(output.CreatedByAccountId),
|
|
2858
|
-
CreatedTime: output.CreatedTime
|
|
2870
|
+
CreatedTime: output.CreatedTime != null
|
|
2859
2871
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreatedTime)))
|
|
2860
2872
|
: undefined,
|
|
2861
2873
|
EnvironmentId: (0, smithy_client_1.expectString)(output.EnvironmentId),
|
|
2862
|
-
Error: output.Error
|
|
2863
|
-
|
|
2864
|
-
: undefined,
|
|
2865
|
-
LastUpdatedTime: output.LastUpdatedTime !== undefined && output.LastUpdatedTime !== null
|
|
2874
|
+
Error: output.Error != null ? deserializeAws_restJson1ErrorResponse(output.Error, context) : undefined,
|
|
2875
|
+
LastUpdatedTime: output.LastUpdatedTime != null
|
|
2866
2876
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastUpdatedTime)))
|
|
2867
2877
|
: undefined,
|
|
2868
2878
|
Name: (0, smithy_client_1.expectString)(output.Name),
|
|
2869
2879
|
OwnerAccountId: (0, smithy_client_1.expectString)(output.OwnerAccountId),
|
|
2870
2880
|
ProxyType: (0, smithy_client_1.expectString)(output.ProxyType),
|
|
2871
2881
|
State: (0, smithy_client_1.expectString)(output.State),
|
|
2872
|
-
Tags: output.Tags
|
|
2873
|
-
? deserializeAws_restJson1TagMap(output.Tags, context)
|
|
2874
|
-
: undefined,
|
|
2882
|
+
Tags: output.Tags != null ? deserializeAws_restJson1TagMap(output.Tags, context) : undefined,
|
|
2875
2883
|
VpcId: (0, smithy_client_1.expectString)(output.VpcId),
|
|
2876
2884
|
};
|
|
2877
2885
|
};
|
|
@@ -2900,38 +2908,32 @@ const deserializeAws_restJson1EnvironmentSummaries = (output, context) => {
|
|
|
2900
2908
|
const deserializeAws_restJson1EnvironmentSummary = (output, context) => {
|
|
2901
2909
|
return {
|
|
2902
2910
|
Arn: (0, smithy_client_1.expectString)(output.Arn),
|
|
2903
|
-
CreatedTime: output.CreatedTime
|
|
2911
|
+
CreatedTime: output.CreatedTime != null
|
|
2904
2912
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreatedTime)))
|
|
2905
2913
|
: undefined,
|
|
2906
2914
|
Description: (0, smithy_client_1.expectString)(output.Description),
|
|
2907
2915
|
EnvironmentId: (0, smithy_client_1.expectString)(output.EnvironmentId),
|
|
2908
|
-
Error: output.Error
|
|
2909
|
-
|
|
2910
|
-
: undefined,
|
|
2911
|
-
LastUpdatedTime: output.LastUpdatedTime !== undefined && output.LastUpdatedTime !== null
|
|
2916
|
+
Error: output.Error != null ? deserializeAws_restJson1ErrorResponse(output.Error, context) : undefined,
|
|
2917
|
+
LastUpdatedTime: output.LastUpdatedTime != null
|
|
2912
2918
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastUpdatedTime)))
|
|
2913
2919
|
: undefined,
|
|
2914
2920
|
Name: (0, smithy_client_1.expectString)(output.Name),
|
|
2915
2921
|
NetworkFabricType: (0, smithy_client_1.expectString)(output.NetworkFabricType),
|
|
2916
2922
|
OwnerAccountId: (0, smithy_client_1.expectString)(output.OwnerAccountId),
|
|
2917
2923
|
State: (0, smithy_client_1.expectString)(output.State),
|
|
2918
|
-
Tags: output.Tags
|
|
2919
|
-
? deserializeAws_restJson1TagMap(output.Tags, context)
|
|
2920
|
-
: undefined,
|
|
2924
|
+
Tags: output.Tags != null ? deserializeAws_restJson1TagMap(output.Tags, context) : undefined,
|
|
2921
2925
|
TransitGatewayId: (0, smithy_client_1.expectString)(output.TransitGatewayId),
|
|
2922
2926
|
};
|
|
2923
2927
|
};
|
|
2924
2928
|
const deserializeAws_restJson1EnvironmentVpc = (output, context) => {
|
|
2925
2929
|
return {
|
|
2926
2930
|
AccountId: (0, smithy_client_1.expectString)(output.AccountId),
|
|
2927
|
-
CidrBlocks: output.CidrBlocks
|
|
2928
|
-
|
|
2929
|
-
: undefined,
|
|
2930
|
-
CreatedTime: output.CreatedTime !== undefined && output.CreatedTime !== null
|
|
2931
|
+
CidrBlocks: output.CidrBlocks != null ? deserializeAws_restJson1CidrBlocks(output.CidrBlocks, context) : undefined,
|
|
2932
|
+
CreatedTime: output.CreatedTime != null
|
|
2931
2933
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreatedTime)))
|
|
2932
2934
|
: undefined,
|
|
2933
2935
|
EnvironmentId: (0, smithy_client_1.expectString)(output.EnvironmentId),
|
|
2934
|
-
LastUpdatedTime: output.LastUpdatedTime
|
|
2936
|
+
LastUpdatedTime: output.LastUpdatedTime != null
|
|
2935
2937
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastUpdatedTime)))
|
|
2936
2938
|
: undefined,
|
|
2937
2939
|
VpcId: (0, smithy_client_1.expectString)(output.VpcId),
|
|
@@ -2952,7 +2954,7 @@ const deserializeAws_restJson1EnvironmentVpcs = (output, context) => {
|
|
|
2952
2954
|
const deserializeAws_restJson1ErrorResponse = (output, context) => {
|
|
2953
2955
|
return {
|
|
2954
2956
|
AccountId: (0, smithy_client_1.expectString)(output.AccountId),
|
|
2955
|
-
AdditionalDetails: output.AdditionalDetails
|
|
2957
|
+
AdditionalDetails: output.AdditionalDetails != null
|
|
2956
2958
|
? deserializeAws_restJson1AdditionalDetails(output.AdditionalDetails, context)
|
|
2957
2959
|
: undefined,
|
|
2958
2960
|
Code: (0, smithy_client_1.expectString)(output.Code),
|
|
@@ -3014,22 +3016,18 @@ const deserializeAws_restJson1RouteSummary = (output, context) => {
|
|
|
3014
3016
|
ApplicationId: (0, smithy_client_1.expectString)(output.ApplicationId),
|
|
3015
3017
|
Arn: (0, smithy_client_1.expectString)(output.Arn),
|
|
3016
3018
|
CreatedByAccountId: (0, smithy_client_1.expectString)(output.CreatedByAccountId),
|
|
3017
|
-
CreatedTime: output.CreatedTime
|
|
3019
|
+
CreatedTime: output.CreatedTime != null
|
|
3018
3020
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreatedTime)))
|
|
3019
3021
|
: undefined,
|
|
3020
3022
|
EnvironmentId: (0, smithy_client_1.expectString)(output.EnvironmentId),
|
|
3021
|
-
Error: output.Error
|
|
3022
|
-
? deserializeAws_restJson1ErrorResponse(output.Error, context)
|
|
3023
|
-
: undefined,
|
|
3023
|
+
Error: output.Error != null ? deserializeAws_restJson1ErrorResponse(output.Error, context) : undefined,
|
|
3024
3024
|
IncludeChildPaths: (0, smithy_client_1.expectBoolean)(output.IncludeChildPaths),
|
|
3025
|
-
LastUpdatedTime: output.LastUpdatedTime
|
|
3025
|
+
LastUpdatedTime: output.LastUpdatedTime != null
|
|
3026
3026
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastUpdatedTime)))
|
|
3027
3027
|
: undefined,
|
|
3028
|
-
Methods: output.Methods
|
|
3029
|
-
? deserializeAws_restJson1HttpMethods(output.Methods, context)
|
|
3030
|
-
: undefined,
|
|
3028
|
+
Methods: output.Methods != null ? deserializeAws_restJson1HttpMethods(output.Methods, context) : undefined,
|
|
3031
3029
|
OwnerAccountId: (0, smithy_client_1.expectString)(output.OwnerAccountId),
|
|
3032
|
-
PathResourceToId: output.PathResourceToId
|
|
3030
|
+
PathResourceToId: output.PathResourceToId != null
|
|
3033
3031
|
? deserializeAws_restJson1PathResourceToId(output.PathResourceToId, context)
|
|
3034
3032
|
: undefined,
|
|
3035
3033
|
RouteId: (0, smithy_client_1.expectString)(output.RouteId),
|
|
@@ -3037,9 +3035,7 @@ const deserializeAws_restJson1RouteSummary = (output, context) => {
|
|
|
3037
3035
|
ServiceId: (0, smithy_client_1.expectString)(output.ServiceId),
|
|
3038
3036
|
SourcePath: (0, smithy_client_1.expectString)(output.SourcePath),
|
|
3039
3037
|
State: (0, smithy_client_1.expectString)(output.State),
|
|
3040
|
-
Tags: output.Tags
|
|
3041
|
-
? deserializeAws_restJson1TagMap(output.Tags, context)
|
|
3042
|
-
: undefined,
|
|
3038
|
+
Tags: output.Tags != null ? deserializeAws_restJson1TagMap(output.Tags, context) : undefined,
|
|
3043
3039
|
};
|
|
3044
3040
|
};
|
|
3045
3041
|
const deserializeAws_restJson1ServiceSummaries = (output, context) => {
|
|
@@ -3058,31 +3054,25 @@ const deserializeAws_restJson1ServiceSummary = (output, context) => {
|
|
|
3058
3054
|
ApplicationId: (0, smithy_client_1.expectString)(output.ApplicationId),
|
|
3059
3055
|
Arn: (0, smithy_client_1.expectString)(output.Arn),
|
|
3060
3056
|
CreatedByAccountId: (0, smithy_client_1.expectString)(output.CreatedByAccountId),
|
|
3061
|
-
CreatedTime: output.CreatedTime
|
|
3057
|
+
CreatedTime: output.CreatedTime != null
|
|
3062
3058
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreatedTime)))
|
|
3063
3059
|
: undefined,
|
|
3064
3060
|
Description: (0, smithy_client_1.expectString)(output.Description),
|
|
3065
3061
|
EndpointType: (0, smithy_client_1.expectString)(output.EndpointType),
|
|
3066
3062
|
EnvironmentId: (0, smithy_client_1.expectString)(output.EnvironmentId),
|
|
3067
|
-
Error: output.Error
|
|
3068
|
-
|
|
3069
|
-
: undefined,
|
|
3070
|
-
LambdaEndpoint: output.LambdaEndpoint !== undefined && output.LambdaEndpoint !== null
|
|
3063
|
+
Error: output.Error != null ? deserializeAws_restJson1ErrorResponse(output.Error, context) : undefined,
|
|
3064
|
+
LambdaEndpoint: output.LambdaEndpoint != null
|
|
3071
3065
|
? deserializeAws_restJson1LambdaEndpointSummary(output.LambdaEndpoint, context)
|
|
3072
3066
|
: undefined,
|
|
3073
|
-
LastUpdatedTime: output.LastUpdatedTime
|
|
3067
|
+
LastUpdatedTime: output.LastUpdatedTime != null
|
|
3074
3068
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastUpdatedTime)))
|
|
3075
3069
|
: undefined,
|
|
3076
3070
|
Name: (0, smithy_client_1.expectString)(output.Name),
|
|
3077
3071
|
OwnerAccountId: (0, smithy_client_1.expectString)(output.OwnerAccountId),
|
|
3078
3072
|
ServiceId: (0, smithy_client_1.expectString)(output.ServiceId),
|
|
3079
3073
|
State: (0, smithy_client_1.expectString)(output.State),
|
|
3080
|
-
Tags: output.Tags
|
|
3081
|
-
|
|
3082
|
-
: undefined,
|
|
3083
|
-
UrlEndpoint: output.UrlEndpoint !== undefined && output.UrlEndpoint !== null
|
|
3084
|
-
? deserializeAws_restJson1UrlEndpointSummary(output.UrlEndpoint, context)
|
|
3085
|
-
: undefined,
|
|
3074
|
+
Tags: output.Tags != null ? deserializeAws_restJson1TagMap(output.Tags, context) : undefined,
|
|
3075
|
+
UrlEndpoint: output.UrlEndpoint != null ? deserializeAws_restJson1UrlEndpointSummary(output.UrlEndpoint, context) : undefined,
|
|
3086
3076
|
VpcId: (0, smithy_client_1.expectString)(output.VpcId),
|
|
3087
3077
|
};
|
|
3088
3078
|
};
|
|
@@ -3101,9 +3091,7 @@ const deserializeAws_restJson1UriPathRouteInput = (output, context) => {
|
|
|
3101
3091
|
return {
|
|
3102
3092
|
ActivationState: (0, smithy_client_1.expectString)(output.ActivationState),
|
|
3103
3093
|
IncludeChildPaths: (0, smithy_client_1.expectBoolean)(output.IncludeChildPaths),
|
|
3104
|
-
Methods: output.Methods
|
|
3105
|
-
? deserializeAws_restJson1HttpMethods(output.Methods, context)
|
|
3106
|
-
: undefined,
|
|
3094
|
+
Methods: output.Methods != null ? deserializeAws_restJson1HttpMethods(output.Methods, context) : undefined,
|
|
3107
3095
|
SourcePath: (0, smithy_client_1.expectString)(output.SourcePath),
|
|
3108
3096
|
};
|
|
3109
3097
|
};
|
|
@@ -3174,5 +3162,4 @@ const loadRestJsonErrorCode = (output, data) => {
|
|
|
3174
3162
|
if (data["__type"] !== undefined) {
|
|
3175
3163
|
return sanitizeErrorCode(data["__type"]);
|
|
3176
3164
|
}
|
|
3177
|
-
return "";
|
|
3178
3165
|
};
|