June 05, 2025
11 11 11 AM

Installation

TradeHook

Software designed to accept webhook alerts from Trading View and execute long and short trades.

How to run on Windows 10

Requirements

  • Microsoft Visual C++ 2015-2022 Redistributable (x64) – 14.42.34433
  • .Net 3.5
  • .Net 6.0

How to install on Ubuntu 22.04

sudo apt update
sudo apt install dotnet6
wget https://github.com/klaxis/tradingview-tradehook/releases/download/v1.0.0.0/Tradehook_console.zip
sudo apt install unzip
unzip Tradehook_console.zip
sudo dotnet ./console.dll

Config

Configuration of the Tradehook software.

  1. Address – All incoming traffic 0.0.0.0 or Local traffic 127.0.0.1 or Public IP address
  2. Port – Trading View will only accept port 80 unless you use a proxy
  3. buy and sell can be enabled or disabled
  4. amount is no longer used
  5. Alpaca mode use paper or live
  6. buy_pct what percent of you balance will be made to purchase a position. (Range is 0.01 to 1)
  7. sell_pct what percent of your position will be sold. (Range is 0.01 to 1)
  8. vix is currently used to enable or disable vix but is overridden by a vix signal from Trading View and does not consume a license.
  9. license code is used to allow more ticker to receive Trading View alerts .
[
  {
    "address": "127.0.0.1",
    "port": "80",
    "buy": "False",
    "sell": "False",
    "amount": "5",
    "alpaca_mode": "paper",
    "buy_pct": "0.1",
    "sell_pct": "0.9",
    "vix": "False",
    "license": ""
  }
]

Secrets

Add your API secrets for use with communicating to the exchange to open and close positions only.

  {
    "alpaca_key": "api-key",
    "alpaca_secret": "api-secret",
    "gemini_key": "",
    "gemini_secret": ""
  }
]

Licensing

Add your trading assets by the ticker name to consume a license. If they are not listed, then you will not be able to use them.

Example (lic.json)

[
  {
    "symbol": "APPL"
  },
  {
    "symbol": "BRK.B"
  },
  {
    "symbol": "BTC"
  }
]