A Blog About Exchange & Office 365

Menu

PowerShell Cmdlets of Office 365: They are a Changin’

Microsoft’s cloud offering, Office 365, is in a constant state of flux. This state is driven by the amount of changed, additions and features that are made to the service. For customers, this state of change can be a bit bewildering, but Microsoft has provided some guidance on the changes with their Roadmap page for Office 365. This roadmap can be found here :

Notice the stages of feature releases. What you won’t see is PowerShell changes specifically declared. Just because the changes are not declared, does not mean the changes are not present. So how do we find those changes?Using PowerShell to Find PowerShell Changes

Office 365 PowerShell covers many services – Exchange Online, SharePoint Online, Skype for Business, Azure, Rights Management (recently renamed), Security and Compliance and more. To discover these cmdlets we need to make a connection to each of the services that are hosted in Office 365. The question is, how do we find those connections for PowerShell.

First, start with your favorite search engine and begin looking into each service. Here are some sample search terms that I’ve used to find the answers and get official documentation on connecting:

With each connection we can gather all the cmdlets for each of these connection points. Each connection provides unique module names to report on. Once connected, we can gather up a list of cmdlets from each Module and store this in a file for later reference. Why do this? For consultants, knowing what the latest or newest of something in a product helps give us a leg up and greater understanding so we can assist our customers with their environment. For engineers that directly support their systems, knowing what cmdlets are available and what has changed helps with performing the job better.

The above code will work for the cmdlets in the Azure PowerShell Module. Other modules can be processed in the same manner.

About a week or two after checking for this, a script I had writing (which I will go through in my next post) found that two cmdlets were added in the Exchange Online set of cmdlets. These cmdlets were added to the PowerShell module for Exchange. Also, one cmdlets was added to Security and Compliance Center as well. After that I added a way for my script to email me and I have it scheduled to run once per day. So now I get a daily report of any changes in Powershell for various (but not all) modules for Office 365 PowerShell.

The cmdlets lists are stored on a file server and I can open a file from the previous day or week and see what cmdlets were available at that point in time:

** Note ** You can even go as far as to restrict access to remote PowerShell for a service if you want as well. See this LINK for an example of how to do this.

How to script for this?

Look for a post on Friday on how to create a script that will connect to each service, record the cmdlets available per module and then send a notification email if the amount of cmdlets has changed from week to week. I explain each step and decision as the script is built and provide a completed script at the end. After the post is dropped, let me know in the comments if you would like the code put in the TechNet Wiki or somewhere.