Feb 23, 2025
Code, Music, and Automation: A Developer's Solution for Sharing Tunes
Written By:Polina Vasiuk

Have you ever found yourself deep in the coding flow, grooving to your favorite tunes, when a colleague asks "How do you show your music?" I faced this question frequently, and while I love sharing my current playlist with my team, manually updating my Slack status became a tedious task that interrupted my workflow. That's when I thought - why not automate this process and let my music speak for itself?
The Musical Challenge
As developers, we often talk about automating repetitive tasks, but sometimes we overlook the small, daily activities that eat away at our productivity. For me, it was the constant back-and-forth between YouTube Music and Slack, manually updating my status to share what I was jamming to. Sure, it might seem trivial, but these small interruptions add up and break our precious focus time.
The Journey to Automation
My quest for a solution led me down two interesting paths:
First Attempt: Desktop App Integration
Initially, I explored using the YouTube Music Desktop App. The idea was promising - a dedicated app with plugin support seemed perfect. However, this approach came with its own set of challenges:
Complex setup requirements
Additional software installation
Potential maintenance overhead
The Breakthrough: Chrome Extension
Sometimes the simplest solution is the best one. Since I was already using YouTube Music in Chrome, why not create an extension? This approach offered several advantages:
Lightweight implementation
No additional software needed
Works right where the music plays
Building the Solution
Let me take you through how I built this musical bridge between YouTube Music and Slack. Even if you're not a developer, understanding the process might inspire your own automation projects.
The Extension Configuration (manifest.json)

This file tells Chrome what permissions our extension needs and how it should work.
The Music Monitor (content.js)

This component watches YouTube Music and detects when songs change.
The Slack Communicator (background.js)

This handles updating your Slack status whenever a new song plays.
The Magic Behind the Scenes
What makes this extension special isn't just the code - it's how it enhances the daily work experience. Every time a new song starts playing:
The extension quietly detects the change
Formats the song information nicely
Updates your Slack status seamlessly
Your colleagues can see what's inspiring your coding session!
Unexpected Benefits
What started as a personal productivity hack turned into something more meaningful:
Sparked musical conversations with colleagues
Created new bonds over shared music tastes
Added a fun, personal touch to remote work
Reduced context switching during deep work sessions
Challenges and Learning Moments
The path wasn't always smooth. I encountered several interesting challenges:
Understanding Chrome extension architecture
Dealing with CORS and security policies
Managing API tokens securely
Handling edge cases when songs change rapidly
Each challenge taught me something valuable about web development and API integration.
The Impact
The real victory wasn't just in the technical implementation - it was in the small moments of connection it created:
A colleague discovering a new artist through my status
Impromptu music discussions in team meetings
The satisfaction of solving a small but persistent annoyance
Contributing to a more connected remote work culture
Looking Forward
This project opened my eyes to the possibilities of simple automation. What other small, daily tasks could we enhance? How else could we use technology to make work more enjoyable and connected?
Want to Try It Yourself?
I've shared all the code and steps above. Whether you're a developer looking to implement this yourself or someone curious about Chrome extensions, feel free to experiment with it. And if you create something cool by building on this idea, I'd love to hear about it!
Final Thoughts
Sometimes the best projects come from solving our own small annoyances. This simple automation not only saved time but also added a bit more music and connection to our workday. What daily tasks would you love to automate?