If order timeInForce is GTX (post only) reduceOnly=true not working

I’m trying to make a limit order with timeInForce = ‘GTX’ (post only) and ‘reduceOnly=true’, but the order is created without reduceOnly parameter.

I’m able to create the same order with timeInForce = ‘GTC’ - this way ‘reduceOnly=true’ is working fine.

Not true.
Your full request and raw error msg pls

  1. On the first image ‘reduceOnly’ => true (type boolean) - the order is created, but reduceOnly parameter is false;
  2. On the second image ‘reduceOnly’ => ‘true’ (type string) - there is an error.

For 1. - you set reduceOnly to 1 which makes it false
For 2. - you failed because you don’t have any LTCUSDT position to reduce.

It has nothing to do with “GTX”. Open some position and set reduceOnly = true and you’d succeed no matter whether it’s GTC or GTX

MJW, thanks for your help. I found my mistake:

  1. ‘reduceOnly’ => ‘true’ (must have type = string, not boolean)
  2. When making ‘reduceOnly’ order I had another open order that would be filled before (as written in p.3 here https://dev.binance.vision/t/why-do-you-get-reduceonly-rejection-errors/1198)

Finally I was able to make an order with timeInForce = ‘GTX’ (post only) and ‘reduceOnly=true’,