Skip to content

Commit 7fbd215

Browse files
author
awstools
committed
feat(client-connect): This release adds Hierarchy based Access Control fields to Security Profile public APIs and adds support for UserAttributeFilter to SearchUsers API.
1 parent b6e079d commit 7fbd215

File tree

9 files changed

+286
-8
lines changed

9 files changed

+286
-8
lines changed

clients/client-connect/src/commands/CreateSecurityProfileCommand.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@ export interface CreateSecurityProfileCommandOutput extends CreateSecurityProfil
5858
* ],
5959
* },
6060
* ],
61+
* HierarchyRestrictedResources: [ // HierarchyRestrictedResourceList
62+
* "STRING_VALUE",
63+
* ],
64+
* AllowedAccessControlHierarchyGroupId: "STRING_VALUE",
6165
* };
6266
* const command = new CreateSecurityProfileCommand(input);
6367
* const response = await client.send(command);

clients/client-connect/src/commands/DescribeSecurityProfileCommand.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@ export interface DescribeSecurityProfileCommandOutput extends DescribeSecurityPr
5858
* // ],
5959
* // LastModifiedTime: new Date("TIMESTAMP"),
6060
* // LastModifiedRegion: "STRING_VALUE",
61+
* // HierarchyRestrictedResources: [ // HierarchyRestrictedResourceList
62+
* // "STRING_VALUE",
63+
* // ],
64+
* // AllowedAccessControlHierarchyGroupId: "STRING_VALUE",
6165
* // },
6266
* // };
6367
*

clients/client-connect/src/commands/SearchUsersCommand.ts

Lines changed: 22 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,26 @@ export interface SearchUsersCommandOutput extends SearchUsersResponse, __Metadat
6060
* ],
6161
* TagCondition: "<TagCondition>",
6262
* },
63+
* UserAttributeFilter: { // ControlPlaneUserAttributeFilter
64+
* OrConditions: [ // AttributeOrConditionList
65+
* { // AttributeAndCondition
66+
* TagConditions: "<TagAndConditionList>",
67+
* HierarchyGroupCondition: { // HierarchyGroupCondition
68+
* Value: "STRING_VALUE",
69+
* HierarchyGroupMatchType: "EXACT" || "WITH_CHILD_GROUPS",
70+
* },
71+
* },
72+
* ],
73+
* AndCondition: {
74+
* TagConditions: "<TagAndConditionList>",
75+
* HierarchyGroupCondition: {
76+
* Value: "STRING_VALUE",
77+
* HierarchyGroupMatchType: "EXACT" || "WITH_CHILD_GROUPS",
78+
* },
79+
* },
80+
* TagCondition: "<TagCondition>",
81+
* HierarchyGroupCondition: "<HierarchyGroupCondition>",
82+
* },
6383
* },
6484
* SearchCriteria: { // UserSearchCriteria
6585
* OrConditions: [ // UserSearchConditionList
@@ -75,10 +95,7 @@ export interface SearchUsersCommandOutput extends SearchUsersResponse, __Metadat
7595
* Value: "STRING_VALUE",
7696
* ComparisonType: "STARTS_WITH" || "CONTAINS" || "EXACT",
7797
* },
78-
* HierarchyGroupCondition: { // HierarchyGroupCondition
79-
* Value: "STRING_VALUE",
80-
* HierarchyGroupMatchType: "EXACT" || "WITH_CHILD_GROUPS",
81-
* },
98+
* HierarchyGroupCondition: "<HierarchyGroupCondition>",
8299
* },
83100
* ],
84101
* AndConditions: [
@@ -89,10 +106,7 @@ export interface SearchUsersCommandOutput extends SearchUsersResponse, __Metadat
89106
* Value: "STRING_VALUE",
90107
* ComparisonType: "STARTS_WITH" || "CONTAINS" || "EXACT",
91108
* },
92-
* HierarchyGroupCondition: {
93-
* Value: "STRING_VALUE",
94-
* HierarchyGroupMatchType: "EXACT" || "WITH_CHILD_GROUPS",
95-
* },
109+
* HierarchyGroupCondition: "<HierarchyGroupCondition>",
96110
* },
97111
* };
98112
* const command = new SearchUsersCommand(input);

clients/client-connect/src/commands/UpdateSecurityProfileCommand.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@ export interface UpdateSecurityProfileCommandOutput extends __MetadataBearer {}
5555
* ],
5656
* },
5757
* ],
58+
* HierarchyRestrictedResources: [ // HierarchyRestrictedResourceList
59+
* "STRING_VALUE",
60+
* ],
61+
* AllowedAccessControlHierarchyGroupId: "STRING_VALUE",
5862
* };
5963
* const command = new UpdateSecurityProfileCommand(input);
6064
* const response = await client.send(command);

