Update api endpoints
This commit is contained in:
parent
2616308baa
commit
f7d0d2c1be
@ -78,7 +78,7 @@ func NewOrderBook(coin string) (*OrderBook, error) {
|
|||||||
var o OrderBook
|
var o OrderBook
|
||||||
var err error
|
var err error
|
||||||
|
|
||||||
o.conn, _, err = websocket.DefaultDialer.Dial("wss://ws-feed.gdax.com", nil)
|
o.conn, _, err = websocket.DefaultDialer.Dial("wss://ws-feed.pro.coinbase.com", nil)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -254,7 +254,7 @@ func (o *OrderBook) loadOrderBook() {
|
|||||||
o.askLock.Unlock()
|
o.askLock.Unlock()
|
||||||
o.bidLock.Unlock()
|
o.bidLock.Unlock()
|
||||||
|
|
||||||
resp, err := http.Get(fmt.Sprintf("https://api.gdax.com/products/%v/book?level=3", coin))
|
resp, err := http.Get(fmt.Sprintf("https://api.pro.coinbase.com/products/%v/book?level=3", coin))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
o.sendError(err)
|
o.sendError(err)
|
||||||
o.Shutdown()
|
o.Shutdown()
|
||||||
|
Reference in New Issue
Block a user