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
'use strict'; | |
const axios = require('axios'); // axios must be installed via npm i axios | |
const webhookURL = "https://outlook.office.com/webhook/1234567890"; // Replace with a valid webhool URL obtained by adding an "Incomming Webhook" connector to your teams channel | |
if (process.argv.length === 4) { | |
const title = process.argv[2]; | |
const message = process.argv[3]; | |
console.log(`${title}, ${message}`); | |
postMessageToTeams(title, message); | |
} else { |