I'm trying to place a future position with /fapi/v1/order.
I keep encounter the error {'code': -1117, 'msg': 'Invalid side.'}
.
More info on code 1117
Actual pseudo code
futures.orders.create(
symbol='ADAUSDT',
market_type="TRAILING_STOP_MARKET",
position='LONG',
activationPrice=1.80,
callbackRate=2.0
)
I've tried ['BOTH', 'BUY/LONG', 'SELL/SHORT', 'LONG', 'SHORT', 'BUY', 'SELL']
but the same erros keeps coming back, so what do I do wrong?
I just realized you got two
side
parameters;positionSide
andside
.positionSide
was set butside
was not.Additional information:
There are only two available values for the
side
parameter of the order endpoint, one isBUY
another isSELL
. If you want to place an order under the hedge mode, please use another parameterpositionSide
along with theside
parameter.Hope this helps future people : )