Connect Slack - Amazon CloudWatch
Services or capabilities described in AWS documentation might vary by Region. To see the differences applicable to the AWS European Sovereign Cloud Region, see the AWS European Sovereign Cloud User Guide.

Connect Slack

An integration connects CloudWatch Omni to a tool your team already uses. Slack delivers alert notifications to your team's channels, and lets your team mention the Omni agent there. You manage it in Settings, on the Integrations page, and a connection applies to your whole space.

With Slack connected, an alert's notification rules can deliver to Slack channels. You choose the channels on each alert when you set its destinations. See Alerts.

Connecting the integration is not enough: delivery also requires the alert's access profile to grant this integration and the channels the alert posts to. Omni checks the grant when you create the alert and again on every delivery, so revoking it stops notifications for alerts that were already working. If an alert fires but nothing reaches Slack, check the profile. See Access profiles.

Alerts that use DefaultAccessProfileForAsyncWorkflows post to the same channels the agent answers in. To give alerts their own set of channels, use a separate access profile for them.

To connect:

  1. In Settings, choose Integrations.

  2. On the Slack card, choose Enable. Slack's authorization page opens in a new tab.

  3. Review the requested permissions and choose Allow.

Back in Omni, the Slack card shows the connected integration: its ID and name. If your Slack workspace requires administrator approval for new apps, ask a workspace administrator to approve the request, then connect again.

What the Slack connection can do. The authorization page lists the exact permissions requested. The connection lets Omni post and reply to messages, read the names of your workspace's public and bot-added private channels so it can offer them as destinations, and receive messages that mention the Omni app. It does not include your workspace's message history. A private channel appears in the channel list only after the Omni app has been added to it.

Bring the Omni agent into Slack. With the integration connected, your team can mention the Omni agent in a Slack channel and get answers there. Connecting the workspace is not enough: the DefaultAccessProfileForAsyncWorkflows access profile must also grant the agent permission to post to the integration. Without that grant, a mention is received but the agent cannot respond. For what the agent can do, see Ask the Omni agent. For profiles and grants, see Access profiles.

Important

Amazon CloudWatch uses generative AI to produce the agent's replies. A reply can be incomplete or wrong. Verify a finding before you act on it. AWS handles information in accordance with the AWS Privacy Notice.

On the connected Slack card, choose Set up Omni permissions for Slack. This opens the add-grant form already filled in for the DefaultAccessProfileForAsyncWorkflows profile, where you choose the channels the agent may post to. Give the profile a viewer grant as well, so the agent can read the resources it answers about.

The grant covers three things:

  • Reply through the Slack integration — cloudwatch:InvokeIntegration, scoped to the Slack integration's ARN and the channels you choose.

  • Work with conversation threads — cloudwatch:GetOmniThread and cloudwatch:CreateOmniThread. A viewer grant already includes both, so a profile that has one does not need them listed separately.

  • Read the resources it answers about — a viewer grant.

If you author grants through the API instead of the console, use your own integration ARN and channel names:

{ "name": "slack-agent-integration", "permission": "CUSTOM", "scopedActions": [ { "actions": ["cloudwatch:InvokeIntegration"], "resources": [ { "resourceType": "Integration", "resourceArns": ["arn:aws:cloudwatch:region:account-id:integration/integration-id"] } ], "contextConditions": { "channelNames": ["oncall-alerts", "incidents"] } }, { "actions": ["cloudwatch:GetOmniThread", "cloudwatch:CreateOmniThread"] } ] }

Pair it with a viewer grant:

{ "name": "slack-agent-viewer", "permission": "READ" }

Choose where Omni answers. Omni posts in a channel when a grant on DefaultAccessProfileForAsyncWorkflows allows that channel. By default, the profile allows every channel. To limit Omni to specific channels, list them in slack-agent-integration, and remove cloudwatch:InvokeIntegration from any other grant on the profile that doesn't list channels.

Regional Slack apps. The Slack app is Region-specific, and you do not choose it: Enable directs you to the Amazon CloudWatch Slack app for the Region your space is in. It appears in your workspace as a bot with a matching name. Several spaces in the same Region can connect the same Slack workspace, even from different AWS accounts. They share that Region's bot. This is available in every Region listed in the bot table below. You can also connect the same workspace to spaces in different Regions. Each Region installs its own bot, so mention the bot whose name matches the Region of the space you want to reach.

Choose the space that answers in a channel. When more than one connected space grants the agent a channel, the channel uses one of them. To set it, do one of the following:

  • Mention the bot with the space's name.

  • Reply to the bot's list of spaces with a number.

In a channel that already uses a space, naming a different space answers only that message.

Change a channel's space. You or any other member of the channel can change the channel's space. To change it, mention the bot with switch and choose a number from the list.

The list and each reply show the space name, Region, and AWS account ID to everyone in the channel. To keep a channel on one space, limit the other spaces' grants to other channels.

Shared channels. Anyone who can post in a channel the bot is in can mention it and get answers from your space. This includes guests and members of other organizations in Slack Connect channels. To keep answers within your organization, invite the bot only to channels that aren't shared with other organizations.

Invite the bot to each channel. Connecting the workspace does not add the bot to any channel. Before an alert can deliver notifications to a channel, or a mention in that channel can reach the agent, invite the Region's bot to it from Slack:

/invite @Amazon CloudWatch - USEast Virginia
Region Bot name
US East (N. Virginia), us-east-1 Amazon CloudWatch - USEast Virginia
US East (Ohio), us-east-2 Amazon CloudWatch - US East (Ohio)
US West (Oregon), us-west-2 Amazon CloudWatch - US West Oregon
Europe (Ireland), eu-west-1 Amazon CloudWatch - EU (Ireland)
Asia Pacific (Mumbai), ap-south-1 Amazon CloudWatch - AP (Mumbai)
Asia Pacific (Singapore), ap-southeast-1 Amazon CloudWatch - AP (Singapore)
Asia Pacific (Sydney), ap-southeast-2 Amazon CloudWatch - AP (Sydney)
Asia Pacific (Tokyo), ap-northeast-1 Amazon CloudWatch - AP (Tokyo)
Canada (Central), ca-central-1 Amazon CloudWatch - CA (Central)
Europe (Frankfurt), eu-central-1 Amazon CloudWatch - EU (Frankfurt)
Europe (London), eu-west-2 Amazon CloudWatch - EU (London)
South America (São Paulo), sa-east-1 Amazon CloudWatch - SA (Sao Paulo)

Disconnect an integration

On the integration's card in Settings, on the Integrations page, choose Disable. Disconnecting Slack stops alert notifications to Slack. The alerts themselves keep evaluating, and their other destinations keep working. You can reconnect with Enable.

Who can manage integrations

Integrations apply to the whole space. One person connects, and the connection works for everyone in the space. Whether a member can connect, change, or disconnect an integration is governed by their grants: the integration create, update, and delete actions. See Custom grant actions.