Code Monkey home page Code Monkey logo

slackfd's Introduction

slackfd

Deletes files from slack. Great for free accounts.

What this tool does

Slack does not have a bulk delete tool. This tool iterates through all files and deletes them (if they are not pinned). This is great for free teams, because eventually every file you upload will result in a message like this:
Your file was uploaded — it’s safe and sound in Slack. Unfortunately your team doesn’t have any storage space left. To get more space, you can upgrade to a paid account or delete some of your older files.
Pretty annoying.

In order for this tool to work, you must have a legacy API token for that user. API tokens can be obtained here: https://api.slack.com/custom-integrations/legacy-tokens

Once obtained, these parameters should be set as environment variables (via dotenv) and the app can be run as: $ node app.js

NOTES:

  • Slack has a very short API rate limit. In order to not be rate limited (and your token possibly banned), this tool deletes 1 file per ~1 second. It's unfortunate, but the deletion rate can easiliy be modified if you think you can do better. I would suggest running this tool overnight for lengthly channels.

slackfd's People

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.