QuickTip: Getting the Microsoft Teams Team ID and Channel ID for Power Automate Flows

When working with Power Automate recently I was struggling being able to get the Teams and Channel IDs but with a bit of Googling I managed to work out how to obtain this information. So all that is required is the following expressions created under Data Operation

For Microsoft Teams Team IDs

first(split(last(split(triggerBody()['webUrl'],'groupId=')),'&tenantId'))

For Microsoft Teams Channel IDs

replace(replace(last(split(first(split(triggerBody()['webUrl'],concat('/',triggerBody()?['etag']))),'message/')),'%3A',':'),'%40','@')

With these expressions within your Power Automate flows you will be able to gather the required information.

Regards
The Author – Blogabout.Cloud

Leave a Reply

Your email address will not be published. Required fields are marked *