Developer Tools Console
User Guide

Configure Integration Between Notifications and AWS Chatbot

AWS Chatbot is an AWS service that makes it possible for DevOps and software development teams to use Amazon Chime chat rooms and Slack channels to monitor and respond to operational events in the AWS Cloud. You can configure integration between notification rule targets and AWS Chatbot so that notifications about events appear in the Amazon Chime room or Slack channel you choose. For more information, see the AWS Chatbot documentation.

Before you configure integration with AWS Chatbot, you must configure a notification rule and a rule target . For more information, see Setting Up and Create a Notification Rule. You must also configure a Slack channel or a Amazon Chime chatroom. For more information, see the documentation for these services.

To integrate notifications with AWS Chatbot and Slack

  1. Open the AWS Developer Tools console at https://console.aws.amazon.com/codesuite/settings/notifications.

  2. Choose Settings, and then choose Notification rules.

  3. In Notification rule targets, find and copy the target.

    Note

    You can configure more than one notification rule to use the same Amazon SNS topic as its target. This can help you consolidate messaging, but can have unintended consequences if the subscription list is intended for one notification rule or resource.

  4. In a browser, open the Slack channel you want to configure for integration.

  5. Open the AWS Chatbot console at https://console.aws.amazon.com/chatbot/.

  6. Choose Slack, and then choose Configure new client.

  7. Choose Install.

  8. If you are prompted to confirm the choices, choose Allow.

  9. In Configure Slack Channel, in Channel type, choose Public or Private, depending on the type of channel you want to integrate.

    • In Public channel, choose the name of the Slack channel from the list.

    • In Private channel ID, enter the channel code or URL.

  10. In IAM permissions, in Role, choose Create an IAM role using a template. In Policy templates, choose Notification permissions. In Role name, enter a name for this role (for example, AWSCodeStarNotifications-Chatbot-Slack-Role).

  11. In SNS topics, in SNS Region, choose the AWS Region where you created the notification rule target. In SNS topics, choose the name of the Amazon SNS topic you configured as the notification rule target.

  12. Choose Configure.

  13. (Optional) To test the integration, make a change in the resource that matches an event type for a notification rule that is configured to use the Amazon SNS topic as its target. For example, if you have a notification rule configured to send notifications when comments are made on a pull request, comment on a pull request and then watch the Slack channel in the browser to see when the notification appears.

To integrate notifications with AWS Chatbot and Amazon Chime

  1. Open the AWS Developer Tools console at https://console.aws.amazon.com/codesuite/settings/notifications.

  2. Choose Settings, and then choose Notification rules.

  3. In Notification rule targets, find and copy the target.

    Note

    You can configure more than one notification rule to use the same Amazon SNS topic as its target. This can help you consolidate messaging, but can have unintended consequences if the subscription list is for one notification rule or resource.

  4. In Amazon Chime, open the chatroom you want to configure for integration.

  5. Choose the gear icon in the upper right corner, and then choose Manage webhooks.

  6. In the Manage webhooks dialog box, choose New, enter a name for the webhook, and then choose Create.

  7. Verify that the webhook appears, and then choose Copy webhook URL.

  8. Open the AWS Chatbot console at https://console.aws.amazon.com/chatbot/.

  9. Choose Amazon Chime, and then choose Configure new client.

  10. In Webhook URL, paste the URL. In Webhook description, provide an optional description.

  11. In IAM permissions, in Role, choose Create an IAM role using a template. In Policy templates, choose Notification permissions. In Role name, enter a name for this role (for example, AWSCodeStarNotifications-Chatbot-Chime-Role).

  12. In SNS topics, in SNS Region, choose the AWS Region where you created the notification rule target. In SNS topics, choose the name of the Amazon SNS topic you configured as the notification rule target.

  13. Choose Configure.

  14. (Optional) To test the integration, make a change in the resource that matches an event type for a notification rule that is configured to use the Amazon SNS topic as its target. For example, if you have a notification rule configured to send notifications when comments are made on a pull request, comment on a pull request and then watch the Amazon Chime chatroom to see when the notification appears.