spot

package
v0.0.0-...-089aa6e Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Api

type Api struct {
	exchange.BaseApi
}

func (*Api) AccountInfo

func (api *Api) AccountInfo() ([]exchange.Balance, error)

func (*Api) AddOrder

func (api *Api) AddOrder(params map[string]interface{}) (map[string]interface{}, error)

func (*Api) CancelOrder

func (api *Api) CancelOrder(params map[string]interface{}) (map[string]interface{}, error)

func (*Api) CreateSpotListenKey

func (api *Api) CreateSpotListenKey() (string, bool)

创建或延期现货账户listenKey

func (*Api) KLines

func (api *Api) KLines(params map[string]interface{}) ([][]interface{}, error)

type Spot

type Spot struct {
	binance.Exchange
	Api Api
}

func (*Spot) AddOrder

func (s *Spot) AddOrder(order db.Order) (map[string]interface{}, error)

func (*Spot) CancelOrder

func (s *Spot) CancelOrder(symbol string, orderId string) (map[string]interface{}, error)

func (*Spot) NewExchange

func (s *Spot) NewExchange(apiKey string, apiSecret string) exchange.IExchange

func (*Spot) NewKLineService

func (s *Spot) NewKLineService() exchange.IKLineService

func (*Spot) RefreshAccount

func (s *Spot) RefreshAccount()

func (*Spot) SubscribeAccount

func (s *Spot) SubscribeAccount(callback func(map[string]interface{})) error

订阅账号更新

func (*Spot) SubscribeMarketData

func (s *Spot) SubscribeMarketData(symbols []string, callback func(map[string]interface{})) error

Jump to

Keyboard shortcuts

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