A twitter bot to facilitate followers and following
If you'd like to use this bot to run your own Twitter Bot, follow these steps:
- Clone this repository to your local machine.
- Create a Twitter developer account and obtain API keys and access tokens. You can do this by following the instructions in Twitter's developer documentation
- Create a config.ini file and add your credentials to it.
[twitter]
consumer_key = xxxxxxxxxxxxxxxxxxxx
consumer_secret = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_token = xxxxxxxxxxxxxxxxxxxx-xxxxxxxxxxxxxxxxxxxx
access_secret = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
- You can simply run the bot through your local computer. If you are feeling brave, you can run it through services like - Digital Occean, AnywherePython, etc.
- Follow people based on certain keywords in bio.
- Repeat process for 15 mins.
- Sleep for 1 hour.
- Repeat.
- Create content calendar
- Auto schedule and tweet
- Like tweet with certain keyword
- Retweet tweet with certain keyword
- Comment tweet with certain keyword
-
Create a Twitter developer account and obtain API keys and access tokens. You can do this by following the instructions in Twitter's developer documentation
-
Once you have your API keys and access tokens, you can use the Tweepy library to interact with Twitter's API in Python. You can install Tweepy by running
pip install tweepy
in your terminal. -
Create a new Python file called bot.py and import the necessary libraries.
-
Load your API keys and access tokens from the config.ini file. You can use the configparser library to do this.
-
Use the Tweepy library to authenticate your Twitter API credentials.
-
Define a list of keywords to search for and a list of users to follow.
-
Unfollow people after 36 hours
-
Run the script by calling python bot.py in your terminal.