How to customize Slack to enhance your development workflow using integrations and bots
It certainly feels like Slack is gradually becoming the standard for modern office communication. While you may argue that technically Slack is no different than, say, IRC – the polished experience is what makes it stand out in the crowd of messaging services. Using less gentler words, Slack is killing email for office communications. And has built in support for code snippets with syntax highlighting. Boom.
In this post we’re highlighting some of the most useful new workflows that Slack is enabling. Apart from the messaging features, it has a huge number of integrations available that let you customize it for the tools you’re working with. Moreover, some more advanced triggers can also let you perform actions just like a terminal, and even automate them.
Let’s see what’s it all about.
— Takipi (@takipid) November 17, 2015
1. The essentials: GitHub and Bitbucket
“He who controls the source, controls the universe”, or something like that. This one is a no brainer. If you’re using GitHub (or Bitbucket) with your team, you want this integration in your Slack. The way we’re using it in Takipi is by having a #github channel with a stream of all the changes in our repositories so anyone can get a quick overview of what’s going on.
The Github integration posts messages about all commits, pull requests, comments, and issues. The messages include links to these events on GitHub’s, and also let’s you see the images attached so everyone can easily look at a new mockup. More active capabilities are available if you’d like to customize a bot to do more stuff, potentially just linking the Slack to a terminal. An easier integration for opening GitHub issues from Slack is available through Zapier.
Bottom line: GitHub notifications in a stream.
Check it out: Get started through the official integrations page.
2. Sentry, Airbrake, Raygun and error tracking
Tools like Sentry and Airbrake report on exceptions and log errors that are happening in your application. After adding the appropriate code and build changes, these tools are able to get access to your errors, aggregate them, and report high level stats.
Check it out:
3. Replacing log files with a Slack channel
Traditionally, to identify and solve errors in production, companies had to rely on log files to know what’s causing them. This includes exceptions, logged errors, warnings, and HTTP errors. A back and forth process that sometimes takes days, even weeks, to complete.
With Takipi’s Slack integration, you not only receive immediate alerts on errors in production – but each alert carries tons of actionable information, without ever having to write it into the log. This includes the full stack trace and variable values at the moment of error – all of that is overlayed on the actual code:
Bottom line: Instead of writing every error to your logs, get the variable values and exact state behind each error in production directly from Takipi with Slack.
4. Codeship and other CI/CD tools
If you build it, they will come. And post notifications on your Slack channel of choice. Another area to look into is integrations your build process to send its notifications to Slack.
Codeship notifications in Slack
Once configured, Codeship sends messages on failed and successful builds to your Slack channel. All your team can easily get notified and stay informed of any change in your build.
Bottom line: Your build process can be viewed through Slack.
Check it out:
5. Slack bots for fun and profit
Starting off with the default slackbot, bot users in Slack can become pretty complex and do literally anything that you’d like them to. When first joining Slack, the friendly (yet pretty simple at the moment) slackbot will greet you and get you to complete the onboarding process. It can also set reminders for you and respond to custom defined triggers. Two of our personal favorites are triggers that we’ve set for the office wifi passwords and fetching the menu from one of our takeaway places for lunch.
In an interview with the Wall Street Journal, Slack CEO Stewart Butterfield compares the future of slackbot to the AI from the movie “Her”, or Siri for that matter. It would be awesome to see how this develops in the future.
Hey slackbot, /remind me to [do something] in [some time from now]
But wait, slackbot is not the only bot in the neighborhood. There are actually tens of available bots, and you can also build one yourself. There’s even one that lets you run pokemon battles with your team, and another one for playing poker over Slack.
On a more serious note, the way this works behind the scenes is by spinning up a server that talks with Slack’s Real Time Messaging API which grants you read and write access to channels. The bot appears as a regular user on the user list and you can choose a custom name and set his photo. Other than games, more practical use cases include things like stand-up meeting in Slack but the real magic hides in custom bots which you can hook automate your own processes.
Bottom line: Bots open up a world of options only limited by your own imagination. Heaven (or… time sink) for productivity geeks.
Check it out:
- The Slack bots list
- GitHub’s Hubot and its Slack adaptor, check out its extensive script list
- Slack bots API docs
6. Custom Slash Commands
These are quite similar to bots, just without the actual bot user so a bit simpler. Custom Slash commands let you define your own actions. One thing we pulled off is a slash command for ordering food straight from Slack. Yup. There’s a restaurant we like that doesn’t support online orders so almost every day we’re sending them an email with everyone’s requests and it’s a bit of a hassle to collect all the orders. The new slash command lets you order the food you like, aggregates everyone’s requests to a an email, and sends it out on a predefined deadline. We’ll do a separate hands-on tutorial about that soon.
In a nutshell, the way this works is by sending an HTTP POST or GET request to a URL of your choice. The request payload includes all the fields you need to execute your response:
Slack slash command payload
Bottom line: Automate ALL the things!
Check it out: Slash commands docs.
Well, if you’re into GIFs like I am, this one is a charm. Once you add the Giphy integration you get quick access to Giphy’s “text-to-GIF” feature. Just type /giphy space cat and get…. Space cat! We just couldn’t build an essential integrations list without it
Giphy, perfect when you’re hungry
The integration is built using Giphy’s API which is quite awesome on its own. Pronouncing it Jiff vs. GIF still remains unresolved.
Bottom line: Let there be cats! Beware of occasional NSFW content.
Check it out: Get Giphy for Slack through the official integrations page.
There are tons of integrations that we didn’t have a chance to mention, a great place to see a comprehensive list is on SlackStack.io which also has a section for developer specific integrations. Slack has entered our lives by storm and now we’re spending all our hours in the office connected to it. The integrations we’re using are kicking it up a notch and making it even more useful, cutting down and centralizing all notifications and alerts. The next step of this evolution will probably include AI bots, and we’re super excited to see where it goes next!
Have an interesting use case that we missed? Share it in the comments section below