Public/Utility/Send-KriticalUtcmPushNotification.ps1
|
<# .SYNOPSIS Kritical.UTCM wrapper over Microsoft365DSC helper Send-M365DSCPushNotification (category: Utility, module: M365DSCUtil). .DESCRIPTION Thin delegating passthrough — logic stays in Microsoft365DSC upstream; Kritical.UTCM provides the friendly namespace + citation registration. Install-Module Microsoft365DSC -Scope CurrentUser BEFORE calling. .NOTES Category: Utility Module: M365DSCUtil Params: 1 #> function Send-KriticalUtcmPushNotification { [CmdletBinding()] param( [Parameter(Mandatory)] [String] $Body ) if (-not (Get-Command -Name 'Send-M365DSCPushNotification' -ErrorAction SilentlyContinue)) { throw '[KriticalUtcm] Send-M365DSCPushNotification not available — Install-Module Microsoft365DSC -Scope CurrentUser then re-run' } try { & 'Send-M365DSCPushNotification' @PSBoundParameters } catch { Write-Error ('[KriticalUtcm/Send-KriticalUtcmPushNotification] ' + 'Send-M365DSCPushNotification' + ' failed: ' + $_.Exception.Message) throw } } |