Go to GitHub

Slack Developer Kit for Python

Slack’s APIs allow anyone to build full featured integrations that extend and expand the capabilities of your Slack workspace. These APIs allow you to build applications that interact with Slack just like the people on your team – they can post messages, respond to events that happen – as well as build complex UIs for getting work done.

To make it easier for Python programmers to build Slack applications, we’ve provided this open source SDK. Slack Developer Kit for Python will let you get started building Python apps as quickly as possible. The current version, 2.0, is built for Python 3.6 and higher – if you need to target Python 2.x, you might consider using v1 of the SDK.

Slack Platform Basics

If you’re new to the Slack platform, we have a general purpose guide for building apps that isn’t specific to any language or framework. It’s a great place to learn all about the concepts that go into building a great Slack app.

Before you get started building on the Slack platform, you need to set up your app’s configuration. This is where you define things like your app’s permissions and the endpoints that Slack should use for interacting with the backend you will build with Python.

The app configuration page is also where you will acquire the OAuth token you will use to call Slack’s APIs. Treat this token with care, just like you would a password, because it has access to workspace and can potentially read and write data to and from it.


We recommend using PyPI to install Slack Developer Kit for Python

pip install slackclient

Of course, you can always pull the source code directly into your project:

git clone

And then, save a few lines of code as ./

import sys
# Load the local source directly
sys.path.insert(1, "./python-slackclient")
# Enable debug logging
import logging
# Verify it works
from slack import WebClient
client = WebClient()
api_response = client.api_test()

You can run the code this way.


It’s also good to try on the Python REPL.

Getting Help

If you get stuck, we’re here to help. The following are the best ways to get assistance working through your issue: