Slack integration using Webhook

Slack integration:

Integration with slack can be used to send alerts to users and channels to notify when certain events are triggered.

Step 1. Create flow

  • Create an HTTP Server
  • Create an endpoint
    • NOTE: under properties the method must be POST
  • From the right panel, press Action tab -> communication, Drag and drop HTTP-Request to the end of the flow
  • From the right panel, press Action tab -> data, Drag and drop Set to the end of the flow

Communication/HTTP-request

Properties:

url: NOTE: Paste the slack webhook created from step 2.

Method: POST

Body: Contents of what is being posted to slack. NOTE: May need to specify the content type as application json.  { “Content-Type”: “Application/JSON” }

Header: blank

Query: blank

Timeout: Default

Output:

Output-location: Drag and drop the response body from right data panel

Data/Set

Properties:

Value:

Output:

At-location: drag and drop the response body from the right panel 

 

Step 2. Configure slack api webhook

  • Navigate to api.slack.com
  • Once logged in click on Your Apps on the right end of the navigation bar
  • Select Create New App
    • Create the application name and select which workspace this app will belong too
  • Select basic information underneath the settings. Select add features and functionality.  From here you can add additional functionality but for this example we just are using incoming webhooks.
  • After selecting and activating incoming webhooks. Scroll to the bottom and select add new webhook to workspace. Select which channel to post to and allow.
  • Copy JUST the URL from the sample. NOTE: Your webhook will be unique
  • Paste the slack webhook on the url line under properties from the communication/http-request action

Step 3. Test and Send Messages to your workspace

Using Talent API Tester:

  • Select Method Post and Paste your slack http server. NOTE: Yours may differ

For Additional help on sending messages Slack webhooks:

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments