/PSWinDocumentation.O365HealthService

PSWinDocumentation.O365HealthService is a Powershell module that has a single goal of getting Office 365 Health Status

Primary LanguagePowerShellMIT LicenseMIT

PSWinDocumentation.O365HealthService - PowerShell Module

PSWinDocumentation.O365HealthService is a Powershell module that has a single goal of getting Office 365 Health Status

Overview

Required Permissions

Please not that Microsoft deprecates the old way of accessing Service Health API. Since version 1.0+ you need to modify permissions for it to work properly.

https://evotec.xyz/wp-content/uploads/2022/01/img_61f59e2b000c3.png

Install

Install-Module PSWinDocumentation.O365HealthService -Force

Example 1

Here's a live demo generated using Dashimo: https://evotec.xyz/wp-content/uploads/2019/05/Health.html

Import-Module PSWinDocumentation.O365HealthService -Force
Import-Module PSWriteHTML -Force

$ApplicationID = ''
$ApplicationKey = ''
$TenantDomain = 'evotec.pl' # CustomDomain (onmicrosoft.com won't work), alternatively you can use DirectoryID

$O365 = Get-Office365Health -ApplicationID $ApplicationID -ApplicationKey $ApplicationKey -TenantDomain $TenantDomain -Verbose

Dashboard -FilePath $PSScriptRoot\Health.html {
    TabOption -BorderRadius 0px -BackgroundColorActive DimGrey
    SectionOption -BorderRadius 0px -HeaderBackGroundColor DimGrey
    TableOption -DataStore JavaScript -ArrayJoinString "; " -ArrayJoin -BoolAsString
    Tab -Name 'Services' {
        Section -Name 'Service List' {
            Table -DataTable $O365.Services -Filtering
        }
    }
    Tab -Name 'Current Status' {
        Section -Invisible {
            Section -Name 'Current Status' {
                Table -DataTable $O365.CurrentStatus {
                    TableCondition -Name 'ServiceStatus' -Value 'serviceOperational' -BackgroundColor MintGreen -FailBackgroundColor Salmon
                } -Filtering
            }
            Section -Name 'Current Status Extended' {
                Table -DataTable $O365.CurrentStatusExtended {
                    TableCondition -Name 'ServiceStatus' -Value 'serviceOperational' -BackgroundColor MintGreen -FailBackgroundColor Salmon
                } -Filtering
            }
        }
    }
    Tab -Name 'Message Center Information' {
        #Section -Invisible {
        Section -Name 'Message Center' {
            Table -DataTable $O365.MessageCenterInformation -Filtering
        }
        Section -Name 'Message Center Extended' {
            Table -DataTable $O365.MessageCenterInformationExtended -InvokeHTMLTags -Filtering
        }
        #}
    }
    Tab -Name 'Incidents' {
        Section -Invisible {
            Section -Name 'Incidents' {
                Table -DataTable $O365.Incidents -Filtering {
                    TableCondition -Name 'IsResolved' -Value $true -BackgroundColor MintGreen -FailBackgroundColor Salmon -ComparisonType bool
                }
            }
            Section -Name 'Incidents Extended' {
                Table -DataTable $O365.IncidentsExtended -Filtering {
                    TableCondition -Name 'IsResolved' -Value $true -BackgroundColor MintGreen -FailBackgroundColor Salmon -ComparisonType bool
                }
            }
        }
        Section -Name 'Incidents Messages' {
            Table -DataTable $O365.IncidentsUpdates -InvokeHTMLTags -Filtering
        }
    }
} -Online -ShowHTML

Example 2

Import-Module PSWinDocumentation.O365HealthService -Force

$ApplicationID = ''
$ApplicationKey = ''
$TenantDomain = 'evotec.pl' # CustomDomain (onmicrosoft.com won't work), alternatively you can use DirectoryID

$O365 = Get-Office365Health -ApplicationID $ApplicationID -ApplicationKey $ApplicationKey -TenantDomain $TenantDomain -Verbose
$O365.CurrentStatus | Format-Table -AutoSize

Output:

Service                                 ServiceStatus       StatusTime          IncidentIds
-------                                 -------------       ----------          -----------
Exchange Online                         Restoring service   21.04.2019 16:54:19 EX177902
Microsoft Kaizala                       Normal service      21.04.2019 16:54:19
Skype for Business                      Service degradation 21.04.2019 16:54:19 LY177449
Microsoft Teams                         Normal service      21.04.2019 16:54:19
Mobile Device Management for Office 365 Normal service      21.04.2019 16:54:19
Office Online                           Normal service      21.04.2019 16:54:19
OneDrive for Business                   Normal service      21.04.2019 16:54:19
Identity Service                        Normal service      21.04.2019 16:54:19
Office 365 Portal                       Normal service      21.04.2019 16:54:19
Planner                                 Normal service      21.04.2019 16:54:19
SharePoint Online                       Normal service      21.04.2019 16:54:19
Microsoft StaffHub                      Normal service      21.04.2019 16:54:19
Sway                                    Normal service      21.04.2019 16:54:19
Yammer Enterprise                       Normal service      21.04.2019 16:54:19

Example 3

Import-Module PSWinDocumentation.O365HealthService -Force

$ApplicationID = ''
$ApplicationKey = ''
$TenantDomain = 'evotec.pl' # CustomDomain (onmicrosoft.com won't work), alternatively you can use DirectoryID

$O365 = Get-Office365Health -ApplicationID $ApplicationID -ApplicationKey $ApplicationKey -TenantDomain $TenantDomain -Verbose
$O365.CurrentStatus | Format-Table -AutoSize

Output:


ID                       Service                                   ServiceStatus      StatusTime          Incidents
--                       -------                                   -------------      ----------          ---------
Exchange                 Exchange Online                           serviceDegradation 29.01.2022 21:14:47 {EX316072, EX316697}
OrgLiveID                Identity Service                          serviceOperational 29.01.2022 21:14:47
OSDPPlatform             Microsoft 365 suite                       serviceOperational 29.01.2022 21:14:47
Lync                     Skype for Business                        serviceOperational 29.01.2022 21:14:47
SharePoint               SharePoint Online                         serviceOperational 29.01.2022 21:14:47
DynamicsCRM              Dynamics 365 Apps                         serviceOperational 29.01.2022 21:14:47
RMS                      Azure Information Protection              serviceOperational 29.01.2022 21:14:47
yammer                   Yammer Enterprise                         serviceOperational 29.01.2022 21:14:47
MobileDeviceManagement   Mobile Device Management for Office 365   serviceOperational 29.01.2022 21:14:47
Planner                  Planner                                   serviceOperational 29.01.2022 21:14:47
SwayEnterprise           Sway                                      serviceOperational 29.01.2022 21:14:47
PowerBIcom               Power BI                                  serviceOperational 29.01.2022 21:14:47
Intune                   Microsoft Intune                          serviceOperational 29.01.2022 21:14:47
OneDriveForBusiness      OneDrive for Business                     serviceOperational 29.01.2022 21:14:47
microsoftteams           Microsoft Teams                           serviceOperational 29.01.2022 21:14:47
StaffHub                 Microsoft StaffHub                        serviceOperational 29.01.2022 21:14:47
kaizalamessagingservices Microsoft Kaizala                         serviceOperational 29.01.2022 21:14:47
Bookings                 Microsoft Bookings                        serviceOperational 29.01.2022 21:14:47
officeonline             Office for the web                        serviceOperational 29.01.2022 21:14:47
O365Client               Microsoft 365 Apps                        serviceOperational 29.01.2022 21:14:47
PowerAppsM365            Power Apps in Microsoft 365               serviceOperational 29.01.2022 21:14:47
MicrosoftFlow            Microsoft Power Automate                  serviceOperational 29.01.2022 21:14:47
MicrosoftFlowM365        Microsoft Power Automate in Microsoft 365 serviceOperational 29.01.2022 21:14:47
Forms                    Microsoft Forms                           serviceOperational 29.01.2022 21:14:47
Microsoft365Defender     Microsoft 365 Defender                    serviceOperational 29.01.2022 21:14:47
Stream                   Microsoft Stream                          serviceOperational 29.01.2022 21:14:47
Viva                     Microsoft Viva                            serviceOperational 29.01.2022 21:14:47
cloudappsecurity         Microsoft Defender for Cloud Apps         serviceOperational 29.01.2022 21:14:47