You might remember from such blog posts as the one on March 24th of this year that I built a Twitter client using Slack as the platform. On the train to HUMAN’s studio-warming, I saw a blog post from Slack about how to add Twitter integration to a team and channel. At first when I read it, I was dismayed that they had implemented what I wrote with Slack-Twitter (i.e. the ability to get your entire Twitter timeline in a Slack channel and post to Twitter from that same Slack channel).
On closer inspection, though, it wasn’t that at all, but rather a nuanced approach to ‘following’ a single Twitter account inside a Slack channel. Instead of my approach, they pitch it as a way to get alerts from one or a just a few accounts, like, for example, a transit agency’s tweets in a Slack channel.
In the course of trying to figure out what they meant by that, I added an official Twitter integration to my test Slack team, and used the @MLBHR Twitter account to notify that channel of every home run. (If you want notifications of just home runs by Toronto Blue Jays slugger Edwin Encarnación, you can do that with the Eddie’s Right Arm account, which RTs just the dingers socked by Eddie.)
To get home run alerts in a Slack channel:
- Follow the instructions at Slack for setting up a Twitter integration.1
- Make the settings look like the following screenshot.
- Uncheck "Post tweets sent TO this account"
- Check "Post tweets sent FROM this account"
- The other settings in "Auto-Post Tweets in Slack" don’t matter so much, but might if you use a different Twitter account.
- You’re on your own for finding a good icon to use.
That’s it! Now you have dingers in your channel. You can expect it to look something like the following:
You get all the benefits of Slack (search, highlight words, etc.) without actually having to follow the account on Twitter.
I’d love to know if there’s a Twitter account for every NHL goal and…I’m not sure what to get alerted about for basketball games. (What happens often enough to happen once or twice a game, but not more than a half-dozen times? And is there a Twitter account for that?) Until publications like ESPN add their own integrations, this is a fun, bare-bones way to get alerts like position players pitching and touchdown notices and the like in your Slack channel.
Also published on Medium on April 16th, 2015.