Skip to content

Commit

Permalink
readme: add users:read.email scope requirement for direct messages
Browse files Browse the repository at this point in the history
  • Loading branch information
Khady committed Feb 14, 2024
1 parent fc5588e commit 310357d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Run the `_build/default/src/monorobot.exe` binary. The following commands are su
1. [Create a Slack app](https://api.slack.com/apps?new_app=1).
2. Click "Install to Workspace", and when prompted to grant permissions to your workspace, click "Allow".
3. Set up notifications with one of the following methods:
- **Web API (recommended):** To use Slack's [Web API](https://api.slack.com/web), click on "OAuth & Permissions" in your app dashboard's sidebar. Give your bot a *Bot Token Scope* of [`chat:write`](https://api.slack.com/scopes/chat:write) (for per-channel authorization) or [`chat:write.public`](https://api.slack.com/scopes/chat:write.public) (for authorization to all channels). Also give `chat:write.customize` (to show branch name as bot username). Copy the generated bot token (`xoxb-XXXX`) to the `slack_access_token` field of your secrets file. This token is used by the bot to authenticate to the workspace, and remains valid until the token is revoked or the app is uninstalled. If you use the `chat:write` scope, add the bot to each channel you want to notify.
- **Web API (recommended):** To use Slack's [Web API](https://api.slack.com/web), click on "OAuth & Permissions" in your app dashboard's sidebar. Give your bot a *Bot Token Scope* of [`chat:write`](https://api.slack.com/scopes/chat:write) (for per-channel authorization) or [`chat:write.public`](https://api.slack.com/scopes/chat:write.public) (for authorization to all channels). Also give `chat:write.customize` (to show branch name as bot username). If you want to send direct messages, also add the `users:read.email` scope, whichis necessary to find the user id matching the email of a commit author. Copy the generated bot token (`xoxb-XXXX`) to the `slack_access_token` field of your secrets file. This token is used by the bot to authenticate to the workspace, and remains valid until the token is revoked or the app is uninstalled. If you use the `chat:write` scope, add the bot to each channel you want to notify.
- **Incoming Webhooks:** To use [incoming webhooks](https://api.slack.com/messaging/webhooks), enable them in your app dashboard and create one for each channel you want to notify. Store them in the `slack_hooks` field of your secrets file. If you decide to notify additional channels later, you will need to update the secrets file with the new webhooks and restart the server.


Expand Down

0 comments on commit 310357d

Please sign in to comment.