A twitter bot that posts financial news articles about Spain's stock market index. You can also ask the bot for the current price of a stock by mentioning it and adding a dollar sign followed by the stock's ticker symbol.
The bot uses RomelTorres' python wrapper for the Alpha Vantage API. It's deployed on Heroku with Docker 🐳 and uses two separate clock processes for posting articles and listening to twitter mentions. To avoid duplicate replies, the bot saves the mention's id into a postgres database table which is queried through peewee's ORM.
Register an account on Twitter's Developer Platform and store your credentials in /envfiles/local.env
.
To run the bot locally, start the project containers with make env-start
and then try out the bot's features with:
make tweet-article
make reply-mentions
To run all the tests use:
make test