entra-powershell icon indicating copy to clipboard operation
entra-powershell copied to clipboard

[Bug] New-AzureADMSAdministrativeUnit

Open SteveMutungi254 opened this issue 1 year ago • 1 comments

Command used:

New-AzureADMSAdministrativeUnit -DisplayName "YuWes Admin Unit" -Description "YuWes Dynamic Membership Admin Unit" -MembershipType "Dynamic" -MembershipRuleProcessingState "On" -MembershipRule '(user.country -eq "United States")'

Error:

New-EntraMSAdministrativeUnit : A parameter cannot be found that matches parameter name 'MembershipType'. At line:1 char:116

  • ... ription "YuWes Dynamic Membership Admin Unit" -MembershipType "Dynami ...
  •                                               ~~~~~~~~~~~~~~~
    
    • CategoryInfo : InvalidArgument: (:) [New-EntraMSAdministrativeUnit], ParameterBindingException
    • FullyQualifiedErrorId : NamedParameterNotFound,New-EntraMSAdministrativeUnit

SteveMutungi254 avatar Jan 06 '24 14:01 SteveMutungi254

The transformed Entra cmdlet i.e. New-EntraMSAdministrativeUnit is throwing an error because the MgGraph cmdlet is missing these parameters: [-MembershipRule <String>], [-MembershipRuleProcessingState <String>], and [-MembershipType <String>]. As a result, the Entra cmdlets won't function with these missing parameters.

v-akarke avatar Jan 12 '24 13:01 v-akarke