Versions in this module Expand all Collapse all v1 v1.2.17 Jul 15, 2021 Changes in this version + type DepthOrderBook struct + func NewDepthOrderBook(symbol string) *DepthOrderBook + func (d *DepthOrderBook) GetOrderBook(depth int) (result OrderBook) + func (d *DepthOrderBook) GetSymbol() string + func (d *DepthOrderBook) Update(data *models.OrderBookRawNotification) + type Deribit struct + func NewDeribit(params *Parameters) *Deribit + func (b *Deribit) AmendOrder(symbol string, id string, price float64, size float64, opts ...OrderOption) (result *Order, err error) + func (b *Deribit) CancelAllOrders(symbol string, opts ...OrderOption) (err error) + func (b *Deribit) CancelOrder(symbol string, id string, opts ...OrderOption) (result *Order, err error) + func (b *Deribit) CloseLong(symbol string, orderType OrderType, price float64, size float64) (result *Order, err error) + func (b *Deribit) CloseShort(symbol string, orderType OrderType, price float64, size float64) (result *Order, err error) + func (b *Deribit) GetBalance(currency string) (result *Balance, err error) + func (b *Deribit) GetContractID() (symbol string, err error) + func (b *Deribit) GetName() (name string) + func (b *Deribit) GetOpenOrders(symbol string, opts ...OrderOption) (result []*Order, err error) + func (b *Deribit) GetOrder(symbol string, id string, opts ...OrderOption) (result *Order, err error) + func (b *Deribit) GetOrderBook(symbol string, depth int) (result *OrderBook, err error) + func (b *Deribit) GetPositions(symbol string) (result []*Position, err error) + func (b *Deribit) GetRecords(symbol string, period string, from int64, end int64, limit int) (records []*Record, err error) + func (b *Deribit) GetTime() (tm int64, err error) + func (b *Deribit) IO(name string, params string) (string, error) + func (b *Deribit) OpenLong(symbol string, orderType OrderType, price float64, size float64) (result *Order, err error) + func (b *Deribit) OpenShort(symbol string, orderType OrderType, price float64, size float64) (result *Order, err error) + func (b *Deribit) PlaceOrder(symbol string, direction Direction, orderType OrderType, price float64, ...) (result *Order, err error) + func (b *Deribit) SetContractType(currencyPair string, contractType string) (err error) + func (b *Deribit) SetLeverRate(value float64) (err error) + func (b *Deribit) SubscribeLevel2Snapshots(market Market, callback func(ob *OrderBook)) error + func (b *Deribit) SubscribeOrders(market Market, callback func(orders []*Order)) error + func (b *Deribit) SubscribePositions(market Market, callback func(positions []*Position)) error + func (b *Deribit) SubscribeTrades(market Market, callback func(trades []*Trade)) error + type DobItem struct + Amount float64 + Price float64 + func (e DobItem) ExtractKey() float64 + func (e DobItem) String() string