msgraph-sdk-powershell icon indicating copy to clipboard operation
msgraph-sdk-powershell copied to clipboard

Failed to execute GetThreadRosterAsync

Open carles-unibas-ch opened this issue 9 months ago • 3 comments

Describe the bug

upgrade version from 2.26.1 to 2.27.0 errors our automation.

Get-MgTeamChannelMember error: Failed to execute GetThreadRosterAsync. Status: 403 (Forbidden) ErrorCode: Forbidden Date: 2025-04-24T11:30:39 Headers: Vary : Accept-Encoding Strict-Transport-Security...

Expected behavior

Get-MgTeamChannelMember OK

How to reproduce

  • Execute
Install-Module -Name "Microsoft.Graph.Teams" -Scope CurrentUser -Force -ErrorAction Stop -Confirm:$FalseImport-Module -Name "Microsoft.Graph.Teams" -Scope Local -Force -ErrorAction Stop
Get-MgTeamChannelMember -TeamId "XXX" -ChannelId "YYY"
  • see error
  • Execute
Install-Module -Name "Microsoft.Graph.Teams" -Scope CurrentUser -Force -ErrorAction Stop -Confirm:$False -RequiredVersion 2.26.1
Import-Module -Name "Microsoft.Graph.Teams" -Scope Local -Force -ErrorAction Stop -RequiredVersion 2.26.1
Get-MgTeamChannelMember -TeamId "XXX" -ChannelId "YYY"
  • no error

SDK Version

2.27.0

Latest version known to work for scenario above?

2.26.1

Known Workarounds

Use stable version:

Install-Module -Name "Microsoft.Graph.Teams" -Scope CurrentUser -Force -ErrorAction Stop -Confirm:$False -RequiredVersion 2.26.1
Import-Module -Name "Microsoft.Graph.Teams" -Scope Local -Force -ErrorAction Stop -RequiredVersion 2.26.1
Get-MgTeamChannelMember -TeamId "XXX" -ChannelId "YYY"

Debug output

raw.log

Click to expand log ```
</details>


### Configuration

_No response_

### Other information

_No response_

carles-unibas-ch avatar Apr 25 '25 07:04 carles-unibas-ch

I also see the exact same error when calling the Uri for that API directly with version 2.27.0

Invoke-MgGraphRequest -Uri https://graph.microsoft.com/v1.0/teams/<team_id>/channels/<channel_id>/allMembers gives 403 error "Failed to execute GetThreadRosterAsync".

Using the similar Invoke-MgGraphRequest -Uri https://graph.microsoft.com/v1.0/teams/<team_id>/channels/<channel_id>/members works perfectly though.

grantemsley avatar May 05 '25 17:05 grantemsley

I have the same exact issue in GCC High

ryanreckard avatar May 06 '25 18:05 ryanreckard

Same issue here : https://github.com/microsoftgraph/msgraph-sdk-powershell/issues/3321

jolscr avatar Jun 10 '25 11:06 jolscr

Please run this with the latest version of MSGraph PowerShell with the -debug flag so that we can review the output so that we can determine the cause of this error.

MIchaelMainer avatar Oct 20 '25 20:10 MIchaelMainer

@MIchaelMainer look my link... i have created a similar issue with the debug parameter so you can investigate my post.

jolscr avatar Oct 20 '25 20:10 jolscr

Closing as a duplicate of #3321

gavinbarron avatar Oct 20 '25 21:10 gavinbarron