This message indicates that the stopLoss.trailAmount
provided in the request is invalid. TradersPost requires that the stopLoss.trailAmount
be a valid positive number. If a trail amount such as "-2" or "two" is provided, the request will not be processed.
This error can occur due to several reasons, such as:
stopLoss.trailAmount
is a negative number.stopLoss.trailAmount
is not a number (e.g., it contains letters or special characters).stopLoss.trailAmount
is zero or improperly formatted according to the required parameters.stopLoss.trailAmount
in your request is a positive number and correctly formatted to avoid this error.Invalid stopLoss.trailAmount
example:
{
"ticker": "AAPL",
"action": "sell",
"orderType": "trailing_stop",
"stopLoss": {
"type": "trailing_stop",
"trailAmount": "-2"
}
}
Valid stopLoss.trailAmount
example:
{
"ticker": "AAPL",
"action": "sell",
"orderType": "trailing_stop",
"stopLoss": {
"type": "trailing_stop",
"trailAmount": "2"
}
}
In the above examples, a valid trailing stop loss order includes a positive trailAmount
, ensuring clear and precise instructions for the trailing stop loss mechanism.