clients/client-connect/src/models/models_0.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4388,6 +4388,18 @@ export interface CreateSecurityProfileRequest {
43884388
* @public
43894389
*/
43904390
Applications?: Application[];
4391+
4392+
/**
4393+
* <p>The list of resources that a security profile applies hierarchy restrictions to in Amazon Connect. Following are acceptable ResourceNames: <code>User</code>.</p>
4394+
* @public
4395+
*/
4396+
HierarchyRestrictedResources?: string[];
4397+
4398+
/**
4399+
* <p>The identifier of the hierarchy group that a security profile uses to restrict access to resources in Amazon Connect.</p>
4400+
* @public
4401+
*/
4402+
AllowedAccessControlHierarchyGroupId?: string;
43914403
}
43924404

43934405
/**

clients/client-connect/src/models/models_1.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -888,6 +888,19 @@ export interface SecurityProfile {
888888
* @public
889889
*/
890890
LastModifiedRegion?: string;
891+
892+
/**
893+
* <p>The list of resources that a security profile applies hierarchy restrictions to in Amazon Connect. Following are acceptable ResourceNames: <code>User</code>.</p>
894+
* @public
895+
*/
896+
HierarchyRestrictedResources?: string[];
897+
898+
/**
899+
* <p>The identifier of the hierarchy group that a security profile uses to restrict access to
900+
* resources in Amazon Connect.</p>
901+
* @public
902+
*/
903+
AllowedAccessControlHierarchyGroupId?: string;
891904
}
892905

893906
/**

clients/client-connect/src/models/models_2.ts

Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -911,6 +911,74 @@ export interface HierarchyGroupCondition {
911911
HierarchyGroupMatchType?: HierarchyGroupMatchType;
912912
}
913913

914+
/**
915+
* <p>A list of conditions which would be applied together with an <code>AND</code>
916+
* condition.</p>
917+
* @public
918+
*/
919+
export interface AttributeAndCondition {
920+
/**
921+
* <p>A leaf node condition which can be used to specify a tag condition.</p>
922+
* @public
923+
*/
924+
TagConditions?: TagCondition[];
925+
926+
/**
927+
* <p>A leaf node condition which can be used to specify a hierarchy group condition.</p>
928+
* @public
929+
*/
930+
HierarchyGroupCondition?: HierarchyGroupCondition;
931+
}
932+
933+
/**
934+
* <p>An object that can be used to specify Tag conditions or Hierarchy Group conditions inside
935+
* the <code>SearchFilter</code>.</p>
936+
* <p>This accepts an <code>OR</code> of <code>AND</code> (List of List) input where:</p>
937+
* <ul>
938+
* <li>
939+
* <p>The top level list specifies conditions that need to be applied with <code>OR</code>
940+
* operator</p>
941+
* </li>
942+
* <li>
943+
* <p>The inner list specifies conditions that need to be applied with <code>AND</code>
944+
* operator.</p>
945+
* </li>
946+
* </ul>
947+
* <note>
948+
* <p>Only one field can be populated. Maximum number of allowed Tag conditions is 25. Maximum
949+
* number of allowed Hierarchy Group conditions is 20. </p>
950+
* </note>
951+
* @public
952+
*/
953+
export interface ControlPlaneUserAttributeFilter {
954+
/**
955+
* <p>A list of conditions which would be applied together with an <code>OR</code>
956+
* condition.</p>
957+
* @public
958+
*/
959+
OrConditions?: AttributeAndCondition[];
960+
961+
/**
962+
* <p>A list of conditions which would be applied together with an <code>AND</code>
963+
* condition.</p>
964+
* @public
965+
*/
966+
AndCondition?: AttributeAndCondition;
967+
968+
/**
969+
* <p>A leaf node condition which can be used to specify a tag condition, for example, <code>HAVE
970+
* BPO = 123</code>. </p>
971+
* @public
972+
*/
973+
TagCondition?: TagCondition;
974+
975+
/**
976+
* <p>A leaf node condition which can be used to specify a hierarchy group condition.</p>
977+
* @public
978+
*/
979+
HierarchyGroupCondition?: HierarchyGroupCondition;
980+
}
981+
914982
/**
915983
* <p>Filters to be applied to search results.</p>
916984
* @public
@@ -932,6 +1000,29 @@ export interface UserSearchFilter {
9321000
* @public
9331001
*/
9341002
TagFilter?: ControlPlaneTagFilter;
1003+
1004+
/**
1005+
* <p>An object that can be used to specify Tag conditions or Hierarchy Group conditions inside
1006+
* the SearchFilter.</p>
1007+
* <p>This accepts an <code>OR</code> of <code>AND</code> (List of List) input where:</p>
1008+
* <ul>
1009+
* <li>
1010+
* <p>The top level list specifies conditions that need to be applied with <code>OR</code>
1011+
* operator.</p>
1012+
* </li>
1013+
* <li>
1014+
* <p>The inner list specifies conditions that need to be applied with <code>AND</code>
1015+
* operator.</p>
1016+
* </li>
1017+
* </ul>
1018+
* <note>
1019+
* <p>Only one field can be populated. This object can’t be used along with TagFilter. Request
1020+
* can either contain TagFilter or UserAttributeFilter if SearchFilter is specified, combination of
1021+
* both is not supported and such request will throw AccessDeniedException.</p>
1022+
* </note>
1023+
* @public
1024+
*/
1025+
UserAttributeFilter?: ControlPlaneUserAttributeFilter;
9351026
}
9361027

