Why you should build an organizational Slack bot?

Yanai Ron
Tech at Trax
Published in
5 min readApr 14, 2020

If you’re working in a tech organization, most chances are that you are using Slack to interact with coworkers. Did you know that you can build your own organizational Slack bot to enhance interaction between co-workers and to share knowledge?

In this post I will show you the simplicity and value of making time for you and the team to build one. I’ll also throw in some ideas to get you started.

What are bots? Here’s the explanation from Slack:

“A bot is a type of Slack App designed to interact with users via conversation…the same as a regular app: it can access the same range of APIs and do all of the magical things that a Slack App can do.

But when you build a bot for your Slack App, you’re giving that app a face, a name, and a personality, and encouraging users to talk to it. Your bot can send DMs, it can be mentioned by users, it can post messages or upload files, and it can be invited to channels — or kicked out. Bots are not cybernetic infiltration units, and it is unlikely that they dream of electric sheep, though we can’t rule it out. 🤖”

Why do I need an organizational Slack bot?

To be honest, you don’t really need it, but it can solve many problems your organization may have (and it’s easy and fun to write), such as:

Knowledge Sharing

Your Slack bot can be used to retrieve internal information, for example:

  • Customer statistics
  • Employee roles, departments, birthdays
  • KPIs, open support tickets, system health
  • Product adoption, Sales data, top customers / customers at risk
  • Data for Salesforce: release notes, new versions, how-tos

At Trax, we have many internal data sources (SQL DBs, No-SQL, internal APIs, etc.). The Slack bot can consolidate the interesting stuff and present it in an easily digestible way, the options are endless…

Supply useful information about our customers
Supply useful information about your mobile versions

Provide easy access to common actions

Your Slack bot can be a great tool to initiate actions, such as:

  • Environment setup
  • Running internal scripts
  • Accessing APIs

At Trax, we can copy a production environment to a testing environment in order to perform tests on real data, it’s a killer feature used daily by multiple departments:

This is a valuable feature for multiple stakeholders in the organization, but in order to get wide usage we needed to make it accessible, and a Slackbot is the simple UI-free way to accomplish that.

We can also run internal jobs (we call it “Simon”):

Alright, I get it, I need all that, but why choose Slack?

Great that you asked, there are many reasons to choose Slack for that:

  • It’s already installed for everybody in your organization: HR, Finance, Sales, Technology, upper management, etc.
  • It’s a “UI without UI”, you don’t need to develop a fancy dashboard and employ designers to get the information to the organization
  • It’s so easy to implement, a few hours to set up everything for any passionate developer

So it’s good for the company, but what’s in it for me?

Well, for starters, it’s an opportunity to work on something new, whether you’re a Frontend developer who wants to experience some Backend, or a Backend developer who wants to try out a new technology.

It’s small and well defined, and you get to do it on work hours because it’s useful at work! Perfect for a side-project, win win!

Okay, I’ll build it, but where should I start?

Alright, firstly you’ll need a server with a public address/DNS, then…

  • Pick the programming language of your choice, Node.js, Python or Golang are good starters for web servers
  • Write a simple REST API using this guide
  • Pick a cool name and avatar
  • Bonus: Track your bot usage using your favorite analytics platform (I use Mixpanel)

You can start with this skeleton I’ve made using Node.js:

Once the skeleton is set up, you can add more and more to it, the sky’s the limit! Here are some ideas:

  • Provide visibility on customer’s statistics about system usage, features adoption, amount of data, etc.
  • Bonus: add some buttons that will lead to open issues, customers’ dashboards, etc.
  • Send a “Did you know” message from your bot once a week, with a trivia detail about the company, events that are happening, “kudos” to those special employees, etc.
  • Send notifications about employees’ birthdays, and let the other employees share a personalized message
  • Think about manual recurring operations your organization is doing, think about automating it with Slack

Later on when it catches like wildfire in your organization, you can make it an internal open-source project for the rest of the company developers to contribute to.

Wrapping up

Now you should have a general idea of how an organizational slack bot can benefit you and your organization.

I’d love to hear about it, please share your ideas and success stories in the comments section, maybe I’ll implement them in Trax as well :)

Hope you enjoyed it, don’t forget to clap!

--

--