@aws-sdk/client-networkmanager 3.39.0 → 3.43.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 +39 -0
- package/README.md +1 -2
- package/dist-cjs/NetworkManager.js +120 -0
- package/dist-cjs/commands/GetNetworkResourceCountsCommand.js +36 -0
- package/dist-cjs/commands/GetNetworkResourceRelationshipsCommand.js +36 -0
- package/dist-cjs/commands/GetNetworkResourcesCommand.js +36 -0
- package/dist-cjs/commands/GetNetworkRoutesCommand.js +36 -0
- package/dist-cjs/commands/GetNetworkTelemetryCommand.js +36 -0
- package/dist-cjs/commands/GetRouteAnalysisCommand.js +36 -0
- package/dist-cjs/commands/StartRouteAnalysisCommand.js +36 -0
- package/dist-cjs/commands/UpdateNetworkResourceMetadataCommand.js +36 -0
- package/dist-cjs/commands/index.js +8 -0
- package/dist-cjs/endpoints.js +98 -7
- package/dist-cjs/models/models_0.js +238 -3
- package/dist-cjs/pagination/GetNetworkResourceCountsPaginator.js +35 -0
- package/dist-cjs/pagination/GetNetworkResourceRelationshipsPaginator.js +35 -0
- package/dist-cjs/pagination/GetNetworkResourcesPaginator.js +35 -0
- package/dist-cjs/pagination/GetNetworkTelemetryPaginator.js +35 -0
- package/dist-cjs/pagination/index.js +5 -1
- package/dist-cjs/protocols/Aws_restJson1.js +1352 -15
- package/dist-cjs/runtimeConfig.browser.js +6 -3
- package/dist-cjs/runtimeConfig.js +5 -3
- package/dist-es/NetworkManager.js +120 -0
- package/dist-es/commands/GetNetworkResourceCountsCommand.js +39 -0
- package/dist-es/commands/GetNetworkResourceRelationshipsCommand.js +39 -0
- package/dist-es/commands/GetNetworkResourcesCommand.js +39 -0
- package/dist-es/commands/GetNetworkRoutesCommand.js +39 -0
- package/dist-es/commands/GetNetworkTelemetryCommand.js +39 -0
- package/dist-es/commands/GetRouteAnalysisCommand.js +39 -0
- package/dist-es/commands/StartRouteAnalysisCommand.js +39 -0
- package/dist-es/commands/UpdateNetworkResourceMetadataCommand.js +39 -0
- package/dist-es/commands/index.js +8 -0
- package/dist-es/endpoints.js +98 -7
- package/dist-es/models/models_0.js +173 -0
- package/dist-es/pagination/GetNetworkResourceCountsPaginator.js +74 -0
- package/dist-es/pagination/GetNetworkResourceRelationshipsPaginator.js +74 -0
- package/dist-es/pagination/GetNetworkResourcesPaginator.js +74 -0
- package/dist-es/pagination/GetNetworkTelemetryPaginator.js +74 -0
- package/dist-es/pagination/index.js +5 -1
- package/dist-es/protocols/Aws_restJson1.js +1576 -142
- package/dist-es/runtimeConfig.browser.js +3 -2
- package/dist-es/runtimeConfig.js +3 -3
- package/dist-types/NetworkManager.d.ts +61 -4
- package/dist-types/NetworkManagerClient.d.ts +19 -4
- package/dist-types/commands/AssociateCustomerGatewayCommand.d.ts +1 -1
- package/dist-types/commands/AssociateLinkCommand.d.ts +1 -1
- package/dist-types/commands/AssociateTransitGatewayConnectPeerCommand.d.ts +1 -1
- package/dist-types/commands/CreateConnectionCommand.d.ts +1 -1
- package/dist-types/commands/CreateDeviceCommand.d.ts +1 -1
- package/dist-types/commands/CreateGlobalNetworkCommand.d.ts +1 -1
- package/dist-types/commands/CreateLinkCommand.d.ts +1 -1
- package/dist-types/commands/CreateSiteCommand.d.ts +1 -1
- package/dist-types/commands/DeleteConnectionCommand.d.ts +1 -1
- package/dist-types/commands/DeleteDeviceCommand.d.ts +1 -1
- package/dist-types/commands/DeleteGlobalNetworkCommand.d.ts +1 -1
- package/dist-types/commands/DeleteLinkCommand.d.ts +1 -1
- package/dist-types/commands/DeleteSiteCommand.d.ts +1 -1
- package/dist-types/commands/DeregisterTransitGatewayCommand.d.ts +1 -1
- package/dist-types/commands/DescribeGlobalNetworksCommand.d.ts +1 -1
- package/dist-types/commands/DisassociateCustomerGatewayCommand.d.ts +1 -1
- package/dist-types/commands/DisassociateLinkCommand.d.ts +1 -1
- package/dist-types/commands/DisassociateTransitGatewayConnectPeerCommand.d.ts +1 -1
- package/dist-types/commands/GetConnectionsCommand.d.ts +1 -1
- package/dist-types/commands/GetCustomerGatewayAssociationsCommand.d.ts +1 -1
- package/dist-types/commands/GetDevicesCommand.d.ts +1 -1
- package/dist-types/commands/GetLinkAssociationsCommand.d.ts +1 -1
- package/dist-types/commands/GetLinksCommand.d.ts +1 -1
- package/dist-types/commands/GetNetworkResourceCountsCommand.d.ts +35 -0
- package/dist-types/commands/GetNetworkResourceRelationshipsCommand.d.ts +35 -0
- package/dist-types/commands/GetNetworkResourcesCommand.d.ts +36 -0
- package/dist-types/commands/GetNetworkRoutesCommand.d.ts +35 -0
- package/dist-types/commands/GetNetworkTelemetryCommand.d.ts +35 -0
- package/dist-types/commands/GetRouteAnalysisCommand.d.ts +35 -0
- package/dist-types/commands/GetSitesCommand.d.ts +1 -1
- package/dist-types/commands/GetTransitGatewayConnectPeerAssociationsCommand.d.ts +1 -1
- package/dist-types/commands/GetTransitGatewayRegistrationsCommand.d.ts +1 -1
- package/dist-types/commands/ListTagsForResourceCommand.d.ts +1 -1
- package/dist-types/commands/RegisterTransitGatewayCommand.d.ts +3 -3
- package/dist-types/commands/StartRouteAnalysisCommand.d.ts +36 -0
- package/dist-types/commands/TagResourceCommand.d.ts +1 -1
- package/dist-types/commands/UntagResourceCommand.d.ts +1 -1
- package/dist-types/commands/UpdateConnectionCommand.d.ts +1 -1
- package/dist-types/commands/UpdateDeviceCommand.d.ts +1 -1
- package/dist-types/commands/UpdateGlobalNetworkCommand.d.ts +1 -1
- package/dist-types/commands/UpdateLinkCommand.d.ts +1 -1
- package/dist-types/commands/UpdateNetworkResourceMetadataCommand.d.ts +35 -0
- package/dist-types/commands/UpdateSiteCommand.d.ts +1 -1
- package/dist-types/commands/index.d.ts +8 -0
- package/dist-types/models/models_0.d.ts +1412 -137
- package/dist-types/pagination/GetNetworkResourceCountsPaginator.d.ts +4 -0
- package/dist-types/pagination/GetNetworkResourceRelationshipsPaginator.d.ts +4 -0
- package/dist-types/pagination/GetNetworkResourcesPaginator.d.ts +4 -0
- package/dist-types/pagination/GetNetworkTelemetryPaginator.d.ts +4 -0
- package/dist-types/pagination/index.d.ts +5 -1
- package/dist-types/protocols/Aws_restJson1.d.ts +24 -0
- package/dist-types/runtimeConfig.browser.d.ts +2 -0
- package/dist-types/runtimeConfig.d.ts +2 -0
- package/dist-types/runtimeConfig.native.d.ts +2 -0
- package/dist-types/ts3.4/NetworkManager.d.ts +40 -0
- package/dist-types/ts3.4/NetworkManagerClient.d.ts +14 -2
- package/dist-types/ts3.4/commands/GetNetworkResourceCountsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetNetworkResourceRelationshipsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetNetworkResourcesCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetNetworkRoutesCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetNetworkTelemetryCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetRouteAnalysisCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/StartRouteAnalysisCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateNetworkResourceMetadataCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/index.d.ts +8 -0
- package/dist-types/ts3.4/models/models_0.d.ts +511 -0
- package/dist-types/ts3.4/pagination/GetNetworkResourceCountsPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/GetNetworkResourceRelationshipsPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/GetNetworkResourcesPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/GetNetworkTelemetryPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/index.d.ts +5 -1
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +24 -0
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +2 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +2 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +2 -0
- package/package.json +23 -23
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { __assign, __awaiter, __generator } from "tslib";
|
|
1
|
+
import { __assign, __awaiter, __generator, __read } from "tslib";
|
|
2
2
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, parseEpochTimestamp as __parseEpochTimestamp, strictParseInt32 as __strictParseInt32, } from "@aws-sdk/smithy-client";
|
|
3
|
+
import { expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, parseEpochTimestamp as __parseEpochTimestamp, strictParseInt32 as __strictParseInt32, } from "@aws-sdk/smithy-client";
|
|
4
4
|
export var serializeAws_restJson1AssociateCustomerGatewayCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
5
5
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
6
6
|
return __generator(this, function (_c) {
|
|
@@ -840,6 +840,242 @@ export var serializeAws_restJson1GetLinksCommand = function (input, context) { r
|
|
|
840
840
|
}
|
|
841
841
|
});
|
|
842
842
|
}); };
|
|
843
|
+
export var serializeAws_restJson1GetNetworkResourceCountsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
844
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, query, body;
|
|
845
|
+
return __generator(this, function (_c) {
|
|
846
|
+
switch (_c.label) {
|
|
847
|
+
case 0: return [4, context.endpoint()];
|
|
848
|
+
case 1:
|
|
849
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
850
|
+
headers = {};
|
|
851
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
852
|
+
"/global-networks/{GlobalNetworkId}/network-resource-count";
|
|
853
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
854
|
+
labelValue = input.GlobalNetworkId;
|
|
855
|
+
if (labelValue.length <= 0) {
|
|
856
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
857
|
+
}
|
|
858
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
859
|
+
}
|
|
860
|
+
else {
|
|
861
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
862
|
+
}
|
|
863
|
+
query = __assign(__assign(__assign({}, (input.ResourceType !== undefined && { resourceType: input.ResourceType })), (input.MaxResults !== undefined && { maxResults: input.MaxResults.toString() })), (input.NextToken !== undefined && { nextToken: input.NextToken }));
|
|
864
|
+
return [2, new __HttpRequest({
|
|
865
|
+
protocol: protocol,
|
|
866
|
+
hostname: hostname,
|
|
867
|
+
port: port,
|
|
868
|
+
method: "GET",
|
|
869
|
+
headers: headers,
|
|
870
|
+
path: resolvedPath,
|
|
871
|
+
query: query,
|
|
872
|
+
body: body,
|
|
873
|
+
})];
|
|
874
|
+
}
|
|
875
|
+
});
|
|
876
|
+
}); };
|
|
877
|
+
export var serializeAws_restJson1GetNetworkResourceRelationshipsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
878
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, query, body;
|
|
879
|
+
return __generator(this, function (_c) {
|
|
880
|
+
switch (_c.label) {
|
|
881
|
+
case 0: return [4, context.endpoint()];
|
|
882
|
+
case 1:
|
|
883
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
884
|
+
headers = {};
|
|
885
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
886
|
+
"/global-networks/{GlobalNetworkId}/network-resource-relationships";
|
|
887
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
888
|
+
labelValue = input.GlobalNetworkId;
|
|
889
|
+
if (labelValue.length <= 0) {
|
|
890
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
891
|
+
}
|
|
892
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
893
|
+
}
|
|
894
|
+
else {
|
|
895
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
896
|
+
}
|
|
897
|
+
query = __assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.RegisteredGatewayArn !== undefined && { registeredGatewayArn: input.RegisteredGatewayArn })), (input.AwsRegion !== undefined && { awsRegion: input.AwsRegion })), (input.AccountId !== undefined && { accountId: input.AccountId })), (input.ResourceType !== undefined && { resourceType: input.ResourceType })), (input.ResourceArn !== undefined && { resourceArn: input.ResourceArn })), (input.MaxResults !== undefined && { maxResults: input.MaxResults.toString() })), (input.NextToken !== undefined && { nextToken: input.NextToken }));
|
|
898
|
+
return [2, new __HttpRequest({
|
|
899
|
+
protocol: protocol,
|
|
900
|
+
hostname: hostname,
|
|
901
|
+
port: port,
|
|
902
|
+
method: "GET",
|
|
903
|
+
headers: headers,
|
|
904
|
+
path: resolvedPath,
|
|
905
|
+
query: query,
|
|
906
|
+
body: body,
|
|
907
|
+
})];
|
|
908
|
+
}
|
|
909
|
+
});
|
|
910
|
+
}); };
|
|
911
|
+
export var serializeAws_restJson1GetNetworkResourcesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
912
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, query, body;
|
|
913
|
+
return __generator(this, function (_c) {
|
|
914
|
+
switch (_c.label) {
|
|
915
|
+
case 0: return [4, context.endpoint()];
|
|
916
|
+
case 1:
|
|
917
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
918
|
+
headers = {};
|
|
919
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
920
|
+
"/global-networks/{GlobalNetworkId}/network-resources";
|
|
921
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
922
|
+
labelValue = input.GlobalNetworkId;
|
|
923
|
+
if (labelValue.length <= 0) {
|
|
924
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
925
|
+
}
|
|
926
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
927
|
+
}
|
|
928
|
+
else {
|
|
929
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
930
|
+
}
|
|
931
|
+
query = __assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.RegisteredGatewayArn !== undefined && { registeredGatewayArn: input.RegisteredGatewayArn })), (input.AwsRegion !== undefined && { awsRegion: input.AwsRegion })), (input.AccountId !== undefined && { accountId: input.AccountId })), (input.ResourceType !== undefined && { resourceType: input.ResourceType })), (input.ResourceArn !== undefined && { resourceArn: input.ResourceArn })), (input.MaxResults !== undefined && { maxResults: input.MaxResults.toString() })), (input.NextToken !== undefined && { nextToken: input.NextToken }));
|
|
932
|
+
return [2, new __HttpRequest({
|
|
933
|
+
protocol: protocol,
|
|
934
|
+
hostname: hostname,
|
|
935
|
+
port: port,
|
|
936
|
+
method: "GET",
|
|
937
|
+
headers: headers,
|
|
938
|
+
path: resolvedPath,
|
|
939
|
+
query: query,
|
|
940
|
+
body: body,
|
|
941
|
+
})];
|
|
942
|
+
}
|
|
943
|
+
});
|
|
944
|
+
}); };
|
|
945
|
+
export var serializeAws_restJson1GetNetworkRoutesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
946
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
947
|
+
return __generator(this, function (_c) {
|
|
948
|
+
switch (_c.label) {
|
|
949
|
+
case 0: return [4, context.endpoint()];
|
|
950
|
+
case 1:
|
|
951
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
952
|
+
headers = {
|
|
953
|
+
"content-type": "application/json",
|
|
954
|
+
};
|
|
955
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
956
|
+
"/global-networks/{GlobalNetworkId}/network-routes";
|
|
957
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
958
|
+
labelValue = input.GlobalNetworkId;
|
|
959
|
+
if (labelValue.length <= 0) {
|
|
960
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
961
|
+
}
|
|
962
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
963
|
+
}
|
|
964
|
+
else {
|
|
965
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
966
|
+
}
|
|
967
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.DestinationFilters !== undefined &&
|
|
968
|
+
input.DestinationFilters !== null && {
|
|
969
|
+
DestinationFilters: serializeAws_restJson1FilterMap(input.DestinationFilters, context),
|
|
970
|
+
})), (input.ExactCidrMatches !== undefined &&
|
|
971
|
+
input.ExactCidrMatches !== null && {
|
|
972
|
+
ExactCidrMatches: serializeAws_restJson1StringList(input.ExactCidrMatches, context),
|
|
973
|
+
})), (input.LongestPrefixMatches !== undefined &&
|
|
974
|
+
input.LongestPrefixMatches !== null && {
|
|
975
|
+
LongestPrefixMatches: serializeAws_restJson1StringList(input.LongestPrefixMatches, context),
|
|
976
|
+
})), (input.PrefixListIds !== undefined &&
|
|
977
|
+
input.PrefixListIds !== null && {
|
|
978
|
+
PrefixListIds: serializeAws_restJson1StringList(input.PrefixListIds, context),
|
|
979
|
+
})), (input.RouteTableIdentifier !== undefined &&
|
|
980
|
+
input.RouteTableIdentifier !== null && {
|
|
981
|
+
RouteTableIdentifier: serializeAws_restJson1RouteTableIdentifier(input.RouteTableIdentifier, context),
|
|
982
|
+
})), (input.States !== undefined &&
|
|
983
|
+
input.States !== null && { States: serializeAws_restJson1RouteStateList(input.States, context) })), (input.SubnetOfMatches !== undefined &&
|
|
984
|
+
input.SubnetOfMatches !== null && {
|
|
985
|
+
SubnetOfMatches: serializeAws_restJson1StringList(input.SubnetOfMatches, context),
|
|
986
|
+
})), (input.SupernetOfMatches !== undefined &&
|
|
987
|
+
input.SupernetOfMatches !== null && {
|
|
988
|
+
SupernetOfMatches: serializeAws_restJson1StringList(input.SupernetOfMatches, context),
|
|
989
|
+
})), (input.Types !== undefined &&
|
|
990
|
+
input.Types !== null && { Types: serializeAws_restJson1RouteTypeList(input.Types, context) })));
|
|
991
|
+
return [2, new __HttpRequest({
|
|
992
|
+
protocol: protocol,
|
|
993
|
+
hostname: hostname,
|
|
994
|
+
port: port,
|
|
995
|
+
method: "POST",
|
|
996
|
+
headers: headers,
|
|
997
|
+
path: resolvedPath,
|
|
998
|
+
body: body,
|
|
999
|
+
})];
|
|
1000
|
+
}
|
|
1001
|
+
});
|
|
1002
|
+
}); };
|
|
1003
|
+
export var serializeAws_restJson1GetNetworkTelemetryCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1004
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, query, body;
|
|
1005
|
+
return __generator(this, function (_c) {
|
|
1006
|
+
switch (_c.label) {
|
|
1007
|
+
case 0: return [4, context.endpoint()];
|
|
1008
|
+
case 1:
|
|
1009
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
1010
|
+
headers = {};
|
|
1011
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
1012
|
+
"/global-networks/{GlobalNetworkId}/network-telemetry";
|
|
1013
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
1014
|
+
labelValue = input.GlobalNetworkId;
|
|
1015
|
+
if (labelValue.length <= 0) {
|
|
1016
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
1017
|
+
}
|
|
1018
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
1019
|
+
}
|
|
1020
|
+
else {
|
|
1021
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
1022
|
+
}
|
|
1023
|
+
query = __assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.RegisteredGatewayArn !== undefined && { registeredGatewayArn: input.RegisteredGatewayArn })), (input.AwsRegion !== undefined && { awsRegion: input.AwsRegion })), (input.AccountId !== undefined && { accountId: input.AccountId })), (input.ResourceType !== undefined && { resourceType: input.ResourceType })), (input.ResourceArn !== undefined && { resourceArn: input.ResourceArn })), (input.MaxResults !== undefined && { maxResults: input.MaxResults.toString() })), (input.NextToken !== undefined && { nextToken: input.NextToken }));
|
|
1024
|
+
return [2, new __HttpRequest({
|
|
1025
|
+
protocol: protocol,
|
|
1026
|
+
hostname: hostname,
|
|
1027
|
+
port: port,
|
|
1028
|
+
method: "GET",
|
|
1029
|
+
headers: headers,
|
|
1030
|
+
path: resolvedPath,
|
|
1031
|
+
query: query,
|
|
1032
|
+
body: body,
|
|
1033
|
+
})];
|
|
1034
|
+
}
|
|
1035
|
+
});
|
|
1036
|
+
}); };
|
|
1037
|
+
export var serializeAws_restJson1GetRouteAnalysisCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1038
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, labelValue, body;
|
|
1039
|
+
return __generator(this, function (_c) {
|
|
1040
|
+
switch (_c.label) {
|
|
1041
|
+
case 0: return [4, context.endpoint()];
|
|
1042
|
+
case 1:
|
|
1043
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
1044
|
+
headers = {};
|
|
1045
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
1046
|
+
"/global-networks/{GlobalNetworkId}/route-analyses/{RouteAnalysisId}";
|
|
1047
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
1048
|
+
labelValue = input.GlobalNetworkId;
|
|
1049
|
+
if (labelValue.length <= 0) {
|
|
1050
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
1051
|
+
}
|
|
1052
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
1053
|
+
}
|
|
1054
|
+
else {
|
|
1055
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
1056
|
+
}
|
|
1057
|
+
if (input.RouteAnalysisId !== undefined) {
|
|
1058
|
+
labelValue = input.RouteAnalysisId;
|
|
1059
|
+
if (labelValue.length <= 0) {
|
|
1060
|
+
throw new Error("Empty value provided for input HTTP label: RouteAnalysisId.");
|
|
1061
|
+
}
|
|
1062
|
+
resolvedPath = resolvedPath.replace("{RouteAnalysisId}", __extendedEncodeURIComponent(labelValue));
|
|
1063
|
+
}
|
|
1064
|
+
else {
|
|
1065
|
+
throw new Error("No value provided for input HTTP label: RouteAnalysisId.");
|
|
1066
|
+
}
|
|
1067
|
+
return [2, new __HttpRequest({
|
|
1068
|
+
protocol: protocol,
|
|
1069
|
+
hostname: hostname,
|
|
1070
|
+
port: port,
|
|
1071
|
+
method: "GET",
|
|
1072
|
+
headers: headers,
|
|
1073
|
+
path: resolvedPath,
|
|
1074
|
+
body: body,
|
|
1075
|
+
})];
|
|
1076
|
+
}
|
|
1077
|
+
});
|
|
1078
|
+
}); };
|
|
843
1079
|
export var serializeAws_restJson1GetSitesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
844
1080
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, query, body;
|
|
845
1081
|
return __generator(this, function (_c) {
|
|
@@ -1012,6 +1248,49 @@ export var serializeAws_restJson1RegisterTransitGatewayCommand = function (input
|
|
|
1012
1248
|
}
|
|
1013
1249
|
});
|
|
1014
1250
|
}); };
|
|
1251
|
+
export var serializeAws_restJson1StartRouteAnalysisCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1252
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
1253
|
+
return __generator(this, function (_c) {
|
|
1254
|
+
switch (_c.label) {
|
|
1255
|
+
case 0: return [4, context.endpoint()];
|
|
1256
|
+
case 1:
|
|
1257
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
1258
|
+
headers = {
|
|
1259
|
+
"content-type": "application/json",
|
|
1260
|
+
};
|
|
1261
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
1262
|
+
"/global-networks/{GlobalNetworkId}/route-analyses";
|
|
1263
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
1264
|
+
labelValue = input.GlobalNetworkId;
|
|
1265
|
+
if (labelValue.length <= 0) {
|
|
1266
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
1267
|
+
}
|
|
1268
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
1269
|
+
}
|
|
1270
|
+
else {
|
|
1271
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
1272
|
+
}
|
|
1273
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign({}, (input.Destination !== undefined &&
|
|
1274
|
+
input.Destination !== null && {
|
|
1275
|
+
Destination: serializeAws_restJson1RouteAnalysisEndpointOptionsSpecification(input.Destination, context),
|
|
1276
|
+
})), (input.IncludeReturnPath !== undefined &&
|
|
1277
|
+
input.IncludeReturnPath !== null && { IncludeReturnPath: input.IncludeReturnPath })), (input.Source !== undefined &&
|
|
1278
|
+
input.Source !== null && {
|
|
1279
|
+
Source: serializeAws_restJson1RouteAnalysisEndpointOptionsSpecification(input.Source, context),
|
|
1280
|
+
})), (input.UseMiddleboxes !== undefined &&
|
|
1281
|
+
input.UseMiddleboxes !== null && { UseMiddleboxes: input.UseMiddleboxes })));
|
|
1282
|
+
return [2, new __HttpRequest({
|
|
1283
|
+
protocol: protocol,
|
|
1284
|
+
hostname: hostname,
|
|
1285
|
+
port: port,
|
|
1286
|
+
method: "POST",
|
|
1287
|
+
headers: headers,
|
|
1288
|
+
path: resolvedPath,
|
|
1289
|
+
body: body,
|
|
1290
|
+
})];
|
|
1291
|
+
}
|
|
1292
|
+
});
|
|
1293
|
+
}); };
|
|
1015
1294
|
export var serializeAws_restJson1TagResourceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1016
1295
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
1017
1296
|
return __generator(this, function (_c) {
|
|
@@ -1253,7 +1532,7 @@ export var serializeAws_restJson1UpdateLinkCommand = function (input, context) {
|
|
|
1253
1532
|
}
|
|
1254
1533
|
});
|
|
1255
1534
|
}); };
|
|
1256
|
-
export var
|
|
1535
|
+
export var serializeAws_restJson1UpdateNetworkResourceMetadataCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1257
1536
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, labelValue, body;
|
|
1258
1537
|
return __generator(this, function (_c) {
|
|
1259
1538
|
switch (_c.label) {
|
|
@@ -1264,7 +1543,7 @@ export var serializeAws_restJson1UpdateSiteCommand = function (input, context) {
|
|
|
1264
1543
|
"content-type": "application/json",
|
|
1265
1544
|
};
|
|
1266
1545
|
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
1267
|
-
"/global-networks/{GlobalNetworkId}/
|
|
1546
|
+
"/global-networks/{GlobalNetworkId}/network-resources/{ResourceArn}/metadata";
|
|
1268
1547
|
if (input.GlobalNetworkId !== undefined) {
|
|
1269
1548
|
labelValue = input.GlobalNetworkId;
|
|
1270
1549
|
if (labelValue.length <= 0) {
|
|
@@ -1275,18 +1554,20 @@ export var serializeAws_restJson1UpdateSiteCommand = function (input, context) {
|
|
|
1275
1554
|
else {
|
|
1276
1555
|
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
1277
1556
|
}
|
|
1278
|
-
if (input.
|
|
1279
|
-
labelValue = input.
|
|
1557
|
+
if (input.ResourceArn !== undefined) {
|
|
1558
|
+
labelValue = input.ResourceArn;
|
|
1280
1559
|
if (labelValue.length <= 0) {
|
|
1281
|
-
throw new Error("Empty value provided for input HTTP label:
|
|
1560
|
+
throw new Error("Empty value provided for input HTTP label: ResourceArn.");
|
|
1282
1561
|
}
|
|
1283
|
-
resolvedPath = resolvedPath.replace("{
|
|
1562
|
+
resolvedPath = resolvedPath.replace("{ResourceArn}", __extendedEncodeURIComponent(labelValue));
|
|
1284
1563
|
}
|
|
1285
1564
|
else {
|
|
1286
|
-
throw new Error("No value provided for input HTTP label:
|
|
1565
|
+
throw new Error("No value provided for input HTTP label: ResourceArn.");
|
|
1287
1566
|
}
|
|
1288
|
-
body = JSON.stringify(__assign(
|
|
1289
|
-
input.
|
|
1567
|
+
body = JSON.stringify(__assign({}, (input.Metadata !== undefined &&
|
|
1568
|
+
input.Metadata !== null && {
|
|
1569
|
+
Metadata: serializeAws_restJson1NetworkResourceMetadataMap(input.Metadata, context),
|
|
1570
|
+
})));
|
|
1290
1571
|
return [2, new __HttpRequest({
|
|
1291
1572
|
protocol: protocol,
|
|
1292
1573
|
hostname: hostname,
|
|
@@ -1299,24 +1580,70 @@ export var serializeAws_restJson1UpdateSiteCommand = function (input, context) {
|
|
|
1299
1580
|
}
|
|
1300
1581
|
});
|
|
1301
1582
|
}); };
|
|
1302
|
-
export var
|
|
1303
|
-
var
|
|
1583
|
+
export var serializeAws_restJson1UpdateSiteCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1584
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, labelValue, body;
|
|
1304
1585
|
return __generator(this, function (_c) {
|
|
1305
1586
|
switch (_c.label) {
|
|
1306
|
-
case 0:
|
|
1307
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1308
|
-
return [2, deserializeAws_restJson1AssociateCustomerGatewayCommandError(output, context)];
|
|
1309
|
-
}
|
|
1310
|
-
contents = {
|
|
1311
|
-
$metadata: deserializeMetadata(output),
|
|
1312
|
-
CustomerGatewayAssociation: undefined,
|
|
1313
|
-
};
|
|
1314
|
-
_a = __expectNonNull;
|
|
1315
|
-
_b = __expectObject;
|
|
1316
|
-
return [4, parseBody(output.body, context)];
|
|
1587
|
+
case 0: return [4, context.endpoint()];
|
|
1317
1588
|
case 1:
|
|
1318
|
-
|
|
1319
|
-
|
|
1589
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
1590
|
+
headers = {
|
|
1591
|
+
"content-type": "application/json",
|
|
1592
|
+
};
|
|
1593
|
+
resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
1594
|
+
"/global-networks/{GlobalNetworkId}/sites/{SiteId}";
|
|
1595
|
+
if (input.GlobalNetworkId !== undefined) {
|
|
1596
|
+
labelValue = input.GlobalNetworkId;
|
|
1597
|
+
if (labelValue.length <= 0) {
|
|
1598
|
+
throw new Error("Empty value provided for input HTTP label: GlobalNetworkId.");
|
|
1599
|
+
}
|
|
1600
|
+
resolvedPath = resolvedPath.replace("{GlobalNetworkId}", __extendedEncodeURIComponent(labelValue));
|
|
1601
|
+
}
|
|
1602
|
+
else {
|
|
1603
|
+
throw new Error("No value provided for input HTTP label: GlobalNetworkId.");
|
|
1604
|
+
}
|
|
1605
|
+
if (input.SiteId !== undefined) {
|
|
1606
|
+
labelValue = input.SiteId;
|
|
1607
|
+
if (labelValue.length <= 0) {
|
|
1608
|
+
throw new Error("Empty value provided for input HTTP label: SiteId.");
|
|
1609
|
+
}
|
|
1610
|
+
resolvedPath = resolvedPath.replace("{SiteId}", __extendedEncodeURIComponent(labelValue));
|
|
1611
|
+
}
|
|
1612
|
+
else {
|
|
1613
|
+
throw new Error("No value provided for input HTTP label: SiteId.");
|
|
1614
|
+
}
|
|
1615
|
+
body = JSON.stringify(__assign(__assign({}, (input.Description !== undefined && input.Description !== null && { Description: input.Description })), (input.Location !== undefined &&
|
|
1616
|
+
input.Location !== null && { Location: serializeAws_restJson1Location(input.Location, context) })));
|
|
1617
|
+
return [2, new __HttpRequest({
|
|
1618
|
+
protocol: protocol,
|
|
1619
|
+
hostname: hostname,
|
|
1620
|
+
port: port,
|
|
1621
|
+
method: "PATCH",
|
|
1622
|
+
headers: headers,
|
|
1623
|
+
path: resolvedPath,
|
|
1624
|
+
body: body,
|
|
1625
|
+
})];
|
|
1626
|
+
}
|
|
1627
|
+
});
|
|
1628
|
+
}); };
|
|
1629
|
+
export var deserializeAws_restJson1AssociateCustomerGatewayCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1630
|
+
var contents, data, _a, _b;
|
|
1631
|
+
return __generator(this, function (_c) {
|
|
1632
|
+
switch (_c.label) {
|
|
1633
|
+
case 0:
|
|
1634
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1635
|
+
return [2, deserializeAws_restJson1AssociateCustomerGatewayCommandError(output, context)];
|
|
1636
|
+
}
|
|
1637
|
+
contents = {
|
|
1638
|
+
$metadata: deserializeMetadata(output),
|
|
1639
|
+
CustomerGatewayAssociation: undefined,
|
|
1640
|
+
};
|
|
1641
|
+
_a = __expectNonNull;
|
|
1642
|
+
_b = __expectObject;
|
|
1643
|
+
return [4, parseBody(output.body, context)];
|
|
1644
|
+
case 1:
|
|
1645
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1646
|
+
if (data.CustomerGatewayAssociation !== undefined && data.CustomerGatewayAssociation !== null) {
|
|
1320
1647
|
contents.CustomerGatewayAssociation = deserializeAws_restJson1CustomerGatewayAssociation(data.CustomerGatewayAssociation, context);
|
|
1321
1648
|
}
|
|
1322
1649
|
return [2, Promise.resolve(contents)];
|
|
@@ -3108,70 +3435,658 @@ var deserializeAws_restJson1DisassociateTransitGatewayConnectPeerCommandError =
|
|
|
3108
3435
|
switch (_k.label) {
|
|
3109
3436
|
case 0:
|
|
3110
3437
|
_a = [__assign({}, output)];
|
|
3111
|
-
_j = {};
|
|
3438
|
+
_j = {};
|
|
3439
|
+
return [4, parseBody(output.body, context)];
|
|
3440
|
+
case 1:
|
|
3441
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_j.body = _k.sent(), _j)]));
|
|
3442
|
+
errorCode = "UnknownError";
|
|
3443
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3444
|
+
_b = errorCode;
|
|
3445
|
+
switch (_b) {
|
|
3446
|
+
case "AccessDeniedException": return [3, 2];
|
|
3447
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3448
|
+
case "ConflictException": return [3, 4];
|
|
3449
|
+
case "com.amazonaws.networkmanager#ConflictException": return [3, 4];
|
|
3450
|
+
case "InternalServerException": return [3, 6];
|
|
3451
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 6];
|
|
3452
|
+
case "ResourceNotFoundException": return [3, 8];
|
|
3453
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 8];
|
|
3454
|
+
case "ThrottlingException": return [3, 10];
|
|
3455
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 10];
|
|
3456
|
+
case "ValidationException": return [3, 12];
|
|
3457
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 12];
|
|
3458
|
+
}
|
|
3459
|
+
return [3, 14];
|
|
3460
|
+
case 2:
|
|
3461
|
+
_c = [{}];
|
|
3462
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3463
|
+
case 3:
|
|
3464
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3465
|
+
return [3, 15];
|
|
3466
|
+
case 4:
|
|
3467
|
+
_d = [{}];
|
|
3468
|
+
return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
3469
|
+
case 5:
|
|
3470
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3471
|
+
return [3, 15];
|
|
3472
|
+
case 6:
|
|
3473
|
+
_e = [{}];
|
|
3474
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3475
|
+
case 7:
|
|
3476
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3477
|
+
return [3, 15];
|
|
3478
|
+
case 8:
|
|
3479
|
+
_f = [{}];
|
|
3480
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
3481
|
+
case 9:
|
|
3482
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3483
|
+
return [3, 15];
|
|
3484
|
+
case 10:
|
|
3485
|
+
_g = [{}];
|
|
3486
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3487
|
+
case 11:
|
|
3488
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3489
|
+
return [3, 15];
|
|
3490
|
+
case 12:
|
|
3491
|
+
_h = [{}];
|
|
3492
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3493
|
+
case 13:
|
|
3494
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _h.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3495
|
+
return [3, 15];
|
|
3496
|
+
case 14:
|
|
3497
|
+
parsedBody = parsedOutput.body;
|
|
3498
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3499
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3500
|
+
_k.label = 15;
|
|
3501
|
+
case 15:
|
|
3502
|
+
message = response.message || response.Message || errorCode;
|
|
3503
|
+
response.message = message;
|
|
3504
|
+
delete response.Message;
|
|
3505
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
3506
|
+
}
|
|
3507
|
+
});
|
|
3508
|
+
}); };
|
|
3509
|
+
export var deserializeAws_restJson1GetConnectionsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3510
|
+
var contents, data, _a, _b;
|
|
3511
|
+
return __generator(this, function (_c) {
|
|
3512
|
+
switch (_c.label) {
|
|
3513
|
+
case 0:
|
|
3514
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3515
|
+
return [2, deserializeAws_restJson1GetConnectionsCommandError(output, context)];
|
|
3516
|
+
}
|
|
3517
|
+
contents = {
|
|
3518
|
+
$metadata: deserializeMetadata(output),
|
|
3519
|
+
Connections: undefined,
|
|
3520
|
+
NextToken: undefined,
|
|
3521
|
+
};
|
|
3522
|
+
_a = __expectNonNull;
|
|
3523
|
+
_b = __expectObject;
|
|
3524
|
+
return [4, parseBody(output.body, context)];
|
|
3525
|
+
case 1:
|
|
3526
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3527
|
+
if (data.Connections !== undefined && data.Connections !== null) {
|
|
3528
|
+
contents.Connections = deserializeAws_restJson1ConnectionList(data.Connections, context);
|
|
3529
|
+
}
|
|
3530
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3531
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
3532
|
+
}
|
|
3533
|
+
return [2, Promise.resolve(contents)];
|
|
3534
|
+
}
|
|
3535
|
+
});
|
|
3536
|
+
}); };
|
|
3537
|
+
var deserializeAws_restJson1GetConnectionsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3538
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3539
|
+
var _h;
|
|
3540
|
+
return __generator(this, function (_j) {
|
|
3541
|
+
switch (_j.label) {
|
|
3542
|
+
case 0:
|
|
3543
|
+
_a = [__assign({}, output)];
|
|
3544
|
+
_h = {};
|
|
3545
|
+
return [4, parseBody(output.body, context)];
|
|
3546
|
+
case 1:
|
|
3547
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_h.body = _j.sent(), _h)]));
|
|
3548
|
+
errorCode = "UnknownError";
|
|
3549
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3550
|
+
_b = errorCode;
|
|
3551
|
+
switch (_b) {
|
|
3552
|
+
case "AccessDeniedException": return [3, 2];
|
|
3553
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3554
|
+
case "InternalServerException": return [3, 4];
|
|
3555
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 4];
|
|
3556
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
3557
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 6];
|
|
3558
|
+
case "ThrottlingException": return [3, 8];
|
|
3559
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 8];
|
|
3560
|
+
case "ValidationException": return [3, 10];
|
|
3561
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 10];
|
|
3562
|
+
}
|
|
3563
|
+
return [3, 12];
|
|
3564
|
+
case 2:
|
|
3565
|
+
_c = [{}];
|
|
3566
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3567
|
+
case 3:
|
|
3568
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3569
|
+
return [3, 13];
|
|
3570
|
+
case 4:
|
|
3571
|
+
_d = [{}];
|
|
3572
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3573
|
+
case 5:
|
|
3574
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3575
|
+
return [3, 13];
|
|
3576
|
+
case 6:
|
|
3577
|
+
_e = [{}];
|
|
3578
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
3579
|
+
case 7:
|
|
3580
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3581
|
+
return [3, 13];
|
|
3582
|
+
case 8:
|
|
3583
|
+
_f = [{}];
|
|
3584
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3585
|
+
case 9:
|
|
3586
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3587
|
+
return [3, 13];
|
|
3588
|
+
case 10:
|
|
3589
|
+
_g = [{}];
|
|
3590
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3591
|
+
case 11:
|
|
3592
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3593
|
+
return [3, 13];
|
|
3594
|
+
case 12:
|
|
3595
|
+
parsedBody = parsedOutput.body;
|
|
3596
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3597
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3598
|
+
_j.label = 13;
|
|
3599
|
+
case 13:
|
|
3600
|
+
message = response.message || response.Message || errorCode;
|
|
3601
|
+
response.message = message;
|
|
3602
|
+
delete response.Message;
|
|
3603
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
3604
|
+
}
|
|
3605
|
+
});
|
|
3606
|
+
}); };
|
|
3607
|
+
export var deserializeAws_restJson1GetCustomerGatewayAssociationsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3608
|
+
var contents, data, _a, _b;
|
|
3609
|
+
return __generator(this, function (_c) {
|
|
3610
|
+
switch (_c.label) {
|
|
3611
|
+
case 0:
|
|
3612
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3613
|
+
return [2, deserializeAws_restJson1GetCustomerGatewayAssociationsCommandError(output, context)];
|
|
3614
|
+
}
|
|
3615
|
+
contents = {
|
|
3616
|
+
$metadata: deserializeMetadata(output),
|
|
3617
|
+
CustomerGatewayAssociations: undefined,
|
|
3618
|
+
NextToken: undefined,
|
|
3619
|
+
};
|
|
3620
|
+
_a = __expectNonNull;
|
|
3621
|
+
_b = __expectObject;
|
|
3622
|
+
return [4, parseBody(output.body, context)];
|
|
3623
|
+
case 1:
|
|
3624
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3625
|
+
if (data.CustomerGatewayAssociations !== undefined && data.CustomerGatewayAssociations !== null) {
|
|
3626
|
+
contents.CustomerGatewayAssociations = deserializeAws_restJson1CustomerGatewayAssociationList(data.CustomerGatewayAssociations, context);
|
|
3627
|
+
}
|
|
3628
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3629
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
3630
|
+
}
|
|
3631
|
+
return [2, Promise.resolve(contents)];
|
|
3632
|
+
}
|
|
3633
|
+
});
|
|
3634
|
+
}); };
|
|
3635
|
+
var deserializeAws_restJson1GetCustomerGatewayAssociationsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3636
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, _h, parsedBody, message;
|
|
3637
|
+
var _j;
|
|
3638
|
+
return __generator(this, function (_k) {
|
|
3639
|
+
switch (_k.label) {
|
|
3640
|
+
case 0:
|
|
3641
|
+
_a = [__assign({}, output)];
|
|
3642
|
+
_j = {};
|
|
3643
|
+
return [4, parseBody(output.body, context)];
|
|
3644
|
+
case 1:
|
|
3645
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_j.body = _k.sent(), _j)]));
|
|
3646
|
+
errorCode = "UnknownError";
|
|
3647
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3648
|
+
_b = errorCode;
|
|
3649
|
+
switch (_b) {
|
|
3650
|
+
case "AccessDeniedException": return [3, 2];
|
|
3651
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3652
|
+
case "ConflictException": return [3, 4];
|
|
3653
|
+
case "com.amazonaws.networkmanager#ConflictException": return [3, 4];
|
|
3654
|
+
case "InternalServerException": return [3, 6];
|
|
3655
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 6];
|
|
3656
|
+
case "ResourceNotFoundException": return [3, 8];
|
|
3657
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 8];
|
|
3658
|
+
case "ThrottlingException": return [3, 10];
|
|
3659
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 10];
|
|
3660
|
+
case "ValidationException": return [3, 12];
|
|
3661
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 12];
|
|
3662
|
+
}
|
|
3663
|
+
return [3, 14];
|
|
3664
|
+
case 2:
|
|
3665
|
+
_c = [{}];
|
|
3666
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3667
|
+
case 3:
|
|
3668
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3669
|
+
return [3, 15];
|
|
3670
|
+
case 4:
|
|
3671
|
+
_d = [{}];
|
|
3672
|
+
return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
3673
|
+
case 5:
|
|
3674
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3675
|
+
return [3, 15];
|
|
3676
|
+
case 6:
|
|
3677
|
+
_e = [{}];
|
|
3678
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3679
|
+
case 7:
|
|
3680
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3681
|
+
return [3, 15];
|
|
3682
|
+
case 8:
|
|
3683
|
+
_f = [{}];
|
|
3684
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
3685
|
+
case 9:
|
|
3686
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3687
|
+
return [3, 15];
|
|
3688
|
+
case 10:
|
|
3689
|
+
_g = [{}];
|
|
3690
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3691
|
+
case 11:
|
|
3692
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3693
|
+
return [3, 15];
|
|
3694
|
+
case 12:
|
|
3695
|
+
_h = [{}];
|
|
3696
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3697
|
+
case 13:
|
|
3698
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _h.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3699
|
+
return [3, 15];
|
|
3700
|
+
case 14:
|
|
3701
|
+
parsedBody = parsedOutput.body;
|
|
3702
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3703
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3704
|
+
_k.label = 15;
|
|
3705
|
+
case 15:
|
|
3706
|
+
message = response.message || response.Message || errorCode;
|
|
3707
|
+
response.message = message;
|
|
3708
|
+
delete response.Message;
|
|
3709
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
3710
|
+
}
|
|
3711
|
+
});
|
|
3712
|
+
}); };
|
|
3713
|
+
export var deserializeAws_restJson1GetDevicesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3714
|
+
var contents, data, _a, _b;
|
|
3715
|
+
return __generator(this, function (_c) {
|
|
3716
|
+
switch (_c.label) {
|
|
3717
|
+
case 0:
|
|
3718
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3719
|
+
return [2, deserializeAws_restJson1GetDevicesCommandError(output, context)];
|
|
3720
|
+
}
|
|
3721
|
+
contents = {
|
|
3722
|
+
$metadata: deserializeMetadata(output),
|
|
3723
|
+
Devices: undefined,
|
|
3724
|
+
NextToken: undefined,
|
|
3725
|
+
};
|
|
3726
|
+
_a = __expectNonNull;
|
|
3727
|
+
_b = __expectObject;
|
|
3728
|
+
return [4, parseBody(output.body, context)];
|
|
3729
|
+
case 1:
|
|
3730
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3731
|
+
if (data.Devices !== undefined && data.Devices !== null) {
|
|
3732
|
+
contents.Devices = deserializeAws_restJson1DeviceList(data.Devices, context);
|
|
3733
|
+
}
|
|
3734
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3735
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
3736
|
+
}
|
|
3737
|
+
return [2, Promise.resolve(contents)];
|
|
3738
|
+
}
|
|
3739
|
+
});
|
|
3740
|
+
}); };
|
|
3741
|
+
var deserializeAws_restJson1GetDevicesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3742
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3743
|
+
var _h;
|
|
3744
|
+
return __generator(this, function (_j) {
|
|
3745
|
+
switch (_j.label) {
|
|
3746
|
+
case 0:
|
|
3747
|
+
_a = [__assign({}, output)];
|
|
3748
|
+
_h = {};
|
|
3749
|
+
return [4, parseBody(output.body, context)];
|
|
3750
|
+
case 1:
|
|
3751
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_h.body = _j.sent(), _h)]));
|
|
3752
|
+
errorCode = "UnknownError";
|
|
3753
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3754
|
+
_b = errorCode;
|
|
3755
|
+
switch (_b) {
|
|
3756
|
+
case "AccessDeniedException": return [3, 2];
|
|
3757
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3758
|
+
case "InternalServerException": return [3, 4];
|
|
3759
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 4];
|
|
3760
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
3761
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 6];
|
|
3762
|
+
case "ThrottlingException": return [3, 8];
|
|
3763
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 8];
|
|
3764
|
+
case "ValidationException": return [3, 10];
|
|
3765
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 10];
|
|
3766
|
+
}
|
|
3767
|
+
return [3, 12];
|
|
3768
|
+
case 2:
|
|
3769
|
+
_c = [{}];
|
|
3770
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3771
|
+
case 3:
|
|
3772
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3773
|
+
return [3, 13];
|
|
3774
|
+
case 4:
|
|
3775
|
+
_d = [{}];
|
|
3776
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3777
|
+
case 5:
|
|
3778
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3779
|
+
return [3, 13];
|
|
3780
|
+
case 6:
|
|
3781
|
+
_e = [{}];
|
|
3782
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
3783
|
+
case 7:
|
|
3784
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3785
|
+
return [3, 13];
|
|
3786
|
+
case 8:
|
|
3787
|
+
_f = [{}];
|
|
3788
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3789
|
+
case 9:
|
|
3790
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3791
|
+
return [3, 13];
|
|
3792
|
+
case 10:
|
|
3793
|
+
_g = [{}];
|
|
3794
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3795
|
+
case 11:
|
|
3796
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3797
|
+
return [3, 13];
|
|
3798
|
+
case 12:
|
|
3799
|
+
parsedBody = parsedOutput.body;
|
|
3800
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3801
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3802
|
+
_j.label = 13;
|
|
3803
|
+
case 13:
|
|
3804
|
+
message = response.message || response.Message || errorCode;
|
|
3805
|
+
response.message = message;
|
|
3806
|
+
delete response.Message;
|
|
3807
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
3808
|
+
}
|
|
3809
|
+
});
|
|
3810
|
+
}); };
|
|
3811
|
+
export var deserializeAws_restJson1GetLinkAssociationsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3812
|
+
var contents, data, _a, _b;
|
|
3813
|
+
return __generator(this, function (_c) {
|
|
3814
|
+
switch (_c.label) {
|
|
3815
|
+
case 0:
|
|
3816
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3817
|
+
return [2, deserializeAws_restJson1GetLinkAssociationsCommandError(output, context)];
|
|
3818
|
+
}
|
|
3819
|
+
contents = {
|
|
3820
|
+
$metadata: deserializeMetadata(output),
|
|
3821
|
+
LinkAssociations: undefined,
|
|
3822
|
+
NextToken: undefined,
|
|
3823
|
+
};
|
|
3824
|
+
_a = __expectNonNull;
|
|
3825
|
+
_b = __expectObject;
|
|
3826
|
+
return [4, parseBody(output.body, context)];
|
|
3827
|
+
case 1:
|
|
3828
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3829
|
+
if (data.LinkAssociations !== undefined && data.LinkAssociations !== null) {
|
|
3830
|
+
contents.LinkAssociations = deserializeAws_restJson1LinkAssociationList(data.LinkAssociations, context);
|
|
3831
|
+
}
|
|
3832
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3833
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
3834
|
+
}
|
|
3835
|
+
return [2, Promise.resolve(contents)];
|
|
3836
|
+
}
|
|
3837
|
+
});
|
|
3838
|
+
}); };
|
|
3839
|
+
var deserializeAws_restJson1GetLinkAssociationsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3840
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3841
|
+
var _h;
|
|
3842
|
+
return __generator(this, function (_j) {
|
|
3843
|
+
switch (_j.label) {
|
|
3844
|
+
case 0:
|
|
3845
|
+
_a = [__assign({}, output)];
|
|
3846
|
+
_h = {};
|
|
3847
|
+
return [4, parseBody(output.body, context)];
|
|
3848
|
+
case 1:
|
|
3849
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_h.body = _j.sent(), _h)]));
|
|
3850
|
+
errorCode = "UnknownError";
|
|
3851
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3852
|
+
_b = errorCode;
|
|
3853
|
+
switch (_b) {
|
|
3854
|
+
case "AccessDeniedException": return [3, 2];
|
|
3855
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3856
|
+
case "InternalServerException": return [3, 4];
|
|
3857
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 4];
|
|
3858
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
3859
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 6];
|
|
3860
|
+
case "ThrottlingException": return [3, 8];
|
|
3861
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 8];
|
|
3862
|
+
case "ValidationException": return [3, 10];
|
|
3863
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 10];
|
|
3864
|
+
}
|
|
3865
|
+
return [3, 12];
|
|
3866
|
+
case 2:
|
|
3867
|
+
_c = [{}];
|
|
3868
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3869
|
+
case 3:
|
|
3870
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3871
|
+
return [3, 13];
|
|
3872
|
+
case 4:
|
|
3873
|
+
_d = [{}];
|
|
3874
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3875
|
+
case 5:
|
|
3876
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3877
|
+
return [3, 13];
|
|
3878
|
+
case 6:
|
|
3879
|
+
_e = [{}];
|
|
3880
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
3881
|
+
case 7:
|
|
3882
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3883
|
+
return [3, 13];
|
|
3884
|
+
case 8:
|
|
3885
|
+
_f = [{}];
|
|
3886
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3887
|
+
case 9:
|
|
3888
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3889
|
+
return [3, 13];
|
|
3890
|
+
case 10:
|
|
3891
|
+
_g = [{}];
|
|
3892
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3893
|
+
case 11:
|
|
3894
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3895
|
+
return [3, 13];
|
|
3896
|
+
case 12:
|
|
3897
|
+
parsedBody = parsedOutput.body;
|
|
3898
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3899
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3900
|
+
_j.label = 13;
|
|
3901
|
+
case 13:
|
|
3902
|
+
message = response.message || response.Message || errorCode;
|
|
3903
|
+
response.message = message;
|
|
3904
|
+
delete response.Message;
|
|
3905
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
3906
|
+
}
|
|
3907
|
+
});
|
|
3908
|
+
}); };
|
|
3909
|
+
export var deserializeAws_restJson1GetLinksCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3910
|
+
var contents, data, _a, _b;
|
|
3911
|
+
return __generator(this, function (_c) {
|
|
3912
|
+
switch (_c.label) {
|
|
3913
|
+
case 0:
|
|
3914
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3915
|
+
return [2, deserializeAws_restJson1GetLinksCommandError(output, context)];
|
|
3916
|
+
}
|
|
3917
|
+
contents = {
|
|
3918
|
+
$metadata: deserializeMetadata(output),
|
|
3919
|
+
Links: undefined,
|
|
3920
|
+
NextToken: undefined,
|
|
3921
|
+
};
|
|
3922
|
+
_a = __expectNonNull;
|
|
3923
|
+
_b = __expectObject;
|
|
3924
|
+
return [4, parseBody(output.body, context)];
|
|
3925
|
+
case 1:
|
|
3926
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3927
|
+
if (data.Links !== undefined && data.Links !== null) {
|
|
3928
|
+
contents.Links = deserializeAws_restJson1LinkList(data.Links, context);
|
|
3929
|
+
}
|
|
3930
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3931
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
3932
|
+
}
|
|
3933
|
+
return [2, Promise.resolve(contents)];
|
|
3934
|
+
}
|
|
3935
|
+
});
|
|
3936
|
+
}); };
|
|
3937
|
+
var deserializeAws_restJson1GetLinksCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3938
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3939
|
+
var _h;
|
|
3940
|
+
return __generator(this, function (_j) {
|
|
3941
|
+
switch (_j.label) {
|
|
3942
|
+
case 0:
|
|
3943
|
+
_a = [__assign({}, output)];
|
|
3944
|
+
_h = {};
|
|
3945
|
+
return [4, parseBody(output.body, context)];
|
|
3946
|
+
case 1:
|
|
3947
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_h.body = _j.sent(), _h)]));
|
|
3948
|
+
errorCode = "UnknownError";
|
|
3949
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3950
|
+
_b = errorCode;
|
|
3951
|
+
switch (_b) {
|
|
3952
|
+
case "AccessDeniedException": return [3, 2];
|
|
3953
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3954
|
+
case "InternalServerException": return [3, 4];
|
|
3955
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 4];
|
|
3956
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
3957
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 6];
|
|
3958
|
+
case "ThrottlingException": return [3, 8];
|
|
3959
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 8];
|
|
3960
|
+
case "ValidationException": return [3, 10];
|
|
3961
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 10];
|
|
3962
|
+
}
|
|
3963
|
+
return [3, 12];
|
|
3964
|
+
case 2:
|
|
3965
|
+
_c = [{}];
|
|
3966
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3967
|
+
case 3:
|
|
3968
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3969
|
+
return [3, 13];
|
|
3970
|
+
case 4:
|
|
3971
|
+
_d = [{}];
|
|
3972
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3973
|
+
case 5:
|
|
3974
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3975
|
+
return [3, 13];
|
|
3976
|
+
case 6:
|
|
3977
|
+
_e = [{}];
|
|
3978
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
3979
|
+
case 7:
|
|
3980
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3981
|
+
return [3, 13];
|
|
3982
|
+
case 8:
|
|
3983
|
+
_f = [{}];
|
|
3984
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3985
|
+
case 9:
|
|
3986
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3987
|
+
return [3, 13];
|
|
3988
|
+
case 10:
|
|
3989
|
+
_g = [{}];
|
|
3990
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3991
|
+
case 11:
|
|
3992
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3993
|
+
return [3, 13];
|
|
3994
|
+
case 12:
|
|
3995
|
+
parsedBody = parsedOutput.body;
|
|
3996
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3997
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3998
|
+
_j.label = 13;
|
|
3999
|
+
case 13:
|
|
4000
|
+
message = response.message || response.Message || errorCode;
|
|
4001
|
+
response.message = message;
|
|
4002
|
+
delete response.Message;
|
|
4003
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
4004
|
+
}
|
|
4005
|
+
});
|
|
4006
|
+
}); };
|
|
4007
|
+
export var deserializeAws_restJson1GetNetworkResourceCountsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4008
|
+
var contents, data, _a, _b;
|
|
4009
|
+
return __generator(this, function (_c) {
|
|
4010
|
+
switch (_c.label) {
|
|
4011
|
+
case 0:
|
|
4012
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
4013
|
+
return [2, deserializeAws_restJson1GetNetworkResourceCountsCommandError(output, context)];
|
|
4014
|
+
}
|
|
4015
|
+
contents = {
|
|
4016
|
+
$metadata: deserializeMetadata(output),
|
|
4017
|
+
NetworkResourceCounts: undefined,
|
|
4018
|
+
NextToken: undefined,
|
|
4019
|
+
};
|
|
4020
|
+
_a = __expectNonNull;
|
|
4021
|
+
_b = __expectObject;
|
|
4022
|
+
return [4, parseBody(output.body, context)];
|
|
4023
|
+
case 1:
|
|
4024
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
4025
|
+
if (data.NetworkResourceCounts !== undefined && data.NetworkResourceCounts !== null) {
|
|
4026
|
+
contents.NetworkResourceCounts = deserializeAws_restJson1NetworkResourceCountList(data.NetworkResourceCounts, context);
|
|
4027
|
+
}
|
|
4028
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
4029
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
4030
|
+
}
|
|
4031
|
+
return [2, Promise.resolve(contents)];
|
|
4032
|
+
}
|
|
4033
|
+
});
|
|
4034
|
+
}); };
|
|
4035
|
+
var deserializeAws_restJson1GetNetworkResourceCountsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4036
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, parsedBody, message;
|
|
4037
|
+
var _g;
|
|
4038
|
+
return __generator(this, function (_h) {
|
|
4039
|
+
switch (_h.label) {
|
|
4040
|
+
case 0:
|
|
4041
|
+
_a = [__assign({}, output)];
|
|
4042
|
+
_g = {};
|
|
3112
4043
|
return [4, parseBody(output.body, context)];
|
|
3113
4044
|
case 1:
|
|
3114
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(
|
|
4045
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_g.body = _h.sent(), _g)]));
|
|
3115
4046
|
errorCode = "UnknownError";
|
|
3116
4047
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3117
4048
|
_b = errorCode;
|
|
3118
4049
|
switch (_b) {
|
|
3119
4050
|
case "AccessDeniedException": return [3, 2];
|
|
3120
4051
|
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3121
|
-
case "
|
|
3122
|
-
case "com.amazonaws.networkmanager#
|
|
3123
|
-
case "
|
|
3124
|
-
case "com.amazonaws.networkmanager#
|
|
3125
|
-
case "
|
|
3126
|
-
case "com.amazonaws.networkmanager#
|
|
3127
|
-
case "ThrottlingException": return [3, 10];
|
|
3128
|
-
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 10];
|
|
3129
|
-
case "ValidationException": return [3, 12];
|
|
3130
|
-
case "com.amazonaws.networkmanager#ValidationException": return [3, 12];
|
|
4052
|
+
case "InternalServerException": return [3, 4];
|
|
4053
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 4];
|
|
4054
|
+
case "ThrottlingException": return [3, 6];
|
|
4055
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 6];
|
|
4056
|
+
case "ValidationException": return [3, 8];
|
|
4057
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 8];
|
|
3131
4058
|
}
|
|
3132
|
-
return [3,
|
|
4059
|
+
return [3, 10];
|
|
3133
4060
|
case 2:
|
|
3134
4061
|
_c = [{}];
|
|
3135
4062
|
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3136
4063
|
case 3:
|
|
3137
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(
|
|
3138
|
-
return [3,
|
|
4064
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4065
|
+
return [3, 11];
|
|
3139
4066
|
case 4:
|
|
3140
4067
|
_d = [{}];
|
|
3141
|
-
return [4,
|
|
4068
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3142
4069
|
case 5:
|
|
3143
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(
|
|
3144
|
-
return [3,
|
|
4070
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4071
|
+
return [3, 11];
|
|
3145
4072
|
case 6:
|
|
3146
4073
|
_e = [{}];
|
|
3147
|
-
return [4,
|
|
4074
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3148
4075
|
case 7:
|
|
3149
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(
|
|
3150
|
-
return [3,
|
|
4076
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4077
|
+
return [3, 11];
|
|
3151
4078
|
case 8:
|
|
3152
4079
|
_f = [{}];
|
|
3153
|
-
return [4,
|
|
4080
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3154
4081
|
case 9:
|
|
3155
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(
|
|
3156
|
-
return [3,
|
|
4082
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4083
|
+
return [3, 11];
|
|
3157
4084
|
case 10:
|
|
3158
|
-
_g = [{}];
|
|
3159
|
-
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3160
|
-
case 11:
|
|
3161
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3162
|
-
return [3, 15];
|
|
3163
|
-
case 12:
|
|
3164
|
-
_h = [{}];
|
|
3165
|
-
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3166
|
-
case 13:
|
|
3167
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _h.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3168
|
-
return [3, 15];
|
|
3169
|
-
case 14:
|
|
3170
4085
|
parsedBody = parsedOutput.body;
|
|
3171
4086
|
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3172
4087
|
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3173
|
-
|
|
3174
|
-
case
|
|
4088
|
+
_h.label = 11;
|
|
4089
|
+
case 11:
|
|
3175
4090
|
message = response.message || response.Message || errorCode;
|
|
3176
4091
|
response.message = message;
|
|
3177
4092
|
delete response.Message;
|
|
@@ -3179,35 +4094,35 @@ var deserializeAws_restJson1DisassociateTransitGatewayConnectPeerCommandError =
|
|
|
3179
4094
|
}
|
|
3180
4095
|
});
|
|
3181
4096
|
}); };
|
|
3182
|
-
export var
|
|
4097
|
+
export var deserializeAws_restJson1GetNetworkResourceRelationshipsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3183
4098
|
var contents, data, _a, _b;
|
|
3184
4099
|
return __generator(this, function (_c) {
|
|
3185
4100
|
switch (_c.label) {
|
|
3186
4101
|
case 0:
|
|
3187
4102
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3188
|
-
return [2,
|
|
4103
|
+
return [2, deserializeAws_restJson1GetNetworkResourceRelationshipsCommandError(output, context)];
|
|
3189
4104
|
}
|
|
3190
4105
|
contents = {
|
|
3191
4106
|
$metadata: deserializeMetadata(output),
|
|
3192
|
-
Connections: undefined,
|
|
3193
4107
|
NextToken: undefined,
|
|
4108
|
+
Relationships: undefined,
|
|
3194
4109
|
};
|
|
3195
4110
|
_a = __expectNonNull;
|
|
3196
4111
|
_b = __expectObject;
|
|
3197
4112
|
return [4, parseBody(output.body, context)];
|
|
3198
4113
|
case 1:
|
|
3199
4114
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3200
|
-
if (data.Connections !== undefined && data.Connections !== null) {
|
|
3201
|
-
contents.Connections = deserializeAws_restJson1ConnectionList(data.Connections, context);
|
|
3202
|
-
}
|
|
3203
4115
|
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3204
4116
|
contents.NextToken = __expectString(data.NextToken);
|
|
3205
4117
|
}
|
|
4118
|
+
if (data.Relationships !== undefined && data.Relationships !== null) {
|
|
4119
|
+
contents.Relationships = deserializeAws_restJson1RelationshipList(data.Relationships, context);
|
|
4120
|
+
}
|
|
3206
4121
|
return [2, Promise.resolve(contents)];
|
|
3207
4122
|
}
|
|
3208
4123
|
});
|
|
3209
4124
|
}); };
|
|
3210
|
-
var
|
|
4125
|
+
var deserializeAws_restJson1GetNetworkResourceRelationshipsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3211
4126
|
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3212
4127
|
var _h;
|
|
3213
4128
|
return __generator(this, function (_j) {
|
|
@@ -3277,17 +4192,17 @@ var deserializeAws_restJson1GetConnectionsCommandError = function (output, conte
|
|
|
3277
4192
|
}
|
|
3278
4193
|
});
|
|
3279
4194
|
}); };
|
|
3280
|
-
export var
|
|
4195
|
+
export var deserializeAws_restJson1GetNetworkResourcesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3281
4196
|
var contents, data, _a, _b;
|
|
3282
4197
|
return __generator(this, function (_c) {
|
|
3283
4198
|
switch (_c.label) {
|
|
3284
4199
|
case 0:
|
|
3285
4200
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3286
|
-
return [2,
|
|
4201
|
+
return [2, deserializeAws_restJson1GetNetworkResourcesCommandError(output, context)];
|
|
3287
4202
|
}
|
|
3288
4203
|
contents = {
|
|
3289
4204
|
$metadata: deserializeMetadata(output),
|
|
3290
|
-
|
|
4205
|
+
NetworkResources: undefined,
|
|
3291
4206
|
NextToken: undefined,
|
|
3292
4207
|
};
|
|
3293
4208
|
_a = __expectNonNull;
|
|
@@ -3295,8 +4210,8 @@ export var deserializeAws_restJson1GetCustomerGatewayAssociationsCommand = funct
|
|
|
3295
4210
|
return [4, parseBody(output.body, context)];
|
|
3296
4211
|
case 1:
|
|
3297
4212
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3298
|
-
if (data.
|
|
3299
|
-
contents.
|
|
4213
|
+
if (data.NetworkResources !== undefined && data.NetworkResources !== null) {
|
|
4214
|
+
contents.NetworkResources = deserializeAws_restJson1NetworkResourceList(data.NetworkResources, context);
|
|
3300
4215
|
}
|
|
3301
4216
|
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3302
4217
|
contents.NextToken = __expectString(data.NextToken);
|
|
@@ -3305,77 +4220,69 @@ export var deserializeAws_restJson1GetCustomerGatewayAssociationsCommand = funct
|
|
|
3305
4220
|
}
|
|
3306
4221
|
});
|
|
3307
4222
|
}); };
|
|
3308
|
-
var
|
|
3309
|
-
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g,
|
|
3310
|
-
var
|
|
3311
|
-
return __generator(this, function (
|
|
3312
|
-
switch (
|
|
4223
|
+
var deserializeAws_restJson1GetNetworkResourcesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4224
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
4225
|
+
var _h;
|
|
4226
|
+
return __generator(this, function (_j) {
|
|
4227
|
+
switch (_j.label) {
|
|
3313
4228
|
case 0:
|
|
3314
4229
|
_a = [__assign({}, output)];
|
|
3315
|
-
|
|
4230
|
+
_h = {};
|
|
3316
4231
|
return [4, parseBody(output.body, context)];
|
|
3317
4232
|
case 1:
|
|
3318
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(
|
|
4233
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_h.body = _j.sent(), _h)]));
|
|
3319
4234
|
errorCode = "UnknownError";
|
|
3320
4235
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3321
4236
|
_b = errorCode;
|
|
3322
4237
|
switch (_b) {
|
|
3323
4238
|
case "AccessDeniedException": return [3, 2];
|
|
3324
4239
|
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
3325
|
-
case "
|
|
3326
|
-
case "com.amazonaws.networkmanager#
|
|
3327
|
-
case "
|
|
3328
|
-
case "com.amazonaws.networkmanager#
|
|
3329
|
-
case "
|
|
3330
|
-
case "com.amazonaws.networkmanager#
|
|
3331
|
-
case "
|
|
3332
|
-
case "com.amazonaws.networkmanager#
|
|
3333
|
-
case "ValidationException": return [3, 12];
|
|
3334
|
-
case "com.amazonaws.networkmanager#ValidationException": return [3, 12];
|
|
4240
|
+
case "InternalServerException": return [3, 4];
|
|
4241
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 4];
|
|
4242
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
4243
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 6];
|
|
4244
|
+
case "ThrottlingException": return [3, 8];
|
|
4245
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 8];
|
|
4246
|
+
case "ValidationException": return [3, 10];
|
|
4247
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 10];
|
|
3335
4248
|
}
|
|
3336
|
-
return [3,
|
|
4249
|
+
return [3, 12];
|
|
3337
4250
|
case 2:
|
|
3338
4251
|
_c = [{}];
|
|
3339
4252
|
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
3340
4253
|
case 3:
|
|
3341
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(
|
|
3342
|
-
return [3,
|
|
4254
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4255
|
+
return [3, 13];
|
|
3343
4256
|
case 4:
|
|
3344
4257
|
_d = [{}];
|
|
3345
|
-
return [4,
|
|
4258
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
3346
4259
|
case 5:
|
|
3347
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(
|
|
3348
|
-
return [3,
|
|
4260
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4261
|
+
return [3, 13];
|
|
3349
4262
|
case 6:
|
|
3350
4263
|
_e = [{}];
|
|
3351
|
-
return [4,
|
|
4264
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
3352
4265
|
case 7:
|
|
3353
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(
|
|
3354
|
-
return [3,
|
|
4266
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4267
|
+
return [3, 13];
|
|
3355
4268
|
case 8:
|
|
3356
4269
|
_f = [{}];
|
|
3357
|
-
return [4,
|
|
4270
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
3358
4271
|
case 9:
|
|
3359
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(
|
|
3360
|
-
return [3,
|
|
4272
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4273
|
+
return [3, 13];
|
|
3361
4274
|
case 10:
|
|
3362
4275
|
_g = [{}];
|
|
3363
|
-
return [4,
|
|
4276
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3364
4277
|
case 11:
|
|
3365
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(
|
|
3366
|
-
return [3,
|
|
4278
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
4279
|
+
return [3, 13];
|
|
3367
4280
|
case 12:
|
|
3368
|
-
_h = [{}];
|
|
3369
|
-
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
3370
|
-
case 13:
|
|
3371
|
-
response = __assign.apply(void 0, [__assign.apply(void 0, _h.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
3372
|
-
return [3, 15];
|
|
3373
|
-
case 14:
|
|
3374
4281
|
parsedBody = parsedOutput.body;
|
|
3375
4282
|
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3376
4283
|
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
3377
|
-
|
|
3378
|
-
case
|
|
4284
|
+
_j.label = 13;
|
|
4285
|
+
case 13:
|
|
3379
4286
|
message = response.message || response.Message || errorCode;
|
|
3380
4287
|
response.message = message;
|
|
3381
4288
|
delete response.Message;
|
|
@@ -3383,35 +4290,43 @@ var deserializeAws_restJson1GetCustomerGatewayAssociationsCommandError = functio
|
|
|
3383
4290
|
}
|
|
3384
4291
|
});
|
|
3385
4292
|
}); };
|
|
3386
|
-
export var
|
|
4293
|
+
export var deserializeAws_restJson1GetNetworkRoutesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3387
4294
|
var contents, data, _a, _b;
|
|
3388
4295
|
return __generator(this, function (_c) {
|
|
3389
4296
|
switch (_c.label) {
|
|
3390
4297
|
case 0:
|
|
3391
4298
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3392
|
-
return [2,
|
|
4299
|
+
return [2, deserializeAws_restJson1GetNetworkRoutesCommandError(output, context)];
|
|
3393
4300
|
}
|
|
3394
4301
|
contents = {
|
|
3395
4302
|
$metadata: deserializeMetadata(output),
|
|
3396
|
-
|
|
3397
|
-
|
|
4303
|
+
NetworkRoutes: undefined,
|
|
4304
|
+
RouteTableArn: undefined,
|
|
4305
|
+
RouteTableTimestamp: undefined,
|
|
4306
|
+
RouteTableType: undefined,
|
|
3398
4307
|
};
|
|
3399
4308
|
_a = __expectNonNull;
|
|
3400
4309
|
_b = __expectObject;
|
|
3401
4310
|
return [4, parseBody(output.body, context)];
|
|
3402
4311
|
case 1:
|
|
3403
4312
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3404
|
-
if (data.
|
|
3405
|
-
contents.
|
|
4313
|
+
if (data.NetworkRoutes !== undefined && data.NetworkRoutes !== null) {
|
|
4314
|
+
contents.NetworkRoutes = deserializeAws_restJson1NetworkRouteList(data.NetworkRoutes, context);
|
|
3406
4315
|
}
|
|
3407
|
-
if (data.
|
|
3408
|
-
contents.
|
|
4316
|
+
if (data.RouteTableArn !== undefined && data.RouteTableArn !== null) {
|
|
4317
|
+
contents.RouteTableArn = __expectString(data.RouteTableArn);
|
|
4318
|
+
}
|
|
4319
|
+
if (data.RouteTableTimestamp !== undefined && data.RouteTableTimestamp !== null) {
|
|
4320
|
+
contents.RouteTableTimestamp = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.RouteTableTimestamp)));
|
|
4321
|
+
}
|
|
4322
|
+
if (data.RouteTableType !== undefined && data.RouteTableType !== null) {
|
|
4323
|
+
contents.RouteTableType = __expectString(data.RouteTableType);
|
|
3409
4324
|
}
|
|
3410
4325
|
return [2, Promise.resolve(contents)];
|
|
3411
4326
|
}
|
|
3412
4327
|
});
|
|
3413
4328
|
}); };
|
|
3414
|
-
var
|
|
4329
|
+
var deserializeAws_restJson1GetNetworkRoutesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3415
4330
|
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3416
4331
|
var _h;
|
|
3417
4332
|
return __generator(this, function (_j) {
|
|
@@ -3481,17 +4396,17 @@ var deserializeAws_restJson1GetDevicesCommandError = function (output, context)
|
|
|
3481
4396
|
}
|
|
3482
4397
|
});
|
|
3483
4398
|
}); };
|
|
3484
|
-
export var
|
|
4399
|
+
export var deserializeAws_restJson1GetNetworkTelemetryCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3485
4400
|
var contents, data, _a, _b;
|
|
3486
4401
|
return __generator(this, function (_c) {
|
|
3487
4402
|
switch (_c.label) {
|
|
3488
4403
|
case 0:
|
|
3489
4404
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3490
|
-
return [2,
|
|
4405
|
+
return [2, deserializeAws_restJson1GetNetworkTelemetryCommandError(output, context)];
|
|
3491
4406
|
}
|
|
3492
4407
|
contents = {
|
|
3493
4408
|
$metadata: deserializeMetadata(output),
|
|
3494
|
-
|
|
4409
|
+
NetworkTelemetry: undefined,
|
|
3495
4410
|
NextToken: undefined,
|
|
3496
4411
|
};
|
|
3497
4412
|
_a = __expectNonNull;
|
|
@@ -3499,8 +4414,8 @@ export var deserializeAws_restJson1GetLinkAssociationsCommand = function (output
|
|
|
3499
4414
|
return [4, parseBody(output.body, context)];
|
|
3500
4415
|
case 1:
|
|
3501
4416
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3502
|
-
if (data.
|
|
3503
|
-
contents.
|
|
4417
|
+
if (data.NetworkTelemetry !== undefined && data.NetworkTelemetry !== null) {
|
|
4418
|
+
contents.NetworkTelemetry = deserializeAws_restJson1NetworkTelemetryList(data.NetworkTelemetry, context);
|
|
3504
4419
|
}
|
|
3505
4420
|
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3506
4421
|
contents.NextToken = __expectString(data.NextToken);
|
|
@@ -3509,7 +4424,7 @@ export var deserializeAws_restJson1GetLinkAssociationsCommand = function (output
|
|
|
3509
4424
|
}
|
|
3510
4425
|
});
|
|
3511
4426
|
}); };
|
|
3512
|
-
var
|
|
4427
|
+
var deserializeAws_restJson1GetNetworkTelemetryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3513
4428
|
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3514
4429
|
var _h;
|
|
3515
4430
|
return __generator(this, function (_j) {
|
|
@@ -3579,35 +4494,31 @@ var deserializeAws_restJson1GetLinkAssociationsCommandError = function (output,
|
|
|
3579
4494
|
}
|
|
3580
4495
|
});
|
|
3581
4496
|
}); };
|
|
3582
|
-
export var
|
|
4497
|
+
export var deserializeAws_restJson1GetRouteAnalysisCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3583
4498
|
var contents, data, _a, _b;
|
|
3584
4499
|
return __generator(this, function (_c) {
|
|
3585
4500
|
switch (_c.label) {
|
|
3586
4501
|
case 0:
|
|
3587
4502
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3588
|
-
return [2,
|
|
4503
|
+
return [2, deserializeAws_restJson1GetRouteAnalysisCommandError(output, context)];
|
|
3589
4504
|
}
|
|
3590
4505
|
contents = {
|
|
3591
4506
|
$metadata: deserializeMetadata(output),
|
|
3592
|
-
|
|
3593
|
-
NextToken: undefined,
|
|
4507
|
+
RouteAnalysis: undefined,
|
|
3594
4508
|
};
|
|
3595
4509
|
_a = __expectNonNull;
|
|
3596
4510
|
_b = __expectObject;
|
|
3597
4511
|
return [4, parseBody(output.body, context)];
|
|
3598
4512
|
case 1:
|
|
3599
4513
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
3600
|
-
if (data.
|
|
3601
|
-
contents.
|
|
3602
|
-
}
|
|
3603
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
3604
|
-
contents.NextToken = __expectString(data.NextToken);
|
|
4514
|
+
if (data.RouteAnalysis !== undefined && data.RouteAnalysis !== null) {
|
|
4515
|
+
contents.RouteAnalysis = deserializeAws_restJson1RouteAnalysis(data.RouteAnalysis, context);
|
|
3605
4516
|
}
|
|
3606
4517
|
return [2, Promise.resolve(contents)];
|
|
3607
4518
|
}
|
|
3608
4519
|
});
|
|
3609
4520
|
}); };
|
|
3610
|
-
var
|
|
4521
|
+
var deserializeAws_restJson1GetRouteAnalysisCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3611
4522
|
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
|
|
3612
4523
|
var _h;
|
|
3613
4524
|
return __generator(this, function (_j) {
|
|
@@ -4097,7 +5008,109 @@ export var deserializeAws_restJson1RegisterTransitGatewayCommand = function (out
|
|
|
4097
5008
|
}
|
|
4098
5009
|
});
|
|
4099
5010
|
}); };
|
|
4100
|
-
var deserializeAws_restJson1RegisterTransitGatewayCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
5011
|
+
var deserializeAws_restJson1RegisterTransitGatewayCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
5012
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, _h, parsedBody, message;
|
|
5013
|
+
var _j;
|
|
5014
|
+
return __generator(this, function (_k) {
|
|
5015
|
+
switch (_k.label) {
|
|
5016
|
+
case 0:
|
|
5017
|
+
_a = [__assign({}, output)];
|
|
5018
|
+
_j = {};
|
|
5019
|
+
return [4, parseBody(output.body, context)];
|
|
5020
|
+
case 1:
|
|
5021
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_j.body = _k.sent(), _j)]));
|
|
5022
|
+
errorCode = "UnknownError";
|
|
5023
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
5024
|
+
_b = errorCode;
|
|
5025
|
+
switch (_b) {
|
|
5026
|
+
case "AccessDeniedException": return [3, 2];
|
|
5027
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
5028
|
+
case "ConflictException": return [3, 4];
|
|
5029
|
+
case "com.amazonaws.networkmanager#ConflictException": return [3, 4];
|
|
5030
|
+
case "InternalServerException": return [3, 6];
|
|
5031
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 6];
|
|
5032
|
+
case "ResourceNotFoundException": return [3, 8];
|
|
5033
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 8];
|
|
5034
|
+
case "ThrottlingException": return [3, 10];
|
|
5035
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 10];
|
|
5036
|
+
case "ValidationException": return [3, 12];
|
|
5037
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 12];
|
|
5038
|
+
}
|
|
5039
|
+
return [3, 14];
|
|
5040
|
+
case 2:
|
|
5041
|
+
_c = [{}];
|
|
5042
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
5043
|
+
case 3:
|
|
5044
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5045
|
+
return [3, 15];
|
|
5046
|
+
case 4:
|
|
5047
|
+
_d = [{}];
|
|
5048
|
+
return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
5049
|
+
case 5:
|
|
5050
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5051
|
+
return [3, 15];
|
|
5052
|
+
case 6:
|
|
5053
|
+
_e = [{}];
|
|
5054
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
5055
|
+
case 7:
|
|
5056
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5057
|
+
return [3, 15];
|
|
5058
|
+
case 8:
|
|
5059
|
+
_f = [{}];
|
|
5060
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
5061
|
+
case 9:
|
|
5062
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5063
|
+
return [3, 15];
|
|
5064
|
+
case 10:
|
|
5065
|
+
_g = [{}];
|
|
5066
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
5067
|
+
case 11:
|
|
5068
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5069
|
+
return [3, 15];
|
|
5070
|
+
case 12:
|
|
5071
|
+
_h = [{}];
|
|
5072
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
5073
|
+
case 13:
|
|
5074
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _h.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5075
|
+
return [3, 15];
|
|
5076
|
+
case 14:
|
|
5077
|
+
parsedBody = parsedOutput.body;
|
|
5078
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
5079
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
5080
|
+
_k.label = 15;
|
|
5081
|
+
case 15:
|
|
5082
|
+
message = response.message || response.Message || errorCode;
|
|
5083
|
+
response.message = message;
|
|
5084
|
+
delete response.Message;
|
|
5085
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
5086
|
+
}
|
|
5087
|
+
});
|
|
5088
|
+
}); };
|
|
5089
|
+
export var deserializeAws_restJson1StartRouteAnalysisCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
5090
|
+
var contents, data, _a, _b;
|
|
5091
|
+
return __generator(this, function (_c) {
|
|
5092
|
+
switch (_c.label) {
|
|
5093
|
+
case 0:
|
|
5094
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
5095
|
+
return [2, deserializeAws_restJson1StartRouteAnalysisCommandError(output, context)];
|
|
5096
|
+
}
|
|
5097
|
+
contents = {
|
|
5098
|
+
$metadata: deserializeMetadata(output),
|
|
5099
|
+
RouteAnalysis: undefined,
|
|
5100
|
+
};
|
|
5101
|
+
_a = __expectNonNull;
|
|
5102
|
+
_b = __expectObject;
|
|
5103
|
+
return [4, parseBody(output.body, context)];
|
|
5104
|
+
case 1:
|
|
5105
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
5106
|
+
if (data.RouteAnalysis !== undefined && data.RouteAnalysis !== null) {
|
|
5107
|
+
contents.RouteAnalysis = deserializeAws_restJson1RouteAnalysis(data.RouteAnalysis, context);
|
|
5108
|
+
}
|
|
5109
|
+
return [2, Promise.resolve(contents)];
|
|
5110
|
+
}
|
|
5111
|
+
});
|
|
5112
|
+
}); };
|
|
5113
|
+
var deserializeAws_restJson1StartRouteAnalysisCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4101
5114
|
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, _h, parsedBody, message;
|
|
4102
5115
|
var _j;
|
|
4103
5116
|
return __generator(this, function (_k) {
|
|
@@ -4791,6 +5804,112 @@ var deserializeAws_restJson1UpdateLinkCommandError = function (output, context)
|
|
|
4791
5804
|
}
|
|
4792
5805
|
});
|
|
4793
5806
|
}); };
|
|
5807
|
+
export var deserializeAws_restJson1UpdateNetworkResourceMetadataCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
5808
|
+
var contents, data, _a, _b;
|
|
5809
|
+
return __generator(this, function (_c) {
|
|
5810
|
+
switch (_c.label) {
|
|
5811
|
+
case 0:
|
|
5812
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
5813
|
+
return [2, deserializeAws_restJson1UpdateNetworkResourceMetadataCommandError(output, context)];
|
|
5814
|
+
}
|
|
5815
|
+
contents = {
|
|
5816
|
+
$metadata: deserializeMetadata(output),
|
|
5817
|
+
Metadata: undefined,
|
|
5818
|
+
ResourceArn: undefined,
|
|
5819
|
+
};
|
|
5820
|
+
_a = __expectNonNull;
|
|
5821
|
+
_b = __expectObject;
|
|
5822
|
+
return [4, parseBody(output.body, context)];
|
|
5823
|
+
case 1:
|
|
5824
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
5825
|
+
if (data.Metadata !== undefined && data.Metadata !== null) {
|
|
5826
|
+
contents.Metadata = deserializeAws_restJson1NetworkResourceMetadataMap(data.Metadata, context);
|
|
5827
|
+
}
|
|
5828
|
+
if (data.ResourceArn !== undefined && data.ResourceArn !== null) {
|
|
5829
|
+
contents.ResourceArn = __expectString(data.ResourceArn);
|
|
5830
|
+
}
|
|
5831
|
+
return [2, Promise.resolve(contents)];
|
|
5832
|
+
}
|
|
5833
|
+
});
|
|
5834
|
+
}); };
|
|
5835
|
+
var deserializeAws_restJson1UpdateNetworkResourceMetadataCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
5836
|
+
var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, _h, parsedBody, message;
|
|
5837
|
+
var _j;
|
|
5838
|
+
return __generator(this, function (_k) {
|
|
5839
|
+
switch (_k.label) {
|
|
5840
|
+
case 0:
|
|
5841
|
+
_a = [__assign({}, output)];
|
|
5842
|
+
_j = {};
|
|
5843
|
+
return [4, parseBody(output.body, context)];
|
|
5844
|
+
case 1:
|
|
5845
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_j.body = _k.sent(), _j)]));
|
|
5846
|
+
errorCode = "UnknownError";
|
|
5847
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
5848
|
+
_b = errorCode;
|
|
5849
|
+
switch (_b) {
|
|
5850
|
+
case "AccessDeniedException": return [3, 2];
|
|
5851
|
+
case "com.amazonaws.networkmanager#AccessDeniedException": return [3, 2];
|
|
5852
|
+
case "ConflictException": return [3, 4];
|
|
5853
|
+
case "com.amazonaws.networkmanager#ConflictException": return [3, 4];
|
|
5854
|
+
case "InternalServerException": return [3, 6];
|
|
5855
|
+
case "com.amazonaws.networkmanager#InternalServerException": return [3, 6];
|
|
5856
|
+
case "ResourceNotFoundException": return [3, 8];
|
|
5857
|
+
case "com.amazonaws.networkmanager#ResourceNotFoundException": return [3, 8];
|
|
5858
|
+
case "ThrottlingException": return [3, 10];
|
|
5859
|
+
case "com.amazonaws.networkmanager#ThrottlingException": return [3, 10];
|
|
5860
|
+
case "ValidationException": return [3, 12];
|
|
5861
|
+
case "com.amazonaws.networkmanager#ValidationException": return [3, 12];
|
|
5862
|
+
}
|
|
5863
|
+
return [3, 14];
|
|
5864
|
+
case 2:
|
|
5865
|
+
_c = [{}];
|
|
5866
|
+
return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
5867
|
+
case 3:
|
|
5868
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5869
|
+
return [3, 15];
|
|
5870
|
+
case 4:
|
|
5871
|
+
_d = [{}];
|
|
5872
|
+
return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
5873
|
+
case 5:
|
|
5874
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5875
|
+
return [3, 15];
|
|
5876
|
+
case 6:
|
|
5877
|
+
_e = [{}];
|
|
5878
|
+
return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
5879
|
+
case 7:
|
|
5880
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5881
|
+
return [3, 15];
|
|
5882
|
+
case 8:
|
|
5883
|
+
_f = [{}];
|
|
5884
|
+
return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
5885
|
+
case 9:
|
|
5886
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5887
|
+
return [3, 15];
|
|
5888
|
+
case 10:
|
|
5889
|
+
_g = [{}];
|
|
5890
|
+
return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
5891
|
+
case 11:
|
|
5892
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5893
|
+
return [3, 15];
|
|
5894
|
+
case 12:
|
|
5895
|
+
_h = [{}];
|
|
5896
|
+
return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
5897
|
+
case 13:
|
|
5898
|
+
response = __assign.apply(void 0, [__assign.apply(void 0, _h.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
|
|
5899
|
+
return [3, 15];
|
|
5900
|
+
case 14:
|
|
5901
|
+
parsedBody = parsedOutput.body;
|
|
5902
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
5903
|
+
response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
|
|
5904
|
+
_k.label = 15;
|
|
5905
|
+
case 15:
|
|
5906
|
+
message = response.message || response.Message || errorCode;
|
|
5907
|
+
response.message = message;
|
|
5908
|
+
delete response.Message;
|
|
5909
|
+
return [2, Promise.reject(Object.assign(new Error(message), response))];
|
|
5910
|
+
}
|
|
5911
|
+
});
|
|
5912
|
+
}); };
|
|
4794
5913
|
export var deserializeAws_restJson1UpdateSiteCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4795
5914
|
var contents, data, _a, _b;
|
|
4796
5915
|
return __generator(this, function (_c) {
|
|
@@ -4960,11 +6079,15 @@ var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsed
|
|
|
4960
6079
|
name: "ResourceNotFoundException",
|
|
4961
6080
|
$fault: "client",
|
|
4962
6081
|
$metadata: deserializeMetadata(parsedOutput),
|
|
6082
|
+
Context: undefined,
|
|
4963
6083
|
Message: undefined,
|
|
4964
6084
|
ResourceId: undefined,
|
|
4965
6085
|
ResourceType: undefined,
|
|
4966
6086
|
};
|
|
4967
6087
|
data = parsedOutput.body;
|
|
6088
|
+
if (data.Context !== undefined && data.Context !== null) {
|
|
6089
|
+
contents.Context = deserializeAws_restJson1ExceptionContextMap(data.Context, context);
|
|
6090
|
+
}
|
|
4968
6091
|
if (data.Message !== undefined && data.Message !== null) {
|
|
4969
6092
|
contents.Message = __expectString(data.Message);
|
|
4970
6093
|
}
|
|
@@ -5059,9 +6182,77 @@ var serializeAws_restJson1AWSLocation = function (input, context) {
|
|
|
5059
6182
|
var serializeAws_restJson1Bandwidth = function (input, context) {
|
|
5060
6183
|
return __assign(__assign({}, (input.DownloadSpeed !== undefined && input.DownloadSpeed !== null && { DownloadSpeed: input.DownloadSpeed })), (input.UploadSpeed !== undefined && input.UploadSpeed !== null && { UploadSpeed: input.UploadSpeed }));
|
|
5061
6184
|
};
|
|
6185
|
+
var serializeAws_restJson1FilterMap = function (input, context) {
|
|
6186
|
+
return Object.entries(input).reduce(function (acc, _a) {
|
|
6187
|
+
var _b;
|
|
6188
|
+
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
6189
|
+
if (value === null) {
|
|
6190
|
+
return acc;
|
|
6191
|
+
}
|
|
6192
|
+
return __assign(__assign({}, acc), (_b = {}, _b[key] = serializeAws_restJson1FilterValues(value, context), _b));
|
|
6193
|
+
}, {});
|
|
6194
|
+
};
|
|
6195
|
+
var serializeAws_restJson1FilterValues = function (input, context) {
|
|
6196
|
+
return input
|
|
6197
|
+
.filter(function (e) { return e != null; })
|
|
6198
|
+
.map(function (entry) {
|
|
6199
|
+
if (entry === null) {
|
|
6200
|
+
return null;
|
|
6201
|
+
}
|
|
6202
|
+
return entry;
|
|
6203
|
+
});
|
|
6204
|
+
};
|
|
5062
6205
|
var serializeAws_restJson1Location = function (input, context) {
|
|
5063
6206
|
return __assign(__assign(__assign({}, (input.Address !== undefined && input.Address !== null && { Address: input.Address })), (input.Latitude !== undefined && input.Latitude !== null && { Latitude: input.Latitude })), (input.Longitude !== undefined && input.Longitude !== null && { Longitude: input.Longitude }));
|
|
5064
6207
|
};
|
|
6208
|
+
var serializeAws_restJson1NetworkResourceMetadataMap = function (input, context) {
|
|
6209
|
+
return Object.entries(input).reduce(function (acc, _a) {
|
|
6210
|
+
var _b;
|
|
6211
|
+
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
6212
|
+
if (value === null) {
|
|
6213
|
+
return acc;
|
|
6214
|
+
}
|
|
6215
|
+
return __assign(__assign({}, acc), (_b = {}, _b[key] = value, _b));
|
|
6216
|
+
}, {});
|
|
6217
|
+
};
|
|
6218
|
+
var serializeAws_restJson1RouteAnalysisEndpointOptionsSpecification = function (input, context) {
|
|
6219
|
+
return __assign(__assign({}, (input.IpAddress !== undefined && input.IpAddress !== null && { IpAddress: input.IpAddress })), (input.TransitGatewayAttachmentArn !== undefined &&
|
|
6220
|
+
input.TransitGatewayAttachmentArn !== null && { TransitGatewayAttachmentArn: input.TransitGatewayAttachmentArn }));
|
|
6221
|
+
};
|
|
6222
|
+
var serializeAws_restJson1RouteStateList = function (input, context) {
|
|
6223
|
+
return input
|
|
6224
|
+
.filter(function (e) { return e != null; })
|
|
6225
|
+
.map(function (entry) {
|
|
6226
|
+
if (entry === null) {
|
|
6227
|
+
return null;
|
|
6228
|
+
}
|
|
6229
|
+
return entry;
|
|
6230
|
+
});
|
|
6231
|
+
};
|
|
6232
|
+
var serializeAws_restJson1RouteTableIdentifier = function (input, context) {
|
|
6233
|
+
return __assign({}, (input.TransitGatewayRouteTableArn !== undefined &&
|
|
6234
|
+
input.TransitGatewayRouteTableArn !== null && { TransitGatewayRouteTableArn: input.TransitGatewayRouteTableArn }));
|
|
6235
|
+
};
|
|
6236
|
+
var serializeAws_restJson1RouteTypeList = function (input, context) {
|
|
6237
|
+
return input
|
|
6238
|
+
.filter(function (e) { return e != null; })
|
|
6239
|
+
.map(function (entry) {
|
|
6240
|
+
if (entry === null) {
|
|
6241
|
+
return null;
|
|
6242
|
+
}
|
|
6243
|
+
return entry;
|
|
6244
|
+
});
|
|
6245
|
+
};
|
|
6246
|
+
var serializeAws_restJson1StringList = function (input, context) {
|
|
6247
|
+
return input
|
|
6248
|
+
.filter(function (e) { return e != null; })
|
|
6249
|
+
.map(function (entry) {
|
|
6250
|
+
if (entry === null) {
|
|
6251
|
+
return null;
|
|
6252
|
+
}
|
|
6253
|
+
return entry;
|
|
6254
|
+
});
|
|
6255
|
+
};
|
|
5065
6256
|
var serializeAws_restJson1Tag = function (input, context) {
|
|
5066
6257
|
return __assign(__assign({}, (input.Key !== undefined && input.Key !== null && { Key: input.Key })), (input.Value !== undefined && input.Value !== null && { Value: input.Value }));
|
|
5067
6258
|
};
|
|
@@ -5106,6 +6297,15 @@ var deserializeAws_restJson1Connection = function (output, context) {
|
|
|
5106
6297
|
: undefined,
|
|
5107
6298
|
};
|
|
5108
6299
|
};
|
|
6300
|
+
var deserializeAws_restJson1ConnectionHealth = function (output, context) {
|
|
6301
|
+
return {
|
|
6302
|
+
Status: __expectString(output.Status),
|
|
6303
|
+
Timestamp: output.Timestamp !== undefined && output.Timestamp !== null
|
|
6304
|
+
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.Timestamp)))
|
|
6305
|
+
: undefined,
|
|
6306
|
+
Type: __expectString(output.Type),
|
|
6307
|
+
};
|
|
6308
|
+
};
|
|
5109
6309
|
var deserializeAws_restJson1ConnectionList = function (output, context) {
|
|
5110
6310
|
return (output || [])
|
|
5111
6311
|
.filter(function (e) { return e != null; })
|
|
@@ -5171,6 +6371,16 @@ var deserializeAws_restJson1DeviceList = function (output, context) {
|
|
|
5171
6371
|
return deserializeAws_restJson1Device(entry, context);
|
|
5172
6372
|
});
|
|
5173
6373
|
};
|
|
6374
|
+
var deserializeAws_restJson1ExceptionContextMap = function (output, context) {
|
|
6375
|
+
return Object.entries(output).reduce(function (acc, _a) {
|
|
6376
|
+
var _b;
|
|
6377
|
+
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
6378
|
+
if (value === null) {
|
|
6379
|
+
return acc;
|
|
6380
|
+
}
|
|
6381
|
+
return __assign(__assign({}, acc), (_b = {}, _b[key] = __expectString(value), _b));
|
|
6382
|
+
}, {});
|
|
6383
|
+
};
|
|
5174
6384
|
var deserializeAws_restJson1GlobalNetwork = function (output, context) {
|
|
5175
6385
|
return {
|
|
5176
6386
|
CreatedAt: output.CreatedAt !== undefined && output.CreatedAt !== null
|
|
@@ -5251,6 +6461,230 @@ var deserializeAws_restJson1Location = function (output, context) {
|
|
|
5251
6461
|
Longitude: __expectString(output.Longitude),
|
|
5252
6462
|
};
|
|
5253
6463
|
};
|
|
6464
|
+
var deserializeAws_restJson1NetworkResource = function (output, context) {
|
|
6465
|
+
return {
|
|
6466
|
+
AccountId: __expectString(output.AccountId),
|
|
6467
|
+
AwsRegion: __expectString(output.AwsRegion),
|
|
6468
|
+
Definition: __expectString(output.Definition),
|
|
6469
|
+
DefinitionTimestamp: output.DefinitionTimestamp !== undefined && output.DefinitionTimestamp !== null
|
|
6470
|
+
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.DefinitionTimestamp)))
|
|
6471
|
+
: undefined,
|
|
6472
|
+
Metadata: output.Metadata !== undefined && output.Metadata !== null
|
|
6473
|
+
? deserializeAws_restJson1NetworkResourceMetadataMap(output.Metadata, context)
|
|
6474
|
+
: undefined,
|
|
6475
|
+
RegisteredGatewayArn: __expectString(output.RegisteredGatewayArn),
|
|
6476
|
+
ResourceArn: __expectString(output.ResourceArn),
|
|
6477
|
+
ResourceId: __expectString(output.ResourceId),
|
|
6478
|
+
ResourceType: __expectString(output.ResourceType),
|
|
6479
|
+
Tags: output.Tags !== undefined && output.Tags !== null
|
|
6480
|
+
? deserializeAws_restJson1TagList(output.Tags, context)
|
|
6481
|
+
: undefined,
|
|
6482
|
+
};
|
|
6483
|
+
};
|
|
6484
|
+
var deserializeAws_restJson1NetworkResourceCount = function (output, context) {
|
|
6485
|
+
return {
|
|
6486
|
+
Count: __expectInt32(output.Count),
|
|
6487
|
+
ResourceType: __expectString(output.ResourceType),
|
|
6488
|
+
};
|
|
6489
|
+
};
|
|
6490
|
+
var deserializeAws_restJson1NetworkResourceCountList = function (output, context) {
|
|
6491
|
+
return (output || [])
|
|
6492
|
+
.filter(function (e) { return e != null; })
|
|
6493
|
+
.map(function (entry) {
|
|
6494
|
+
if (entry === null) {
|
|
6495
|
+
return null;
|
|
6496
|
+
}
|
|
6497
|
+
return deserializeAws_restJson1NetworkResourceCount(entry, context);
|
|
6498
|
+
});
|
|
6499
|
+
};
|
|
6500
|
+
var deserializeAws_restJson1NetworkResourceList = function (output, context) {
|
|
6501
|
+
return (output || [])
|
|
6502
|
+
.filter(function (e) { return e != null; })
|
|
6503
|
+
.map(function (entry) {
|
|
6504
|
+
if (entry === null) {
|
|
6505
|
+
return null;
|
|
6506
|
+
}
|
|
6507
|
+
return deserializeAws_restJson1NetworkResource(entry, context);
|
|
6508
|
+
});
|
|
6509
|
+
};
|
|
6510
|
+
var deserializeAws_restJson1NetworkResourceMetadataMap = function (output, context) {
|
|
6511
|
+
return Object.entries(output).reduce(function (acc, _a) {
|
|
6512
|
+
var _b;
|
|
6513
|
+
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
6514
|
+
if (value === null) {
|
|
6515
|
+
return acc;
|
|
6516
|
+
}
|
|
6517
|
+
return __assign(__assign({}, acc), (_b = {}, _b[key] = __expectString(value), _b));
|
|
6518
|
+
}, {});
|
|
6519
|
+
};
|
|
6520
|
+
var deserializeAws_restJson1NetworkResourceSummary = function (output, context) {
|
|
6521
|
+
return {
|
|
6522
|
+
Definition: __expectString(output.Definition),
|
|
6523
|
+
IsMiddlebox: __expectBoolean(output.IsMiddlebox),
|
|
6524
|
+
NameTag: __expectString(output.NameTag),
|
|
6525
|
+
RegisteredGatewayArn: __expectString(output.RegisteredGatewayArn),
|
|
6526
|
+
ResourceArn: __expectString(output.ResourceArn),
|
|
6527
|
+
ResourceType: __expectString(output.ResourceType),
|
|
6528
|
+
};
|
|
6529
|
+
};
|
|
6530
|
+
var deserializeAws_restJson1NetworkRoute = function (output, context) {
|
|
6531
|
+
return {
|
|
6532
|
+
DestinationCidrBlock: __expectString(output.DestinationCidrBlock),
|
|
6533
|
+
Destinations: output.Destinations !== undefined && output.Destinations !== null
|
|
6534
|
+
? deserializeAws_restJson1NetworkRouteDestinationList(output.Destinations, context)
|
|
6535
|
+
: undefined,
|
|
6536
|
+
PrefixListId: __expectString(output.PrefixListId),
|
|
6537
|
+
State: __expectString(output.State),
|
|
6538
|
+
Type: __expectString(output.Type),
|
|
6539
|
+
};
|
|
6540
|
+
};
|
|
6541
|
+
var deserializeAws_restJson1NetworkRouteDestination = function (output, context) {
|
|
6542
|
+
return {
|
|
6543
|
+
ResourceId: __expectString(output.ResourceId),
|
|
6544
|
+
ResourceType: __expectString(output.ResourceType),
|
|
6545
|
+
TransitGatewayAttachmentId: __expectString(output.TransitGatewayAttachmentId),
|
|
6546
|
+
};
|
|
6547
|
+
};
|
|
6548
|
+
var deserializeAws_restJson1NetworkRouteDestinationList = function (output, context) {
|
|
6549
|
+
return (output || [])
|
|
6550
|
+
.filter(function (e) { return e != null; })
|
|
6551
|
+
.map(function (entry) {
|
|
6552
|
+
if (entry === null) {
|
|
6553
|
+
return null;
|
|
6554
|
+
}
|
|
6555
|
+
return deserializeAws_restJson1NetworkRouteDestination(entry, context);
|
|
6556
|
+
});
|
|
6557
|
+
};
|
|
6558
|
+
var deserializeAws_restJson1NetworkRouteList = function (output, context) {
|
|
6559
|
+
return (output || [])
|
|
6560
|
+
.filter(function (e) { return e != null; })
|
|
6561
|
+
.map(function (entry) {
|
|
6562
|
+
if (entry === null) {
|
|
6563
|
+
return null;
|
|
6564
|
+
}
|
|
6565
|
+
return deserializeAws_restJson1NetworkRoute(entry, context);
|
|
6566
|
+
});
|
|
6567
|
+
};
|
|
6568
|
+
var deserializeAws_restJson1NetworkTelemetry = function (output, context) {
|
|
6569
|
+
return {
|
|
6570
|
+
AccountId: __expectString(output.AccountId),
|
|
6571
|
+
Address: __expectString(output.Address),
|
|
6572
|
+
AwsRegion: __expectString(output.AwsRegion),
|
|
6573
|
+
Health: output.Health !== undefined && output.Health !== null
|
|
6574
|
+
? deserializeAws_restJson1ConnectionHealth(output.Health, context)
|
|
6575
|
+
: undefined,
|
|
6576
|
+
RegisteredGatewayArn: __expectString(output.RegisteredGatewayArn),
|
|
6577
|
+
ResourceArn: __expectString(output.ResourceArn),
|
|
6578
|
+
ResourceId: __expectString(output.ResourceId),
|
|
6579
|
+
ResourceType: __expectString(output.ResourceType),
|
|
6580
|
+
};
|
|
6581
|
+
};
|
|
6582
|
+
var deserializeAws_restJson1NetworkTelemetryList = function (output, context) {
|
|
6583
|
+
return (output || [])
|
|
6584
|
+
.filter(function (e) { return e != null; })
|
|
6585
|
+
.map(function (entry) {
|
|
6586
|
+
if (entry === null) {
|
|
6587
|
+
return null;
|
|
6588
|
+
}
|
|
6589
|
+
return deserializeAws_restJson1NetworkTelemetry(entry, context);
|
|
6590
|
+
});
|
|
6591
|
+
};
|
|
6592
|
+
var deserializeAws_restJson1PathComponent = function (output, context) {
|
|
6593
|
+
return {
|
|
6594
|
+
DestinationCidrBlock: __expectString(output.DestinationCidrBlock),
|
|
6595
|
+
Resource: output.Resource !== undefined && output.Resource !== null
|
|
6596
|
+
? deserializeAws_restJson1NetworkResourceSummary(output.Resource, context)
|
|
6597
|
+
: undefined,
|
|
6598
|
+
Sequence: __expectInt32(output.Sequence),
|
|
6599
|
+
};
|
|
6600
|
+
};
|
|
6601
|
+
var deserializeAws_restJson1PathComponentList = function (output, context) {
|
|
6602
|
+
return (output || [])
|
|
6603
|
+
.filter(function (e) { return e != null; })
|
|
6604
|
+
.map(function (entry) {
|
|
6605
|
+
if (entry === null) {
|
|
6606
|
+
return null;
|
|
6607
|
+
}
|
|
6608
|
+
return deserializeAws_restJson1PathComponent(entry, context);
|
|
6609
|
+
});
|
|
6610
|
+
};
|
|
6611
|
+
var deserializeAws_restJson1ReasonContextMap = function (output, context) {
|
|
6612
|
+
return Object.entries(output).reduce(function (acc, _a) {
|
|
6613
|
+
var _b;
|
|
6614
|
+
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
6615
|
+
if (value === null) {
|
|
6616
|
+
return acc;
|
|
6617
|
+
}
|
|
6618
|
+
return __assign(__assign({}, acc), (_b = {}, _b[key] = __expectString(value), _b));
|
|
6619
|
+
}, {});
|
|
6620
|
+
};
|
|
6621
|
+
var deserializeAws_restJson1Relationship = function (output, context) {
|
|
6622
|
+
return {
|
|
6623
|
+
From: __expectString(output.From),
|
|
6624
|
+
To: __expectString(output.To),
|
|
6625
|
+
};
|
|
6626
|
+
};
|
|
6627
|
+
var deserializeAws_restJson1RelationshipList = function (output, context) {
|
|
6628
|
+
return (output || [])
|
|
6629
|
+
.filter(function (e) { return e != null; })
|
|
6630
|
+
.map(function (entry) {
|
|
6631
|
+
if (entry === null) {
|
|
6632
|
+
return null;
|
|
6633
|
+
}
|
|
6634
|
+
return deserializeAws_restJson1Relationship(entry, context);
|
|
6635
|
+
});
|
|
6636
|
+
};
|
|
6637
|
+
var deserializeAws_restJson1RouteAnalysis = function (output, context) {
|
|
6638
|
+
return {
|
|
6639
|
+
Destination: output.Destination !== undefined && output.Destination !== null
|
|
6640
|
+
? deserializeAws_restJson1RouteAnalysisEndpointOptions(output.Destination, context)
|
|
6641
|
+
: undefined,
|
|
6642
|
+
ForwardPath: output.ForwardPath !== undefined && output.ForwardPath !== null
|
|
6643
|
+
? deserializeAws_restJson1RouteAnalysisPath(output.ForwardPath, context)
|
|
6644
|
+
: undefined,
|
|
6645
|
+
GlobalNetworkId: __expectString(output.GlobalNetworkId),
|
|
6646
|
+
IncludeReturnPath: __expectBoolean(output.IncludeReturnPath),
|
|
6647
|
+
OwnerAccountId: __expectString(output.OwnerAccountId),
|
|
6648
|
+
ReturnPath: output.ReturnPath !== undefined && output.ReturnPath !== null
|
|
6649
|
+
? deserializeAws_restJson1RouteAnalysisPath(output.ReturnPath, context)
|
|
6650
|
+
: undefined,
|
|
6651
|
+
RouteAnalysisId: __expectString(output.RouteAnalysisId),
|
|
6652
|
+
Source: output.Source !== undefined && output.Source !== null
|
|
6653
|
+
? deserializeAws_restJson1RouteAnalysisEndpointOptions(output.Source, context)
|
|
6654
|
+
: undefined,
|
|
6655
|
+
StartTimestamp: output.StartTimestamp !== undefined && output.StartTimestamp !== null
|
|
6656
|
+
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.StartTimestamp)))
|
|
6657
|
+
: undefined,
|
|
6658
|
+
Status: __expectString(output.Status),
|
|
6659
|
+
UseMiddleboxes: __expectBoolean(output.UseMiddleboxes),
|
|
6660
|
+
};
|
|
6661
|
+
};
|
|
6662
|
+
var deserializeAws_restJson1RouteAnalysisCompletion = function (output, context) {
|
|
6663
|
+
return {
|
|
6664
|
+
ReasonCode: __expectString(output.ReasonCode),
|
|
6665
|
+
ReasonContext: output.ReasonContext !== undefined && output.ReasonContext !== null
|
|
6666
|
+
? deserializeAws_restJson1ReasonContextMap(output.ReasonContext, context)
|
|
6667
|
+
: undefined,
|
|
6668
|
+
ResultCode: __expectString(output.ResultCode),
|
|
6669
|
+
};
|
|
6670
|
+
};
|
|
6671
|
+
var deserializeAws_restJson1RouteAnalysisEndpointOptions = function (output, context) {
|
|
6672
|
+
return {
|
|
6673
|
+
IpAddress: __expectString(output.IpAddress),
|
|
6674
|
+
TransitGatewayArn: __expectString(output.TransitGatewayArn),
|
|
6675
|
+
TransitGatewayAttachmentArn: __expectString(output.TransitGatewayAttachmentArn),
|
|
6676
|
+
};
|
|
6677
|
+
};
|
|
6678
|
+
var deserializeAws_restJson1RouteAnalysisPath = function (output, context) {
|
|
6679
|
+
return {
|
|
6680
|
+
CompletionStatus: output.CompletionStatus !== undefined && output.CompletionStatus !== null
|
|
6681
|
+
? deserializeAws_restJson1RouteAnalysisCompletion(output.CompletionStatus, context)
|
|
6682
|
+
: undefined,
|
|
6683
|
+
Path: output.Path !== undefined && output.Path !== null
|
|
6684
|
+
? deserializeAws_restJson1PathComponentList(output.Path, context)
|
|
6685
|
+
: undefined,
|
|
6686
|
+
};
|
|
6687
|
+
};
|
|
5254
6688
|
var deserializeAws_restJson1Site = function (output, context) {
|
|
5255
6689
|
return {
|
|
5256
6690
|
CreatedAt: output.CreatedAt !== undefined && output.CreatedAt !== null
|