Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kfei/slack-cleaner
:speech_balloon: Bulk delete messages and files on Slack
https://github.com/kfei/slack-cleaner
Last synced: 5 days ago
JSON representation
:speech_balloon: Bulk delete messages and files on Slack
- Host: GitHub
- URL: https://github.com/kfei/slack-cleaner
- Owner: kfei
- License: mit
- Created: 2015-09-18T23:10:38.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2019-05-08T19:41:12.000Z (over 5 years ago)
- Last Synced: 2024-10-14T10:40:32.971Z (20 days ago)
- Language: Python
- Homepage:
- Size: 55.7 KB
- Stars: 1,243
- Watchers: 36
- Forks: 144
- Open Issues: 58
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- starred-awesome - slack-cleaner - :speech_balloon: Bulk delete messages and files on Slack (Python)
README
# slack-cleaner
Bulk delete messages and files on Slack.
## Install
Install from Pip:
```bash
pip install slack-cleaner
```If you prefer Docker, there is a pre-built Docker image as well:
```bash
docker pull kfei/slack-cleaner
```## Usage
```bash
# Delete all messages from a channel
slack-cleaner --token --message --channel general --user "*"# Delete all messages from a private group
slack-cleaner --token --message --group hr --user "*"# Delete all messages from a direct message channel
slack-cleaner --token --message --direct sherry --user johndoe# Delete all messages from a multiparty direct message channel. Note that the
# list of usernames must contains yourself
slack-cleaner --token --message --mpdirect sherry,james,johndoe --user "*"# Delete all messages from certain user
slack-cleaner --token --message --channel gossip --user johndoe# Delete all messages from bots (especially flooding CI updates)
slack-cleaner --token --message --channel auto-build --bot# Delete all messages older than 2015/09/19
slack-cleaner --token --message --channel general --user "*" --before 20150919# Delete all files
slack-cleaner --token --file --user "*"# Delete all files from certain user
slack-cleaner --token --file --user johndoe# Delete all snippets and images
slack-cleaner --token --file --types snippets,images# Always have a look at help message
slack-cleaner --help
```## Tips
After the task, a backup file `slack-cleaner..log` will be created
in current directory if `--log` is supplied.If any API problem occurred, try `--rate=` to reduce the API
call rate (which by default is unlimited).If you see the following warning from `urllib3`, consider to install missing
packages: `pip install --upgrade requests[security]` or just upgrade your
Python to 2.7.9.```
InsecurePlatformWarning: A true SSLContext object is not available.
This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail.
For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
```## Credits
**To all the people who can only afford a free plan. :cry:**