Start integrating with ONEiO for free!

How to configure Slack for integration with ONEiO


This document shows an example of what needs to be done on Slack to make it integration-ready with the endpoint in your ONEiO. Note also that the amount of fields used in integrations might vary.

ONEiO utilises Interactivity, Slash Commands and Incoming Webhooks features of Slack App.

For any questions related setting up the integration, please send mail to

Create Slack Endpoint Type

Before go any further, first a new Slack endpoint should be created.


As first step Create and Save your endpoint type.

  • Enter your endpoint type name
  • Select your timezone
  • Insert any value on Bot User OAuth Token. This field will be updated in next steps.

As second step Edit your endpoint type and Generate new password.


As third step  Copy Target URL to clipboard


Store your generated URL for usage in next steps.

Lastly, Save the changes on endpoint.

For more details of you can check Endpoint Configuration Guide - Slack 

Sending messages from Slack to ONEiO

In this part, focus is how to setup a Slack app and adjust its settings for sending messages to ONEiO.

Create an App in Slack

Log in to your Slack account ( with your account administrator user and click Your Apps from the top right corner of your screen.

Start by clicking Create New App


Go on with From scratch;


Write the app name and select the workspace for app;


Fill out the basic information/ display information


Navigate to Add features and functionality.


Select Interactivity & Shortcuts and Activate the feature.


Enter your Generated URL from Slack Endpoint Type. Details are on Create Slack Endpoint Type


Create Slash Command on Slack

To be able to send messages from Slack to ONEiO, first you need to define slash command.

Go to Slash Commands on the app menu and create a new slash commands;


You are going to see a form to create slash command. Create your command, write your description and usage hint. To fill Request URL, first it is needed to create URL on ONEiO.


command Slash command keyword. "/incident"
Request URL


The URL generated on Create Slack Endpoint Type step above.

Short Description Description of your slash command
Usage Hint Additional text field to describe functionalty of slash command

Configure Scopes for Slack App

Go to App Menu, OAuth & Permissions and then navigate through Scopes. Configure the scopes below to your bot user of Slack App.


To activate your app in Slack, Install to Workspace.


In next page, select an existing channel to posting messages from app or create a new channel for app to post messages via Incoming Webhooks.

Note: As soon as you install your app into channel you decided, an Incoming Webhooks is created for selected channel.


Even though, you selected a channel for Incoming Webhooks of Slack App, by default, Slack endpoint type Slack API methods. To enable to use message types within default configurations of Slack endpoint type, please add the app preferably in same channel.

Go to channel which you want to install application and navigate to View channel details


Navigate to Integrations and Add an app


Type your app name and Add app. 


After adding app, pop-up window will be automatically closed and you will a message on channel.


Congratulations! Slack App setup is completed.

Sending messages from Slack to ONEiO

Go to Endpoint Type page and create a new endpoint.


  • Enter your endpoint type name
  • Select your timezone
  • Insert Bot User OAuth Token

To insert your Bot User OAuth Token, go to your Slack App menu, navigate to OAuth & Permissions 


Copy your token and insert your token as Bearer xoxb-*** on Both User OAuth Token.

Then go right top corner of the page and Create the endpoint.

Setting Routing Rules

Create Rule for Slash Commands

When a user enters a slash command on Slack channel, Slack sends a POST request to Request URL in it. On ONEiO, in order to react with a slash command at least one rule needed to be created. In sample rule below, ONEiO responds slash command with Slack Modal, designed in Block Kit Builder tool of Slack. 

Go to Routing Rules and Create New Rule;

Make sure you select Response Template as Message Type on the right side.


Then go to Mappings 

Set Outbound mappings as below


${trigger_id} trigger_id
modal json view

The example modal JSON body can be found below;

    "type": "modal",
    "callback_id": "incident",
    "title": {
        "type": "plain_text",
        "text": "ServiceNow Incident"
    "submit": {
        "type": "plain_text",
        "text": "Submit",
        "emoji": true
    "close": {
        "type": "plain_text",
        "text": "Cancel",
        "emoji": true
    "blocks": [
            "type": "input",
            "block_id": "short_description",
            "label": {
                "type": "plain_text",
                "text": "Short Description"
            "element": {
                "type": "plain_text_input",
                "action_id": "add_short_description",
                "multiline": false
            "type": "input",
            "block_id": "description",
            "label": {
                "type": "plain_text",
                "text": "Description",
                "emoji": true
            "element": {
                "type": "plain_text_input",
                "action_id": "add_description",
                "multiline": true
            "optional": true
            "type": "input",
            "block_id": "worknotes",
            "label": {
                "type": "plain_text",
                "text": "Work Notes",
                "emoji": true
            "element": {
                "type": "plain_text_input",
                "action_id": "add_worknotes",
                "multiline": true
            "optional": true

For more details about Slack Modals you can follow Slack instructions.

You can also modify the example modal easily or create new modals with Slack's Block Kit Builder

Field name Details
callback_id callback_id is used as identifier for what modal template is used. It is used in rules.
block_id block_id is used as identifier for modal field in block elements. It is used in rules.

Set Conversation Variables as below


Source Value Conversation variable
${response_url} sf:conversation:response_url
${trigger_id} sf:conversation:trigger_id
${token} sf:conversation:slack_token
${text} sf:conversation:slack_text
${channel_id} sf:conversation:channel_id

Rule for responding Slash command is set now. Next step is to define a rule for directing and mapping inbound message which is created by Slack after clicking Submit on Slack Modal.

Create rule to integrate Slack to ServiceNow;

Assumption: You already set up ServiceNow or similar ITSM tool on your subscription.


Set Outbound Mappings;


Set Conversation Variables

Screenshot_2022-09-27_at_14.43.41.pngThen save your rule. 

In order to be notified that your incident successfully is created, another rule should be set;

Go to the rule Slack to ServiceNow - Create Incident and click Edit Rule on right top of the page. You will see Response Rules section below Outbound side of the rule structure. Create new response rule.


A rule edit page is seen below. On Outbound side, select Message as Message Type.


Then go to Mappings tab and set Runtime Variables;


${result.number} incident_number

Then set Outbound Mappings;


channel id channel
Incident ${sf:virtual:incident_number} created successfully. text

Channel field must filled with channel_id value. It must be same channel where you app is installed. Go to that channel then open channel menu and copy link.


Select and copy channel_id from the URL."channel_id" and paste on outbound mappings.

After rules' setup is complete, slash command can be tested. Go to any channel you like and enter defined slash command. On our example, it is defined /incident


As soon as you enter the slash command, a modal will be appear over the Slack application.


After filling the modal, when form is submitted. ONEiO send response message to designated app channel, which app is installed by admins.

In this tutorial, how to create slack app, how to set up Slack Bilateral endpoint type and setting basic rules with ServiceNow are covered.

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request



Please sign in to leave a comment.