@aws-sdk/client-macie2 3.128.0 → 3.137.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 +31 -0
- package/dist-cjs/Macie2.js +60 -0
- package/dist-cjs/commands/AcceptInvitationCommand.js +2 -2
- package/dist-cjs/commands/BatchGetCustomDataIdentifiersCommand.js +2 -2
- package/dist-cjs/commands/CreateClassificationJobCommand.js +2 -2
- package/dist-cjs/commands/CreateCustomDataIdentifierCommand.js +2 -2
- package/dist-cjs/commands/CreateFindingsFilterCommand.js +2 -2
- package/dist-cjs/commands/CreateInvitationsCommand.js +2 -2
- package/dist-cjs/commands/CreateMemberCommand.js +2 -2
- package/dist-cjs/commands/CreateSampleFindingsCommand.js +2 -2
- package/dist-cjs/commands/DeclineInvitationsCommand.js +2 -2
- package/dist-cjs/commands/DeleteCustomDataIdentifierCommand.js +2 -2
- package/dist-cjs/commands/DeleteFindingsFilterCommand.js +2 -2
- package/dist-cjs/commands/DeleteInvitationsCommand.js +2 -2
- package/dist-cjs/commands/DeleteMemberCommand.js +2 -2
- package/dist-cjs/commands/DescribeBucketsCommand.js +2 -2
- package/dist-cjs/commands/DescribeClassificationJobCommand.js +2 -2
- package/dist-cjs/commands/DescribeOrganizationConfigurationCommand.js +2 -2
- package/dist-cjs/commands/DisableMacieCommand.js +2 -2
- package/dist-cjs/commands/DisableOrganizationAdminAccountCommand.js +2 -2
- package/dist-cjs/commands/DisassociateFromAdministratorAccountCommand.js +2 -2
- package/dist-cjs/commands/DisassociateFromMasterAccountCommand.js +2 -2
- package/dist-cjs/commands/DisassociateMemberCommand.js +2 -2
- package/dist-cjs/commands/EnableMacieCommand.js +2 -2
- package/dist-cjs/commands/EnableOrganizationAdminAccountCommand.js +2 -2
- package/dist-cjs/commands/GetAdministratorAccountCommand.js +2 -2
- package/dist-cjs/commands/GetBucketStatisticsCommand.js +2 -2
- package/dist-cjs/commands/GetClassificationExportConfigurationCommand.js +2 -2
- package/dist-cjs/commands/GetCustomDataIdentifierCommand.js +2 -2
- package/dist-cjs/commands/GetFindingStatisticsCommand.js +2 -2
- package/dist-cjs/commands/GetFindingsCommand.js +2 -2
- package/dist-cjs/commands/GetFindingsFilterCommand.js +2 -2
- package/dist-cjs/commands/GetFindingsPublicationConfigurationCommand.js +2 -2
- package/dist-cjs/commands/GetInvitationsCountCommand.js +2 -2
- package/dist-cjs/commands/GetMacieSessionCommand.js +2 -2
- package/dist-cjs/commands/GetMasterAccountCommand.js +2 -2
- package/dist-cjs/commands/GetMemberCommand.js +2 -2
- package/dist-cjs/commands/GetRevealConfigurationCommand.js +36 -0
- package/dist-cjs/commands/GetSensitiveDataOccurrencesAvailabilityCommand.js +36 -0
- package/dist-cjs/commands/GetSensitiveDataOccurrencesCommand.js +36 -0
- package/dist-cjs/commands/GetUsageStatisticsCommand.js +2 -2
- package/dist-cjs/commands/GetUsageTotalsCommand.js +2 -2
- package/dist-cjs/commands/ListClassificationJobsCommand.js +2 -2
- package/dist-cjs/commands/ListCustomDataIdentifiersCommand.js +2 -2
- package/dist-cjs/commands/ListFindingsCommand.js +2 -2
- package/dist-cjs/commands/ListFindingsFiltersCommand.js +2 -2
- package/dist-cjs/commands/ListInvitationsCommand.js +2 -2
- package/dist-cjs/commands/ListManagedDataIdentifiersCommand.js +2 -2
- package/dist-cjs/commands/ListMembersCommand.js +2 -2
- package/dist-cjs/commands/ListOrganizationAdminAccountsCommand.js +2 -2
- package/dist-cjs/commands/ListTagsForResourceCommand.js +2 -2
- package/dist-cjs/commands/PutClassificationExportConfigurationCommand.js +2 -2
- package/dist-cjs/commands/PutFindingsPublicationConfigurationCommand.js +2 -2
- package/dist-cjs/commands/SearchResourcesCommand.js +2 -2
- package/dist-cjs/commands/TagResourceCommand.js +2 -2
- package/dist-cjs/commands/TestCustomDataIdentifierCommand.js +2 -2
- package/dist-cjs/commands/UntagResourceCommand.js +2 -2
- package/dist-cjs/commands/UpdateClassificationJobCommand.js +2 -2
- package/dist-cjs/commands/UpdateFindingsFilterCommand.js +2 -2
- package/dist-cjs/commands/UpdateMacieSessionCommand.js +2 -2
- package/dist-cjs/commands/UpdateMemberSessionCommand.js +2 -2
- package/dist-cjs/commands/UpdateOrganizationConfigurationCommand.js +2 -2
- package/dist-cjs/commands/UpdateRevealConfigurationCommand.js +36 -0
- package/dist-cjs/commands/index.js +4 -0
- package/dist-cjs/index.js +1 -0
- package/dist-cjs/models/models_0.js +1007 -1392
- package/dist-cjs/protocols/Aws_restJson1.js +368 -3
- package/dist-cjs/waiters/index.js +4 -0
- package/dist-cjs/waiters/waitForFindingRevealed.js +45 -0
- package/dist-es/Macie2.js +60 -0
- package/dist-es/commands/AcceptInvitationCommand.js +3 -3
- package/dist-es/commands/BatchGetCustomDataIdentifiersCommand.js +3 -3
- package/dist-es/commands/CreateClassificationJobCommand.js +3 -3
- package/dist-es/commands/CreateCustomDataIdentifierCommand.js +3 -3
- package/dist-es/commands/CreateFindingsFilterCommand.js +3 -3
- package/dist-es/commands/CreateInvitationsCommand.js +3 -3
- package/dist-es/commands/CreateMemberCommand.js +3 -3
- package/dist-es/commands/CreateSampleFindingsCommand.js +3 -3
- package/dist-es/commands/DeclineInvitationsCommand.js +3 -3
- package/dist-es/commands/DeleteCustomDataIdentifierCommand.js +3 -3
- package/dist-es/commands/DeleteFindingsFilterCommand.js +3 -3
- package/dist-es/commands/DeleteInvitationsCommand.js +3 -3
- package/dist-es/commands/DeleteMemberCommand.js +3 -3
- package/dist-es/commands/DescribeBucketsCommand.js +3 -3
- package/dist-es/commands/DescribeClassificationJobCommand.js +3 -3
- package/dist-es/commands/DescribeOrganizationConfigurationCommand.js +3 -3
- package/dist-es/commands/DisableMacieCommand.js +3 -3
- package/dist-es/commands/DisableOrganizationAdminAccountCommand.js +3 -3
- package/dist-es/commands/DisassociateFromAdministratorAccountCommand.js +3 -3
- package/dist-es/commands/DisassociateFromMasterAccountCommand.js +3 -3
- package/dist-es/commands/DisassociateMemberCommand.js +3 -3
- package/dist-es/commands/EnableMacieCommand.js +3 -3
- package/dist-es/commands/EnableOrganizationAdminAccountCommand.js +3 -3
- package/dist-es/commands/GetAdministratorAccountCommand.js +3 -3
- package/dist-es/commands/GetBucketStatisticsCommand.js +3 -3
- package/dist-es/commands/GetClassificationExportConfigurationCommand.js +3 -3
- package/dist-es/commands/GetCustomDataIdentifierCommand.js +3 -3
- package/dist-es/commands/GetFindingStatisticsCommand.js +3 -3
- package/dist-es/commands/GetFindingsCommand.js +3 -3
- package/dist-es/commands/GetFindingsFilterCommand.js +3 -3
- package/dist-es/commands/GetFindingsPublicationConfigurationCommand.js +3 -3
- package/dist-es/commands/GetInvitationsCountCommand.js +3 -3
- package/dist-es/commands/GetMacieSessionCommand.js +3 -3
- package/dist-es/commands/GetMasterAccountCommand.js +3 -3
- package/dist-es/commands/GetMemberCommand.js +3 -3
- package/dist-es/commands/GetRevealConfigurationCommand.js +39 -0
- package/dist-es/commands/GetSensitiveDataOccurrencesAvailabilityCommand.js +39 -0
- package/dist-es/commands/GetSensitiveDataOccurrencesCommand.js +39 -0
- package/dist-es/commands/GetUsageStatisticsCommand.js +3 -3
- package/dist-es/commands/GetUsageTotalsCommand.js +3 -3
- package/dist-es/commands/ListClassificationJobsCommand.js +3 -3
- package/dist-es/commands/ListCustomDataIdentifiersCommand.js +3 -3
- package/dist-es/commands/ListFindingsCommand.js +3 -3
- package/dist-es/commands/ListFindingsFiltersCommand.js +3 -3
- package/dist-es/commands/ListInvitationsCommand.js +3 -3
- package/dist-es/commands/ListManagedDataIdentifiersCommand.js +3 -3
- package/dist-es/commands/ListMembersCommand.js +3 -3
- package/dist-es/commands/ListOrganizationAdminAccountsCommand.js +3 -3
- package/dist-es/commands/ListTagsForResourceCommand.js +3 -3
- package/dist-es/commands/PutClassificationExportConfigurationCommand.js +3 -3
- package/dist-es/commands/PutFindingsPublicationConfigurationCommand.js +3 -3
- package/dist-es/commands/SearchResourcesCommand.js +3 -3
- package/dist-es/commands/TagResourceCommand.js +3 -3
- package/dist-es/commands/TestCustomDataIdentifierCommand.js +3 -3
- package/dist-es/commands/UntagResourceCommand.js +3 -3
- package/dist-es/commands/UpdateClassificationJobCommand.js +3 -3
- package/dist-es/commands/UpdateFindingsFilterCommand.js +3 -3
- package/dist-es/commands/UpdateMacieSessionCommand.js +3 -3
- package/dist-es/commands/UpdateMemberSessionCommand.js +3 -3
- package/dist-es/commands/UpdateOrganizationConfigurationCommand.js +3 -3
- package/dist-es/commands/UpdateRevealConfigurationCommand.js +39 -0
- package/dist-es/commands/index.js +4 -0
- package/dist-es/index.js +1 -0
- package/dist-es/models/models_0.js +277 -924
- package/dist-es/protocols/Aws_restJson1.js +470 -1
- package/dist-es/waiters/index.js +1 -0
- package/dist-es/waiters/waitForFindingRevealed.js +60 -0
- package/dist-types/Macie2.d.ts +28 -0
- package/dist-types/Macie2Client.d.ts +6 -2
- package/dist-types/commands/GetRevealConfigurationCommand.d.ts +35 -0
- package/dist-types/commands/GetSensitiveDataOccurrencesAvailabilityCommand.d.ts +35 -0
- package/dist-types/commands/GetSensitiveDataOccurrencesCommand.d.ts +35 -0
- package/dist-types/commands/UpdateRevealConfigurationCommand.d.ts +35 -0
- package/dist-types/commands/index.d.ts +4 -0
- package/dist-types/index.d.ts +1 -0
- package/dist-types/models/models_0.d.ts +1074 -1387
- package/dist-types/protocols/Aws_restJson1.d.ts +12 -0
- package/dist-types/ts3.4/Macie2.d.ts +20 -0
- package/dist-types/ts3.4/Macie2Client.d.ts +6 -2
- package/dist-types/ts3.4/commands/GetRevealConfigurationCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetSensitiveDataOccurrencesAvailabilityCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetSensitiveDataOccurrencesCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateRevealConfigurationCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/index.d.ts +4 -0
- package/dist-types/ts3.4/index.d.ts +1 -0
- package/dist-types/ts3.4/models/models_0.d.ts +550 -917
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +12 -0
- package/dist-types/ts3.4/waiters/index.d.ts +1 -0
- package/dist-types/ts3.4/waiters/waitForFindingRevealed.d.ts +7 -0
- package/dist-types/waiters/index.d.ts +1 -0
- package/dist-types/waiters/waitForFindingRevealed.d.ts +14 -0
- package/package.json +10 -9
|
@@ -3,7 +3,7 @@ import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
|
3
3
|
import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectLong as __expectLong, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, limitedParseDouble as __limitedParseDouble, parseRfc3339DateTime as __parseRfc3339DateTime, } from "@aws-sdk/smithy-client";
|
|
4
4
|
import { v4 as generateIdempotencyToken } from "uuid";
|
|
5
5
|
import { Macie2ServiceException as __BaseException } from "../models/Macie2ServiceException";
|
|
6
|
-
import { AccessDeniedException, ConflictException, InternalServerException, ResourceNotFoundException, ServiceQuotaExceededException, ThrottlingException, ValidationException, } from "../models/models_0";
|
|
6
|
+
import { AccessDeniedException, ConflictException, InternalServerException, ResourceNotFoundException, ServiceQuotaExceededException, ThrottlingException, UnprocessableEntityException, ValidationException, } from "../models/models_0";
|
|
7
7
|
export var serializeAws_restJson1AcceptInvitationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
8
8
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
9
9
|
return __generator(this, function (_c) {
|
|
@@ -930,6 +930,92 @@ export var serializeAws_restJson1GetMemberCommand = function (input, context) {
|
|
|
930
930
|
}
|
|
931
931
|
});
|
|
932
932
|
}); };
|
|
933
|
+
export var serializeAws_restJson1GetRevealConfigurationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
934
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
935
|
+
return __generator(this, function (_c) {
|
|
936
|
+
switch (_c.label) {
|
|
937
|
+
case 0: return [4, context.endpoint()];
|
|
938
|
+
case 1:
|
|
939
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
940
|
+
headers = {
|
|
941
|
+
"content-type": "application/json",
|
|
942
|
+
};
|
|
943
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/reveal-configuration";
|
|
944
|
+
body = "";
|
|
945
|
+
return [2, new __HttpRequest({
|
|
946
|
+
protocol: protocol,
|
|
947
|
+
hostname: hostname,
|
|
948
|
+
port: port,
|
|
949
|
+
method: "GET",
|
|
950
|
+
headers: headers,
|
|
951
|
+
path: resolvedPath,
|
|
952
|
+
body: body,
|
|
953
|
+
})];
|
|
954
|
+
}
|
|
955
|
+
});
|
|
956
|
+
}); };
|
|
957
|
+
export var serializeAws_restJson1GetSensitiveDataOccurrencesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
958
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
959
|
+
return __generator(this, function (_c) {
|
|
960
|
+
switch (_c.label) {
|
|
961
|
+
case 0: return [4, context.endpoint()];
|
|
962
|
+
case 1:
|
|
963
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
964
|
+
headers = {};
|
|
965
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/findings/{findingId}/reveal";
|
|
966
|
+
if (input.findingId !== undefined) {
|
|
967
|
+
labelValue = input.findingId;
|
|
968
|
+
if (labelValue.length <= 0) {
|
|
969
|
+
throw new Error("Empty value provided for input HTTP label: findingId.");
|
|
970
|
+
}
|
|
971
|
+
resolvedPath = resolvedPath.replace("{findingId}", __extendedEncodeURIComponent(labelValue));
|
|
972
|
+
}
|
|
973
|
+
else {
|
|
974
|
+
throw new Error("No value provided for input HTTP label: findingId.");
|
|
975
|
+
}
|
|
976
|
+
return [2, new __HttpRequest({
|
|
977
|
+
protocol: protocol,
|
|
978
|
+
hostname: hostname,
|
|
979
|
+
port: port,
|
|
980
|
+
method: "GET",
|
|
981
|
+
headers: headers,
|
|
982
|
+
path: resolvedPath,
|
|
983
|
+
body: body,
|
|
984
|
+
})];
|
|
985
|
+
}
|
|
986
|
+
});
|
|
987
|
+
}); };
|
|
988
|
+
export var serializeAws_restJson1GetSensitiveDataOccurrencesAvailabilityCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
989
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
990
|
+
return __generator(this, function (_c) {
|
|
991
|
+
switch (_c.label) {
|
|
992
|
+
case 0: return [4, context.endpoint()];
|
|
993
|
+
case 1:
|
|
994
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
995
|
+
headers = {};
|
|
996
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/findings/{findingId}/reveal/availability";
|
|
997
|
+
if (input.findingId !== undefined) {
|
|
998
|
+
labelValue = input.findingId;
|
|
999
|
+
if (labelValue.length <= 0) {
|
|
1000
|
+
throw new Error("Empty value provided for input HTTP label: findingId.");
|
|
1001
|
+
}
|
|
1002
|
+
resolvedPath = resolvedPath.replace("{findingId}", __extendedEncodeURIComponent(labelValue));
|
|
1003
|
+
}
|
|
1004
|
+
else {
|
|
1005
|
+
throw new Error("No value provided for input HTTP label: findingId.");
|
|
1006
|
+
}
|
|
1007
|
+
return [2, new __HttpRequest({
|
|
1008
|
+
protocol: protocol,
|
|
1009
|
+
hostname: hostname,
|
|
1010
|
+
port: port,
|
|
1011
|
+
method: "GET",
|
|
1012
|
+
headers: headers,
|
|
1013
|
+
path: resolvedPath,
|
|
1014
|
+
body: body,
|
|
1015
|
+
})];
|
|
1016
|
+
}
|
|
1017
|
+
});
|
|
1018
|
+
}); };
|
|
933
1019
|
export var serializeAws_restJson1GetUsageStatisticsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
934
1020
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
935
1021
|
return __generator(this, function (_c) {
|
|
@@ -1533,6 +1619,32 @@ export var serializeAws_restJson1UpdateOrganizationConfigurationCommand = functi
|
|
|
1533
1619
|
}
|
|
1534
1620
|
});
|
|
1535
1621
|
}); };
|
|
1622
|
+
export var serializeAws_restJson1UpdateRevealConfigurationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1623
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
1624
|
+
return __generator(this, function (_c) {
|
|
1625
|
+
switch (_c.label) {
|
|
1626
|
+
case 0: return [4, context.endpoint()];
|
|
1627
|
+
case 1:
|
|
1628
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
1629
|
+
headers = {
|
|
1630
|
+
"content-type": "application/json",
|
|
1631
|
+
};
|
|
1632
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/reveal-configuration";
|
|
1633
|
+
body = JSON.stringify(__assign({}, (input.configuration != null && {
|
|
1634
|
+
configuration: serializeAws_restJson1RevealConfiguration(input.configuration, context),
|
|
1635
|
+
})));
|
|
1636
|
+
return [2, new __HttpRequest({
|
|
1637
|
+
protocol: protocol,
|
|
1638
|
+
hostname: hostname,
|
|
1639
|
+
port: port,
|
|
1640
|
+
method: "PUT",
|
|
1641
|
+
headers: headers,
|
|
1642
|
+
path: resolvedPath,
|
|
1643
|
+
body: body,
|
|
1644
|
+
})];
|
|
1645
|
+
}
|
|
1646
|
+
});
|
|
1647
|
+
}); };
|
|
1536
1648
|
export var deserializeAws_restJson1AcceptInvitationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1537
1649
|
var contents;
|
|
1538
1650
|
return __generator(this, function (_a) {
|
|
@@ -4562,6 +4674,233 @@ var deserializeAws_restJson1GetMemberCommandError = function (output, context) {
|
|
|
4562
4674
|
}
|
|
4563
4675
|
});
|
|
4564
4676
|
}); };
|
|
4677
|
+
export var deserializeAws_restJson1GetRevealConfigurationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4678
|
+
var contents, data, _a, _b;
|
|
4679
|
+
return __generator(this, function (_c) {
|
|
4680
|
+
switch (_c.label) {
|
|
4681
|
+
case 0:
|
|
4682
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
4683
|
+
return [2, deserializeAws_restJson1GetRevealConfigurationCommandError(output, context)];
|
|
4684
|
+
}
|
|
4685
|
+
contents = {
|
|
4686
|
+
$metadata: deserializeMetadata(output),
|
|
4687
|
+
configuration: undefined,
|
|
4688
|
+
};
|
|
4689
|
+
_a = __expectNonNull;
|
|
4690
|
+
_b = __expectObject;
|
|
4691
|
+
return [4, parseBody(output.body, context)];
|
|
4692
|
+
case 1:
|
|
4693
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
4694
|
+
if (data.configuration !== undefined && data.configuration !== null) {
|
|
4695
|
+
contents.configuration = deserializeAws_restJson1RevealConfiguration(data.configuration, context);
|
|
4696
|
+
}
|
|
4697
|
+
return [2, Promise.resolve(contents)];
|
|
4698
|
+
}
|
|
4699
|
+
});
|
|
4700
|
+
}); };
|
|
4701
|
+
var deserializeAws_restJson1GetRevealConfigurationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4702
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
4703
|
+
var _c;
|
|
4704
|
+
return __generator(this, function (_d) {
|
|
4705
|
+
switch (_d.label) {
|
|
4706
|
+
case 0:
|
|
4707
|
+
_a = [__assign({}, output)];
|
|
4708
|
+
_c = {};
|
|
4709
|
+
return [4, parseBody(output.body, context)];
|
|
4710
|
+
case 1:
|
|
4711
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
4712
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
4713
|
+
_b = errorCode;
|
|
4714
|
+
switch (_b) {
|
|
4715
|
+
case "AccessDeniedException": return [3, 2];
|
|
4716
|
+
case "com.amazonaws.macie2#AccessDeniedException": return [3, 2];
|
|
4717
|
+
case "InternalServerException": return [3, 4];
|
|
4718
|
+
case "com.amazonaws.macie2#InternalServerException": return [3, 4];
|
|
4719
|
+
case "ThrottlingException": return [3, 6];
|
|
4720
|
+
case "com.amazonaws.macie2#ThrottlingException": return [3, 6];
|
|
4721
|
+
case "ValidationException": return [3, 8];
|
|
4722
|
+
case "com.amazonaws.macie2#ValidationException": return [3, 8];
|
|
4723
|
+
}
|
|
4724
|
+
return [3, 10];
|
|
4725
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
4726
|
+
case 3: throw _d.sent();
|
|
4727
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
4728
|
+
case 5: throw _d.sent();
|
|
4729
|
+
case 6: return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
4730
|
+
case 7: throw _d.sent();
|
|
4731
|
+
case 8: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
4732
|
+
case 9: throw _d.sent();
|
|
4733
|
+
case 10:
|
|
4734
|
+
parsedBody = parsedOutput.body;
|
|
4735
|
+
$metadata = deserializeMetadata(output);
|
|
4736
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
4737
|
+
response = new __BaseException({
|
|
4738
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
4739
|
+
$fault: "client",
|
|
4740
|
+
$metadata: $metadata,
|
|
4741
|
+
});
|
|
4742
|
+
throw __decorateServiceException(response, parsedBody);
|
|
4743
|
+
}
|
|
4744
|
+
});
|
|
4745
|
+
}); };
|
|
4746
|
+
export var deserializeAws_restJson1GetSensitiveDataOccurrencesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4747
|
+
var contents, data, _a, _b;
|
|
4748
|
+
return __generator(this, function (_c) {
|
|
4749
|
+
switch (_c.label) {
|
|
4750
|
+
case 0:
|
|
4751
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
4752
|
+
return [2, deserializeAws_restJson1GetSensitiveDataOccurrencesCommandError(output, context)];
|
|
4753
|
+
}
|
|
4754
|
+
contents = {
|
|
4755
|
+
$metadata: deserializeMetadata(output),
|
|
4756
|
+
error: undefined,
|
|
4757
|
+
sensitiveDataOccurrences: undefined,
|
|
4758
|
+
status: undefined,
|
|
4759
|
+
};
|
|
4760
|
+
_a = __expectNonNull;
|
|
4761
|
+
_b = __expectObject;
|
|
4762
|
+
return [4, parseBody(output.body, context)];
|
|
4763
|
+
case 1:
|
|
4764
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
4765
|
+
if (data.error !== undefined && data.error !== null) {
|
|
4766
|
+
contents.error = __expectString(data.error);
|
|
4767
|
+
}
|
|
4768
|
+
if (data.sensitiveDataOccurrences !== undefined && data.sensitiveDataOccurrences !== null) {
|
|
4769
|
+
contents.sensitiveDataOccurrences = deserializeAws_restJson1SensitiveDataOccurrences(data.sensitiveDataOccurrences, context);
|
|
4770
|
+
}
|
|
4771
|
+
if (data.status !== undefined && data.status !== null) {
|
|
4772
|
+
contents.status = __expectString(data.status);
|
|
4773
|
+
}
|
|
4774
|
+
return [2, Promise.resolve(contents)];
|
|
4775
|
+
}
|
|
4776
|
+
});
|
|
4777
|
+
}); };
|
|
4778
|
+
var deserializeAws_restJson1GetSensitiveDataOccurrencesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4779
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
4780
|
+
var _c;
|
|
4781
|
+
return __generator(this, function (_d) {
|
|
4782
|
+
switch (_d.label) {
|
|
4783
|
+
case 0:
|
|
4784
|
+
_a = [__assign({}, output)];
|
|
4785
|
+
_c = {};
|
|
4786
|
+
return [4, parseBody(output.body, context)];
|
|
4787
|
+
case 1:
|
|
4788
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
4789
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
4790
|
+
_b = errorCode;
|
|
4791
|
+
switch (_b) {
|
|
4792
|
+
case "AccessDeniedException": return [3, 2];
|
|
4793
|
+
case "com.amazonaws.macie2#AccessDeniedException": return [3, 2];
|
|
4794
|
+
case "InternalServerException": return [3, 4];
|
|
4795
|
+
case "com.amazonaws.macie2#InternalServerException": return [3, 4];
|
|
4796
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
4797
|
+
case "com.amazonaws.macie2#ResourceNotFoundException": return [3, 6];
|
|
4798
|
+
case "ServiceQuotaExceededException": return [3, 8];
|
|
4799
|
+
case "com.amazonaws.macie2#ServiceQuotaExceededException": return [3, 8];
|
|
4800
|
+
case "ThrottlingException": return [3, 10];
|
|
4801
|
+
case "com.amazonaws.macie2#ThrottlingException": return [3, 10];
|
|
4802
|
+
case "UnprocessableEntityException": return [3, 12];
|
|
4803
|
+
case "com.amazonaws.macie2#UnprocessableEntityException": return [3, 12];
|
|
4804
|
+
}
|
|
4805
|
+
return [3, 14];
|
|
4806
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
4807
|
+
case 3: throw _d.sent();
|
|
4808
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
4809
|
+
case 5: throw _d.sent();
|
|
4810
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
4811
|
+
case 7: throw _d.sent();
|
|
4812
|
+
case 8: return [4, deserializeAws_restJson1ServiceQuotaExceededExceptionResponse(parsedOutput, context)];
|
|
4813
|
+
case 9: throw _d.sent();
|
|
4814
|
+
case 10: return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
4815
|
+
case 11: throw _d.sent();
|
|
4816
|
+
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
4817
|
+
case 13: throw _d.sent();
|
|
4818
|
+
case 14:
|
|
4819
|
+
parsedBody = parsedOutput.body;
|
|
4820
|
+
$metadata = deserializeMetadata(output);
|
|
4821
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
4822
|
+
response = new __BaseException({
|
|
4823
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
4824
|
+
$fault: "client",
|
|
4825
|
+
$metadata: $metadata,
|
|
4826
|
+
});
|
|
4827
|
+
throw __decorateServiceException(response, parsedBody);
|
|
4828
|
+
}
|
|
4829
|
+
});
|
|
4830
|
+
}); };
|
|
4831
|
+
export var deserializeAws_restJson1GetSensitiveDataOccurrencesAvailabilityCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4832
|
+
var contents, data, _a, _b;
|
|
4833
|
+
return __generator(this, function (_c) {
|
|
4834
|
+
switch (_c.label) {
|
|
4835
|
+
case 0:
|
|
4836
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
4837
|
+
return [2, deserializeAws_restJson1GetSensitiveDataOccurrencesAvailabilityCommandError(output, context)];
|
|
4838
|
+
}
|
|
4839
|
+
contents = {
|
|
4840
|
+
$metadata: deserializeMetadata(output),
|
|
4841
|
+
code: undefined,
|
|
4842
|
+
reasons: undefined,
|
|
4843
|
+
};
|
|
4844
|
+
_a = __expectNonNull;
|
|
4845
|
+
_b = __expectObject;
|
|
4846
|
+
return [4, parseBody(output.body, context)];
|
|
4847
|
+
case 1:
|
|
4848
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
4849
|
+
if (data.code !== undefined && data.code !== null) {
|
|
4850
|
+
contents.code = __expectString(data.code);
|
|
4851
|
+
}
|
|
4852
|
+
if (data.reasons !== undefined && data.reasons !== null) {
|
|
4853
|
+
contents.reasons = deserializeAws_restJson1__listOfUnavailabilityReasonCode(data.reasons, context);
|
|
4854
|
+
}
|
|
4855
|
+
return [2, Promise.resolve(contents)];
|
|
4856
|
+
}
|
|
4857
|
+
});
|
|
4858
|
+
}); };
|
|
4859
|
+
var deserializeAws_restJson1GetSensitiveDataOccurrencesAvailabilityCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4860
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
4861
|
+
var _c;
|
|
4862
|
+
return __generator(this, function (_d) {
|
|
4863
|
+
switch (_d.label) {
|
|
4864
|
+
case 0:
|
|
4865
|
+
_a = [__assign({}, output)];
|
|
4866
|
+
_c = {};
|
|
4867
|
+
return [4, parseBody(output.body, context)];
|
|
4868
|
+
case 1:
|
|
4869
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
4870
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
4871
|
+
_b = errorCode;
|
|
4872
|
+
switch (_b) {
|
|
4873
|
+
case "AccessDeniedException": return [3, 2];
|
|
4874
|
+
case "com.amazonaws.macie2#AccessDeniedException": return [3, 2];
|
|
4875
|
+
case "InternalServerException": return [3, 4];
|
|
4876
|
+
case "com.amazonaws.macie2#InternalServerException": return [3, 4];
|
|
4877
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
4878
|
+
case "com.amazonaws.macie2#ResourceNotFoundException": return [3, 6];
|
|
4879
|
+
case "ThrottlingException": return [3, 8];
|
|
4880
|
+
case "com.amazonaws.macie2#ThrottlingException": return [3, 8];
|
|
4881
|
+
}
|
|
4882
|
+
return [3, 10];
|
|
4883
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
4884
|
+
case 3: throw _d.sent();
|
|
4885
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
4886
|
+
case 5: throw _d.sent();
|
|
4887
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
4888
|
+
case 7: throw _d.sent();
|
|
4889
|
+
case 8: return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
4890
|
+
case 9: throw _d.sent();
|
|
4891
|
+
case 10:
|
|
4892
|
+
parsedBody = parsedOutput.body;
|
|
4893
|
+
$metadata = deserializeMetadata(output);
|
|
4894
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
4895
|
+
response = new __BaseException({
|
|
4896
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
4897
|
+
$fault: "client",
|
|
4898
|
+
$metadata: $metadata,
|
|
4899
|
+
});
|
|
4900
|
+
throw __decorateServiceException(response, parsedBody);
|
|
4901
|
+
}
|
|
4902
|
+
});
|
|
4903
|
+
}); };
|
|
4565
4904
|
export var deserializeAws_restJson1GetUsageStatisticsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
4566
4905
|
var contents, data, _a, _b;
|
|
4567
4906
|
return __generator(this, function (_c) {
|
|
@@ -6238,6 +6577,75 @@ var deserializeAws_restJson1UpdateOrganizationConfigurationCommandError = functi
|
|
|
6238
6577
|
}
|
|
6239
6578
|
});
|
|
6240
6579
|
}); };
|
|
6580
|
+
export var deserializeAws_restJson1UpdateRevealConfigurationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
6581
|
+
var contents, data, _a, _b;
|
|
6582
|
+
return __generator(this, function (_c) {
|
|
6583
|
+
switch (_c.label) {
|
|
6584
|
+
case 0:
|
|
6585
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
6586
|
+
return [2, deserializeAws_restJson1UpdateRevealConfigurationCommandError(output, context)];
|
|
6587
|
+
}
|
|
6588
|
+
contents = {
|
|
6589
|
+
$metadata: deserializeMetadata(output),
|
|
6590
|
+
configuration: undefined,
|
|
6591
|
+
};
|
|
6592
|
+
_a = __expectNonNull;
|
|
6593
|
+
_b = __expectObject;
|
|
6594
|
+
return [4, parseBody(output.body, context)];
|
|
6595
|
+
case 1:
|
|
6596
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
6597
|
+
if (data.configuration !== undefined && data.configuration !== null) {
|
|
6598
|
+
contents.configuration = deserializeAws_restJson1RevealConfiguration(data.configuration, context);
|
|
6599
|
+
}
|
|
6600
|
+
return [2, Promise.resolve(contents)];
|
|
6601
|
+
}
|
|
6602
|
+
});
|
|
6603
|
+
}); };
|
|
6604
|
+
var deserializeAws_restJson1UpdateRevealConfigurationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
6605
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
6606
|
+
var _c;
|
|
6607
|
+
return __generator(this, function (_d) {
|
|
6608
|
+
switch (_d.label) {
|
|
6609
|
+
case 0:
|
|
6610
|
+
_a = [__assign({}, output)];
|
|
6611
|
+
_c = {};
|
|
6612
|
+
return [4, parseBody(output.body, context)];
|
|
6613
|
+
case 1:
|
|
6614
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
6615
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
6616
|
+
_b = errorCode;
|
|
6617
|
+
switch (_b) {
|
|
6618
|
+
case "AccessDeniedException": return [3, 2];
|
|
6619
|
+
case "com.amazonaws.macie2#AccessDeniedException": return [3, 2];
|
|
6620
|
+
case "InternalServerException": return [3, 4];
|
|
6621
|
+
case "com.amazonaws.macie2#InternalServerException": return [3, 4];
|
|
6622
|
+
case "ThrottlingException": return [3, 6];
|
|
6623
|
+
case "com.amazonaws.macie2#ThrottlingException": return [3, 6];
|
|
6624
|
+
case "ValidationException": return [3, 8];
|
|
6625
|
+
case "com.amazonaws.macie2#ValidationException": return [3, 8];
|
|
6626
|
+
}
|
|
6627
|
+
return [3, 10];
|
|
6628
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
6629
|
+
case 3: throw _d.sent();
|
|
6630
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
6631
|
+
case 5: throw _d.sent();
|
|
6632
|
+
case 6: return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
|
|
6633
|
+
case 7: throw _d.sent();
|
|
6634
|
+
case 8: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
6635
|
+
case 9: throw _d.sent();
|
|
6636
|
+
case 10:
|
|
6637
|
+
parsedBody = parsedOutput.body;
|
|
6638
|
+
$metadata = deserializeMetadata(output);
|
|
6639
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
6640
|
+
response = new __BaseException({
|
|
6641
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
6642
|
+
$fault: "client",
|
|
6643
|
+
$metadata: $metadata,
|
|
6644
|
+
});
|
|
6645
|
+
throw __decorateServiceException(response, parsedBody);
|
|
6646
|
+
}
|
|
6647
|
+
});
|
|
6648
|
+
}); };
|
|
6241
6649
|
var deserializeAws_restJson1AccessDeniedExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
6242
6650
|
var contents, data, exception;
|
|
6243
6651
|
return __generator(this, function (_a) {
|
|
@@ -6310,6 +6718,18 @@ var deserializeAws_restJson1ThrottlingExceptionResponse = function (parsedOutput
|
|
|
6310
6718
|
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
6311
6719
|
});
|
|
6312
6720
|
}); };
|
|
6721
|
+
var deserializeAws_restJson1UnprocessableEntityExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
6722
|
+
var contents, data, exception;
|
|
6723
|
+
return __generator(this, function (_a) {
|
|
6724
|
+
contents = {};
|
|
6725
|
+
data = parsedOutput.body;
|
|
6726
|
+
if (data.message !== undefined && data.message !== null) {
|
|
6727
|
+
contents.message = __expectString(data.message);
|
|
6728
|
+
}
|
|
6729
|
+
exception = new UnprocessableEntityException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
6730
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
6731
|
+
});
|
|
6732
|
+
}); };
|
|
6313
6733
|
var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
6314
6734
|
var contents, data, exception;
|
|
6315
6735
|
return __generator(this, function (_a) {
|
|
@@ -6525,6 +6945,9 @@ var serializeAws_restJson1ListJobsSortCriteria = function (input, context) {
|
|
|
6525
6945
|
var serializeAws_restJson1MonthlySchedule = function (input, context) {
|
|
6526
6946
|
return __assign({}, (input.dayOfMonth != null && { dayOfMonth: input.dayOfMonth }));
|
|
6527
6947
|
};
|
|
6948
|
+
var serializeAws_restJson1RevealConfiguration = function (input, context) {
|
|
6949
|
+
return __assign(__assign({}, (input.kmsKeyId != null && { kmsKeyId: input.kmsKeyId })), (input.status != null && { status: input.status }));
|
|
6950
|
+
};
|
|
6528
6951
|
var serializeAws_restJson1S3BucketCriteriaForJob = function (input, context) {
|
|
6529
6952
|
return __assign(__assign({}, (input.excludes != null && { excludes: serializeAws_restJson1CriteriaBlockForJob(input.excludes, context) })), (input.includes != null && { includes: serializeAws_restJson1CriteriaBlockForJob(input.includes, context) }));
|
|
6530
6953
|
};
|
|
@@ -6701,6 +7124,17 @@ var deserializeAws_restJson1__listOfCustomDataIdentifierSummary = function (outp
|
|
|
6701
7124
|
});
|
|
6702
7125
|
return retVal;
|
|
6703
7126
|
};
|
|
7127
|
+
var deserializeAws_restJson1__listOfDetectedDataDetails = function (output, context) {
|
|
7128
|
+
var retVal = (output || [])
|
|
7129
|
+
.filter(function (e) { return e != null; })
|
|
7130
|
+
.map(function (entry) {
|
|
7131
|
+
if (entry === null) {
|
|
7132
|
+
return null;
|
|
7133
|
+
}
|
|
7134
|
+
return deserializeAws_restJson1DetectedDataDetails(entry, context);
|
|
7135
|
+
});
|
|
7136
|
+
return retVal;
|
|
7137
|
+
};
|
|
6704
7138
|
var deserializeAws_restJson1__listOfFinding = function (output, context) {
|
|
6705
7139
|
var retVal = (output || [])
|
|
6706
7140
|
.filter(function (e) { return e != null; })
|
|
@@ -6844,6 +7278,17 @@ var deserializeAws_restJson1__listOfTagValuePair = function (output, context) {
|
|
|
6844
7278
|
});
|
|
6845
7279
|
return retVal;
|
|
6846
7280
|
};
|
|
7281
|
+
var deserializeAws_restJson1__listOfUnavailabilityReasonCode = function (output, context) {
|
|
7282
|
+
var retVal = (output || [])
|
|
7283
|
+
.filter(function (e) { return e != null; })
|
|
7284
|
+
.map(function (entry) {
|
|
7285
|
+
if (entry === null) {
|
|
7286
|
+
return null;
|
|
7287
|
+
}
|
|
7288
|
+
return __expectString(entry);
|
|
7289
|
+
});
|
|
7290
|
+
return retVal;
|
|
7291
|
+
};
|
|
6847
7292
|
var deserializeAws_restJson1__listOfUnprocessedAccount = function (output, context) {
|
|
6848
7293
|
var retVal = (output || [])
|
|
6849
7294
|
.filter(function (e) { return e != null; })
|
|
@@ -7209,6 +7654,11 @@ var deserializeAws_restJson1DefaultDetections = function (output, context) {
|
|
|
7209
7654
|
});
|
|
7210
7655
|
return retVal;
|
|
7211
7656
|
};
|
|
7657
|
+
var deserializeAws_restJson1DetectedDataDetails = function (output, context) {
|
|
7658
|
+
return {
|
|
7659
|
+
value: __expectString(output.value),
|
|
7660
|
+
};
|
|
7661
|
+
};
|
|
7212
7662
|
var deserializeAws_restJson1DomainDetails = function (output, context) {
|
|
7213
7663
|
return {
|
|
7214
7664
|
domainName: __expectString(output.domainName),
|
|
@@ -7566,6 +8016,12 @@ var deserializeAws_restJson1ResourcesAffected = function (output, context) {
|
|
|
7566
8016
|
s3Object: output.s3Object != null ? deserializeAws_restJson1S3Object(output.s3Object, context) : undefined,
|
|
7567
8017
|
};
|
|
7568
8018
|
};
|
|
8019
|
+
var deserializeAws_restJson1RevealConfiguration = function (output, context) {
|
|
8020
|
+
return {
|
|
8021
|
+
kmsKeyId: __expectString(output.kmsKeyId),
|
|
8022
|
+
status: __expectString(output.status),
|
|
8023
|
+
};
|
|
8024
|
+
};
|
|
7569
8025
|
var deserializeAws_restJson1S3Bucket = function (output, context) {
|
|
7570
8026
|
return {
|
|
7571
8027
|
allowsUnencryptedObjectUploads: __expectString(output.allowsUnencryptedObjectUploads),
|
|
@@ -7666,6 +8122,16 @@ var deserializeAws_restJson1SensitiveDataItem = function (output, context) {
|
|
|
7666
8122
|
totalCount: __expectLong(output.totalCount),
|
|
7667
8123
|
};
|
|
7668
8124
|
};
|
|
8125
|
+
var deserializeAws_restJson1SensitiveDataOccurrences = function (output, context) {
|
|
8126
|
+
return Object.entries(output).reduce(function (acc, _a) {
|
|
8127
|
+
var _b;
|
|
8128
|
+
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
8129
|
+
if (value === null) {
|
|
8130
|
+
return acc;
|
|
8131
|
+
}
|
|
8132
|
+
return __assign(__assign({}, acc), (_b = {}, _b[key] = deserializeAws_restJson1__listOfDetectedDataDetails(value, context), _b));
|
|
8133
|
+
}, {});
|
|
8134
|
+
};
|
|
7669
8135
|
var deserializeAws_restJson1ServerSideEncryption = function (output, context) {
|
|
7670
8136
|
return {
|
|
7671
8137
|
encryptionType: __expectString(output.encryptionType),
|
|
@@ -7882,6 +8348,9 @@ var loadRestJsonErrorCode = function (output, data) {
|
|
|
7882
8348
|
var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
|
|
7883
8349
|
var sanitizeErrorCode = function (rawValue) {
|
|
7884
8350
|
var cleanValue = rawValue;
|
|
8351
|
+
if (typeof cleanValue === "number") {
|
|
8352
|
+
cleanValue = cleanValue.toString();
|
|
8353
|
+
}
|
|
7885
8354
|
if (cleanValue.indexOf(":") >= 0) {
|
|
7886
8355
|
cleanValue = cleanValue.split(":")[0];
|
|
7887
8356
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./waitForFindingRevealed";
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
|
+
import { checkExceptions, createWaiter, WaiterState } from "@aws-sdk/util-waiter";
|
|
3
|
+
import { GetSensitiveDataOccurrencesCommand, } from "../commands/GetSensitiveDataOccurrencesCommand";
|
|
4
|
+
var checkState = function (client, input) { return __awaiter(void 0, void 0, void 0, function () {
|
|
5
|
+
var reason, result_1, returnComparator, returnComparator, exception_1;
|
|
6
|
+
return __generator(this, function (_a) {
|
|
7
|
+
switch (_a.label) {
|
|
8
|
+
case 0:
|
|
9
|
+
_a.trys.push([0, 2, , 3]);
|
|
10
|
+
return [4, client.send(new GetSensitiveDataOccurrencesCommand(input))];
|
|
11
|
+
case 1:
|
|
12
|
+
result_1 = _a.sent();
|
|
13
|
+
reason = result_1;
|
|
14
|
+
try {
|
|
15
|
+
returnComparator = function () {
|
|
16
|
+
return result_1.status;
|
|
17
|
+
};
|
|
18
|
+
if (returnComparator() === "SUCCESS") {
|
|
19
|
+
return [2, { state: WaiterState.SUCCESS, reason: reason }];
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
catch (e) { }
|
|
23
|
+
try {
|
|
24
|
+
returnComparator = function () {
|
|
25
|
+
return result_1.status;
|
|
26
|
+
};
|
|
27
|
+
if (returnComparator() === "ERROR") {
|
|
28
|
+
return [2, { state: WaiterState.SUCCESS, reason: reason }];
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
catch (e) { }
|
|
32
|
+
return [3, 3];
|
|
33
|
+
case 2:
|
|
34
|
+
exception_1 = _a.sent();
|
|
35
|
+
reason = exception_1;
|
|
36
|
+
return [3, 3];
|
|
37
|
+
case 3: return [2, { state: WaiterState.RETRY, reason: reason }];
|
|
38
|
+
}
|
|
39
|
+
});
|
|
40
|
+
}); };
|
|
41
|
+
export var waitForFindingRevealed = function (params, input) { return __awaiter(void 0, void 0, void 0, function () {
|
|
42
|
+
var serviceDefaults;
|
|
43
|
+
return __generator(this, function (_a) {
|
|
44
|
+
serviceDefaults = { minDelay: 2, maxDelay: 120 };
|
|
45
|
+
return [2, createWaiter(__assign(__assign({}, serviceDefaults), params), input, checkState)];
|
|
46
|
+
});
|
|
47
|
+
}); };
|
|
48
|
+
export var waitUntilFindingRevealed = function (params, input) { return __awaiter(void 0, void 0, void 0, function () {
|
|
49
|
+
var serviceDefaults, result;
|
|
50
|
+
return __generator(this, function (_a) {
|
|
51
|
+
switch (_a.label) {
|
|
52
|
+
case 0:
|
|
53
|
+
serviceDefaults = { minDelay: 2, maxDelay: 120 };
|
|
54
|
+
return [4, createWaiter(__assign(__assign({}, serviceDefaults), params), input, checkState)];
|
|
55
|
+
case 1:
|
|
56
|
+
result = _a.sent();
|
|
57
|
+
return [2, checkExceptions(result)];
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
}); };
|