How do I make a slack bot leave a channel?

talloaktrees picture talloaktrees · Jul 5, 2016 · Viewed 33.4k times · Source

Bots cannot use the regular channels.leave API call, so how do I make a bot leave a channel, short of kicking it? I need it to leave a channel where I do not have rights to kick users.

Answer

guillaume.deslandes picture guillaume.deslandes · Jul 6, 2016

You can /remove (or /kick) the bot. Type /kick @botname in the channel which you want the bot to leave.