Solution for Errors:
1) DiscourseChat::ProviderError
2) {\"ok\":false,\"error\":\"not_in_channel\"}
Trying to make this more obvious because it was unfortunately difficult to find the answer. The Slack App creation process has changed a bit since these instructions. And it seems the actual integration of the bot with a channel in Slack takes a bit more setup as well.
From my Slack workspace, I could confirm the app was working by DM’ing the bot @discourse as well as the running commands /discourse. But from the Discourse Plugin settings, I was receiving errors and could not set a channel nor send a test message.
How to implement
EDIT: there is updated information in the replies below. I’ve attempted to incorporate the additional steps here as of 4/6/20. Please comment or modify these as needed. - dp
- Bot permissions:
chat:write.customizepermission needs to be added in order for the /discourse post slash command to work. I also addedchat:write. - You’ll need to create the channel in Slack. And then either run the
/discoursecommands from the channel or set up a rule in Discourse. - You need to manually add the bot to the channel of interest (at least to post a transcript)! You can do this in the private conversation with the bot in slack:
"conversation settings" > "add this app to a channel". - Then, importantly, you need to add the discourse bot user to the channel. I could not get this to work through the normal channel “add user” or “add app” buttons. BUT I was successful by sending a message to “@discourse” within the channel → I was then prompted by slack with the message “@discourse is not in this channel, would you like to add?”
- I could then run a test message successfully from Plugins settings

Note: in the Slack app setup I set the App name to @discourse