TradierCPP is a C++ application designed to interface with the Tradier API, perform market data streaming via WebSockets, and perform custom data processing.
- Market Data Streaming: Utilizes Tradier's WebSocket API to stream real-time market data.
- Data Processing: Processes streamed data to perform financial analysis or other operations.
- Modular Architecture: Divided into separate modules for streaming and processing to enhance maintainability and scalability.
- Boost (specifically Asio, Beast, and System components)
- OpenSSL for secure connections
- nlohmann-json for JSON parsing
TradierCPP/
│
├── include/ - Header files
│ └── Account.h
│ └── EnvReader.h
│ └── Tradier.h
│
├── src/ - Source files
│ ├── Tradier.cpp
│ ├── Account.cpp
│ ├── EnvReader.cpp
│ ├── main.cpp
│ ├── main_stream.cpp
│ ├── main_dataprocess.cpp
│ └── TradierHTTPConnect.cpp
|
├── data/ - Streamed data and processed JSON
│ ├── market_data.txt
│ ├── processed_json{DATE}.txt
│
├── CMakeLists.txt - CMake build configuration file
└── .env - Environment variables for API keys and account details
-
Clone the repository:
git clone https://yourrepository.com/TradierCPP.git cd TradierCPP
-
Build with CMake:
mkdir build && cd build cmake .. make
This will generate executable files for different parts of the application, such as for streaming and processing.
After building the project, run the executables:
• WebSocket Streaming
./TradierStream
• Convert streamed data into JSON for downstream processing
./TradierDataProcess
• General account information
./TradierCPP
This command will initiate the WebSocket streaming and other financial data processing tasks.
Ensure that the .env
file is correctly set up with your Tradier API credentials and other configuration details:
tradier_acct_live=YourAccountNumber
tradier_token_live=YourAuthToken
Still under development, so contributions are welcome. Fork and pull please.
Distributed under the MIT License. See LICENSE
for more information.
Tom Hammons
hammons.thomas@gmail.com
https://github.com/thammo4/tradiercpp