OPEN-SOURCE SCRIPT

ST + EMA [BTCUSD]

662
Delta Exchange embeds your strategy_id inside the Webhook URL itself when they generate it for you. Putting strategy_id in the JSON body sends the request to the wrong endpoint — Delta's router can't find it, hence the 404. The correct JSON body has only 4 fields, no strategy_id.
🔴 Root Cause 2 — qty with quotes → rejected by Delta
Our previous JSON had "qty":"{{strategy.order.contracts}}" (quoted = string). Delta's official format is "qty": {{strategy.order.contracts}} Delta Exchange India — no quotes, making it a JSON number. Delta's API validates the type and rejects strings.
🔴 Root Cause 3 — Decimal qty from percent_of_equity → rejected by Delta
The strategy was using default_qty_type=strategy.percent_of_equity, which calculates fractional contract sizes (e.g. 0.023). Delta Exchange requires order quantities to be whole numbers — decimals like 0.02 or 1.5 are rejected. Delta Exchange Changed to strategy.fixed with default_qty_value=1.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.