1 stable release
Uses new Rust 2024
| 1.3.1 | Dec 16, 2025 |
|---|
#419 in HTTP server
42KB
911 lines
brib
-
A tool to sync messages between messaging apps bi-directionally
-
Current Support
- Telegram
- Slack
Pre Run
- Fill the .env file with reference to example-prod.env
Telegram
TELEGRAM_BOT_TOKEN- Create a bot from @BotFather
- Obtain the Bot Token from BotFather
TELEGRAM_CHANNEL_ID- Create a channel
- Add created bot to the channel and make it as Admin
- Login Telegram Web and go to the channel. Obtain the Channel ID from the URL. (example:
-100xxx)
Slack
SLACK_BOT_TOKEN- Go to https://api.slack.com/apps
- "Create New App" -> "From scratch"
- Give App name and select workspace
- Go to "OAuth & Permissions"
- Add following Bot Token Scopes. NOTE: Some of the permissions are not-necessary.
channels:history(to read messages from public channels)channels:write.inviteschannels:write.topicchat:writechat:write.customizechat:write.publicfiles:readfiles:writegroups:history(if using private channels)users.profile:readusers:read(for reading user info in workspace to use in forwarding message)
- Install the app to your workspace
- Copy the "Bot User OAuth Token" (starts with
xoxb-)
SLACK_CHANNEL_ID- Open Slack in a web browser
- Navigate to the channel you want to post to
- The channel ID is in the URL:
https://app.slack.com/client/T.../C123456789 - The part after the last
/(starting withC) is your channel ID
Run
fly.io
- configure example.fly.toml with necessary values
- create a App using
fly launch --no-deploy - set secrets using
fly secrets set KEY=VALUEcommand, same as .env - deploy using
fly deploycommand and use same command in consecutive runs
Post Run
Slack configuration
- Navigate to "Event Subscriptions" and enable events:
- Set Request URL to your server:
https://your-domain.com/slack/events - Subscribe to bot events:
message.channels(ormessage.groupsfor private channels) - Save changes
- Set Request URL to your server:
Reference
Slack
Repo Structure
- scripts: Scripts
Dependencies
~36–56MB
~1M SLoC