About β’ Features β’ Installation β’ Images β’ Help
The TradingView Webhook Bot βοΈ listens to TradingView alerts via webhooks using flask. All alerts can be instantly sent to Telegram, Discord, Twitter and/or Email.
Webhook Alerts π₯
I am running my own Webhook Alerts Service. No setup and hosting required!
Send all your alerts to Telegram, Discord, Slack & Twitter along with a full screenshot of the chart complete with your indicators.
Find out more at WebhookAlerts.com. Got a question? Let me know!
- Telegram Support using the Python Telegram libary
- Discord Support using webhooks
- Slack Support using webhooks
- Twitter Support using the tweepy libary
- Email Support using smtplib
- Alert channels can be enabled or disabled in
config.py
- Dynamically send alerts to different Telegram and/or Discord channels
- TradingView
{{close}}
,{{exchange}}
etc. variables support. Read more here
π‘ Got a feature idea? Open an issue and I might implement it.
β οΈ Best to run the bot on a VPS. I can recommend Hetzner's CX11 VPS for 2.89β¬/month. Sign up now and receive β¬20 free credits.
- Clone this repository
git clone https://github.com/fabston/TradingView-Webhook-Bot.git
- Create your virtual environment
python3 -m venv TradingView-Webhook-Bot
- Activate it
source TradingView-Webhook-Bot/bin/activate && cd TradingView-Webhook-Bot
- Install all requirements
pip install -r requirements.txt
- Edit and update
config.py
- Setup TradingView alerts. An example alert message would be:
{ "key": "9T2q394M92", "telegram": "-1001277977502", "discord": "789842341870960670/BFeBBrCt-w2Z9RJ2wlH6TWUjM5bJuC29aJaJ5OQv9sE6zCKY_AlOxxFwRURkgEl852s3", "slack": "T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", "msg": "Long *#{{ticker}}* at `{{close}}`" }
key
is mandatory! It has to match withsec_key
inconfig.py
. It's an extra security measurement to ensure nobody else is executing your alertstelegram
,discord
,slack
is optional. If it is not set it will fall back to the config.py settingsmsg
can be anything. Markdown for Telegram and Discord is supported as well- TradingViews variables like
{{close}}
,{{exchange}}
etc. work too. More can be found here
- TradingViews variables like
- Your webhook url would be
http://<YOUR-IP>/webhook
- If you use a firewall be sure to open the corresponding port
- Run the bot with
python main.py
- PM2 can help you in running the app in the background / on system boot.
- Clone this repository
git clone https://github.com/fabston/TradingView-Webhook-Bot.git
- Edit and update
config.py
docker-compose build
docker-compuse up
It is recommended to run flask on a different port like 8080. It is then necessary to forward port 80 to 8080.
All kinds of contributions are welcome π! The most basic way to show your support is to βοΈ star
the project, or raise π issues
. You can also support this project by becoming a π sponsor on GitHub
to ensure this journey continues indefinitely! π