microsoftgraph / microsoftgraph/msgraph-sdk-powershell
New-MgTeamChannelMember fails with "Parameter set cannot be resolved using the specified named parameters."
Nessuno ha ancora preso questa issue.
- Lingua principale
- C#
- Stelle
- 898
- Fork
- 230
- Merge medio
- 2g 5h
- PR unite (30g)
- 31
Descrizione
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
- 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_
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia riproducendo New-MgTeamChannelMember con -TeamId, -ChannelId e -BodyParameters in PowerShell 5.1 o 7.4, quindi verifica quali set di parametri espone il cmdlet. Il lavoro è completato quando il comando accetta gli input documentati e aggiunge un utente a un canale privato del team senza richiedere il workaround della REST API.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- powershell
- Ambito
- cli
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Tranquilla
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 45/100