The new Slack platform and the features described below are in beta and under active development.

Create or remove an app

Verify workspace authentication

Before you can create (or remove) an app, ensure your CLI is authenticated into the workspace you want to develop in. You can do so with the slack auth list command:

$ slack auth list 

ACTIVE  myworkspace (Team ID: T123456789)
User ID: U123456789
Last update: 2022-03-24 18:20:47 -07:00

To change your active workspace authorization run slack login

Look for the ACTIVE label next to your desired workspace. In the above example, myworkspace is ready to be used.

Create an app

With our CLI authenticated into the workspace we want to develop in, the next step is to scaffold an app with the slack create command:

$ slack create my-app

The above command will scaffold a new app named my-app in a directory with the same name. If you don't pass an app name, slack will scaffold an app with a random alphanumeric name.

You will be presented with three options to build from:

If you'd like to build from a specific sample app, see Create an app from a template below.
? Select a template to build from: [Use arrows to move]

> Hello World
  A simple workflow that sends a greeting

  Scaffolded project
  A solid foundational project that uses a Slack datastore

  Blank project
  A, well.. blank project

  Check out more samples at api.slack.com/future/samples

Once you select an option the Slack CLI will get you set up for success.

$ slack create my-app

โš™๏ธ  Creating a new Slack app in ~/programming/my-app

๐Ÿ“ฆ Installed project dependencies

โœจ my-app successfully created

๐Ÿงญ Explore the documentation to learn more
   Read the README.md or peruse the docs over at api.slack.com/future
   Find available commands and usage info with `slack help`

๐Ÿ“‹ Follow the steps below to begin development
   Change into your project directory with `cd my-app`
   Develop locally and see changes in real-time with `slack run`
   When you're ready to deploy for production use `slack deploy`
   Create a trigger to invoke your workflows `slack trigger create`

After creating an app, don't forget to cd into your app project's directory.

โžก๏ธ To keep building your own app, learn about your app's manifest in the manifest section.

โคต๏ธ To use a sample app as a template instead, read on!

Create an app from a template

We have a collection of sample apps that contain a bevy of use cases. Find one particularly suited for your needs? Great! You can use it as a template to build from.

Create an app from a template by using the create command with the --template (or -t) flag and passing the link to the template's Github repo.

For example, the following command creates an app using our Welcome Bot app as a template:

slack create my-welcome-bot-app -t https://github.com/slack-samples/deno-welcome-bot

Create an app from a specific branch

Use a specific branch of a template repo by using the --branch (or -b) flag and passing the name of a branch:

slack create my-welcome-bot-app -t https://github.com/slack-samples/deno-welcome-bot -b main

Remove an app

Uninstall an app from your workspace

All good things must come to an end. You can uninstall your app if you need to remove an app from a workspace, change permissions, or delete the app in its entirety. To uninstall an app using the CLI, use the slack uninstall command. Then, choose the workspace you want to uninstall the app from.

Uninstalling your app permanently deletes all of its data
Your app's related workflows, functions, and datastores will also be deleted. This decision is final and can not be undone.
Choose a workspace  my-workspace T123ABC456
   my-app U123ABC456

โ— Danger zone! Uninstalling your app will also delete:
  - the app, workflows, and functions from this workspace
  - all app data and datastores from this workspace

โ“ Are you sure you want to uninstall? Yes

๐Ÿ  Workspace uninstall
   Uninstalled the app "my-app" from workspace "workspace"

๐Ÿ“š App Manifest
   Deleted the app manifest for "my-app" from workspace "workspace"

๐Ÿ˜๏ธ Installed Workspaces
   There are no workspaces with the app installed

Onward

Your wish is our command! For information about other actions you can perform from the CLI, refer to Using the Slack CLI and Commands.

Check out more about how to configure your app via the manifest. You can also start building functions to perform some logic, chain them together in workflows, then invoke those workflows by building triggers.

Have 2 minutes to provide some feedback?

We'd love to hear about your experience building modular Slack apps. Please complete our short survey so we can use your feedback to improve.