[GAS x Slack Automation] I Built a System to Automatically Post Monthly Reaction Rankings (Top 10 + Details) to a Thread | A Non-Engineer HR/PR Professional's Challenge_MENDAN PR Monologue #04
Here is this note!
Apart from MENDAN, I, a non-engineer HR/PR professional, will introduce how I used GAS (Google Apps Script) to create a system that automatically posts the "Slack Reaction Ranking Top 10 + Details" to a thread every month!
🔧 Background
While a culture of "gratitude" and "praise" through reactions (stamps) is taking root on Slack, I felt that
what kind of reactions are frequently used?
who is frequently using reactions?
who is receiving the most reactions?
I felt that things like these were not being quantitatively visualized.
🎯 Goals
Automatically aggregate monthly Slack reactions
Post the Top 10 reactions to Slack
Post the "Top 3 users who used / Top 3 users who received" for the top 5 reactions to a thread
Exclude specific stamps (e.g., :white_check_mark:) from the ranking
Create a system that automatically notifies on the 1st of every month
🧰 Tools Used
Google Sheets (for data aggregation)
Google Apps Script (GAS) (Slack API integration)
Slack (operated via User Token)
🪜 Implementation Flow
① Create a Slack App
Create an app from the Slack API page and grant the following scopes.
users.conversations
channels:read
channels:history
reactions:read
users:read
chat:write
➡ Obtain a token in xoxp-... format and use it in GAS.
② Automatically collect reactions with GAS
const oldest = new Date('2024-10-01T00:00:00Z');
const latest = new Date('2025-04-30T23:59:59Z');
Set the target period, retrieve messages with reactions from all public channels you are participating in, and save them to a spreadsheet.
③ Create rankings and detailed data with GAS
Reaction TOP 50 sheet: Ranking by usage count
Details sheet: Record the top 3 people who reacted and the top 3 people who received reactions for the top 5 reactions
You can also easily set excluded reactions (e.g.):
const excludedReactions = ["チェックマーク_緑", "テスト送信", "white_check_mark", "#ERROR!"];
④ Bulk post to Slack (with threads)
Main post: TOP 10 ranking
Thread post: Details of the top 5 reactions
By specifying thread_ts in the Slack message posting API, you can display them all together in one thread.
⑤ Automatically execute on the 1st of every month (trigger setting)
With the Apps Script trigger function, you can just set the following function to run on the 1st of every month at 9:00 AM, etc.:
function mainMonthlySummary() {
collectReactionsFromUserChannels();
createReactionReports();
postReactionSummaryWithThread();
}
✅ Example of a posted Slack message
Internal output example


Body (TOP 10)
:trophy: リアクションランキング TOP10(2024年10月〜2025年4月)
1位::ありがとう:(210件)
2位::ありがとうございます:(148件)
...
Thread (Details)
:bust_in_silhouette: 上位5リアクションの詳細(押した人 / 押された人)
:label: :ありがとう: の 押した人TOP3
・@ユーザーA(90回)
・@ユーザーB(43回)
・@ユーザーC(29回)
:label: :ありがとう: の 押された人TOP3
・@ユーザーB(62回)
・@ユーザーD(38回)
・@ユーザーE(30回)
...
...📌 Impressions
By summarizing details in a thread,information is easy to see and not distracting
Even just with a monthly Slack notification,the culture of praise within the team is visualized
It's great that it can be completed entirely with GAS (free and flexible)
☁️ Future Outlook
Saving monthly archives
I also want to add labels and medals other than emojis to reaction notifications on Slack
I also want to include a feature to notify people who received many reactions via a recognition DM
📩 If you are interested, I can provide the full code and templates! Please feel free to reach out via comments or LinkedIn DM.
