Hacktoberfest 2026:維護者為十月標記出來的 issue,仍然開放、適合新手。 瀏覽 Hacktoberfest issue

New-MgTeamChannelMember fails with "Parameter set cannot be resolved using the specified named parameters."

未關閉
#3,471 2 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

維護者通常 1 天內回覆

還沒有人認領這個 Issue。

評估

難度
3/5
預估耗時
1-2 天
新手友好度
45/100
Issue 類型
缺陷
描述清晰度
需要釐清
活躍度
冷清
技術堆疊
powershell
領域
cli

研究方向

先在 PowerShell 5.1 或 7.4 上使用 -TeamId、-ChannelId 和 -BodyParameters 重現 New-MgTeamChannelMember,然後檢查該 cmdlet 公開了哪些參數集。命令能夠接受文件中說明的輸入,並在不需要 REST API workaround 的情況下將使用者新增至私人團隊頻道,即表示完成。

由索引模型根據 Issue 內容生成。

描述

Needs: Directive type:bug
Describe the bug

When running the command "New-MgTeamChannelMember" using PowerShell 5.1 or 7.4 we receive an error message.

Error:
Parameter set cannot be resolved using the specified named parameters. One or more parameters issued cannot be used together or an insufficient number of parameters were provided.

This is also discussed in https://github.com/microsoftgraph/msgraph-sdk-powershell/discussions/3370

Module:
Microsoft.Graph.Teams v2.33.0

Expected behavior

Running the command should add the user to the private team channel.

How to reproduce
  1. Execute New-MgTeamChannelMember with the -TeamId, -ChannelId, and -BodyParameters
SDK Version

2.33.0

Latest version known to work for scenario above?

No response

Known Workarounds

One known workaround is to use the Graph REST API instead of the cmdlet New-MgTeamChannelMember

Debug output
Click to expand log ```
</details>


### Configuration

- OS: Windows Server 2019
- 64 bit
- PowerShell details
PS C:\Windows\system32> $PSVersionTable

Name                           Value                                                                                                                                                               
----                           -----                                                                                                                                                               
PSVersion                      5.1.17763.8024                                                                                                                                                      
PSEdition                      Desktop                                                                                                                                                             
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}                                                                                                                                             
BuildVersion                   10.0.17763.8024                                                                                                                                                     
CLRVersion                     4.0.30319.42000                                                                                                                                                     
WSManStackVersion              3.0                                                                                                                                                                 
PSRemotingProtocolVersion      2.3                                                                                                                                                                 
SerializationVersion           1.1.0.1   

Name                           Value
----                           -----
PSVersion                      7.4.13
PSEdition                      Core
GitCommitId                    7.4.13
OS                             Microsoft Windows 10.0.17763
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0


### Other information

_No response_
主要語言
C#
星號
901
分支
232
平均合併
1 天 5 小時
30 天內合併 PR
20

環境準備

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

microsoftgraph/msgraph-sdk-powershell 的其他 Issue

查看 microsoftgraph/msgraph-sdk-powershell 的全部 Issue

相似的 Issue

更多 C# Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。