response_plans
Creates, updates, deletes or gets a response_plan resource or lists response_plans in a region
Overview
| Name | response_plans |
| Type | Resource |
| Description | Resource type definition for AWS::SSMIncidents::ResponsePlan |
| Id | awscc.ssmincidents.response_plans |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
arn | string | The ARN of the response plan. |
name | string | The name of the response plan. |
display_name | string | The display name of the response plan. |
chat_channel | object | The chat channel configuration. |
engagements | array | The list of engagements to use. |
actions | array | The list of actions. |
integrations | array | The list of integrations. |
tags | array | The tags to apply to the response plan. |
incident_template | object | The incident template configuration. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
arn | string | The ARN of the response plan. |
region | string | AWS region. |
For more information, see AWS::SSMIncidents::ResponsePlan.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | response_plans | INSERT | Name, IncidentTemplate, region |
delete_resource | response_plans | DELETE | Identifier, region |
update_resource | response_plans | UPDATE | Identifier, PatchDocument, region |
list_resources | response_plans_list_only | SELECT | region |
get_resource | response_plans | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual response_plan.
SELECT
region,
arn,
name,
display_name,
chat_channel,
engagements,
actions,
integrations,
tags,
incident_template
FROM awscc.ssmincidents.response_plans
WHERE
region = 'us-east-1' AND
Identifier = '{{ arn }}';
Lists all response_plans in a region.
SELECT
region,
arn
FROM awscc.ssmincidents.response_plans_list_only
WHERE
region = 'us-east-1';
INSERT example
Use the following StackQL query and manifest file to create a new response_plan resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.ssmincidents.response_plans (
Name,
IncidentTemplate,
region
)
SELECT
'{{ name }}',
'{{ incident_template }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.ssmincidents.response_plans (
Name,
DisplayName,
ChatChannel,
Engagements,
Actions,
Integrations,
Tags,
IncidentTemplate,
region
)
SELECT
'{{ name }}',
'{{ display_name }}',
'{{ chat_channel }}',
'{{ engagements }}',
'{{ actions }}',
'{{ integrations }}',
'{{ tags }}',
'{{ incident_template }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: response_plan
props:
- name: name
value: '{{ name }}'
- name: display_name
value: '{{ display_name }}'
- name: chat_channel
value:
chatbot_sns:
- '{{ chatbot_sns[0] }}'
- name: engagements
value:
- '{{ engagements[0] }}'
- name: actions
value:
- ssm_automation:
role_arn: '{{ role_arn }}'
document_name: '{{ document_name }}'
document_version: '{{ document_version }}'
target_account: '{{ target_account }}'
parameters:
- key: '{{ key }}'
values:
- '{{ values[0] }}'
dynamic_parameters:
- key: '{{ key }}'
value:
variable: '{{ variable }}'
- name: integrations
value:
- pager_duty_configuration:
name: '{{ name }}'
secret_id: '{{ secret_id }}'
pager_duty_incident_configuration:
service_id: '{{ service_id }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
- name: incident_template
value:
dedupe_string: '{{ dedupe_string }}'
impact: '{{ impact }}'
notification_targets:
- sns_topic_arn: null
summary: '{{ summary }}'
title: '{{ title }}'
incident_tags:
- null
UPDATE example
Use the following StackQL query and manifest file to update a response_plan resource, using stack-deploy.
/*+ update */
UPDATE awscc.ssmincidents.response_plans
SET PatchDocument = string('{{ {
"DisplayName": display_name,
"ChatChannel": chat_channel,
"Engagements": engagements,
"Actions": actions,
"Integrations": integrations,
"Tags": tags,
"IncidentTemplate": incident_template
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ arn }}';
DELETE example
/*+ delete */
DELETE FROM awscc.ssmincidents.response_plans
WHERE
Identifier = '{{ arn }}' AND
region = 'us-east-1';
Permissions
To operate on the response_plans resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
ssm-incidents:CreateResponsePlan,
ssm-incidents:GetResponsePlan,
ssm-incidents:TagResource,
ssm-incidents:ListTagsForResource,
iam:PassRole,
secretsmanager:GetSecretValue,
kms:Decrypt,
kms:GenerateDataKey,
kms:GenerateDataKeyPair,
kms:GenerateDataKeyPairWithoutPlaintext,
kms:GenerateDataKeyWithoutPlaintext
ssm-incidents:GetResponsePlan,
ssm-incidents:ListTagsForResource
ssm-incidents:UpdateResponsePlan,
ssm-incidents:GetResponsePlan,
ssm-incidents:TagResource,
ssm-incidents:UntagResource,
ssm-incidents:ListTagsForResource,
iam:PassRole,
secretsmanager:GetSecretValue,
kms:Decrypt,
kms:GenerateDataKey,
kms:GenerateDataKeyPair,
kms:GenerateDataKeyPairWithoutPlaintext,
kms:GenerateDataKeyWithoutPlaintext
ssm-incidents:DeleteResponsePlan,
ssm-incidents:GetResponsePlan
ssm-incidents:ListResponsePlans