Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/khiga8/alt-text-slack-bot
Encourage accessible image sharing in your Slack workspace
https://github.com/khiga8/alt-text-slack-bot
accessibility slack-bot
Last synced: 5 days ago
JSON representation
Encourage accessible image sharing in your Slack workspace
- Host: GitHub
- URL: https://github.com/khiga8/alt-text-slack-bot
- Owner: khiga8
- Created: 2022-04-06T00:46:13.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-05-06T23:52:19.000Z (over 2 years ago)
- Last Synced: 2023-03-04T08:11:17.893Z (over 1 year ago)
- Topics: accessibility, slack-bot
- Language: TypeScript
- Homepage:
- Size: 1.56 MB
- Stars: 9
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# alt-text-slack-bot
`alt-text-slack-bot` aims to encourage accessible image sharing in a Slack workspace. When configured and added to a workspace, this Slack bot will detect when an image file has been shared in a channel without alternative text. It will send a friendly reminder that can only be seen by the user who posted the image along with instructions on how to add the alternative text.
This repo contains the code for the bot setup and should be customized to fit your workspace needs. For a comprehensive guide on the process of setting up a Slack app and installing it in a workspace, check out a fantastic tutorial by `@lukeocodes` at [DEV: Guy's Bot - Inclusive Language in Slack](https://dev.to/lukeocodes/who-s-a-good-bot-a-slack-bot-for-inclusive-language-2fkh).
## Motivation
The alt text feature in Slack is relatively new and hidden so a lot of people don't know about it or forget to use it. This bot was created to ensure that images are accessible to everyone, including channel members who are blind or have low-vision. This bot eliminates the potential burden of individual members having to remind people to add alt text.
## Requirements
### Slack permissions
- [messages:channels](https://api.slack.com/events/message.channels): allows subscription to receive events of messages that are posted to the channel.
- [chat:write](https://api.slack.com/scopes/chat:write): send messages as your configured Slack bot.### Environment variables
Fetch the following tokens on the admin panel of your newly created Slack app page:
- `SLACK_TOKEN`: fetch `Bot User OAuth Token` in the **OAuth and Permissions** tab.
- `SLACK_SIGNING_SECRET`: fetch `Signing secret` in the **Basic Information** tab.## Tips
- If you prefer not to experiment with a Slack app in an active workspace, you can create a free test workspace.
- Customize the bot message by updating `utils.ts`.