This document describes the functionality provide by the xlr-slack-plugin
This plugin provides a notification task to send Slack messages to channels or direct messages. It's based on Incoming Webhooks integration, which provides a URL within an authorization token ready to POST messages. See Slack Incoming Webhooks documentation for background information on post messages from external sources into Slack.
Copy the plugin JAR file into the SERVER_HOME/plugins
directory of XL Release.
This configuration allows you to connect to multiple servers or connect to just one. Before to use Slack notification task, it's needed to setup a Slack server definition within the following information:
- Title: Name of the Slack server definition.
- Slack URL: Tokenized URL provided by the Incoming WebHook integration.
- User name: Name to use in the notifications.
- User icon: Icon to use in the notifications, it should be a icon emoji, e.g.
:ghost:
. - Proxy URL: Proxy URL to use in format http://username:password@proxyurl:proxyport, leave it in blank if isn't required.
The available tasks for interfacing with Slack. These tasks utilize the Slack REST API and the provided Slack Authentication Configuration.
The Slack notification task needs the next information:
- Server: The Slack server definition to use.
- Channel: Comma separated list of targets for the notification, use
#
or@
to refer to a channel or direct message. - Message: The notification message text, it could be formatted.
This task creates a new channel in slack
This task adds a list of users based on their email addresses
This task posts a message to a slack channel based on the channel's ID
This plugin needs a Slack to communicate. You can create a custom app to to by doing the following:
- Got to https://api.slack.com/apps to start building your app
- Create a Slack App - provide App Name and Workspace
- Add features and functionality - Incoming Webhooks & Permissions
a. Incoming Webhooks
Keep track of the Webhook URL
. This will be the URL for sending notifications.
b. Permissions
Add Slack Permissions as follows:
- Access information about user's public channels
channels:read
- Modify your private channels
channels:write
- Post to specific channels in Slack
incomming-webhook
- Add a bot user with the username @
chat:write:bot
- Access your workspace's profile information
users:read
- View email addresses of people on this workspace
users:read.email
Keep track of the OAuth Token
and Reinstall App
Use the Webhook URL
and the OAuth Token
to configure the connection in XL Release