You limit order to sell was below Bid and so got immediately converted into market.
Which - given your latency and a fast falling market - resulted in a significant slippage.

This would happen regardless of the broker/API.

Frequency of price updates from the API is another thing that will influence this behaviour(to be changed via TickTime).