web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Post Slack message as ...
Power Automate
Answered

Post Slack message as an attachment

(0) ShareShare
ReportReport
Posted on by 9

I am using a flow which simply posts a message to slack.

 

However I am wanting to post as an attachment which allows me to change the layout of the message and especially the color of verticle bar to be either danger, warning or good.

 

Is there a particular message format and parse option I need to select to be able to use attachments.

 

The info from the api documents says to use:

 

Test

{
 "attachments": [
 {
 "fallback": "Required plain-text summary of the attachment.",
 "color": "#2eb886",
 "pretext": "Optional text that appears above the attachment block",
 "author_name": "Bobby Tables",
 "author_link": "http://flickr.com/bobby/",
 "author_icon": "http://flickr.com/icons/bobby.jpg",
 "title": "Slack API Documentation",
 "title_link": "https://api.slack.com/",
 "text": "Optional text that appears within the attachment",
 "fields": [
 {
 "title": "Priority",
 "value": "High",
 "short": false
 }
 ],
 "image_url": "http://my-website.com/path/to/image.jpg",
 "thumb_url": "http://example.com/path/to/thumb.png",
 "footer": "Slack API",
 "footer_icon": "https://platform.slack-edge.com/img/default_application_icon.png",
 "ts": 123456789
 }
 ]
}
Categories:
I have the same question (0)
  • Verified answer
    v-yuazh-msft Profile Picture
    Microsoft Employee on at

    Hi @JaseC,

     

    The function to post Slack message as an attachment is not supported in microsoft flow currently.

    I afraid that there is no way to achieve your needs in Microsoft Flow currently.

     

    If you would like this feature to be added in Microsoft Flow, please submit an idea to Flow Ideas Forum:

    https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

     

    Best regards,

    Alice

  • GabrielStJohn Profile Picture
    Microsoft Employee on at

    Hello, @JaseC!

    Thank you for posting on the Flow Community Forum! If you have already posted your idea to the Flow Community Ideas Forum or found an existing idea to upvote, then you need to post the URL to the idea’s thread as a reply to this thread. Then click "Accept as Solution" on the reply if you approve it as a solution to your issue so that other users may vote for the Flow Idea and identify the information easily within this thread.

    Thank You for being an active member of the Flow Community!

    -Gabriel
    Flow Community Manager

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hello -

     

    There is actually a fix or work around for Slack to receive attachments for messages as you seek but not from the Slack action option but using the 'HTTP' action instead. This would involve in setting up a slack bot within your workspace in Slack and creating a incoming webhook for this Slack bot to the designated slack channel you desire. Here's a break down:

     

    1. Once your created a blank Flow template, search for 'HTTP Request' as the trigger:

    2. Configure the 'HTTP Request' as you need with a custom JSON payload but ensure the method is set as a 'POST'. You will be provided a URL which will be plugged into your 3rd party application example, New Relic or some type of Logic App.

    3. Next, add an action by searching for 'Control' conditioner.

    4. Configure as you see fit following the results from the incoming HTTP request.

    5. The control conditioner gives you an 'if yes' or 'if no' options... Configure both by searching for another action named 'HTTP'. The method remains the same as 'POST' and input any custom header information you may have if needed. The URI will be your incoming webhook URL from your Slack bot in your workspace. The body option is where you would input your custom Slack message to be displayed in Slack. Also, authentication and value are set per security settings within your workspace. But normally, default is usually 'raw' with value defined as 'application/json'.

     

    I've also ran into a snag with the HTTP Request URL output as its encoded and my 3rd party application service could not recognize it so I had to decode the URL from Flow and once I did that, things started rolling from there.

     

    Hope this helps.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hello -

     

    There is actually a fix or work around for Slack to receive attachments for messages as you seek but not from the Slack action option but using the 'HTTP' action instead. This would involve in setting up a slack bot within your workspace in Slack and creating a incoming webhook for this Slack bot to the designated slack channel you desire. Here's a break down:

     

    1. Once your created a blank Flow template, search for 'HTTP Request' as the trigger:

    2. Configure the 'HTTP Request' as you need with a custom JSON payload but ensure the method is set as a 'POST'. You will be provided a URL which will be plugged into your 3rd party application example, New Relic or some type of Logic App.

    3. Next, add an action by searching for 'Control' conditioner.

    4. Configure as you see fit following the results from the incoming HTTP request.

    5. The control conditioner gives you an 'if yes' or 'if no' options... Configure both by searching for another action named 'HTTP'. The method remains the same as 'POST' and input any custom header information you may have if needed. The URI will be your incoming webhook URL from your Slack bot in your workspace. The body option is where you would input your custom Slack message to be displayed in Slack. Also, authentication and value are set per security settings within your workspace. But normally, default is usually 'raw' with value defined as 'application/json'.

     

    I've also ran into a snag with the HTTP Request URL output as its encoded and my 3rd party application service could not recognize it so I had to decode the URL from Flow and once I did that, things started rolling from there.

     

    Hope this helps.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 552

#2
Valantis Profile Picture

Valantis 388

#3
11manish Profile Picture

11manish 375

Last 30 days Overall leaderboard