Last active
June 16, 2018 21:03
-
-
Save deslee/a474c17f17a57940f4ad20fe8824a63d to your computer and use it in GitHub Desktop.
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
import { WebClient } from '@slack/client' | |
postMessage(teamData: TeamData, channel: string, text: string): Promise<any> { | |
const web = new WebClient(teamData.bot.bot_access_token); | |
return web.chat.postMessage({ | |
channel: channel.substring(2, channel.length-1), | |
text: text | |
}) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment