Skip to content

Commit a8d9582

Browse files
author
awstools
committed
feat(client-mpa): Updates to multi-party approval (MPA) service to add support for multi-factor authentication (MFA) for voting operations.
1 parent 37623f4 commit a8d9582

File tree

13 files changed

+4613
-4360
lines changed

13 files changed

+4613
-4360
lines changed

clients/client-mpa/src/commands/GetApprovalTeamCommand.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ export interface GetApprovalTeamCommandOutput extends GetApprovalTeamResponse, _
5656
* // PrimaryIdentityId: "STRING_VALUE",
5757
* // PrimaryIdentitySourceArn: "STRING_VALUE",
5858
* // PrimaryIdentityStatus: "PENDING" || "ACCEPTED" || "REJECTED" || "INVALID",
59+
* // MfaMethods: [ // MfaMethods
60+
* // { // MfaMethod
61+
* // Type: "EMAIL_OTP", // required
62+
* // SyncStatus: "IN_SYNC" || "OUT_OF_SYNC", // required
63+
* // },
64+
* // ],
5965
* // },
6066
* // ],
6167
* // Arn: "STRING_VALUE",
@@ -91,6 +97,12 @@ export interface GetApprovalTeamCommandOutput extends GetApprovalTeamResponse, _
9197
* // PrimaryIdentityId: "STRING_VALUE",
9298
* // PrimaryIdentitySourceArn: "STRING_VALUE",
9399
* // PrimaryIdentityStatus: "PENDING" || "ACCEPTED" || "REJECTED" || "INVALID",
100+
* // MfaMethods: [
101+
* // {
102+
* // Type: "EMAIL_OTP", // required
103+
* // SyncStatus: "IN_SYNC" || "OUT_OF_SYNC", // required
104+
* // },
105+
* // ],
94106
* // },
95107
* // ],
96108
* // UpdateInitiationTime: new Date("TIMESTAMP"),

clients/client-mpa/src/commands/GetPolicyVersionCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export interface GetPolicyVersionCommandInput extends GetPolicyVersionRequest {}
2727
export interface GetPolicyVersionCommandOutput extends GetPolicyVersionResponse, __MetadataBearer {}
2828

2929
/**
30-
* <p>Returns details for the version of a policy. Policies define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
30+
* <p>Returns details for the version of a policy. Policies define the permissions for team resources.</p>
3131
* @example
3232
* Use a bare-bones client and the command you need to make an API call.
3333
* ```javascript

clients/client-mpa/src/commands/GetSessionCommand.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,9 @@ export interface GetSessionCommandOutput extends GetSessionResponse, __MetadataB
7979
* // ResponseTime: new Date("TIMESTAMP"),
8080
* // },
8181
* // ],
82+
* // AdditionalSecurityRequirements: [ // AdditionalSecurityRequirements
83+
* // "APPROVER_VERIFICATION_REQUIRED",
84+
* // ],
8285
* // };
8386
*
8487
* ```

clients/client-mpa/src/commands/ListPoliciesCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export interface ListPoliciesCommandInput extends ListPoliciesRequest {}
2727
export interface ListPoliciesCommandOutput extends ListPoliciesResponse, __MetadataBearer {}
2828

2929
/**
30-
* <p>Returns a list of policies. Policies define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
30+
* <p>Returns a list of policies. Policies define the permissions for team resources.</p>
3131
* @example
3232
* Use a bare-bones client and the command you need to make an API call.
3333
* ```javascript

clients/client-mpa/src/commands/ListPolicyVersionsCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export interface ListPolicyVersionsCommandInput extends ListPolicyVersionsReques
2727
export interface ListPolicyVersionsCommandOutput extends ListPolicyVersionsResponse, __MetadataBearer {}
2828

2929
/**
30-
* <p>Returns a list of the versions for policies. Policies define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
30+
* <p>Returns a list of the versions for policies. Policies define the permissions for team resources.</p>
3131
* @example
3232
* Use a bare-bones client and the command you need to make an API call.
3333
* ```javascript

clients/client-mpa/src/commands/ListSessionsCommand.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,9 @@ export interface ListSessionsCommandOutput extends ListSessionsResponse, __Metad
7171
* // StatusCode: "REJECTED" || "EXPIRED" || "CONFIGURATION_CHANGED",
7272
* // StatusMessage: "STRING_VALUE",
7373
* // ActionCompletionStrategy: "AUTO_COMPLETION_UPON_APPROVAL",
74+
* // AdditionalSecurityRequirements: [ // AdditionalSecurityRequirements
75+
* // "APPROVER_VERIFICATION_REQUIRED",
76+
* // ],
7477
* // },
7578
* // ],
7679
* // };

clients/client-mpa/src/commands/UpdateApprovalTeamCommand.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ export interface UpdateApprovalTeamCommandOutput extends UpdateApprovalTeamRespo
5050
* ],
5151
* Description: "STRING_VALUE",
5252
* Arn: "STRING_VALUE", // required
53+
* UpdateActions: [ // UpdateActions
54+
* "SYNCHRONIZE_MFA_DEVICES",
55+
* ],
5356
* };
5457
* const command = new UpdateApprovalTeamCommand(input);
5558
* const response = await client.send(command);

clients/client-mpa/src/models/enums.ts

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,44 @@ export const ActionCompletionStrategy = {
1111
*/
1212
export type ActionCompletionStrategy = (typeof ActionCompletionStrategy)[keyof typeof ActionCompletionStrategy];
1313

