Delete Message

Delete Message

In this article

Overview

Use this Snap to delete one or messages you have sent to a Public Channel/Private Group/User based on their timestamps.

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 appSee 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)

Post messages in approved channels & conversations

chat:write

chat:write

Start direct messages with people

im:write

im:write

Read direct messages based on their IDs

im:read

im:read

View lists of channels and users to select from

users:read

users:read

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.

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

  • JSON Generator

  • Copy

  • Sort

  • Search (Slack)

A document containing one or more timestamps of the original messages to be deleted.

Output

Document

  • Min: 0

  • Max: 1

  • Mapper

  • JSON Formatter

  • CSV Parser

A document containing details of one or more messages deleted.

Snap Settings

Parameter Name

Data Type

Description

Default Value

Example 

Parameter Name

Data Type

Description

Default Value

Example 

Label

String

N/A

 

Target Type

Drop-down list

Select an option from the following list of permitted Target Types and specify the corresponding details needed:

  • Public Channel. To delete the message sent to one of the public channels in the workspace. Requires Channel.

  • Private Channel/Group. To delete the message sent to a private channel or group within the workspace. You must be a participant of the respective channel or group. Requires Channel.

  • Users. To delete the message sent to one or more individual users. Requires Users.

Public Channel

Private Channel/Group

Channel

String/Expression/Suggestion

Required for Target Types - Public Channel and Private Channel/Group

Click the 

 icon and select a channel from the suggested values. To add more channels, enter comma-separated values manually in one of the following formats: 

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

  • #channel.name OR

  • <11-character alphanumeric channel ID>

N/A

#testprivate:G019B3ETYMB

Users

String/Expression/Suggestion

Required for Target Type - Users

Click the 

 icon and select a recipient from the suggested values. To add more recipients, enter comma-separated values manually in one of the following formats: 

  • @user.name:<11-character alphanumeric user ID> OR

  • @user.name OR

  • @<11-character alphanumeric user ID>

N/A

@user.name:W01A94P7MK1

Timestamp

String/Expression/Suggestion

Required. To delete one or more messages you sent earlier, enter or pass their Epoch timestamps separated by a comma.

N/A

1601469028.000100

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