Hello all,
I'm using PowerShell version 5.1.26100.2161 in case that's relevant.
What I'm trying to do:
I'm trying to use the PowerShell functions Get-TeamsProtectionPolicy and Get-TeamsProtectionPolicyRule to view a company's Teams protection policy info. However, those functions don't appear to be included in the ExchangeOnlineManagment version 3.7.0, even though some people seem to reference using that moduel for these functions.
What I initially tried:
Looking on Microsoft's website, it appears those functions are a part of the ExchangePowerShell module, so I installed it. However, when I try to run Import-Module ExchangePowerShell, it throws an error saying "import-Module : Exchange Server system variable ExchangeInstallPath missing."
This seems to be in reference to an on-premises Exchange server, which most of the environments I'd be running this in don't have, and it shouldn't be necessary for functions that are meant to be used for Microsoft 365 environments.
When I search the error online:
When I search online for if other people have had this issue, I'm seeing recommendations to manually set the Exchange install path variable. However, I don't want to have my PowerShell script automatically do this because I may run the script in environments where they actually do have an on-premises Exchange server, and I don't want the script to change that. Also, this script is meant to be run as a "read-only" script that shouldn't be making changes to a company's environment, so changing an Exchange install path variable wouldn't be acceptable.
My ultimate goal is to get access to these two Teams PowerShell functions--does anyone know what I need to do for this?
Thanks,
Brett