Forum Discussion
Teams Shared Channel PowerShell, Retrieve Members and Teams
- Aug 15, 2023
AlistairKeay1 to retrieve the list of teams a for a shared channel, use the https://learn.microsoft.com/en-us/powershell/module/teams/get-sharedwithteam?view=teams-ps command
For example,
Get-SharedWithTeam -HostTeamId id-of-the-team-that-created-the-shared-channel -ChannelId id-of-the-shared-channelIt will return the teams that shared channel is shared with
Also, you can see all the Shared Channels that are shared with a specific team (the reverse lookup of what you are doing) via https://learn.microsoft.com/en-us/powershell/module/teams/get-teamallchannel?view=teams-ps cmlet
AlistairKeay1 to retrieve the list of teams a for a shared channel, use the https://learn.microsoft.com/en-us/powershell/module/teams/get-sharedwithteam?view=teams-ps command
For example,
Get-SharedWithTeam -HostTeamId id-of-the-team-that-created-the-shared-channel -ChannelId id-of-the-shared-channel
It will return the teams that shared channel is shared with
Also, you can see all the Shared Channels that are shared with a specific team (the reverse lookup of what you are doing) via https://learn.microsoft.com/en-us/powershell/module/teams/get-teamallchannel?view=teams-ps cmlet