cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
gkamakani
Level: Power Up

Posting to Teams

I am needing to post to specific a Team/Channel using the input from a MS Form.  Can anyone help?

8 REPLIES 8
Dual Super User
Dual Super User

Re: Posting to Teams

Hi @gkamakani 

 

Flow trigger when new response is submitted

 

there is a template for this - "Notify the team when a new response is submitted"

 

Use the post a message as a Flow bot to a channel action in Flow

 

and then in the message you can add dynamic content which is data from your MS Form

Capture.PNG

Regards,

Reza Dorrani

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

Super User
Super User

Re: Posting to Teams

Hi @gkamakani this is only a basic example but should get you going.

 

You first of all need to create a Flow which uses the "When a new response is submitted" trigger from the Forms connector. This will give you the ID of the response. Simply tell it which Form it needs to listen to for responses.

 

Secondly you need to use the "Get response details" action, again from the Forms connector. You will need to provide it with the form which it is going to get the response from, and also the Response ID, which is dynamic content provided from the trigger.

 

This will automatically create an "Apply to each" loop as there could potentially be multiple responses, but most of the time this will just be one. There are more advanced techniques for doing this without the loop, but for now we'll leave it in place.

 

Once we have got the response, we can effectively do what we want with the data. In your scenario, you want to post to Teams which can be done in a couple of ways. As @RezaDorrani has pointed out, you can post using the Flow Bot, however you can also use the "Post a message" action which will do the job. The difference is that the "Post a message" will post as you (or the account specified in the connection) whereas the Flow Bot will post as, well, the Bot.

 

I hope that helps

 

FormsToTeams.PNG





Did my reply help? Please give it a thumbs up.
Did I answer your question? Please mark my post as a solution!
If you liked my response, please consider giving it a thumbs up. THANKS!


Proud to be a Flownaut!





Community Leader: Black Country PowerApps & Flow User Group

gkamakani
Level: Power Up

Re: Posting to Teams

Thank you for your response but what I am missing is that I need to be able to have the input change or rather dictate what Team and Channel actually gets the post.  I've tried adding the Dyanmic form result of "Region" (Team name) and "Area" (which is Channel name).  I get fail with Unauthorized error. 

Unauthorized.jpg

Super User
Super User

Re: Posting to Teams

For that action to work you need to have the Flow Bot installed to the relevant Team. This is where the action in my example is slightly easier as it doesn't involve the bot being in place. If you go to Apps in the relevant Team and install Flow, then you might see that error disappear.





Did my reply help? Please give it a thumbs up.
Did I answer your question? Please mark my post as a solution!
If you liked my response, please consider giving it a thumbs up. THANKS!


Proud to be a Flownaut!





Community Leader: Black Country PowerApps & Flow User Group

Super User
Super User

Re: Posting to Teams

Also as an addition, it's not quite as clear cut as just putting dynamic content in to the Channel as it is expecting an ID rather than just plain text. 

 

In order to get the Channel ID, you need to use the List Channels action, Followed by Filter array and then use the output from the filter array in your post message.

 

Get Teams Channels.PNG





Did my reply help? Please give it a thumbs up.
Did I answer your question? Please mark my post as a solution!
If you liked my response, please consider giving it a thumbs up. THANKS!


Proud to be a Flownaut!





Community Leader: Black Country PowerApps & Flow User Group

Community Support Team
Community Support Team

Re: Posting to Teams

 

Hi @gkamakani ,

 

Have you had an opportunity to apply @MattWeston365 's recommendations to adapt your Flow? This method is suitable for your needs, please take a try.

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
gkamakani
Level: Power Up

Re: Posting to Teams

unfortunately i tried both suggestions on still end result it the same.

Super User
Super User

Re: Posting to Teams

Hi @gkamakani can you please confirm that you have the Flow app installed on the relevant Team/Channel? If that's not there, then it won't be able to communicate.





Did my reply help? Please give it a thumbs up.
Did I answer your question? Please mark my post as a solution!
If you liked my response, please consider giving it a thumbs up. THANKS!


Proud to be a Flownaut!





Community Leader: Black Country PowerApps & Flow User Group

Helpful resources

Announcements
firstImage

Power Platform Online Conference

Join us for the first ever Power Platform Online Conference!

firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

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!

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Solution Authors
Top Kudoed Authors
Users online (4,970)