- Create a TradingView account
- Go to a chart
- Add an alert
- Configure alert
- Setup your condition
- Webhook url :
http://YOUR.STATIC.IP.ADDRESS/trades
- Search the exchange symbol alias format you want to trade (examples: XXX-PERP for FTX futures, XXX/USD for FTX spot, XXX/USDT for Binance USD markets ... you can use list markets command in Commands section)
- Message should have this structure :
-
Long position :
{ "stub": "dev", "direction": "long", "symbol": "ETH-PERP", "size": "50" }
-
Short position :
{ "stub": "dev", "direction": "short", "symbol": "ETH-PERP", "size": "50" }
-
Close 100% of a position :
{ "stub": "dev", "direction": "close", "symbol": "ETH-PERP" }
-
Close a fraction of a position in percent (
⚠️ WATCH OUT, the fraction must be greater or equal than the minimum tradable amount set by the exchange for selected pair ! Size must be between 1 and 100 with a percent sign, otherwise 100% will be closed) :{ "stub": "dev", "direction": "close", "symbol": "ETH-PERP", "size": "50%" }
-
Open a long position with 5% of available collateral (Futures) or available balance (Spot) (
⚠️ WATCH OUT, the fraction must be greater or equal than the minimum tradable amount set by the exchange for selected pair !) :{ "stub": "dev", "direction": "long", "symbol": "ETH-PERP", "size": "5%" }
-
Open a short position with 5% of available collateral (Futures) or available balance (Spot) (
⚠️ WATCH OUT, the fraction must be greater or equal than the minimum tradable amount set by the exchange for selected pair !) :{ "stub": "dev", "direction": "short", "symbol": "ETH-PERP", "size": "5%" }
-
Long position with a 500 $US max budget :
{ "stub": "dev", "direction": "long", "symbol": "ETH-PERP", "size": "50", "max": "500" }
-
Short position with a 500 $US max budget :
{ "stub": "dev", "direction": "short", "symbol": "ETH-PERP", "size": "50", "max": "500" }
-
Process multiple trades :
[{ "stub": "dev", "direction": "long", "symbol": "ETH-PERP", "size": "50" }, { "stub": "dev", "direction": "long", "symbol": "BTC-PERP", "size": "50" }]
-