MT5 Requote and Deviation
To get symbol execution type of the symbol use following:
ExecutionType type = api.Symbols.GetGroup("EURUSD").TradeType;
In restful you can get TradeType with using /SymbolParams
If symbol has Market execution deviation parameter doesn’t work, it also doesn’t depend open price you put during order sending. Market execution means that position would be opened at any comfortable for broker price.
Instant execution means that you can specify maximum deviation and if price will go against you for more pips than specified in slippage parameter requote exception would be thrown.
If you getting unexpected requote exceptions:
- Make sure that you open buy order at latest ask price and sell order at latest bid.
- Make sure that you close buy order at latest bid price and sell order at latest ask.
- Use bigger deviation parameter value.