Trying to place an order to the test network via the api/v3/order Spot API endpoint with a trailingDelta.
I have tried LIMIT, STOP_LOSS_LIMIT, TAKE_PROFIT_LIMIT order types with the trailingDelta optional field, but it throws the error missing field price or missing field symbol.
The order definitely has these fields, the exchange info endpoint api/v3/exchangeInfo for Spot BTCBUSD or BTCUSDT says that the order types I tried are valid: LIMIT, STOP_LOSS_LIMIT, TAKE_PROFIT_LIMIT.
And the endpoint api/v3/account says that I have permission to trade SPOT for the test network.
The documentation for Spot API says that trailingDelta is supported for these order types.
Here is one of the requests that throws the error "missing field price", line: 1, column: 125
Maybe it’s related with how your local code is sending the request?
Because I’ve tried: POST https://testnet.binance.vision/api/v3/order?symbol=BTCBUSD&side=BUY&type=TAKE_PROFIT_LIMIT&timeInForce=GTC&quantity=0.00828&price=26907.21&trailingDelta=95×tamp=<timestamp>&signature=<signature>
Thanks for the quick reply! Yes, you’re correct. I got it to work with Postman as well.
My issue was the JSON response for different Orders varies.
I was deserializing the Order response into a struct with a field ‘price’ that did not exist on the response I was actually getting: