-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmodels.go
More file actions
62 lines (49 loc) · 1.26 KB
/
models.go
File metadata and controls
62 lines (49 loc) · 1.26 KB
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
package WebsocketCryptoScraper
//ListenOut contains data from exchanges and the corresponding exchange
type ListenOut struct {
exchange string
message interface{}
}
//Huobi models
//PingHuobi is a ping message to Huobi
type PingHuobi struct {
Ping int64 `json:"ping"`
}
//PongHuobi a pong message to Huobi
type PongHuobi struct {
Pong int64 `json:"pong"`
}
//HuobiSubscription is a subscription a Huobi channel
type HuobiSubscription struct {
Sub string `json:"sub"`
ID string `json:"id"`
Unsub string `json:"unsub"`
}
//Binance models
//PingBinance is a ping to Binance
type PingBinance struct {
Ping int `json:"ping"`
}
//Bitfinex models
//BitFinexSub is a subscription message to BitFinex
type BitFinexSub struct {
Event string `json:"event"`
Channel string `json:"channel"`
Symbol string `json:"symbol"`
}
//BitFinexPing is a ping message to BitFinex
type BitFinexPing struct {
Event string `json:"event"`
Cid int `json:"cid"`
}
//HitBTC models
//HitBtcSubscription is a subscription message to HitBtc
type HitBtcSubscription struct {
Method string `json:"method"`
Params HitBtcParams `json:"params"`
ID int `json:"id"`
}
//HitBtcParams is used for HitBtcSubscription
type HitBtcParams struct {
Symbol string `json:"symbol"`
}