kfei / slack-cleaner

:speech_balloon: Bulk delete messages and files on Slack
MIT License
1.24k stars 144 forks source link

Cannot delete push notifications from apps in a public channel (not DMs) #80

Closed Freelensia closed 5 years ago

Freelensia commented 5 years ago

We have configured CircleCI, Bitbucket to pour push notifications into a public channel. We can delete them manually below. image

However, when running the code, these messages are excluded from the message view, hence they cannot be deleted. image

Is is because these messages are not actually messages, and rather notifications? Therefore we need to replace the --message with something else?

Freelensia commented 5 years ago

Updated. This is solved. Actually messages coming from apps are considered "bot" and we had to use this code.

slack-cleaner --token xxx --message --channel bot-bitbucket --bot --rate 1