added okex websocket types
package okex
+import "encoding/json"
+
// ContractPrice holds date and ticker price price for contracts.
type ContractPrice struct {
Date string `json:"date"`
@@ -17,6 +19,33 @@ type ContractPrice struct {
Error interface{} `json:"error_code"`
}
+type MultiStreamData struct {
+ Channel string `json:"channel"`
+ Data json.RawMessage `json:"data"`
+}
+
+type TickerStreamData struct {
+ Buy string `json:"buy"`
+ Change string `json:"change"`
+ High string `json:"high"`
+ Low string `json:"low"`
+ Last string `json:"last"`
+ Sell string `json:"sell"`
+ DayLow string `json:"dayLow"`
+ DayHigh string `json:"dayHigh"`
+ Timestamp float64 `json:"timestamp"`
+ Vol string `json:"vol"`
+}
+
+type DealsStreamData = [][]string
+type KlineStreamData = [][]string
+
+type DepthStreamData struct {
+ Asks [][]string `json:"asks"`
+ Bids [][]string `json:"bids"`
+ Timestamp float64 `json:"timestamp"`
+}
+
// ContractDepth response depth
type ContractDepth struct {
Asks []interface{} `json:"asks"`
