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 lineErrorWatch(){ | |
var token = PropertiesService.getScriptProperties().getProperty('SLACK_ACCESS_TOKEN'); | |
var slackApp = SlackApp.create(token); | |
var channelId = "#xxx" // put your slack channel id here | |
var slackId = "xxx"; // put your slack id here | |
var boticon = "http://a274.phobos.apple.com/us/r30/Purple2/v4/72/47/a9/7247a999-3323-2063-e0d4-0cf48a8a2f82/mzl.nfffibwl.png" | |
var start = 0; | |
var max = 100; | |
var filterString = 'label:line is:unread'; | |
var threads = GmailApp.search(filterString,start,max); |