This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Get-WebSSLExpirationDate { | |
[OutputType([byte[]])] | |
PARAM ( | |
[Uri]$Uri | |
) | |
if (-Not ($uri.Scheme -eq "https")) { | |
Write-Error "You can only get keys for https addresses" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Define AppId, secret and scope, your tenant name and endpoint URL | |
$ClientID = '' | |
$ClientSecret = '' | |
$tenantDomain = "domain.onmicrosoft.com" | |
$emailSender = "shared@domain.com" | |
$emailRecipient = $emailSender | |
$emailSubject = "Email sent via GraphAPI" | |
$emailBody = "<h1>Incoming Email</h1>`n" |