bitmex

package
v0.0.0-...-dd292ea Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BitMex

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

func NewBitMEX

func NewBitMEX(config *ExchangeConfig) *BitMex

func (*BitMex) GetName

func (b *BitMex) GetName() string

func (*BitMex) GetOHLCV

func (b *BitMex) GetOHLCV(
	symbol string,
	period string,
	start int64,
	end int64,
	limit int64,
) (results []*OHLCV, err error)

func (*BitMex) GetOrderBook

func (b *BitMex) GetOrderBook(symbol string, depth int) (result *OrderBook, err error)

func (BitMex) GetSymbol

func (b BitMex) GetSymbol() (symbol string, err error)

func (*BitMex) GetTime

func (b *BitMex) GetTime() (tm int64, err error)

func (*BitMex) PlaceOrder

func (b *BitMex) PlaceOrder(
	symbol string,
	direction Direction,
	orderType OrderType,
	price float64,
	size float64,
) (result *Order, err error)

func (*BitMex) SetSymbol

func (b *BitMex) SetSymbol(symbol string) (err error)

func (*BitMex) SubscribeLevel2Snapshots

func (b *BitMex) SubscribeLevel2Snapshots(market string, callback func(ob *OrderBook)) error

func (*BitMex) SubscribeOrders

func (b *BitMex) SubscribeOrders(market string, callback func(orders []*Order)) error

func (*BitMex) SubscribePositions

func (b *BitMex) SubscribePositions(market string, callback func(positions []*Position)) error

func (*BitMex) SubscribeTrades

func (b *BitMex) SubscribeTrades(market string, callback func(trades []*Trade)) error

Jump to

Keyboard shortcuts

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