9371028
/**
@@ -3968,6 +4059,18 @@ export interface UpdateSecurityProfileRequest {
39684059
* @public
39694060
*/
39704061
Applications?: Application[];
4062+
4063+
/**
4064+
* <p>The list of resources that a security profile applies hierarchy restrictions to in Amazon Connect. Following are acceptable ResourceNames: <code>User</code>.</p>
4065+
* @public
4066+
*/
4067+
HierarchyRestrictedResources?: string[];
4068+
4069+
/**
4070+
* <p>The identifier of the hierarchy group that a security profile uses to restrict access to resources in Amazon Connect.</p>
4071+
* @public
4072+
*/
4073+
AllowedAccessControlHierarchyGroupId?: string;
39714074
}
39724075

39734076
/**

clients/client-connect/src/protocols/Aws_restJson1.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -897,6 +897,7 @@ import {
897897
} from "../models/models_1";
898898
import {
899899
AnswerMachineDetectionConfig,
900+
AttributeAndCondition,
900901
ChatEvent,
901902
ChatMessage,
902903
ChatParticipantRoleConfig,
@@ -906,6 +907,7 @@ import {
906907
ContactSearchSummaryAgentInfo,
907908
ContactSearchSummaryQueueInfo,
908909
ControlPlaneTagFilter,
910+
ControlPlaneUserAttributeFilter,
909911
DestinationNotAllowedException,
910912
DisconnectReason,
911913
EvaluationAnswerInput,
@@ -1849,9 +1851,11 @@ export const se_CreateSecurityProfileCommand = async (
18491851
let body: any;
18501852
body = JSON.stringify(
18511853
take(input, {
1854+
AllowedAccessControlHierarchyGroupId: [],
18521855
AllowedAccessControlTags: (_) => _json(_),
18531856
Applications: (_) => _json(_),
18541857
Description: [],
1858+
HierarchyRestrictedResources: (_) => _json(_),
18551859
Permissions: (_) => _json(_),
18561860
SecurityProfileName: [],
18571861
TagRestrictedResources: (_) => _json(_),
@@ -6151,9 +6155,11 @@ export const se_UpdateSecurityProfileCommand = async (
61516155
let body: any;
61526156
body = JSON.stringify(
61536157
take(input, {
6158+
AllowedAccessControlHierarchyGroupId: [],
61546159
AllowedAccessControlTags: (_) => _json(_),
61556160
Applications: (_) => _json(_),
61566161
Description: [],
6162+
HierarchyRestrictedResources: (_) => _json(_),
61576163
Permissions: (_) => _json(_),
61586164
TagRestrictedResources: (_) => _json(_),
61596165
})
@@ -11944,6 +11950,10 @@ const de_UserNotFoundExceptionRes = async (
1194411950

1194511951
// se_AssignContactCategoryActionDefinition omitted.
1194611952

11953+
// se_AttributeAndCondition omitted.
11954+
11955+
// se_AttributeOrConditionList omitted.
11956+
1194711957
// se_Attributes omitted.
1194811958

1194911959
// se_Campaign omitted.
@@ -11976,6 +11986,8 @@ const de_UserNotFoundExceptionRes = async (
1197611986

1197711987
// se_ControlPlaneTagFilter omitted.
1197811988

11989+
// se_ControlPlaneUserAttributeFilter omitted.
11990+
1197911991
/**
1198011992
* serializeAws_restJson1CreateCaseActionDefinition
1198111993
*/
@@ -12177,6 +12189,8 @@ const se_FieldValueUnion = (input: FieldValueUnion, context: __SerdeContext): an
1217712189

1217812190
// se_HierarchyLevelUpdate omitted.
1217912191

12192+
// se_HierarchyRestrictedResourceList omitted.
12193+
1218012194
// se_HierarchyStructureUpdate omitted.
1218112195

1218212196
/**
@@ -13495,6 +13509,8 @@ const de_HierarchyPath = (output: any, context: __SerdeContext): HierarchyPath =
1349513509

1349613510
// de_HierarchyPathReference omitted.
1349713511

13512+
// de_HierarchyRestrictedResourceList omitted.
13513+
1349813514
/**
1349913515
* deserializeAws_restJson1HierarchyStructure
1350013516
*/
@@ -14381,9 +14397,11 @@ const de_SecurityKeysList = (output: any, context: __SerdeContext): SecurityKey[
1438114397
*/
1438214398
const de_SecurityProfile = (output: any, context: __SerdeContext): SecurityProfile => {
1438314399
return take(output, {
14400+
AllowedAccessControlHierarchyGroupId: __expectString,
1438414401
AllowedAccessControlTags: _json,
1438514402
Arn: __expectString,
1438614403
Description: __expectString,
14404+
HierarchyRestrictedResources: _json,
1438714405
Id: __expectString,
1438814406
LastModifiedRegion: __expectString,
1438914407
LastModifiedTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),

0 commit comments

Comments
 (0)