Skip to main content

slack_channel_configurations

Creates, updates, deletes or gets a slack_channel_configuration resource or lists slack_channel_configurations in a region

Overview

Nameslack_channel_configurations
TypeResource
DescriptionResource schema for AWS::Chatbot::SlackChannelConfiguration.
Idawscc.chatbot.slack_channel_configurations

Fields

NameDatatypeDescription
slack_workspace_idstringThe id of the Slack workspace
slack_channel_idstringThe id of the Slack channel
configuration_namestringThe name of the configuration
iam_role_arnstringThe ARN of the IAM role that defines the permissions for AWS Chatbot
sns_topic_arnsarrayARNs of SNS topics which delivers notifications to AWS Chatbot, for example CloudWatch alarm notifications.
logging_levelstringSpecifies the logging level for this configuration:ERROR,INFO or NONE. This property affects the log entries pushed to Amazon CloudWatch logs
arnstringAmazon Resource Name (ARN) of the configuration
guardrail_policiesarrayThe list of IAM policy ARNs that are applied as channel guardrails. The AWS managed 'AdministratorAccess' policy is applied as a default if this is not set.
tagsarrayThe tags to add to the configuration
user_role_requiredbooleanEnables use of a user role requirement in your chat configuration
customization_resource_arnsarrayARNs of Custom Actions to associate with notifications in the provided chat channel.
regionstringAWS region.

For more information, see AWS::Chatbot::SlackChannelConfiguration.

Methods

NameResourceAccessible byRequired Params
create_resourceslack_channel_configurationsINSERTSlackWorkspaceId, SlackChannelId, ConfigurationName, IamRoleArn, region
delete_resourceslack_channel_configurationsDELETEIdentifier, region
update_resourceslack_channel_configurationsUPDATEIdentifier, PatchDocument, region
list_resourcesslack_channel_configurations_list_onlySELECTregion
get_resourceslack_channel_configurationsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual slack_channel_configuration.

SELECT
region,
slack_workspace_id,
slack_channel_id,
configuration_name,
iam_role_arn,
sns_topic_arns,
logging_level,
arn,
guardrail_policies,
tags,
user_role_required,
customization_resource_arns
FROM awscc.chatbot.slack_channel_configurations
WHERE
region = '{{ region }}' AND
Identifier = '{{ arn }}';

INSERT example

Use the following StackQL query and manifest file to create a new slack_channel_configuration resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.chatbot.slack_channel_configurations (
SlackWorkspaceId,
SlackChannelId,
ConfigurationName,
IamRoleArn,
region
)
SELECT
'{{ slack_workspace_id }}',
'{{ slack_channel_id }}',
'{{ configuration_name }}',
'{{ iam_role_arn }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

UPDATE example

Use the following StackQL query and manifest file to update a slack_channel_configuration resource, using stack-deploy.

/*+ update */
UPDATE awscc.chatbot.slack_channel_configurations
SET PatchDocument = string('{{ {
"SlackChannelId": slack_channel_id,
"IamRoleArn": iam_role_arn,
"SnsTopicArns": sns_topic_arns,
"LoggingLevel": logging_level,
"GuardrailPolicies": guardrail_policies,
"Tags": tags,
"UserRoleRequired": user_role_required,
"CustomizationResourceArns": customization_resource_arns
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ arn }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

DELETE example

/*+ delete */
DELETE FROM awscc.chatbot.slack_channel_configurations
WHERE
Identifier = '{{ arn }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

Additional Parameters

Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:

ParameterDescription
ClientToken
A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.
A client token is valid for 36 hours once used.
After that, a resource request with the same client token is treated as a new request.
If you do not specify a client token, one is generated for inclusion in the request.
RoleArn
The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.
If you do not specify a role, a temporary session is created using your AWS user credentials.
TypeVersionId
For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used.

Permissions

To operate on the slack_channel_configurations resource, the following permissions are required:

chatbot:CreateSlackChannelConfiguration,
chatbot:TagResource,
chatbot:AssociateToConfiguration,
chatbot:ListAssociations,
iam:PassRole,
iam:CreateServiceLinkedRole