Added new initial functions for bot/exchange interface. (#120)

This commit is contained in:
Ryan O'Hara-Reid
2018-05-30 13:49:58 +10:00
committed by Adrian Gallagher
parent 729b9a68f7
commit 02dbab03ce
27 changed files with 970 additions and 3 deletions

View File

@@ -95,3 +95,62 @@ func (a *Alphapoint) GetExchangeHistory(p pair.CurrencyPair, assetType string) (
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order and returns a true value when
// successfully submitted
func (a *Alphapoint) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return a.CreateOrder(p.Pair().String(), side, orderType, amount, price)
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (a *Alphapoint) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return a.ModifyOrder(p.Pair().String(), orderID, action)
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (a *Alphapoint) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return a.CancelOrder(p.Pair().String(), orderID)
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (a *Alphapoint) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return a.CancelAllOrders(p.Pair().String())
}
// GetExchangeOrderInfo returns information on a current open order
func (a *Alphapoint) GetExchangeOrderInfo(orderID int64) (float64, error) {
orders, err := a.GetOrders()
if err != nil {
return 0, err
}
for x := range orders {
for y := range orders[x].Openorders {
if int64(orders[x].Openorders[y].Serverorderid) == orderID {
return float64(orders[x].Openorders[y].QtyRemaining), nil
}
}
}
return 0, errors.New("order not found")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (a *Alphapoint) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
addreses, err := a.GetDepositAddresses()
if err != nil {
return "", err
}
for x := range addreses {
if addreses[x].Name == p.Pair().String() {
return addreses[x].DepositAddress, nil
}
}
return "", errors.New("associated currency address not found")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (a *Alphapoint) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", a.WithdrawCoins(p.Pair().String(), p.GetFirstCurrency().String(), address, amount)
}

View File

@@ -147,3 +147,39 @@ func (a *ANX) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]excha
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (a *ANX) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (a *ANX) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (a *ANX) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (a *ANX) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (a *ANX) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (a *ANX) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (a *ANX) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -132,3 +132,39 @@ func (b *Binance) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]e
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *Binance) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *Binance) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *Binance) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *Binance) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *Binance) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *Binance) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *Binance) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -169,3 +169,39 @@ func (b *Bitfinex) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *Bitfinex) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *Bitfinex) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *Bitfinex) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *Bitfinex) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *Bitfinex) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *Bitfinex) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *Bitfinex) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -12,7 +12,7 @@ import (
"github.com/thrasher-/gocryptotrader/exchanges/ticker"
)
// Start starts the Bitfinex go routine
// Start starts the Bitflyer go routine
func (b *Bitflyer) Start(wg *sync.WaitGroup) {
wg.Add(1)
go func() {
@@ -21,7 +21,7 @@ func (b *Bitflyer) Start(wg *sync.WaitGroup) {
}()
}
// Run implements the Bitfinex wrapper
// Run implements the Bitflyer wrapper
func (b *Bitflyer) Run() {
if b.Verbose {
log.Printf("%s Websocket: %s.", b.GetName(), common.IsEnabled(b.Websocket))
@@ -121,7 +121,7 @@ func (b *Bitflyer) UpdateOrderbook(p pair.CurrencyPair, assetType string) (order
}
// GetExchangeAccountInfo retrieves balances for all enabled currencies on the
// Bitfinex exchange
// Bitflyer exchange
func (b *Bitflyer) GetExchangeAccountInfo() (exchange.AccountInfo, error) {
var response exchange.AccountInfo
response.ExchangeName = b.GetName()
@@ -144,3 +144,39 @@ func (b *Bitflyer) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *Bitflyer) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *Bitflyer) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *Bitflyer) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *Bitflyer) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *Bitflyer) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *Bitflyer) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *Bitflyer) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -104,3 +104,39 @@ func (b *Bithumb) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]e
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *Bithumb) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *Bithumb) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *Bithumb) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *Bithumb) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *Bithumb) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *Bithumb) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *Bithumb) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -154,3 +154,39 @@ func (b *Bitstamp) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *Bitstamp) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *Bitstamp) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *Bitstamp) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *Bitstamp) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *Bitstamp) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *Bitstamp) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *Bitstamp) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -160,3 +160,39 @@ func (b *Bittrex) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]e
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *Bittrex) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *Bittrex) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *Bittrex) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *Bittrex) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *Bittrex) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *Bittrex) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *Bittrex) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -139,3 +139,39 @@ func (b *BTCC) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exch
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *BTCC) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *BTCC) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *BTCC) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *BTCC) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *BTCC) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *BTCC) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *BTCC) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -139,3 +139,39 @@ func (b *BTCMarkets) GetExchangeHistory(p pair.CurrencyPair, assetType string) (
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (b *BTCMarkets) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (b *BTCMarkets) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (b *BTCMarkets) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (b *BTCMarkets) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (b *BTCMarkets) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (b *BTCMarkets) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (b *BTCMarkets) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -136,3 +136,39 @@ func (c *COINUT) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]ex
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (c *COINUT) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (c *COINUT) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (c *COINUT) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (c *COINUT) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (c *COINUT) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (c *COINUT) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (c *COINUT) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -98,6 +98,14 @@ type IBotExchange interface {
SupportsAutoPairUpdates() bool
GetLastPairsUpdateTime() int64
SupportsRESTTickerBatchUpdates() bool
SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error)
ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error)
CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error)
CancelAllExchangeOrders(p pair.CurrencyPair) error
GetExchangeOrderInfo(orderID int64) (float64, error)
GetExchangeDepositAddress(p pair.CurrencyPair) (string, error)
WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error)
}
// SupportsRESTTickerBatchUpdates returns whether or not the

