From c602121171b77029e536a0a445a3808f40e3c78c Mon Sep 17 00:00:00 2001 From: rht Date: Sat, 3 Jul 2021 22:06:29 -0400 Subject: [PATCH] slack bridge: Update doc for current version of making Slack bot user. --- zulip/integrations/bridge_with_slack/README.md | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/zulip/integrations/bridge_with_slack/README.md b/zulip/integrations/bridge_with_slack/README.md index 3ce1568..209c644 100644 --- a/zulip/integrations/bridge_with_slack/README.md +++ b/zulip/integrations/bridge_with_slack/README.md @@ -15,9 +15,19 @@ This is a bridge between Slack and Zulip. ### 2. Slack endpoint 1. Make sure Websocket isn't blocked in the computer where you run this bridge. Test it at https://www.websocket.org/echo.html. -2. Go to https://api.slack.com/apps?new_classic_app=1 and create a new classic app (note: must be a classic app). Choose a bot name that will be put into bridge_with_slack_config.py, e.g. "zulip_mirror". Make sure to install the app to the workspace. When successful, you should see a token that starts with "xoxb-..." (there is also a token that starts with "xoxp-...", we need the "xoxb-..." one). -3. (Important) Make sure the bot is subscribed to the channel. You can do this by typing e.g. `/invite @zulip_mirror` in the relevant channel. -4. In the `slack` section of the configuration file, enter the bot name (e.g. "zulip_mirror") and token, and the channel ID (note: must be ID, not name). +2. Go to https://api.slack.com/apps?new_classic_app=1 and create a new classic + app (note: must be a classic app). Choose a bot name that will be put into + bridge_with_slack_config.py, e.g. "zulip_mirror". In the process of doing + this, you need to add oauth token scope. Simply choose `bot`. Slack will say + that this is a legacy scope, but we still need to use it anyway. The reason + why we need the legacy scope is because otherwise the RTM API wouldn't work. + We might remove the RTM API usage in newer version of this bot. Make sure to + install the app to the workspace. When successful, you should see a token + that starts with "xoxb-...". There is also a token that starts with + "xoxp-...", we need the "xoxb-..." one. +3. Go to "App Home", click the button "Add Legacy Bot User". +4. (Important) Make sure the bot is subscribed to the channel. You can do this by typing e.g. `/invite @zulip_mirror` in the relevant channel. +5. In the `slack` section of the Zulip-Slack bridge configuration file, enter the bot name (e.g. "zulip_mirror") and token, and the channel ID (note: must be ID, not name). ### Running the bridge