Limit Orders via TradingView - Tickerly - Alpaca rejected with error

I am running an automated trading strategy on TradingView that sends alerts to Tickerly, which then executes orders through the Alpaca API. Market orders execute successfully through the same pipeline:

TradingViewStrategy - Tickerly Webhook - Alpaca

However, limit orders consistently fail with the following error:

“To place a limit order for(symbol) on Alpaca, you need to specify a limit price.” This occurs across multiple symbols including equities and crypto

TradingView strategy generates the following JSON payload:

{

“ticker”: “AAVEUSD”,

“action”: “buy”,

“prev_position”: “flat”,

“quantity”: 10,

“type”: “limit”,

“price”: 85.42,

“pointer”: “v2……….Masked)” ( I removed the pointer for sharing purposes)

}

The limit price is calculated in Pine Script and formatted according to Alpaca price rules

; Price greater than and equal to 1 - 2 decimals and Price less than 1 - 4 decimals

My question is what am I missing here? what is the correct JSON structure required by Alpaca when submitting limit orders through a third-party webhook service like Tickerly?

For Alpaca limit orders, time_in_force must be gtc or ioc. Does Tickerly require me to include time_in_force in the alert payload(and if so, what key name does it expect: tif, time_in_force, etc.)? Also, should the limit value be provided as price or Limit_price for Alpaca routing?

@ImmortalOrigin I’m not familiar with Tickerly, but I assume the format they require is simply the JSON format Alpaca requires to place an order? If that is the case, then you will need to name the parameters like this:

{
“type”: “limit”,
“time_in_force”: “gtc”,
“symbol”: “AAVE/USD”,
“qty”: “10”,
“side”: “buy”,
“limit_price”: “85.42”
}

Also, notice you need to include a forward slash ( /) when specifying a crypto pair. In this case, it specifies you want to buy AAVE using USD from cash in your account.