Today, we will focus on two of the Slack-related automatic Steps in Questetra BPM Suite: Slack: Post Chat (Bots) and Slack: Upload File (Bots).

Slack is…

Slack is a business-oriented chatting tool that is developed and managed by Slack Technologies, Inc. With Slack, in addition to being able to use different channels depending on topics, teams, etc. you can link it with various applications and create bots using APIs.

For more information on Slack, please visit Slack’s official page.

Automatic Steps in Questetra

First, I will briefly explain each automated Step.

Slack: Post Chat (Bots)

It is an auto-step that posts a message to a Slack channel from Questetra. You can also specify additional information called Attachments.

Slack: Post Chat (Bots) settings screen

In addition to text messages, you can also use some parts of Attachments. If all three of Sending Text, Attachment Title, and Attachment Text are blank, a script error will result. In addition, if C6: Attachment Title is not entered, C7: Attachment Title Link will be invalid Please be aware of this.

About Attachments

Attachment is the mechanism of expanding messages on Slack. In the automatic Steps in Questetra, Title, Title Link, Text, Color, Attachment Summary (fallback message) are supported.

The relationship between the settings on the message and the appearance of the message actually posted is like the image below.

Relationship between settings and appearance

Attachment Summary is not reflected in the message body, it will only be used for notification if the Sending Text is empty.

For information on Attachment, please see the official documentation of Slack.

Slack: Upload File (Bots)

It is an auto-step that uploads files to a Slack channel.

Slack: Upload File (Bots) settings screen

Slack and Questetra integration settings

I will explain how to set up integration between Questetra and Slack.

  • The System Administrator privilege is required to set up HTTP Authorization settings
  • The registered HTTP Authorization settings are also shared with other Apps on the same workflow platform

After placing the above automatic Step in the workflow App editing screen of Questetra, open its properties screen. When you click the [Set up Settings] button below the settings item of C1: OAuth2 settings in the Slack: Post Chat (Bots), the HTTP Authorization Setting Slack screen will open.

Click [Add] on the screen and specify a name of your choice. (Arbitrary string: It’s better to give a name that is easy to understand later.)

Click [Get Token] in the added setting to move to the Slack authentication screen. First, specify the workspace you are going to link. (If you’re already signed in to Slack with your browser, this screen will be skipped.)

Sign in to Slack. (Skipped if you already signed in.)

When you allow the connection, the setting is completed. Incidentally, this procedure will also install the Questetra BPM Suite app registered in Slack in your workspace.

You now have obtained a token for OAuth2 authentication with Slack. (“○ (Access Token)” is displayed above the [Get Token] button.)

Invite the Bot to a channel

From these auto-steps, posting/uploading to a Slack channel is done as a Bot. A Bot must have been Invited to access the channel, like other members in a channel.

To invite the “questetra_bot” to a channel, post /invite @questetra_bot on the channel you want to invite and the bot will be invited. Incidentally, if you want to remove a Bot from a channel for some reason, you can remove it with a post /remove @questetra_bot.

Incidentally, although the Questetra BPM Suite app must be installed in your Slack workspace to invite a Bot, the installation is done automatically when setting the integration between Questetra and Slack.


Example App

Examples of how to use these automatic Steps are as follows.

  • Notify the end of a Process on Slack
  • Notify occurrence of an error on Slack
  • Automatically report issues that should be reported
  • Share files

In this article, I will introduce a simple example App in its basic form. For actual use, utilize it by incorporating it into other Apps etc. according to the application.

At the [Set Post] Step, specify the content you want to post and the file to be uploaded. The message body and the Attachment are posted at the Post to Slack Step, and then the file set in the File-type Data Item is uploaded at the Upload Step.

Data Items settings

The Data Items settings are as follows.

Data Item NameData-typeRequired[Set Post] StepDescription
TitleNoEditableThe title of the Process
MessageString-type (multiple lines)NoEditableThe main message to be posted
Attachment TitleString-type (single line)NoEditableCharacter string to be the Attachment Ttle
Attachment Title LinkString-type (single line)NoEditableThe URL to be the link destination
Attachment TextString-type (multiple lines)NoEditableCharacter string to be the Attachment Text
File to UploadFile-typeNoEditableFiles set in this item will be uploaded
Settings in Post to Slack (Slack: Post Chat (Bots))

Settings in the Post to Slack Step are as follows.

Config nameRequiredDescription
C1: OAuth2 SettingYesSpecify the name of the HTTP Authorization Setting. An OAuth2 Token must have been obtained in the Authorization Settings of the name you specify. (Refer to “Slack and Questetra integration settings.”)
C2: Slack Channel NameYesType the name of the channel you want to post to. # at the top is disregarded.
C3: Sending TextNoEnter a message to be posted.
In this example, set an expression referring to the Data Item [Message].
C4: Attachment SummaryNoEnter the text used for notification from Slack when C2: Sending Text is empty.
C5: Attachment ColorNoThis sets the color of the Attachment sidebar. Enter a hexadecimal color code as a fixed value.
C6: Attachment TitleNoEnter a character string to be the Attachment Title
In this example, set an expression referring to the Data Item [Attachment Title].
C7: Attachment Title LinkNoIf you want a hyperlink on the Attachment Title, enter the URL to link to.
In this example, set an expression referring to the Data Item [Attachment Title Link].
C8: Attachment TextNoEnter a character string to be the Attachment Text
In this example, set an expression referring to the Data Item [Attachment Text].
Settings in Upload (Slack: Upload File (Bots))

Settings in the Upload Step are as follows.

Settings in Upload Step are as follows.RequiredDescription
C1: OAuth2 SettingYesSelect the same setting name as you set in Post to Slack
C2: Slack Channel NameYesType the name of the channel you want to post to. # at the top is disregarded.
C3: Data item whose attached files will be uploaded (File)YesSelect Files to Upload from the pull-down list

When you run this App, it will be posted to Slack as the image below

Captured image of a message posted to Slack

3 thoughts on “Posting a Message to Slack”

  1. Pingback: Slack: Post Chat (Bots) – Questetra Support

  2. Pingback: Slack: Post Chat (Incoming Webhook) – Questetra Support

  3. Pingback: Slack: Upload File (Bots) – Questetra Support

Comments are closed.

%d