The stop loss configuration is invalid. stopLoss.pnlAmount cannot be used when stopLoss.type is trailing_stop.
This message indicates that stopLoss.pnlAmount was used together with stopLoss.type trailing_stop. Portfolio PnL stop loss applies only to stop market (stop) and stop limit (stop_limit) orders. Trailing stops use trailAmount or trailPercent instead.
Invalid example:
{
"ticker": "AAPL",
"action": "buy",
"orderType": "limit",
"limitPrice": 100,
"stopLoss": {
"type": "trailing_stop",
"pnlAmount": 100,
"trailPercent": "1"
}
}
Valid trailing stop (no PnL):
{
"ticker": "AAPL",
"action": "buy",
"orderType": "limit",
"limitPrice": 100,
"stopLoss": {
"type": "trailing_stop",
"trailPercent": "1"
}
}
Valid PnL stop (non-trailing):
{
"ticker": "AAPL",
"action": "buy",
"orderType": "limit",
"limitPrice": 100,
"stopLoss": {
"type": "stop",
"pnlAmount": 100
}
}
Free 7-day trial
Set-up in 3 minutes
Paper account for testing
By continuing, you agree to the TradersPost Terms of Service and Privacy Policy. This site is protected by reCAPTCHA.