Office 365 licenses

Gagandeep Singh Hoda 1 Reputation point
2020-07-30T19:12:57.48+00:00

Dear Team

I want to know about the poerwshell scriot which can give list of users with microsoft teams licenses as part of E3

In my organization we have applied e3 liceses only for sharepoint and few only for teams

I need the script to list user only with ms teams active licenses

Microsoft Exchange Online Management
Microsoft Exchange Online Management
Microsoft Exchange Online: A Microsoft email and calendaring hosted service.Management: The act or process of organizing, handling, directing or controlling something.
4,576 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Vasil Michev 107.7K Reputation points MVP
    2020-07-30T19:33:55.863+00:00

    You can use something like this:

    Get-MsolUser  | ? {$_.Licenses.ServiceStatus | ? {$_.ServicePlan.ServiceName -eq "TEAMS1" -and $_.ProvisioningStatus -eq "Success"}}
    
    0 comments No comments

  2. KyleXu-MSFT 26,266 Reputation points
    2020-07-31T05:46:07.767+00:00

    Follow this article to install MSOnline module : Connect with the Microsoft Azure Active Directory Module for Windows PowerShell

    Then connect to Azure AD with command below:

    Connect-MsolService  
    

    After that, you can use command provided by michev to filter the suitable account.

    If there also exist other subscriptions plan(such as E5, business) in your organization, you can use command below to only check for account which has E3 license:

    Get-MsolUser | where {$_.Licenses.AccountSkuId -like "*e3*"} | where {$_.Licenses.ServiceStatus | ? {$_.ServicePlan.ServiceName -eq "TEAMS1" -and $_.ProvisioningStatus -eq "Success"}}  
    
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.