-
Notifications
You must be signed in to change notification settings - Fork 0
/
config-template.ini
82 lines (66 loc) · 2 KB
/
config-template.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
[DEFAULT]
# The config variables below are:
# - your preferred ngrok subdomain (remove the line if you want to use the free ngrok)
# - a password you put in the Tradingview alert text, which the broker app on this end will require to match what's in the config
ngrok-subdomain = YOUR-NGROK-SUBDOMAIN
signals-password = YOUR-SIGNALS-PASSWORD
ngrok-run = yes
# If you want to use TextMagic to SMS any errors (leave blank if not):
textmagic-username =
textmagic-key =
textmagic-phone = +1xxxyyyzzzz
# Global multiplier
multiplier = 1.0
# For each IB bot, you can list your accounts, comma delimited, and they'll all get the trades with
# a percent of funds or proportional multiplier; otherwise just the main account will get the trades
[bot-live]
accounts-live = U9999999x,U9999999y
[U9999999x]
TQQQ-pct = 90
# driver info for IBKR for this account
driver = ibkr
host = 127.0.0.1
port = 7496
[U9999999y]
multiplier = 0.1
use-inverse-etf = yes
# driver info for Alpaca for this account
driver = alpaca
key = YOURKEY
secret = YOURSECRET
paper = yes
# some standard mapping from long ETF to short ones, for use-inverse-etf (i.e. cash) accounts
[inverse-etfs]
SOXL = SOXS
TQQQ = SQQQ
BOIL = KOLD
LABU = LABD
/*
For the signals from TV, use this json payload:
{
"time": "{{timenow}}",
"exchange": "{{exchange}}",
"ticker": "{{ticker}}",
"bar": {
"time": "{{time}}",
"open": {{open}},
"high": {{high}},
"low": {{low}},
"close": {{close}},
"volume": {{volume}}
},
"strategy": {
"bot": "live",
"position:size": {{strategy.position_size}},
"order_action": "{{strategy.order.action}}",
"order_contracts": {{strategy.order.contracts}},
"order_price": {{strategy.order.price}},
"order_id": "{{strategy.order.id}}",
"market_position": "{{strategy.market_position}}",
"market_position_size": {{strategy.market_position_size}},
"prev_market_position": "{{strategy.prev_market_position}}",
"prev_market_position_size": {{strategy.prev_market_position_size}}
},
"passphrase": "YOURPASSPHRASE"
}
*/