then what else can i use on tws?
I use ib_insync
then what else can i use on tws?
The boy band?ib_insync
The boy band?
I am currently using IB api, but I plan to use multiple brokers, so I need to choose an api which is easy to plant across brokers. I find there are two options, fix or restful api. which is better? fix protocol is old, and restful api is the future to go? which api has more brokers to support so far and in the future?
We can provide you with 2 types of API so you can test it.
You can have FIX API from CTS-T4 and C++ and C# from Rithmic.
Rithmic also uses R Protocol that could work with python.
This is for Futures. Please PM if you need a trial.
WebSockets are magnitudes slower than native sockets (I think 100x last I checked). Why not have a proper socket interface?
No. I mean a C++ API that uses a C++ sample code to send orders. The broker then takes that and only sends orders using FIX to the exchanges. If you use FIX, you need a FIX server that needs to be certified with each broker. And, not every broker uses the same FIX version.
REST APIs are by definition all proprietary. Be prepared to write new code for each broker. FIX is in theory more standardized.
Another item to consider: REST is generally a request-response protocol, while FIX is message-based. In general, you can expect more latency in a REST API.
any idea how slow is FIX compared with native socket?
thank youPurely latency wide Fix is slower than a very high performance C++ Api. That is why most hft houses use the direct C++ APIs offered by exchanges and don't use FIX. But Fix is still easier (not trivial) to implement than having to target the entirely unique non fix api each broker offers.