Trading View Signals Trading Mode
TradingViewSignalsTradingMode is a trading mode configured to automate orders creation on the exchange of your choice by following alerts from TradingView price events, indicators or strategies.
Free TradingView email alerts as well as webhook alerts can be used to automate trades based on TradingView alerts.
To know more, checkout the full TradingView trading mode guide.
Generate your own strategy using AI
Describe your trading strategy to the OctoBot AI strategy generator and get your strategy as Pine Script in seconds. Automate it with your self-hosted OctoBot or a TradingView OctoBot.
Alert format cheatsheet
Basic signals have the following format:
EXCHANGE=BINANCE
SYMBOL=BTCUSD
SIGNAL=BUY
Additional order details can be added to the signal but are optional:
ORDER_TYPE=LIMIT
VOLUME=0.01
PRICE=42000
STOP_PRICE=25000
TAKE_PROFIT_PRICE=50000
REDUCE_ONLY=true
Where:
ORDER_TYPEis the type of order (LIMIT, MARKET or STOP). Overrides theUse market ordersparameterVOLUMEis the volume of the order in base asset (BTC for BTC/USDT) it can a flat amount (ex:0.1to trade 0.1 BTC on BTC/USD), a % of the total portfolio value (ex:2%), a % of the available holdings (ex:12a%), a % of available holdings associated to the current traded symbol assets (10s%) or a % of available holdings associated to all configured trading pairs assets (10t%). It follows the orders amount syntax.PRICEis the price of the limit order in quote asset (USDT for BTC/USDT). Can also be a delta value from the current price by addingd(ex:10dor-0.55d) or a delta percent from the price (ex:-5%or25.4%). It follows the orders price syntax.STOP_PRICEis the price of the stop order to create. Can also be a delta or % delta likePRICE. When increasing the position or buying in spot trading, the stop loss will automatically be created once the initial order is filled. When decreasing the position (or selling in spot) using a LIMITORDER_TYPE, the stop loss will be created instantly. Orders crated this way are compatible with PNL history. It follows the orders price syntax.TAKE_PROFIT_PRICEis the price of the take profit order to create. Can also be a delta or % delta likePRICE. When increasing the position or buying in spot trading, the take profit will automatically be created once the initial order is filled. When decreasing the position (or selling in spot) using a LIMITORDER_TYPE, the take profit will be created instantly. Orders crated this way are compatible with PNL history. It follows the orders price syntax. Funds will be evenly split between take profits unless aTAKE_PROFIT_VOLUME_RATIOis set for each take profit.
Multiple take profit prices can be used fromTAKE_PROFIT_PRICE_1,TAKE_PROFIT_PRICE_2, ...TAKE_PROFIT_VOLUME_RATIOis the ratio of the entry order volume to include in this take profit. Used when multiple take profits are set. Specify multiple values usingTAKE_PROFIT_VOLUME_RATIO_1,TAKE_PROFIT_VOLUME_RATIO_2, .... When used, aTAKE_PROFIT_VOLUME_RATIOis required for each take profit.
Exemple:TAKE_PROFIT_PRICE=1234;TAKE_PROFIT_PRICE_1=1456;TAKE_PROFIT_VOLUME_RATIO_1=1;TAKE_PROFIT_VOLUME_RATIO_2=2will split 33% of entry amount in TP 1 and 67% in TP 2.REDUCE_ONLYwhen true, only reduce the current position (avoid accidental short position opening when reducing a long position). Only used in futures trading. Default is falseTAGis an identifier to give to the orders to create.LEVERAGEthe leverage value to use when trading futures.
When not specified, orders volume and price are automatically computed based on the current asset price and holdings.
Orders can be cancelled using the following format:
EXCHANGE=binance
SYMBOL=ETHBTC
SIGNAL=CANCEL
Additional cancel parameters:
PARAM_SIDEis the side of the orders to cancel, it can bebuyorsellto only cancel buy or sell orders.TAGis the tag of the order(s) to cancel. It can be used to only cancel orders that have been created with a specific tag.
Note: ; can also be used to separate signal parameters, exemple: EXCHANGE=binance;SYMBOL=ETHBTC;SIGNAL=CANCEL is equivalent to the previous example.
Find the full TradingView alerts format on the TradingView alerts format guide.