A Deno application that monitors Slack message reactions in a specific channel and summarizes them in a Notion database.
- Monitors reactions on messages in a specified Slack channel
- Summarizes reaction data and stores it in Notion
- Supports both one-time runs and scheduled monitoring
- Automatically updates existing entries or creates new ones
- Deno runtime installed
- Slack app with appropriate permissions
- Notion integration with database access
- Copy
.env.example
to.env
:
cp .env.example .env
- Fill in your credentials in
.env
:SLACK_BOT_TOKEN
: Your Slack bot token (starts withxoxb-
)SLACK_APP_TOKEN
: Your Slack app token (starts withxapp-
)NOTION_TOKEN
: Your Notion integration tokenNOTION_DATABASE_ID
: The ID of your Notion databaseSLACK_CHANNEL_ID
: The Slack channel ID to monitor
- Create a new Slack app at https://api.slack.com/apps
- Add the following OAuth scopes:
channels:history
reactions:read
- Install the app to your workspace
- Add the bot to the channel you want to monitor
Create a Notion database with the following properties:
- Message ID (Title)
- Message Text (Text)
- Author (Text)
- Channel ID (Text)
- Total Reactions (Number)
- Reactions (Text)
- Timestamp (Text)
deno task start
deno run --allow-net --allow-env --allow-read --allow-write --allow-sys src/main.ts --schedule
deno task dev
- Connects to Slack API and fetches recent messages from the specified channel
- Identifies messages that have reactions
- Counts and summarizes reactions for each message
- Updates or creates entries in the Notion database
- Sorts messages by total reaction count (most reacted first)
The application handles both creating new entries and updating existing ones based on the message ID.