-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.go
More file actions
48 lines (33 loc) · 808 Bytes
/
app.go
File metadata and controls
48 lines (33 loc) · 808 Bytes
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
package main
import (
"github.com/CryptoTradingBot/exchanges/bitmex"
"github.com/CryptoTradingBot/exchanges/config"
"github.com/CryptoTradingBot/botApp/charts"
)
const (
// fields for test verification bitmex methods
Key = "yHCVhvImDYXCyDVJCiJPjUDT"
KeySecret = "b6LvJGLI3-cZJ5geVhRvccdE_w9y94opWVzaX5mGPReRJHMK"
SYMBOL = "XBTUSD"
)
type Bot struct {
exchange bitmex.Bitmex
}
var bot Bot
var exchangeConfig config.ExchangeConfig
func main() {
// set minimal settings
exchangeConfig := config.ExchangeConfig{
Enabled:true,
Verbose:true,
AuthenticatedAPISupport:true,
APIKey: Key,
APISecret: KeySecret,
UseSandbox: true,
}
bot.exchange.SetDefaults()
// setup
bot.exchange.Setup(exchangeConfig)
var b = bot.exchange
charts.GetCharts(SYMBOL, "5m", 100, b)
}