A Python library written to handle IB's Client Portal API, manage portfolio and execute trades.
Explore the docs »
View Demo
·
Report Bug
·
Request Feature
This project is built entirely on Python, it combines other Interactive Brokers libraries written by other contributors as well as my own contribution in making algorithmic trading on Interactive Brokers possible.
To get a local copy up and running follow these simple steps.
Before using this library, ensure you have Java installed and have an account with Interactive Brokers. Check out Interactive Broker Client Portal Web API for setting up. You can skip the download and unzip the CPI WebAPI step from the IB site as this step has been taken care off in the library.
-
Clone the repo
git clone https://github.com/Vincentho711/Interactive-Brokers-Trading-Bot.git
-
Navigate to the working directory
-
In the terminal, run
python setup.py build
and then
python setup.py install
-
Enter your IB credentials in write_config.py and run the script
-
Open run_client.py and run the script. It will download the clientportal.gw to the working directory.
-
Using Git Bash, navigate to the clientportal.gw folder and run
"bin/run.bat" "root/conf.yaml"
-
Run run_client.py in tests and the bot should be up and running.
-
Follow the instructions on run_client.py to configure your trading bot.
To use it, study the revelant libraries, namely the python objects in robot/ folder. There are also some simple instructions in the run_client.py to get you up and running quick.
See the open issues for a list of proposed features (and known issues).
Status | Milestone | Goals | ETA |
---|---|---|---|
🚀 | Implement the ability to associate tickers with different indicators and trigger levels | 1 / 1 | 15 April 2021 |
This milestone will be done when
- Different signals can be attached to a ticker
- All the indicators' signal can be checked independently, giving correct buy/sell signals
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.
Vincent Ho - LinkedIn
Project Link: https://github.com/Vincentho711/Interactive-Brokers-Trading-Bot