View File

@@ -167,3 +167,39 @@ func (e *EXMO) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exch
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (e *EXMO) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (e *EXMO) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (e *EXMO) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (e *EXMO) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (e *EXMO) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (e *EXMO) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (e *EXMO) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -139,3 +139,39 @@ func (g *GDAX) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exch
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (g *GDAX) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (g *GDAX) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (g *GDAX) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (g *GDAX) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (g *GDAX) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (g *GDAX) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (g *GDAX) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -118,3 +118,39 @@ func (g *Gemini) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]ex
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (g *Gemini) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (g *Gemini) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (g *Gemini) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (g *Gemini) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (g *Gemini) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (g *Gemini) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (g *Gemini) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -150,3 +150,39 @@ func (h *HitBTC) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]ex
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (h *HitBTC) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (h *HitBTC) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (h *HitBTC) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (h *HitBTC) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (h *HitBTC) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (h *HitBTC) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (h *HitBTC) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -155,3 +155,39 @@ func (h *HUOBI) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exc
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (h *HUOBI) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (h *HUOBI) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (h *HUOBI) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (h *HUOBI) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (h *HUOBI) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (h *HUOBI) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (h *HUOBI) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -120,3 +120,39 @@ func (i *ItBit) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exc
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (i *ItBit) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (i *ItBit) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (i *ItBit) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (i *ItBit) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (i *ItBit) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (i *ItBit) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (i *ItBit) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -191,3 +191,39 @@ func (k *Kraken) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]ex
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (k *Kraken) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (k *Kraken) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (k *Kraken) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (k *Kraken) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (k *Kraken) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (k *Kraken) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (k *Kraken) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -120,3 +120,39 @@ func (l *LakeBTC) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]e
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (l *LakeBTC) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (l *LakeBTC) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (l *LakeBTC) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (l *LakeBTC) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (l *LakeBTC) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (l *LakeBTC) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (l *LakeBTC) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -138,3 +138,39 @@ func (l *Liqui) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exc
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (l *Liqui) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (l *Liqui) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (l *Liqui) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (l *Liqui) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (l *Liqui) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (l *Liqui) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (l *Liqui) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -111,3 +111,39 @@ func (l *LocalBitcoins) GetExchangeHistory(p pair.CurrencyPair, assetType string
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (l *LocalBitcoins) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (l *LocalBitcoins) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (l *LocalBitcoins) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (l *LocalBitcoins) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (l *LocalBitcoins) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (l *LocalBitcoins) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (l *LocalBitcoins) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -153,3 +153,39 @@ func (o *OKCoin) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]ex
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (o *OKCoin) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (o *OKCoin) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (o *OKCoin) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (o *OKCoin) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (o *OKCoin) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (o *OKCoin) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (o *OKCoin) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -158,3 +158,39 @@ func (o *OKEX) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exch
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (o *OKEX) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (o *OKEX) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (o *OKEX) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (o *OKEX) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (o *OKEX) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (o *OKEX) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (o *OKEX) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -150,3 +150,39 @@ func (po *Poloniex) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (po *Poloniex) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (po *Poloniex) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (po *Poloniex) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (po *Poloniex) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (po *Poloniex) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (po *Poloniex) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (po *Poloniex) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -125,3 +125,39 @@ func (w *WEX) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]excha
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (w *WEX) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (w *WEX) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (w *WEX) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (w *WEX) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (w *WEX) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (w *WEX) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (w *WEX) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}

View File

@@ -131,3 +131,39 @@ func (y *Yobit) GetExchangeHistory(p pair.CurrencyPair, assetType string) ([]exc
return resp, errors.New("trade history not yet implemented")
}
// SubmitExchangeOrder submits a new order
func (y *Yobit) SubmitExchangeOrder(p pair.CurrencyPair, side string, orderType int, amount, price float64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// ModifyExchangeOrder will allow of changing orderbook placement and limit to
// market conversion
func (y *Yobit) ModifyExchangeOrder(p pair.CurrencyPair, orderID, action int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelExchangeOrder cancels an order by its corresponding ID number
func (y *Yobit) CancelExchangeOrder(p pair.CurrencyPair, orderID int64) (int64, error) {
return 0, errors.New("not yet implemented")
}
// CancelAllExchangeOrders cancels all orders associated with a currency pair
func (y *Yobit) CancelAllExchangeOrders(p pair.CurrencyPair) error {
return errors.New("not yet implemented")
}
// GetExchangeOrderInfo returns information on a current open order
func (y *Yobit) GetExchangeOrderInfo(orderID int64) (float64, error) {
return 0, errors.New("not yet implemented")
}
// GetExchangeDepositAddress returns a deposit address for a specified currency
func (y *Yobit) GetExchangeDepositAddress(p pair.CurrencyPair) (string, error) {
return "", errors.New("not yet implemented")
}
// WithdrawExchangeFunds returns a withdrawal ID when a withdrawal is submitted
func (y *Yobit) WithdrawExchangeFunds(address string, p pair.CurrencyPair, amount float64) (string, error) {
return "", errors.New("not yet implemented")
}