Channel Operations

Channel Operations

In this article

Overview

Use this Snap to perform the following Channel operations in your Slack workspace:

  • Archive channel

  • Create channel

  • Invite user

  • List members

  • Remove user

  • Rename channel

  • Retrieve channel info

  • Unarchive channel

Prerequisites

Add valid Slack Scopes based on the intended operation. See Required Slack Scopes below for details.

Required Slack Scopes

Any action you want to perform within a Slack workspace additionally needs appropriate Scopes assigned to your app See the Scope and Permissions article in Slack API documentation for the complete list and each Account page under Configuring Slack Accounts for information on defining Scopes for your app.

To

Bot Token Accounts
(scope)

User Token Accounts
(user_scope)

To

Bot Token Accounts
(scope)

User Token Accounts
(user_scope)

  • Create channel

  • Invite user

  • Remove user

  • Rename channel

channels:manage

channels:write

  • List members in a channel

  • Retrieve channel info

channels:read

channels:read

  • Archive channel

  • Unarchive channel

N/A

channels:write

Support for Ultra Pipelines

Works in Ultra Pipelines

Limitations

  • Snaps in this Snap Pack use conditional display/hiding of fields. So, ensure that you always use the New Form UI (and not the classic UI) for the Snaps to function as designed/expected.

  • Channel operations Archive Channel and Unarchive Channel cannot be performed using a Bot Token account. Use a User Token account instead.

Known Issues

None.

Snap Input and Output

Input/Output

Type of View

Number of Views

Examples of Upstream and Downstream Snaps

Description

Input/Output

Type of View

Number of Views

Examples of Upstream and Downstream Snaps

Description

Input 

Document

  • Min: 0

  • Max: 1

  • Mapper

  • Copy

  • JSON Generator

A document containing details required for the selected channel operation.

Output

Document

  • Min: 1

  • Max: 1

  • JSON Formatter

  • CSV Parser

A document containing the result (success/failure) of the selected channel operation.

Snap Settings

Parameter Name

Data Type

Description

Default Value

Example 

Parameter Name

Data Type

Description

Default Value

Example 

Label

String

Channel Operations

Channel Operations

Operation

Drop-down list

Select an operation from the following list of permitted channel operations and specify the corresponding details needed:

  • List Members. To retrieve the list of users subscribed to a channel. Requires Channel. 

  • Invite User. To invite a user in the workspace to a channel. Requires Channel and Users

  • Remove User. To remove a user from a channel. Requires Channel and User

  • Channel Info. To view the details of a channel, such as its creation date, purpose, creator, topic, locale, and the current number of members in the channel. Requires Channel.

  • Create Channel. To create a new channel in the workspace. Requires Name and Private.

  • Rename Channel. To rename an existing channel in the workspace. Requires Channel and New Name.

  • Archive Channel. To archive an existing channel. Requires Channel.

  • Unarchive Channel. To unarchive an archived channel. Requires Channel.

List Members

Invite User

Channel

String/Expression/Suggestion

Required for all channel operations except Create Channel.

Click the

 icon and select a channel from the list of suggested channels to perform the selected channel operation. Alternatively, you can enter the channel name and/or channel ID in one of the following formats.

  • #channel.name:<11-character alphanumeric Channel ID>

  • #channel.name

  • <11-character alphanumeric Channel ID>

N/A

#testprivate:G019B3ETYMB

Users

String/Expression/Suggestion

Required for channel operation - Invite User.

Click the 

 icon and select a user from the suggested list of users available in the workspace. Alternatively, you can enter one or more user IDs separated by commas. The user IDs are in the 11-character alphanumeric format.

The specified users are invited to join the selected channel when you run the pipeline.

N/A

W01A94P7MK1, W01A94P7MK2, W01A94P7MK3

User

String/Expression/Suggestion

Required for channel operation - Remove User.

Click the 

 icon and select a user from the suggested list of users available in the workspace. Alternatively, you can enter the user ID in the 11-character alphanumeric format.

The specified user is removed from the selected channel when you run the pipeline.

N/A

W01A94P7MK1

Name

String/Expression

Required for channel operation - Create Channel.

Enter a name for the new channel.

N/A

Support_Vertical

Private

Check box

Required for channel operation - Create Channel.

Select this check box to keep the new channel private – visible to only members/invitees.

Not selected

Selected

New Name

String/Expression

Required for channel operation - Rename Channel.

Enter the new name for the channel.

N/A

ReleaseTeam_Channel

Snap Execution

Drop-down list

Select one of the three following modes in which the Snap executes:

  • Validate & Execute. Performs limited execution of the Snap and generates a data preview during Pipeline validation, then performs full execution of the Snap (unlimited records) during Pipeline runtime.

  • Execute only. Performs full execution of the Snap during Pipeline execution without generating preview data.

  • Disabled. Disables the Snap and all Snaps downstream from it.

Execute only

Validate & Execute