2.7 KiB
Telegram Bot Commands
About
Simple Stock Bot is a bot for Telegram that provides information about the stock market. You can view the source code here.. You can also build your own docker container to run here.
Coded with ❤ by @MisterBiggs
Getting a Stock Quote
Anytime the Bot is in your chat it will search all chats for $
followed by a ticker. For example $tsla
will return the following message for Tesla Motors:
The current stock price of Tesla Inc. is $321.35, the stock is currently up 2.7%
This works no matter where the ticker is in the message and you can have as many tickers as you want in the same message. For example:
I wonder how $aapl, $nflx, and $sono are performing today.
Will return:

As long as the bot is in your chat it will reply to any stock tickers in your messages.
Commands
/help
This command just displays a short description of what the bot does and a link to this page.
/news
This command is intelligent enough to get any tickers in the ticker format: $amzn
, and can handle as many tickers as you would like to enter. The bot will then return the price of the ticker, and links various websites that provide news about the ticker. Currently for Apple stock the Bot would return:
The current stock price of Apple Inc. is **$174.18**, the stock is currently up **1.71%**
Bravos
Seeking Alpha
MSN Money
Yahoo Finance
Wall Street Journal
The Street
Zacks
The /news command needs updating, feel free to open an issue with suggestions.
Run your own Bot
You can also run your own bot super easily in a Docker Container.
- Download the repository.
- Change information in Credentials.py with your own Telegram Bot key, which can be found here.
- Navigate to /bot directory in Powershell
- Build an image of the bot:
docker build -t stockbot .
- Run the image:
docker run -it --rm --detatch --name stockbot stockbot
- Or you can run the image headless:
docker run -it --rm --detatch --name stockbot stockbot