Last active
January 19, 2022 02:19
-
-
Save pmatthews05/951656ac653fc827e379bd84fa31eb9d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param( | |
#OutPut CSV File Path | |
[Parameter(Mandatory)] | |
[string] | |
$Path | |
) | |
$InformationPreference = 'Continue' | |
Write-Information -MessageData "Obtaining Module, please connect when prompted..." | |
Import-Module "C:\\Program Files\\Common Files\\Skype for Business Online\\Modules\\SkypeOnlineConnector\\SkypeOnlineConnector.psd1" | |
$Session = New-CsOnlineSession | |
Import-PSSession -Session:$Session -AllowClobber | |
Write-Information -MessageData "Getting all enabled users" | |
$Users = Get-CsOnlineUser | Select-Object DisplayName, ` | |
UserPrincipalName, ` | |
SipAddress, ` | |
TeamsMeetingPolicy, ` | |
TeamsMessagingPolicy, ` | |
TeamsMeetingBroadcastPolicy, ` | |
TeamsAppPermissionPolicy, ` | |
TeamsAppSetupPolicy, ` | |
TeamsCallParkPolicy, ` | |
TeamsCallingPolicy, ` | |
CallerIdPolicy, ` | |
TeamsChannelsPolicy, ` | |
TeamsEmergencyCallingPolicy, ` | |
TeamsEmergencyCallRoutingPolicy, ` | |
TenantDialPlan, ` | |
TeamsUpgradePolicy | |
$Users | Export-Csv -Path:$Path -NoTypeInformation | |
Write-Information "Complete" | |
Remove-PSSession -Session:$session |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment