Skip to content

Slack Token

Andrew Kerr edited this page Jan 5, 2022 · 6 revisions

ℹ️ If you are a Shopify employee and you'd like to use this for an internal Shopify project, please reach out in the #ruby-and-rails-infra channel for instructions.

ℹ️ If you already have a personal Slack bot in your Slack workspace, all you need to do is to make sure the bot has these permissions. You can skip the rest of this guide.

  1. users:read
  2. users:read.email
  3. chat:write
  4. chat:write:public

Get a Slack token

The easiest way to get a Slack token for your Slack workspace is to create a Slack Bot.

This guide was written on July 19, 2019. It's possible that it becomes outdated as Slack evolves. I'll recommend reading the official Slack documentation for the most up to date tutorial.

  1. Head to https://api.slack.com/apps (Make sure you are logged in before proceeding to step 2)
  2. Click on the "Create New App" button and fill the modal
  3. In your new App configuration page, click on the "Bot Users" link (below the "Features" menu)
  4. Click on the "Add a Bot User", and fill the info for your bot. (The Always Show My Bot as Online option is up to you)
  5. Click on the "OAuth & Permissions" link (below the "Feature" menu)
  6. Under the "Scopes" Menu, add the users:read and the users:read.email permission. Save changes.
  7. Click on the "Install app" (below the "Settings" menu)
  8. Click on the "Install App to Workspace"
  9. If the installation of your app in the workspace was successful, you should see your token. You want the "Bot User OAuth Access token" one (it should start with xoxb-)
Clone this wiki locally