Local Files

Learn to use Slack API calls to manipulate files in the workspace.

Overview

We can use Slack API calls to regularly upload and share local files on our system.

Let’s look at the following endpoints in this lesson:

  1. files.upload: This endpoint uploads or creates a file.
  2. files.list: This endpoint list files for a team, in a channel, or from a user with applied filters.
  3. files.info: This endpoint gets information about a file.
  4. files.delete: This endpoint deletes a file.

Upload a file

To upload a file, we’ll access the https://slack.com/api/files.upload endpoint. First, we’ll go over how to upload a file using the files.uplaod endpoint. We’ll use the POST request to call this endpoint.

Some important query parameters for the files.uplaod endpoint are the following:

Get hands-on with 1200+ tech skills courses.