Skip to content

Latest commit

 

History

History
61 lines (47 loc) · 2.44 KB

File metadata and controls

61 lines (47 loc) · 2.44 KB

TradingView Integration

This section provides details on integrating TradingView strategies and indicators with Alphabots Signal based webhook.

Project Structure

  • `tradingview/strategies/`: Trading strategy implementations
    • `ma_crossover_strategy.pine`: Moving Average Crossover strategy
    • `macd_vwap_strategy.pine`: MACD + VWAP strategy
    • `macd_vwap_atr_strategy.pine`: MACD + VWAP + ATR strategy
    • `momentumbreak_Crypto.pine`: Momentum breakout for crypto
    • `sample_strategy.pine`: Sample strategy with webhook alerts

TradingView Strategies

This folder contains Pine Script v5 strategies demonstrating:

  • JSON alert generation for Alphabots Signal webhook
  • Entry/exit logic with dynamic symbol support
  • Various technical indicator combinations

Setting Up Webhook in TradingView

  1. Open TradingView: Log in to your account and open the chart
  2. Create Alert: Click "Alerts" → "Create Alert"
  3. Configure Conditions: Set conditions based on your strategy
  4. Set Webhook URL: Enter your Alphabots webhook URL in the "Webhook URL" field
  5. Customize Message: Enter the JSON formatted alert message
  6. Save Alert: Click "Create" to save

TradingView Webhook Setup

Features

  • Generates JSON alerts compatible with Alphabots Signal webhook
  • Supports both `alert()` and `alertcondition()` functions
  • Dynamic symbol input for flexible deployment
  • Multiple strategies with different technical indicators
  • Supports multiple timeframes

Alert Format

Alerts follow this JSON structure:

```json {"order":[{"type":"ENTRY","quantity":1,"side":"B","ordertype":"MARKET","symbol":"NSE:SYMBOL","segment":"FUT","product":"N"}]} ```

Order Format Reference

Field Values Required For
`type` "ENTRY" or "EXIT" All
`symbol` "NSE:SBIN-EQ", "NSE:NIFTY25APRFUT" All
`quantity` Number (must be > 0) All
`side` "B" (Buy) or "S" (Sell) All
`ordertype` "MARKET", "LIMIT", "STOP", "STOPLIMIT" All
`segment` "EQ", "FUT", "OPT" ENTRY only
`product` "I" (Intraday), "D" (Delivery), "N" (Normal) ENTRY only
`limit_price` Number (must be > 0) LIMIT, STOPLIMIT
`stop_price` Number (must be > 0) STOP, STOPLIMIT

For more details visit alphabots.in