CmdID / PowerShell / Cmdlets / Set
Set-MgUserLicense
Add or remove licenses for the user to enable or disable their use of Microsoft cloud offerings that the company has licenses to. Microsoft Graph PowerShell reference
From the Microsoft Graph PowerShell reference 16 parameters Its page in the reference
Parameters
-AdditionalPropertiesAdditional Parameters-AddLicensesTo construct, see NOTES section for ADDLICENSES properties and create a hash table.-BodyParameterTo construct, see NOTES section for BODYPARAMETER properties and create a hash table.-BreakWait for .NET debugger to attach-Confirm, -cfPrompts you for confirmation before running the cmdlet.-HeadersOptional headers that will be added to the request.-HttpPipelineAppendSendAsync Pipeline Steps to be appended to the front of the pipeline-HttpPipelinePrependSendAsync Pipeline Steps to be prepended to the front of the pipeline-InputObjectIdentity Parameter To construct, see NOTES section for INPUTOBJECT properties and create a hash table.-ProxyThe URI for the proxy server to use-ProxyCredentialCredentials for a proxy server to use for the remote call-ProxyUseDefaultCredentialsUse the default credentials for the proxy-RemoveLicenses-ResponseHeadersVariable, -RHVOptional Response Headers Variable.-UserIdThe unique identifier of user-WhatIf, -wiRuns the command in a mode that only reports what would happen without performing the actions.