r/Python • • 21d ago

Showcase Showcase Thread

Post all of your code/projects/showcases/AI slop here.

Recycles once a month.

28 Upvotes

154 comments sorted by

View all comments

1

u/Significant-Pea-6852 6d ago

ninjatrader8-python-bridge: send orders from Python to NinjaTrader 8 and read the fills back, without the NT8 add-on API, sockets or DLLs.

Python writes a JSON order file, a small NinjaScript strategy inside NinjaTrader picks it up, enters the market order, attaches stop-loss/take-profit after the fill and writes a status file that Python polls. There's also a helper for futures prop accounts (tick values, contracts from dollar risk, trailing drawdown). Standard library only, MIT.

Limits: market entries only, orders go to the instrument and account the strategy is running on, and file polling adds roughly 0.1–0.5 s.

https://github.com/SimplAiTech/ninjatrader8-python-bridge