I create a slackbot fusing the following from this guide:
var util = require('util');
var path = require('path');
var fs = require('fs');
var SQLite = require('sqlite3').verbose();
var Bot = require('slackbots');
The slackbot I created is basic by replying to keywords and posting messages back in the channel using: this.postMessageToChannel(...)
What I would like is to use functions I see from the slack API such as the ability for the slackbot to leave a channel by itself. The channel.leave
function found here in the slack API looks to be able to do this however I am not sure how to get it to work.
How am I able to use this Slack api correctly? Specifically starting with the channel.leave
method?