Maximizing productivity with Slack — and why we made our own Slack bot

A developer’s guide on how to make your life easier with Slack

Martin Stiles
Oct 13 · 6 min read
Image for post
Image for post
Let the bots turn Slack into your favorite tool!

Considering you clicked this article, I’m assuming you know what Slack is. However, not many are utilizing the feature that truly makes Slack powerful: Slack apps, or Slack bots as I will be calling them throughout this blogpost. A Slack bot is an addon you can add to your Slack workspace for additional functionality. These bots will definitely improve your workflow as they help you keep everything related to your work in one place: Slack.

Improved workflow → faster and more controlled development → profit

There are many public Slack bots free for you to download, and they can help you with many common things like github management and Scrum. However, there is another option: Making your own bot. Of course, making your own bot will require a little more effort than downloading a public one. But once you have made a bot, there are literally no limits to what you can make it do.

We in Strise use multiple Slack bots every single day, including our own. In this blogpost we will look at some of the bots I claim to be essential for productivity, and I will do my best to inspire you to make your very own bot!

Public Slack bots

The best place to start is the Slack app directory. This website has all of the most popular bots on display and is a great place for exploring public Slack bots. There is only one slight problem: if you’re like me, the directory is like a toy store for toddlers. A lot of what you see is going to be cool for at most one day, but for some reason, you still want it all! To help you out, here are four bots we are currently using in Strise with great results:

Ever missed a PR review? We all have! Except for me though, I’m just an intern… Anyway, this bot is here to help you keep track of everything happening on the hub. Which most often is a lot 😰
To get started: click the link and add the bot to Slack. Then, you can send it a message with the repository you want to receive notifications from. Example:

Image for post
Image for post
Pro tip: switch “subscribe” with “unsubscribe” to unsubscribe 🤯

This is the only bot on my list that requires subscription, but for a team it will definitely give a great bang for the buck.

Now let’s be honest for a second. Standup is fine. But every day? 😅Scenario: “You are working. You are in the zone. But stop! It’s that time of the day, when you have to stand up and listen to your coworkers explain what they are doing in the most complicated way possible, so that the rest of the team think they are super busy and important.” I could write a lot about why I don’t think daily standups are a good idea, but here is a blogpost that I feel expresses my thoughts.

Let Geekbot be your new daily standup! That is mainly how we use it in Strise, but it also has many more features which you can check out on their info page.

Image for post
Image for post
Every day, Geekbot asks me what I’m up to
Image for post
Image for post
My answer is then posted in the Slack channel devoted to daily standups, along with everyone else’s answers

In Strise, we have a Slack channel solely devoted to Sentry. There, the bot will post every error caught in production with a solid explanation of what caused the error. That is Sentry’s main purpose, which means that adding it to Slack is a quick and easy way of implementing perhaps the most important error catcher for your product. Following is an example of Sentry reporting an error, which we always face with a smile:

Image for post
Image for post
He was probably smiling while commenting 😬

Send GIFs. Because GIFs are awesome! 🤷‍♂

This is the GIF I got by sending “/giphy awesome”. It gives you a random GIF that is labeled with the word or sentence written after /giphy.

Why we made our own bot

If you look at the image below, you might notice that the first bot in my top 6 list has the Strise logo on it. And yes, that’s because we made our very own bot: Omni bot! There are just some things a public Slack bot won’t be able to do, like authenticating your application, or hacking your neighbor’s phone because he is playing way too loud music on Spotify. Although our bot is unable to do the latter, it is able to communicate with our API. Thus, we can truly make the bot do whatever we want it to! Let’s take a look at some examples of what Omni bot does, and hopefully, inspire you to make your very own bot.

Image for post
Image for post
My top 6 most used Slack bots

“Just merge the API changes. Everything will be just fine. Right?”

Image for post
Image for post

Luckily, with well-written tests and GraphQL, we are able to catch breaking changes in our code. Omni bot communicates with Jenkins at fixed intervals to check if everything is fine. If it’s not, it notifies us all that something requires immediate attention, at the same time as it creates a natural environment for discussion (in Slack, that is). Here’s an example:

Image for post
Image for post
We also used the slack API to send buttons along with the message, so that we can continue or abort deployment without even leaving Slack.

In Strise, we analyze around 3 million documents every day. Analyzing takes time. This leads to us having three queues for documents waiting to be analyzed, each queue with a different priority. We are all familiar with Murphy’s law. Since everything goes wrong eventually, Omni bot regularly reports the status of the priority queues. If a queue grows abnormally large, Omni bot will mark the queue with a red color, signalling that something is probably preventing the queue from proceeding.

Image for post
Image for post
Here, the “low priority queue” has exceeded its threshold, meaning that someone should investigate ASAP

Slack automatically crawls every link sent in a message and provides a preview for all of them. But what if a linked website requires authentication?

Slack crawler trying to crawl a website that requires authentication

Such is the case for app.strise.ai, the URL for our product. To work around this, we created customized link previews using Slack unfurling. Any link sent with the domain “app.strise.ai” will be sent to Omni bot. Omni bot will then find out what the link is referring to, ask the API for info about it and then construct an object that Slack will display. In essence: we decide what content we want in the display in the preview. Take a look at this:

Image for post
Image for post
Custom preview of an event in the Strise app! It also supports images if there are any 😄

Recap

After becoming a summer intern in Strise I realized how much simpler it was to keep work-related stuff in one workspace, namely Slack. I recommend you to check out bots like GitHub and Geekbot, as they are bots I now use on a daily basis. And of course, you should check out the slack app directory, which has countless bots that might suit your need.

To cover up missing features of public slack bots we created our own. I hope the examples presented in this blog post have inspired you to create your own as well. Making a complete tutorial for how to make a Slack bot would make this blogpost way too long. Luckily, Slack provides very good documentation. For a quick start, head to Slack’s intro guide. I also recommend taking a look at Traversy Media’s tutorial if you enjoy video guides.

That’s it, folks. And remember, don’t read about productivity all day, because that is definitely not productive! 😄

Strise

Stay ahead of change with an AI-driven workflow

Thanks to Alf Jonassen, Sigurd Berglann, and Patrick Skjennum

Martin Stiles

Written by

A rather unpretentious guy that wants to give back to the software community after leeching of it for many years. M.Sc in Computer Science, NTNU.

Strise

Strise

Stay ahead of change with an AI-driven workflow

Martin Stiles

Written by

A rather unpretentious guy that wants to give back to the software community after leeching of it for many years. M.Sc in Computer Science, NTNU.

Strise

Strise

Stay ahead of change with an AI-driven workflow

Medium is an open platform where 170 million readers come to find insightful and dynamic thinking. Here, expert and undiscovered voices alike dive into the heart of any topic and bring new ideas to the surface. Learn more

Follow the writers, publications, and topics that matter to you, and you’ll see them on your homepage and in your inbox. Explore

If you have a story to tell, knowledge to share, or a perspective to offer — welcome home. It’s easy and free to post your thinking on any topic. Write on Medium

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store