coinex

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Sym2duo

func Sym2duo(pair string) q.D

Types

type CoinEx

type CoinEx struct {
	// contains filtered or unexported fields
}

func New

func New(client *http.Client, accessKey, secretKey string) *CoinEx

func (*CoinEx) AllTicker

func (coinex *CoinEx) AllTicker(SymPair map[string]q.D) (mdt *sync.Map, err error)

func (*CoinEx) Balances

func (coinex *CoinEx) Balances() (availables, frozens *sync.Map, err error)

func (*CoinEx) CancelOrder

func (coinex *CoinEx) CancelOrder(orderId string, currency CurrencyPair) (bool, error)

func (*CoinEx) Fee

func (coinex *CoinEx) Fee() float64

func (*CoinEx) GetAccount

func (coinex *CoinEx) GetAccount() (*Account, error)

func (*CoinEx) GetAttr

func (coinex *CoinEx) GetAttr() (a q.Attr)

func (*CoinEx) GetDepth

func (coinex *CoinEx) GetDepth(size int, currency CurrencyPair) (*Depth, error)

func (*CoinEx) GetDifficulty

func (coinex *CoinEx) GetDifficulty() (limit, cur float64, err error)

func (*CoinEx) GetKlineRecords

func (coinex *CoinEx) GetKlineRecords(currency CurrencyPair, period KlinePeriod, size int, opt ...OptionalParameter) ([]Kline, error)

func (*CoinEx) GetOneOrder

func (coinex *CoinEx) GetOneOrder(orderId string, currency CurrencyPair) (*Order, error)

func (*CoinEx) GetOrderHistorys

func (coinex *CoinEx) GetOrderHistorys(currency CurrencyPair, optional ...OptionalParameter) ([]Order, error)

func (*CoinEx) GetPendingOrders

func (coinex *CoinEx) GetPendingOrders(page, limit int, pair CurrencyPair) ([]Order, error)

func (*CoinEx) GetTicker

func (coinex *CoinEx) GetTicker(currency CurrencyPair) (*Ticker, error)

func (*CoinEx) GetTrades

func (coinex *CoinEx) GetTrades(currencyPair CurrencyPair, since int64) ([]Trade, error)

非个人,整个交易所的交易记录

func (*CoinEx) GetUnfinishedOrders

func (coinex *CoinEx) GetUnfinishedOrders(currency CurrencyPair) ([]Order, error)

func (*CoinEx) LimitBuy

func (coinex *CoinEx) LimitBuy(amount, price string, currency CurrencyPair, opt ...LimitOrderOptionalParameter) (*Order, error)

func (*CoinEx) LimitSell

func (coinex *CoinEx) LimitSell(amount, price string, currency CurrencyPair, opt ...LimitOrderOptionalParameter) (*Order, error)

func (*CoinEx) MarketBuy

func (coinex *CoinEx) MarketBuy(amount, price string, currency CurrencyPair) (*Order, error)

func (*CoinEx) MarketSell

func (coinex *CoinEx) MarketSell(amount, price string, currency CurrencyPair) (*Order, error)

func (*CoinEx) OneTicker

func (coinex *CoinEx) OneTicker(d q.D) (ticker q.Bbo, err error)

func (*CoinEx) PairArray

func (coinex *CoinEx) PairArray() (map[string]q.D, map[q.D]q.P, error)

func (*CoinEx) PlaceOrders

func (coinex *CoinEx) PlaceOrders(places [3]q.Order) (orders [3]q.Order, err error)

func (*CoinEx) String

func (coinex *CoinEx) String() string

func (*CoinEx) Test

func (coinex *CoinEx) Test() bool

func (*CoinEx) TradeFee

func (coinex *CoinEx) TradeFee() (map[string]q.TradeFee, error)

func (*CoinEx) WithdrawFee

func (coinex *CoinEx) WithdrawFee() (sf []q.NetworkWithdraw, err error)

Jump to

Keyboard shortcuts

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