Skip to content
🛁 Clean-up inactive accounts and bots from your Twitter
Python
Branch: master
Clone or download
Latest commit dd7a3ff Apr 22, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs Fix links in the docs Jul 23, 2018
twitter_cleanup Use custom error class in BotometerResult Apr 22, 2019
.gitignore Make it pip-installable Jul 22, 2018
CHANGELOG Version bump Apr 22, 2019
LICENSE 1st commit Jul 21, 2018
README.rst Fix links in the docs Jul 23, 2018
setup.py

README.rst

Twitter Clean-up

🇧🇷 Versão em português do Brasil

Tiny script to clean-up your Twitter account:

  • Removing users that have not been tweeting for a while
  • Soft-blocking bots (blocks and immediately unblocks the account, so it stops following you)

Requirements

  • Python 3.6
  • Set environment variables with your Twitter API keys and with Botometer API key:
    • TWITTER_CONSUMER_KEY
    • TWITTER_CONSUMER_SECRET
    • TWITTER_ACCESS_TOKEN_KEY
    • TWITTER_ACCESS_TOKEN_SECRET
    • BOTOMETER_MASHAPE_KEY

Installing

Install the package with:

$ pip install twitter-cleanup

Usage

Run the CLI with twitter-cleanup --help and follow the on screen instructions.

For example, unfollow everyone that hasn't tweeted in the last 30 days with:

$ twitter-cleanup inactive 30

Or soft-block every bot with:

$ twitter-cleanup bots

Contributing

Please, format your code with Black.

You can’t perform that action at this time.