Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/Erfaniaa/binance-futures-trading-bot
Easy-to-use multi-strategic automatic trading for Binance Futures with Telegram integration
https://github.com/Erfaniaa/binance-futures-trading-bot
algo-trading auto-trading binance binance-api binance-bot binance-futures bitcoin bot crypto cryptocurrency cryptocurrency-trading-bot futures python python3 robot telegram telegram-bot trading trading-bot trading-robot
Last synced: 2 months ago
JSON representation
Easy-to-use multi-strategic automatic trading for Binance Futures with Telegram integration
- Host: GitHub
- URL: https://github.com/Erfaniaa/binance-futures-trading-bot
- Owner: Erfaniaa
- License: gpl-3.0
- Created: 2022-07-04T16:25:19.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-03-13T00:30:33.000Z (11 months ago)
- Last Synced: 2024-10-26T21:49:23.392Z (3 months ago)
- Topics: algo-trading, auto-trading, binance, binance-api, binance-bot, binance-futures, bitcoin, bot, crypto, cryptocurrency, cryptocurrency-trading-bot, futures, python, python3, robot, telegram, telegram-bot, trading, trading-bot, trading-robot
- Language: Python
- Homepage:
- Size: 68.4 KB
- Stars: 333
- Watchers: 9
- Forks: 80
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-crypto-trading-bots - binance-futures-trading-bot - Easy-to-use multi-strategic automatic trading for Binance Futures with Telegram integration (Open source bots)
- awesome-crypto-trading-bots - binance-futures-trading-bot - Easy-to-use multi-strategic automatic trading for Binance Futures with Telegram integration (Open source bots)
README
# Binance Futures Trading Bot
Easy-to-use multi-strategic automatic trading for Binance Futures with Telegram integration
## Features
- You can run it fast and it's easy to use.
- This project can handle multiple strategies at the same time.
- There are no complexities and no database usage in this project. Even dependencies are a few.
- It's easy to modify and customize.
- It automatically stores recent candles that can be used for machine learning model input.
- You can read the code for educational purposes.
- You can be notified with Telegram messages## Run
1. Clone the repository.
2. Generate a Binance API key (with Futures access) and put it in `credentials.py`.
3. Run `pip3 install -r requirements.txt`.
4. Run `python3 init_indicators_dict.py`.
5. Run `python3 init_orders_dict.py`.
6. Run `python3 main.py`.This will run an example bot on trading Bitcoin with 4 strategies simultaneously.
## Config
To write custom bots you can:
- Set an initial indicators setting in `init_indicators_dict.py` (because we are handling indicators in the client side with pickle files).
- Set an initial orders setting in `init_orders_dict.py` (because we are handling orders in the client side with pickle files).
- Define new indicators in `indicators.py`.
- Define a new strategy in `main.py` (especially inside `is_it_time_to_open_long_position` and `is_it_time_to_open_short_position` functions).
- Config your bot settings in `config.py`.**Note:** If you define any machine learning model, you can use `recent_prices_list` as its input.
**Warning:** Binance has a maximum limit of 10 take-profit and stop-loss open orders, therefore do not use more than 5 strategies at the same time.
## Telegram Config
1. Firstly, you need to create a Telegram bot, so talk to [@botfather](https://t.me/botfather).
2. Secondly, need to know your own Telegram user ID, so the bot will know who to send messages to. Talk to [@userinfobot](https://t.me/userinfobot) to get this information.
3. Thirdly, you have to `/start` your bot. Open up a private message with your bot by searching its username, then hit the start button.
4. Finally, set `TELEGRAM_API_KEY` and `TELEGRAM_USER_ID` in `credentials.py`, and `SEND_TELEGRAM_MESSAGE` in `config.py`.## To-do
- Import modules, not variables.
- Use classes and make `main.py` smaller.
- Add more indicators to `indicators.py`.
- Find a better way to handle error codes.
- Unify get candles functions.## See Also
- [Crypto Trading Strategy Backtester](https://github.com/Erfaniaa/crypto-trading-strategy-backtester)
- [Binance Spot Trading Bot](https://github.com/smzerehpoush/binance-spot-trading-bot)
- Finestel: Our automated trading bot can be used on Finestel & Finestel Pro: a crypto copy trading platform where pro traders & asset managers can connect their exchange accounts and manage their clients and communities of investors’ assets by using Finestel/Finestel Pro in conjunction with our Binance futures bot. Investors have the opportunity to profit the same as you while learning from more experienced traders.## Credits
[Erfan Alimohammadi](https://github.com/Erfaniaa) and [Amir Reza Shahmiri](https://github.com/Amirrezashahmiri)