Step by step guide to install a Slack channel
The Slack integration provides you with a Manifest that allows you to setup most of the heavy Slack App configuration in seconds. To get started, simply click on the link provided here:
Simply follow the on-screen instructions until the app is installed to your workspace. You will be required to allow the app to perform the necessary actions - you must be a workspace admin to do that.
You will still need to perform a few actions to correctly setup your app. First, visit the App Manifest menu. It may have an orange warning box at the top: in that case, click the "Click here to verify" link to make that warning disappear. Another way to perform this verification if needed is by visiting Event Subscriptions and performing the same operation.
Next, visit the OAuth & Permissions menu, copy the Bot User Token and save it for later.
Next, select App Home in the left-side menu. Enter a Display Name and a Default Name for your bot and select Always Show My Bot as Online.
At the bottom of the same App Home page, under Show Tabs, make sure the Messages Tab toggle is on and the Allow users to send Slash commands and messages from the messages tab checkbox is checked.
Next, visit Basic Information from the left-side menu, copy the App ID, Client ID, Client Secret and Signing Secret under App Credentials and save them for later.
On the same page, you can also customize the appearance of your chatbot in Slack (image, colors...).
Finally, back in CSML Studio, paste the credentials you retrieved earlier: Bot User Token, App ID, Client ID, Client Secret, Signing Secret, then click on Submit.
You should now be able to see your app in the left sidebar of your Slack workspace, under Apps. This is where you can chat with your slack bot!
List of available message formats in Slack channel
Slack has partial markdown support in text components.
In Slack, Wait
and Typing
have the same behavior. No typing indicator exists in slack, so the bot will simply wait for the duration given (in milliseconds) before the next message is processed.
Slack makes it possible to style your buttons and define a custom payload that is sent to the chatbot on click. Available styles are "danger" and "primary". Slacks recommends to only use primary on one button in a list, and danger even less often.
CSML Studio will also take advantage of Slack's features to update the content of the component when an option is chosen, so that the user's choice appears clearly after they select an option.
Send the URL of an image. Slack will attempt to display it.
Generic files will render as standard URLs. When it can, Slack will try to display the URL nicely, such as the Wikipedia link below.
A Carousel
is essentially a collection of Card
elements A single Card
will display as a Carousel
of 1 element.
You can add several Button
or Url
buttons to your Card
components.
For a complete reference of all the code presented on this page, refer to the following gist:
A sample _metadata
for an incoming event will be similar to the following object:
CSML Studio supports Slack as one of its channels. Slack is a very popular option at startups and schools, and is widely used as a "ChatOps" solution by tech teams.