approval_teams
Creates, updates, deletes or gets an approval_team resource or lists approval_teams in a region
Overview
| Name | approval_teams |
| Type | Resource |
| Description | Resource Type definition for AWS::MPA::ApprovalTeam. |
| Id | awscc.mpa.approval_teams |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
approval_strategy | object | |
approvers | array | |
tags | array | |
policies | array | |
name | string | |
description | string | |
arn | string | |
version_id | string | |
update_session_arn | string | |
creation_time | string | |
number_of_approvers | integer | |
status | string | |
status_code | string | |
status_message | string | |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
arn | string | |
region | string | AWS region. |
For more information, see AWS::MPA::ApprovalTeam.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | approval_teams | INSERT | ApprovalStrategy, Approvers, Policies, Name, Description, region |
delete_resource | approval_teams | DELETE | Identifier, region |
update_resource | approval_teams | UPDATE | Identifier, PatchDocument, region |
list_resources | approval_teams_list_only | SELECT | region |
get_resource | approval_teams | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual approval_team.
SELECT
region,
approval_strategy,
approvers,
tags,
policies,
name,
description,
arn,
version_id,
update_session_arn,
creation_time,
last_update_time,
number_of_approvers,
status,
status_code,
status_message
FROM awscc.mpa.approval_teams
WHERE
region = 'us-east-1' AND
Identifier = '{{ arn }}';
Lists all approval_teams in a region.
SELECT
region,
arn
FROM awscc.mpa.approval_teams_list_only
WHERE
region = 'us-east-1';
INSERT example
Use the following StackQL query and manifest file to create a new approval_team resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.mpa.approval_teams (
ApprovalStrategy,
Approvers,
Policies,
Name,
Description,
region
)
SELECT
'{{ approval_strategy }}',
'{{ approvers }}',
'{{ policies }}',
'{{ name }}',
'{{ description }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.mpa.approval_teams (
ApprovalStrategy,
Approvers,
Tags,
Policies,
Name,
Description,
region
)
SELECT
'{{ approval_strategy }}',
'{{ approvers }}',
'{{ tags }}',
'{{ policies }}',
'{{ name }}',
'{{ description }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: approval_team
props:
- name: approval_strategy
value:
mof_n:
min_approvals_required: '{{ min_approvals_required }}'
- name: approvers
value:
- primary_identity_id: '{{ primary_identity_id }}'
primary_identity_source_arn: '{{ primary_identity_source_arn }}'
approver_id: '{{ approver_id }}'
response_time: '{{ response_time }}'
primary_identity_status: '{{ primary_identity_status }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
- name: policies
value:
- null
- name: name
value: '{{ name }}'
- name: description
value: '{{ description }}'
UPDATE example
Use the following StackQL query and manifest file to update a approval_team resource, using stack-deploy.
/*+ update */
UPDATE awscc.mpa.approval_teams
SET PatchDocument = string('{{ {
"ApprovalStrategy": approval_strategy,
"Tags": tags,
"Description": description
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ arn }}';
DELETE example
/*+ delete */
DELETE FROM awscc.mpa.approval_teams
WHERE
Identifier = '{{ arn }}' AND
region = 'us-east-1';
Permissions
To operate on the approval_teams resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
mpa:CreateApprovalTeam,
mpa:TagResource,
mpa:GetApprovalTeam,
mpa:ListTagsForResource
mpa:GetApprovalTeam,
mpa:ListTagsForResource
mpa:GetApprovalTeam,
mpa:UpdateApprovalTeam,
mpa:TagResource,
mpa:ListTagsForResource,
mpa:UntagResource
mpa:StartActiveApprovalTeamDeletion,
mpa:DeleteInactiveApprovalTeamVersion,
mpa:GetApprovalTeam,
mpa:UntagResource
mpa:ListApprovalTeams,
mpa:ListTagsForResource