Twitter contest JS bot
I am not actively maintaining this bot. It was written purely for educational purposes. There have been a couple of contributers so far so if you have improvements, fixes or any other ideas feel free to contribute.
I hold no liability for what you do with this bot or what happens to you by using this bot. Abusing this bot can get you banned from Twitter, so make sure to read up on proper usage of the Twitter API.
- Make sure you have NodeJS up and running
git clonethe repository, or download the zip file and unzip it
npm installin the directory where you cloned the repository (this is needed for installing dependencies)
- Edit the
config.jsfile with your Twitter API Credentials
- The configuration file also holds all configurations needed for the bot:
- SEARCH_QUERIES - the searches the bot will do
- SEARCH_QUERY_FILTERS - filters out data (each filter must be preceded by a "-")
- SEARCH_BY_GEOCODE - allows searching by location given a latitude, longitude and radius
- RESULT_TYPE - recent, popular or mixed
- MIN_RETWEETS_NEEDED - minimum amount of retweets a tweet needs before we retweet it (significantly reduces the amount of fake contests)
- MAX_USER_TWEETS - maximum amount of tweets a user can have before we do not retweet them
- MAX_USER_TWEETS_BLOCK - block the user you suspect of being fake because of the high number of tweets
- RATE_LIMIT_EXCEEDED_TIMEOUT - timeout when the max Twitter API limit is exceeded
- RETWEET_TIMEOUT - timeout between retweets
- RATE_SEARCH_TIMEOUT - timeout between searches
- PREFERRED_ACCOUNTS - array of preferred accounts; if set, it only filters tweets from these accounts
- To start, run
It makes use of request-promise - a HTTP JS client
If you're looking for similar projects in alternative languages, check these out:
The code is open-source and available under the MIT Licence. More details in the LICENCE.md file.