The documentation does not explicitly state which leg should be treated as the main leg.
The API docs mention:
“Note: Cancelling main order ID cancels all legs.”
However, it is unclear which leg should be passed as order-leg to cancel the entire order. Is the ENTRY_LEG considered the main leg?
Additionally, I would like clarification on partial fills:
If the order is partially filled and I cancel using the entry leg, will the trailing stop-loss / target / SL legs continue to function correctly for the remaining filled quantity?