- 25 Sep 2024
- 2 Minutes to read
- Print
- DarkLight
- PDF
Get-MSTeamsUserLicense
- Updated on 25 Sep 2024
- 2 Minutes to read
- Print
- DarkLight
- PDF
Return Teams licensed users for a given tenant.
Description
Return Teams licensed users for a given tenant. Excludes disabled accounts.
Syntax
Get-MSTeamsUserLicense
-CountOnly <Boolean>
-LicenseType <String>
-ExportCSV <String>
-TenantName <String>
-HideProgressBar
-ProgressUpdateFreq <Int32>
-UserList <Object>
-MSClientID <String>
-MSClientSecret <String>
-MSTenantID <String>
-AuthToken <String>
Examples
Example 1
Get-MSTeamsUserLicense -TenantName contoso
Shows the Teams user count for Contoso
Example 2
Get-MSTeamsUserLicense -ExportCSV TeamsList.csv
Exports a list of all Teams users to a CSV file
Example 3
Get-MSTeamsUserLicense -ExportCSV TeamsList-EV.csv -LicenseType EV
Exports a list of all Teams users with a Phone license to a CSV file
Parameters
-CountOnly <Boolean>
Only return a total count. Much faster than pulling the entire list of users. Shows columns for All Teams licensed users, Teams Phone licensed users and MTR license counts. This is on by default.
Parameter | Value |
---|---|
Required | false |
Position | 1 |
Required | false |
Default Value | True |
Accept pipeline input? | false |
Accept wildcard characters? | false |
-LicenseType <String>
What license type of Teams licensed users to export. Choose from All, EV, MTR. Only useful when pulling the entire user list, instead of a count. Defaults to All.
Parameter | Value |
---|---|
Required | false |
Position | 2 |
Required | false |
Default Value | All |
Accept pipeline input? | false |
Accept wildcard characters? | false |
-ExportCSV <String>
Exports the list of users and the assigned Teams SKU to a CSV file. Assumes CountOnly is $FALSE
Parameter | Value |
---|---|
Required | false |
Position | 3 |
Required | false |
Default Value | None |
Accept pipeline input? | false |
Accept wildcard characters? | false |
-TenantName <String>
The name of the Nectar DXP tenant. Used in multi-tenant configurations.
Parameter | Value |
---|---|
Required | false |
Position | 4 |
Required | false |
Default Value | None |
Accept pipeline input? | true (ByPropertyName) |
Accept wildcard characters? | false |
-HideProgressBar <SwitchParameter>
Don't show the progress bar. Cleans up logs when running on Docker.
Parameter | Value |
---|---|
Required | false |
Position | named |
Required | false |
Default Value | False |
Accept pipeline input? | false |
Accept wildcard characters? | false |
-ProgressUpdateFreq <Int32>
How frequently to show progress updates, in seconds. Defaults to 1 second
Parameter | Value |
---|---|
Required | false |
Position | 5 |
Required | false |
Default Value | 1 |
Accept pipeline input? | false |
Accept wildcard characters? | false |
-UserList <Object>
Use a previously obtained list of Azure user IDs. If this isn't specified, then a list will be downloaded using Get-MSAzureUser
Parameter | Value |
---|---|
Required | false |
Position | 6 |
Required | false |
Default Value | None |
Accept pipeline input? | false |
Accept wildcard characters? | false |
-MSClientID <String>
The MS client ID for the application granted access to Azure AD.
Parameter | Value |
---|---|
Required | false |
Position | 7 |
Required | false |
Default Value | None |
Accept pipeline input? | true (ByPropertyName) |
Accept wildcard characters? | false |
-MSClientSecret <String>
The MS client secret for the application granted access to Azure AD.
Parameter | Value |
---|---|
Required | false |
Position | 8 |
Required | false |
Default Value | None |
Accept pipeline input? | true (ByPropertyName) |
Accept wildcard characters? | false |
-MSTenantID <String>
The MS tenant ID for the O365 customer granted access to Azure AD.
Parameter | Value |
---|---|
Required | false |
Position | 9 |
Required | false |
Default Value | None |
Accept pipeline input? | true (ByPropertyName) |
Accept wildcard characters? | false |
-AuthToken <String>
The authorization token used for this request. Normally obtained via Get-MSGraphAccessToken
Parameter | Value |
---|---|
Required | false |
Position | 10 |
Required | false |
Default Value | None |
Accept pipeline input? | true (ByPropertyName) |
Accept wildcard characters? | false |