Skip to main content
Skip table of contents

Send a Slack Hook

Being able to send messages to Slack Channels and Users is very helpful!

There are two fields that you need to input information into, the URL of the endpoint you want to reach, and the JSON of the payload that you are going to send.

The JSON Payload field allows variable substitution! To learn more read the guide here: Variable Substitution

Name of Field

Type of Field

Description

Webhook URL

Textfield

Insert the URL of the Slack Webhook endpoint

JSON Payload

JSON

Define the JSON body that will be sent along with the POST request

How to Set-Up your Slack

Before being able to use this action you will need to create an App for your Workspace and create the Webhook that you will be using to send messages to a Channel

  1. Navigate to this site

  2. Create an App

  3. Once created select Incoming Webhooks

  4. Select Add New Webhook to Workspace

5. Specify the channel that you want the message to be sent to and click Allow

6. Copy the URL that follows after https://hooks.slack.com/services/.....................

Example

Here is an example of a Webhook, note the JSON format you are entering. The Keys must be wrapped in quotations and and Page Variables you wish to add must be wrapped in quotes too.

If you want to create your own JSON payload (you can style the Slack messages really nicely using this tool)

Here is a Payload that we used in our Webinar:

CODE
{
    "blocks": [
        {
            "type": "section",
            "block_id": "section567",
            "text": {
                "type": "mrkdwn",
                "text": "${transitioner.displayName} has requested approval for the page: \n\n <${page.url}|${page.title}> \n\n\n The approval was requested at ${datetime}"
            },
            "accessory": {
                "type": "image",
                "image_url": "https://remote.automation-consultants.com/knowledge/download/thumbnails/57671882/Workflows%201024px-01.png?version=1&modificationDate=1585156122921&api=v2",
                "alt_text": "Workflows "
            }
        }
    ]
}

Need support? We’re here to help 🧡

If you have any questions or would like to speak with us about Workflows, please don’t hesitate to reach out to our Customer Support team.


JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.