
##### Part 3: The Victory of Automation – How Kattappa’s Messenger Became Independent
How Kattappa’s royal messenger learned to work without waiting for instructions.
The Secret Behind the Royal Schedule
Bhallaladeva was not convinced.
He asked Kattappa:
“How can you guarantee that these messages arrive at the correct time? Who is controlling the royal messenger?”
Kattappa explained that Google Apps Script provided something called `time-driven triggers`.
These triggers allowed functions to execute automatically according to a predefined schedule.
Instead of manually running the script, Kattappa configured separate triggers for the required notifications.
The kingdom’s communication system was now ready to work independently.
# Chapter 6: The Royal Clock – Time-Driven Triggers
Kattappa explained that the automation had two important responsibilities:
1. Prepare and send the correct notification.
2. Execute the notification function according to the required schedule.
Google Apps Script time-driven triggers handled the second responsibility.
The implementation used the following schedule:
| Time | Notification | Purpose |
| 08:30 AM | Odoo Update | Start the day with activity updates |
| 09:45 AM | Clock-In | Reminder Maintain attendance records |
| 06:00 PM | Clock-Out + Odoo | Update Complete daily records |
The project also used the `Asia/Kolkata` timezone and weekday scheduling.
The intention was to send reminders from Monday to Friday rather than unnecessarily notifying the team over the weekend.
A simplified weekday scheduling approach looked like this:
function isWorkingDay() {
const day = new Date().getDay();
return day >= 1 && day <= 5;
}
The scheduled functions would check whether the current day was a working day before sending the notification.
For the actual implementation, the time-driven triggers were configured separately for each notification.
One important detail: Google Apps Script time-driven triggers can execute within a time window rather than guaranteeing an exact second. Therefore, the schedule is intended for approximate notification times.
Bhallaladeva finally understood.
The messenger was no longer a person.
The schedule itself had become the messenger!
# Chapter 7: The First Successful Day
The next morning arrived.
At 08:30 AM, the Google Chat space received its first automated Odoo update reminder.
Nobody had to ask Kattappa to send it.
At 09:45 AM, another message appeared, reminding the team to complete their clock-in.
And at 06:00 PM, the final reminder arrived, asking everyone to complete their clock-out and update their Odoo activities.
The entire process worked as planned.
Sivagami was impressed by the consistency.
Devasena appreciated the reduction in manual follow-ups.
Baahubali saw an opportunity to improve team productivity.
Even Bhallaladeva had to admit that the system was useful!
The kingdom had successfully moved from manual reminders to scheduled communication.
# Chapter 8: What We Learned from Mahishmati
Although this story takes place in a fictional kingdom, the problem is very familiar in modern organizations.
Teams frequently depend on manual messages for attendance reminders, daily status updates, task tracking, and end-of-day reporting.
These activities may appear small, but repeating them every working day consumes time and creates unnecessary dependencies.
Automating these reminders offers several benefits.
1. Consistency
Messages are scheduled and delivered automatically without depending on someone remembering to send them.
2. Reduced Manual Effort
Team members and administrators can focus on their actual responsibilities instead of repeatedly sending reminders.
3. Better Communication
A shared Google Chat space provides one central location for daily notifications.
4. Improved Workflow Discipline
Regular reminders encourage employees to complete attendance and activity updates on time.
5. Simple Maintenance
Google Apps Script provides a lightweight way to manage scheduled notifications without building and maintaining a separate application or server.
There are also a few important operational considerations.
– Webhook URLs should be treated as secrets and never exposed in public repositories.
– Trigger execution should be monitored.
– Duplicate triggers should be avoided.
– The automation should be tested whenever notification schedules or message formats change.
# The Battle Was Not Against an Enemy – It Was Against Repetitive Work!
At the end of the day, Baahubali stood before the people of Mahishmati.
He had fought powerful enemies, protected the kingdom, and built a strong administration.
But this time, his victory was different.
He hadn’t defeated an army.
He had defeated repetitive manual work.
Kattappa no longer needed to remember every reminder. Devasena could focus on administration. Sivagami received a more consistent daily workflow, and even Bhallaladeva had fewer reasons to complain about missing updates.
And in Mahishmati, that solution was a simple combination of Google Apps Script, Google Chat webhooks, and scheduled notifications.
## What Comes Next? – The Final Chapter
The royal messenger had successfully learned when to communicate.
Daily announcements were automated, reminders arrived on schedule, and Kattappa no longer needed to remember every notification.
But Baahubali had one final question:
“Can our messenger do more than simply deliver announcements? Can it understand individual responsibilities and prepare reminders for every minister?”
Kattappa realized that scheduling was only the beginning.
The next mission would be to bring intelligence into Mahishmati’s communication system.
What if the messenger could work with a Large Language Model (LLM), understand individual responsibilities, and generate personalized reminders?
The final evolution was about to begin – from scheduled automation to intelligent, personalized communication!
To be continued: Part 4 – The Intelligent Royal Messenger: Bringing LLMs and Personalized Reminders to Mahishmati
