This message indicates that the takeProfit.limitPrice
provided in the request is invalid. TradersPost requires that the takeProfit.limitPrice
be a valid positive number, representing the price at which the take profit order will be filled.
For example, if a takeProfit.limitPrice
such as "-50" or "xyz" is provided, the request will not be processed.
This error can occur due to several reasons, such as:
takeProfit.limitPrice
is a negative number.takeProfit.limitPrice
is not a number (e.g., it contains letters or special characters).takeProfit.limitPrice
is zero or improperly formatted according to the required parameters.takeProfit.limitPrice
in your request is a positive number and correctly formatted to avoid this error.Invalid takeProfit.limitPrice
example:
{
"ticker": "AAPL",
"action": "buy",
"orderType": "limit",
"limitPrice": 100,
"takeProfit": {
"stopPrice": "90",
"limitPrice": "invalid"
},
}
Valid takeProfit.limitPrice
example:
{
"ticker": "AAPL",
"action": "buy",
"orderType": "limit",
"limitPrice": 100,
"takeProfit": {
"type": "stop_limit",
"stopPrice": "110",
"limitPrice": "109"
},
}