cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Post Slack Message to an Individual from Dynamic Content

I'm trying to send a Slack message to an individual user, with that person's username as a piece of dynamic content. If I just type a username in the Slack channel name (@user), it works fine, but I'm trying to direct the message to a user based on a lookup of the username in a Sharepoint list. When I try to use the dynamic content from the lookup earlier in the Flow, the Slack message send step throws an error, as it thinks the channel name is @{body('Get_item')['HostID']}. I've tried writing the HostID as a string variable and passing the string into the Slack step, but it returns the same error, thinking the channel name is @{variables('hostID')}. I tried putting the dynamic username into a tolower() function, that also didn't help.

 

Any thoughts on a workaround here? I found this discussion from 2016, but it seems like any kind of dynamic content is rejected by Slack.

2 ACCEPTED SOLUTIONS

Accepted Solutions
Frequent Visitor

Re: Post Slack Message to an Individual from Dynamic Content

Thanks for your help @v-yamao-msft. I was able to do what I need to do by pushing the messages directly into Slack from PowerApps, rather than going through Flow as an intermediate step.

View solution in original post

Highlighted
Frequent Visitor

Re: Post Slack Message to an Individual from Dynamic Content

@chico: Make sure you have the Slack connection installed. Then you can use the Slack.PostMessage command in PowerApps:

 

Slack.PostMessage("#channelname", "MessageText", {username:"Bot", parse:"full"})

 

The details of the connector are here

View solution in original post

4 REPLIES 4
Highlighted
Community Support
Community Support

Re: Post Slack Message to an Individual from Dynamic Content

Hi @amarkit ,

 

Thanks for feedback. The issue could be reproduced by me.

 

I am afraid that @ mention has not been supported currently by Flow.

 

Please feel free submit your request on Flow Ideas Forum at here:

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

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Frequent Visitor

Re: Post Slack Message to an Individual from Dynamic Content

Thanks for your help @v-yamao-msft. I was able to do what I need to do by pushing the messages directly into Slack from PowerApps, rather than going through Flow as an intermediate step.

View solution in original post

Highlighted
Advocate II
Advocate II

Re: Post Slack Message to an Individual from Dynamic Content

got any reference or pointers on how/what you did in powerapps to send to slack?

Highlighted
Frequent Visitor

Re: Post Slack Message to an Individual from Dynamic Content

@chico: Make sure you have the Slack connection installed. Then you can use the Slack.PostMessage command in PowerApps:

 

Slack.PostMessage("#channelname", "MessageText", {username:"Bot", parse:"full"})

 

The details of the connector are here

View solution in original post

Helpful resources

Announcements
firstImage

Super User Program Update

Three Super User rank tiers have been launched!

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

firstImage

Join the new Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Top Solution Authors
Top Kudoed Authors
Users online (10,418)