Created
September 4, 2017 05:38
-
-
Save darrenjrobinson/71ef9509f7abcea70e84e44505e3c58c to your computer and use it in GitHub Desktop.
Send a Test Message to confirm configuration
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
# My Push Bullet Access Token | |
# Created via Profile Page https://www.pushbullet.com/#settings/account | |
$accessToken = 'o.oy3Un8Zb56FjJa8cQVNQ1234567890' | |
# Push Bullet API URI | |
$apiURI = "https://api.pushbullet.com/" | |
# Web Request Header | |
$header = @{"Access-Token" = $accessToken | |
'Content-Type' = "application/json" | |
} | |
$content = @{ | |
"type" = "note" | |
"title" = "MIM Azure Function Error" | |
"body" = "Test Message" | |
} | |
$body = $content | ConvertTo-Json | |
# Test POST | |
$notification = Invoke-RestMethod -Method Post -Headers $header -Uri ($apiURI +"v2/pushes") -Body $body | |
$notification |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment