exchange

package
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 22, 2020 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Exchange

type Exchange struct{}

Exchange implements all required methods for Wrapper

func (Exchange) AccountInformation

func (e Exchange) AccountInformation(exch string) (account.Holdings, error)

AccountInformation returns account information (balance etc) for requested exchange

func (Exchange) CancelOrder

func (e Exchange) CancelOrder(exch, orderID string) (bool, error)

CancelOrder wrapper to cancel order on exchange

func (Exchange) DepositAddress

func (e Exchange) DepositAddress(exch string, currencyCode currency.Code) (out string, err error)

DepositAddress gets the address required to deposit funds for currency type

func (Exchange) Exchanges

func (e Exchange) Exchanges(enabledOnly bool) []string

Exchanges returns slice of all current exchanges

func (Exchange) GetExchange

func (e Exchange) GetExchange(exch string) (exchange.IBotExchange, error)

GetExchange returns IBotExchange for exchange or error if exchange is not found

func (Exchange) IsEnabled

func (e Exchange) IsEnabled(exch string) bool

IsEnabled returns if requested exchange is enabled or disabled

func (Exchange) OHLCV

func (e Exchange) OHLCV(exch string, pair currency.Pair, item asset.Item, start, end time.Time, interval kline.Interval) (kline.Item, error)

OHLCV returns open high low close volume candles for requested exchange/pair/asset/start & end time

func (Exchange) Orderbook

func (e Exchange) Orderbook(exch string, pair currency.Pair, item asset.Item) (*orderbook.Base, error)

Orderbook returns current orderbook requested exchange, pair and asset

func (Exchange) Pairs

func (e Exchange) Pairs(exch string, enabledOnly bool, item asset.Item) (*currency.Pairs, error)

Pairs returns either all or enabled currency pairs

func (Exchange) QueryOrder

func (e Exchange) QueryOrder(exch, orderID string) (*order.Detail, error)

QueryOrder returns details of a valid exchange order

func (Exchange) SubmitOrder

func (e Exchange) SubmitOrder(submit *order.Submit) (*order.SubmitResponse, error)

SubmitOrder submit new order on exchange

func (Exchange) Ticker

func (e Exchange) Ticker(exch string, pair currency.Pair, item asset.Item) (*ticker.Price, error)

Ticker returns ticker for provided currency pair & asset type

func (Exchange) WithdrawalCryptoFunds

func (e Exchange) WithdrawalCryptoFunds(exch string, request *withdraw.Request) (out string, err error)

WithdrawalCryptoFunds withdraw funds from exchange to requested Crypto source

func (Exchange) WithdrawalFiatFunds

func (e Exchange) WithdrawalFiatFunds(exch, bankAccountID string, request *withdraw.Request) (string, error)

WithdrawalFiatFunds withdraw funds from exchange to requested fiat source

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL