Webhook Message

Invalid Stop Loss Trail Amount

Invalid stop loss trail amount.

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:

  • The stopLoss.trailAmount is a negative number.
  • The stopLoss.trailAmount is not a number (e.g., it contains letters or special characters).
  • The stopLoss.trailAmount is zero or improperly formatted according to the required parameters.
  • Ensure that the 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.

Ready to automate your trading? Sign up for free today.