14+
/**
15+
* @public
16+
* @enum
17+
*/
18+
export const AdditionalSecurityRequirement = {
19+
APPROVER_VERIFICATION_REQUIRED: "APPROVER_VERIFICATION_REQUIRED",
20+
} as const;
21+
/**
22+
* @public
23+
*/
24+
export type AdditionalSecurityRequirement =
25+
(typeof AdditionalSecurityRequirement)[keyof typeof AdditionalSecurityRequirement];
26+
27+
/**
28+
* @public
29+
* @enum
30+
*/
31+
export const MfaSyncStatus = {
32+
IN_SYNC: "IN_SYNC",
33+
OUT_OF_SYNC: "OUT_OF_SYNC",
34+
} as const;
35+
/**
36+
* @public
37+
*/
38+
export type MfaSyncStatus = (typeof MfaSyncStatus)[keyof typeof MfaSyncStatus];
39+
40+
/**
41+
* @public
42+
* @enum
43+
*/
44+
export const MfaType = {
45+
EMAIL_OTP: "EMAIL_OTP",
46+
} as const;
47+
/**
48+
* @public
49+
*/
50+
export type MfaType = (typeof MfaType)[keyof typeof MfaType];
51+
1452
/**
1553
* @public
1654
* @enum
@@ -64,6 +102,18 @@ export const ApprovalTeamStatusCode = {
64102
*/
65103
export type ApprovalTeamStatusCode = (typeof ApprovalTeamStatusCode)[keyof typeof ApprovalTeamStatusCode];
66104

105+
/**
106+
* @public
107+
* @enum
108+
*/
109+
export const UpdateAction = {
110+
SYNCHRONIZE_MFA_DEVICES: "SYNCHRONIZE_MFA_DEVICES",
111+
} as const;
112+
/**
113+
* @public
114+
*/
115+
export type UpdateAction = (typeof UpdateAction)[keyof typeof UpdateAction];
116+
67117
/**
68118
* @public
69119
* @enum

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

Lines changed: 57 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,24 @@
11
// smithy-typescript generated code
22
import {
33
ActionCompletionStrategy,
4+
AdditionalSecurityRequirement,
45
ApprovalTeamStatus,
56
ApprovalTeamStatusCode,
67
FilterField,
78
IdentitySourceStatus,
89
IdentitySourceStatusCode,
910
IdentitySourceType,
1011
IdentityStatus,
12+
MfaSyncStatus,
13+
MfaType,
1114
Operator,
1215
PolicyStatus,
1316
PolicyType,
1417
SessionExecutionStatus,
1518
SessionResponse,
1619
SessionStatus,
1720
SessionStatusCode,
21+
UpdateAction,
1822
} from "./enums";
1923

2024
/**
@@ -126,7 +130,7 @@ export interface ApprovalTeamRequestApprover {
126130
}
127131

128132
/**
129-
* <p>Contains the Amazon Resource Name (ARN) for a policy. Policies define what operations a team that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
133+
* <p>Contains the Amazon Resource Name (ARN) for a policy. Policies define what operations a team that define the permissions for team resources.</p>
130134
* @public
131135
*/
132136
export interface PolicyReference {
@@ -166,7 +170,7 @@ export interface CreateApprovalTeamRequest {
166170
Description: string | undefined;
167171

168172
/**
169-
* <p>An array of <code>PolicyReference</code> objects. Contains a list of policies that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
173+
* <p>An array of <code>PolicyReference</code> objects. Contains a list of policies that define the permissions for team resources.</p>
170174
* @public
171175
*/
172176
Policies: PolicyReference[] | undefined;
@@ -246,6 +250,24 @@ export interface GetApprovalTeamRequest {
246250
Arn: string | undefined;
247251
}
248252

253+
/**
254+
* <p>MFA configuration and sycnronization status for an approver</p>
255+
* @public
256+
*/
257+
export interface MfaMethod {
258+
/**
259+
* <p>The type of MFA configuration used by the approver</p>
260+
* @public
261+
*/
262+
Type: MfaType | undefined;
263+
264+
/**
265+
* <p>Indicates if the approver's MFA device is in-sync with the Identity Source</p>
266+
* @public
267+
*/
268+
SyncStatus: MfaSyncStatus | undefined;
269+
}
270+
249271
/**
250272
* <p>Contains details for an approver.</p>
251273
* @public
@@ -280,6 +302,12 @@ export interface GetApprovalTeamResponseApprover {
280302
* @public
281303
*/
282304
PrimaryIdentityStatus?: IdentityStatus | undefined;
305+
306+
/**
307+
* <p>Multi-factor authentication configuration for the approver</p>
308+
* @public
309+
*/
310+
MfaMethods?: MfaMethod[] | undefined;
283311
}
284312

285313
/**
@@ -419,7 +447,7 @@ export interface GetApprovalTeamResponse {
419447
VersionId?: string | undefined;
420448

421449
/**
422-
* <p>An array of <code>PolicyReference</code> objects. Contains a list of policies that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
450+
* <p>An array of <code>PolicyReference</code> objects. Contains a list of policies that define the permissions for team resources.</p>
423451
* @public
424452
*/
425453
Policies?: PolicyReference[] | undefined;
@@ -592,6 +620,12 @@ export interface UpdateApprovalTeamRequest {
592620
* @public
593621
*/
594622
Arn: string | undefined;
623+
624+
/**
625+
* <p>A list of <code>UpdateAction</code> to perform when updating the team.</p>
626+
* @public
627+
*/
628+
UpdateActions?: UpdateAction[] | undefined;
595629
}
596630

597631
/**
@@ -617,7 +651,7 @@ export interface GetPolicyVersionRequest {
617651
}
618652

619653
/**
620-
* <p>Contains details for the version of a policy. Policies define what operations a team that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
654+
* <p>Contains details for the version of a policy. Policies define what operations a team that define the permissions for team resources.</p>
621655
* @public
622656
*/
623657
export interface PolicyVersion {
@@ -658,7 +692,7 @@ export interface PolicyVersion {
658692
Name: string | undefined;
659693

660694
/**
661-
* <p>Status for the policy. For example, if the policy is <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_groups_manage_attach-policy.html">attachable</a> or <a href="https://docs.aws.amazon.com/access_policies_managed-deprecated.html">deprecated</a>.</p>
695+
* <p>Status for the policy. For example, if the policy is <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_groups_manage_attach-policy.html">attachable</a> or <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_managed-deprecated.html">deprecated</a>.</p>
662696
* @public
663697
*/
664698
Status: PolicyStatus | undefined;
@@ -687,7 +721,7 @@ export interface PolicyVersion {
687721
*/
688722
export interface GetPolicyVersionResponse {
689723
/**
690-
* <p>A <code>PolicyVersion</code> object. Contains details for the version of the policy. Policies define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
724+
* <p>A <code>PolicyVersion</code> object. Contains details for the version of the policy. Policies define the permissions for team resources.</p>
691725
* @public
692726
*/
693727
PolicyVersion: PolicyVersion | undefined;
@@ -1122,7 +1156,7 @@ export interface ListPoliciesRequest {
11221156
}
11231157

11241158
/**
1125-
* <p>Contains details for a policy. Policies define what operations a team that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
1159+
* <p>Contains details for a policy. Policies define what operations a team that define the permissions for team resources.</p>
11261160
* @public
11271161
*/
11281162
export interface Policy {
@@ -1162,7 +1196,7 @@ export interface ListPoliciesResponse {
11621196
NextToken?: string | undefined;
11631197

11641198
/**
1165-
* <p>An array of <code>Policy</code> objects. Contains a list of policies that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
1199+
* <p>An array of <code>Policy</code> objects. Contains a list of policies that define the permissions for team resources.</p>
11661200
* @public
11671201
*/
11681202
Policies?: Policy[] | undefined;
@@ -1192,7 +1226,7 @@ export interface ListPolicyVersionsRequest {
11921226
}
11931227

11941228
/**
1195-
* <p>Contains details for the version of a policy. Policies define what operations a team that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
1229+
* <p>Contains details for the version of a policy. Policies define what operations a team that define the permissions for team resources.</p>
11961230
* @public
11971231
*/
11981232
export interface PolicyVersionSummary {
@@ -1233,7 +1267,7 @@ export interface PolicyVersionSummary {
12331267
Name: string | undefined;
12341268

12351269
/**
1236-
* <p>Status for the policy. For example, if the policy is <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_groups_manage_attach-policy.html">attachable</a> or <a href="https://docs.aws.amazon.com/access_policies_managed-deprecated.html">deprecated</a>.</p>
1270+
* <p>Status for the policy. For example, if the policy is <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_groups_manage_attach-policy.html">attachable</a> or <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_managed-deprecated.html">deprecated</a>.</p>
12371271
* @public
12381272
*/
12391273
Status: PolicyStatus | undefined;
@@ -1262,7 +1296,7 @@ export interface ListPolicyVersionsResponse {
12621296
NextToken?: string | undefined;
12631297

12641298
/**
1265-
* <p>An array of <code>PolicyVersionSummary</code> objects. Contains details for the version of the policies that define the permissions for team resources.</p> <p>The protected operation for a service integration might require specific permissions. For more information, see <a href="https://docs.aws.amazon.com/mpa/latest/userguide/mpa-integrations.html">How other services work with Multi-party approval</a> in the <i>Multi-party approval User Guide</i>.</p>
1299+
* <p>An array of <code>PolicyVersionSummary</code> objects. Contains details for the version of the policies that define the permissions for team resources.</p>
12661300
* @public
12671301
*/
12681302
PolicyVersions?: PolicyVersionSummary[] | undefined;
@@ -1558,6 +1592,12 @@ export interface GetSessionResponse {
15581592
* @public
15591593
*/
15601594
ApproverResponses?: GetSessionResponseApproverResponse[] | undefined;
1595+
1596+
/**
1597+
* <p>A list of <code>AdditionalSecurityRequirement</code> applied to the session.</p>
1598+
* @public
1599+
*/
1600+
AdditionalSecurityRequirements?: AdditionalSecurityRequirement[] | undefined;
15611601
}
15621602

15631603
/**
@@ -1719,6 +1759,12 @@ export interface ListSessionsResponseSession {
17191759
* @public
17201760
*/
17211761
ActionCompletionStrategy?: ActionCompletionStrategy | undefined;
1762+
1763+
/**
1764+
* <p>A list of <code>AdditionalSecurityRequirement</code> applied to the session.</p>
1765+
* @public
1766+
*/
1767+
AdditionalSecurityRequirements?: AdditionalSecurityRequirement[] | undefined;
17221768
}
17231769

17241770
/**

0 commit comments

Comments
 (0)