This is reference content about building functions and workflows. Learn more if you're not yet familiar with this new Slack platform paradigm.

archive_channel

Archive a channel

Facts

Schema ID

Schema.slack.functions.ArchiveChannel

Schema reference

slack#/functions/archive_channel

Related methods

Input parameters

Required parameters
The conversation ID for the channel you are archiving
  • C123456
  • D123ABC456

Output parameters

Required parameters
The conversation ID for the channel you archived
  • C123456
  • D123ABC456

Usage guide

Not all conversations need to continue forever, so when the project is done, this function archives the channel, preventing new messages from being posted while preserving its history.

Learn more about archiving channels.

Archive or delete a channel

From channels to search, learn how Slack works from top to bottom.

When a channel is no longer needed, it can be archived or deleted. Archived channels are closed to new activity, but the message history is retained and searchable. Deleted channels are permanently removed from a workspace, message history included.

Example workflow step:

const archiveChannelStep = ExampleWorkflow.addStep(
  Schema.slack.functions.ArchiveChannel,
  {
    channel_id: "C082T4F6S1N",
  },
);