GBPTrader wrote:
- If I place a MKT order of BUY 1mi and it gets partial filled as (0.2mi, 0.3mi and 0.5mi, in this order), what would be the getAmount(), getRequestedAmount() and Order state for each of these orders received in ORDER_FILL_OK messages?
Market orders don't get filled in such increments. The unfilled amount after the immidiate execution gets rejected. That is
getAmount() = 0.2
getRequestedAmount() = 1.0
IOrder.State = FILLED
See more here:
https://www.dukascopy.com/wiki/index.php ... rket_OrderGBPTrader wrote:
- Is it possible that for each of the above partial fills, only the second one was rejected. In other words, will I receive ORDER_FILL_OK, ORDER_FILL_REJECTED and ORDER_FILL_OK messages?
You will only receive ORDER_FILL_OK.
GBPTrader wrote:
- If a fill is rejected, does the system try to re-fill it automatically again or is it the user's responsibility to re-submit it?
For market orders there are no resubmission attempts - user has to do it himself. If you wish your order to be resubmitted, you might consider, for instance, limit entry orders, see:
https://www.dukascopy.com/wiki/index.php ... ntry_OrderGBPTrader wrote:
- If I close an order of 1mi and it gets partial filled as (0.2mi, 0.3mi and 0.5mi, in this order), what would be the getAmount(), getRequestedAmount() and Order state for each of these orders received in ORDER_CLOSE_OK?
Amounts are the same as on ORDER_FILL_OK.