Tim Woo is technical product manager on the Skype team focused on Lync Online.
Since Windows PowerShell was released in 2006, administrators have fully embraced the scripting language for controlling and automating tasks in the Windows operating system and applications that run on Windows, including Lync. In fact, Lync administrators have come to rely on PowerShell so much that as a product manager for Lync Online, one of the first questions I often get asked at events/conferences is: “when is PowerShell coming to Lync Online?”
Well today, the Lync Online team is releasing remote PowerShell capabilities to all commercial Office 365 customers.
What can Office 365 admins do with the new Lync Online remote PowerShell?
Windows PowerShell is a command shell and scripting language that you can use to manage and automate aspects of Lync Online using a command-line instead of the browser based Office 365 admin center.
For example, to manage mobile phone notifications, also known as push notifications, you can use the Lync admin center. Push notifications enable the service to send notifications about events, such as new instant messages or new voice mail, to mobile devices such as Windows Phones and iPhones.
With today’s release, you can enable and disable push notifications by using the remote PowerShell command Set-CsPushNotificationConfiguration cmdlet. For example, the following command would disable push notifications for both iPhones and Windows Phones:
Set-CsPushNotificationConfiguration -EnableApplePushNotificationService $False -EnableMicrosoftPushNotificationService $False
In this example, you can use the Lync admin center or Windows PowerShell to enable or disable push notifications. Both approaches work equally well, and you can now use your preferred interface.
Why Use PowerShell?
Of course, that brings up an obvious question: if the Lync admin center and Windows PowerShell provide the exact same functionality, why would someone choose to use one over the other? For that matter, why would an administrator ever choose to type commands in Windows PowerShell rather than simply select and deselect checkboxes in the Lync admin center?
In a simple case such as the one just presented, the question regarding which approach to use comes down to personal preference: some people prefer using a graphical user interface while other people prefer using a command-line tool like Windows PowerShell. At other times, however, Windows PowerShell provides the most efficient way to perform a management task.
For example, if you had to set policies for hundreds of individual users, it would be quite repetitive and tedious to select the options one by one in the Office 365 admin center. With PowerShell, you can write a script with the appropriate cmdlets to automate this repetitive task and save yourself a lot of time.
In addition, there are instances where PowerShell cmdlets are the only way to perform a certain management task.
Additional Management Capabilities of PowerShell
As a general rule, any task you can carry out using the Lync Online admin center can also be carried out by using Windows PowerShell. However, there is additional functionality from PowerShell that goes beyond what is available in the Lync Online admin center. The following are a few examples (not a comprehensive list) of functionality that can be controlled via PowerShell and not from the Office 365 admin center.
Managing Exchange Unified Messaging and hosted voicemail policies:
Managing meeting room endpoint devices with a Microsoft Exchange Server 2013 resource mailbox:
Granting client inband policies using pre-created policy instances. In this example, the following policy instance can be used to block saving of IMs and call logs in Outlook for all users:
Get-CsOnlineUser | Grant-CsClientPolicy -PolicyName Tag:ClientPolicyNoSaveIMNoArchiving
In addition to the Lync Online cmdlets, you can also utilize Exchange Online cmdlets to extend the capabilities of Lync Online reports beyond the currently available reports in the Office 365 admin center (your subscription must include Exchange Online for these to work):
Get-CsActiveUserReport (Active users)
Get-CsAVConferenceTimeReport (AV Conference minutes)
Get-CsP2PAVTimeReport (Total p2p audio minutes and total p2p video minutes)
For more information, please see the following:
- Introduction to Lync Online remote PowerShell documentation
- List of Lync Online Cmdlets
- Download Windows PowerShell Module for Lync Online (Note: To install the module, you will need to be running Windows PowerShell 3.0 and have installed Microsoft Online Services Sign-In Assistant or be running Windows 8)
— Tim Woo