Token types

Access tokens are the keys to the Slack platform. They tie together all the scopes and permissions your app has obtained, allowing it to read, write, and interact. There are multiple types of tokens available. Each type is suited for different functionality, and certain scopes are unique to particular token types, as summarized in the table below:

Token Description
Bot token Bot tokens ascribe to a granular permission model to request only the scopes you need.
User token User tokens allow you to work directly on behalf of users when necessary.
Configuration token Configuration tokens are per-workspace tokens used with App Manifest APIs to create and configure Slack apps.
Service token With workflow automations, service tokens are long-lived, non-rotatable user tokens that won't expire, so they can be used to perform any Slack CLI action without the need to refresh tokens.
App-level token App-level tokens are used with specific APIs, which are related to the app across all organizations where the app is installed.

Bot tokens

Bot tokens represent a bot associated with an app installed in a workspace. Unlike user tokens, they're not tied to a user's identity β€” they're only tied to your app. Since acting independently allows your app to stay installed even when an installing user is deactivated, using bot tokens is usually for the best.

Workflow tokens

Workflow tokens are a superset of bot tokens. They cannot perform actions that require a user scope. They expire and need to be refreshed, similar to service tokens. Workflow token strings begin with xwfp-.

User tokens

User tokens represent workspace members. They are issued for the user who installed the app and for users who authenticate the app. When your app asks for OAuth scopes, they are applied to user tokens. You can use these tokens to take actions on behalf of users.

  • User tokens gain the resource-based OAuth scopes requested in the installation process (e.g. asking for channels:history grants a user token access to conversations.history for any public channel).
  • User tokens represent the same access a user has to a workspace β€” the channels, conversations, users, reactions, and so on that they can see. Write actions with user tokens are performed as if by the user themselves.
  • User token strings begin with xoxp-.

Both configuration and service tokens are also tied to a user logged into Slack.

Configuration tokens

App configuration tokens (or config tokens for short) are solely used to create and configure Slack apps using our App Manifest APIs. Each configuration token is unique to a user and a workspace, but not an app. This means you can manage the configuration of any of your apps in a single development workspace, with just one config token.

Service tokens

Service tokens can only be used by workflow automations.

Service tokens won't expire, so they can be used to perform any Slack CLI action without the need to refresh tokens.

  • The service token will not conflict with your regular authentication token; you can continue using your regular authentication token within the Slack CLI.
  • For more details, refer to best practices for service tokens.

App-level tokens

App-level tokens represent your app across organizations, including installations by all individual users on all workspaces in a given organization.

Legacy token types

Legacy bot tokens

These bot tokens, obtained through an older OAuth flow, should only be used in special cases β€” such as connecting to the now-deprecated Real Time Messaging (RTM) API.

  • Legacy bot tokens requested an umbrella bot scope with many different permissions included within it. We have now moved away from this umbrella permission model, and instead recommend you use newer, granular bot tokens. Newer platform features will no longer be supported with the legacy bot token.
  • Legacy bot tokens can't have resource-based OAuth scopes added to them; any scopes other than bot requested during the OAuth installation flow have no effect on the legacy bot token.
  • Revoking a legacy bot token with auth.revoke does not uninstall the bot user. A new token may be obtained via OAuth or, for internal integrations, your app management console.

Legacy workspace tokens

Legacy workspace apps have been fully deprecated as of August 2021. Don't use this token type for new apps.

Legacy custom integration tokens

These tokens were associated with legacy custom integrations and early Slack integrations requiring an ambiguous "API token." They were generated using the legacy token generator, and are no longer recommended for use.

  • These tokens take on the full operational scope of the user that created them. If you're building a tool for your own team, we encourage creating a single-workspace app with only the scopes it needs.

How to get a token

Check out our tutorial, How to quickly get and use a Slack API token.