Your Dynatrace environment can integrate with a Slack workspace using Slack Connector
. You can automate sending messages to Slack based on the events and schedules defined for your workflow.
External requests enable outbound network connections from your Dynatrace environment to external services. They allow you to control access to public endpoints from the AppEngine with app functions and functions in Dashboards, Notebooks, and Automations.
Go to
Settings > General > External requests.
Select New host pattern.
Add the domain names.
Select Add.
This way you can granularly control the web services your functions can connect to.
Some permissions are required by Workflows to run actions on your behalf. Other permissions are required by actions that come bundled with Slack Connector itself.
To fine-tune permissions granted to Workflows
app-settings:objects:readapp-settings:objects:writestate:app-states:readstate:app-states:writestate:app-states:deletestate:user-app-states:readstate:user-app-states:writestate:user-app-states:deleteFor more on general Workflows user permissions, see User permissions for workflows.
For Slack Connector workflow actions to interact with your Slack workspace, you first need to create a Slack App for Dynatrace and authorize its connection to Slack.
Go to Slack API and select Create an App.
In the Create an app window, select From an app manifest.
In the Pick a workspace to develop your app window, select the Slack workspace you want to connect to and select Next.
In the Enter app manifest below window, paste the manifest YAML provided below into the YAML tab.
Replace <app-name> and <bot-name> with values of your choice (for example, Dynatrace). For more information on the manifest YAML, see Slack documentation.
display_information:name: <app-name>features:bot_user:display_name: <bot-name>always_online: falseoauth_config:scopes:bot:- channels:join- channels:read- chat:write- chat:write.public- files:read- files:write- groups:read- im:read- mpim:read- reactions:read- reactions:writesettings:org_deploy_enabled: falsesocket_mode_enabled: falsetoken_rotation_enabled: false
Your Dynatrace Slack Connector requires an OAuth token to authorize sending messages to Slack.
Go to Workflows
and select to create a new workflow.
In the Choose trigger panel, select the trigger best suited to your needs.
On the trigger node, select to browse available actions.
In the Choose action panel, search for slack and select Send message.
Select a pre-configured Slack connection.
Select a channel to send your message to.
We recommend using the Slack channel ID. You can also use a Slack channel name or Slack channel ID; however, not all features of the Send Message action will be available.
Provide a message body. Format your message using Slack Markdown. It is also possible to use workflow expressions as input.
To test your workflow, select Run.
The following are solutions to problems some people had with Slack integration.