Versions in this module Expand all Collapse all v0 v0.0.3 Oct 12, 2019 v0.0.2 Oct 12, 2019 v0.0.1 Oct 12, 2019 Changes in this version + const BTCEUR + const BTCFUSTF + const BTCJPY + const BTCUSD + const Checksum + const Dec_s + const EOSBTC + const EOSETH + const EOSEUR + const EOSGBP + const EOSJPY + const EOSUSD + const ETCBTC + const ETCUSD + const ETHBTC + const ETHEUR + const ETHFUSTF + const ETHGBP + const ETHJPY + const ETHUSD + const ETHUST + const FrequencyRealtime + const FrequencyTwoPerSecond + const FundingPrefix + const IOTBTC + const IOTETH + const IOTEUR + const IOTGBP + const IOTJPY + const IOTUSD + const LEOBTC + const LEOEOS + const LEOETH + const LEOUSD + const LEOUST + const LTCBTC + const LTCUSD + const NEOBTC + const NEOETH + const NEOUSD + const OrderFlagClose + const OrderFlagHidden + const OrderFlagOCO + const OrderFlagPostOnly + const OrderTypeExchangeFOK + const OrderTypeExchangeLimit + const OrderTypeExchangeMarket + const OrderTypeExchangeStop + const OrderTypeExchangeStopLimit + const OrderTypeExchangeTrailingStop + const OrderTypeFOK + const OrderTypeLimit + const OrderTypeMarket + const OrderTypeStop + const OrderTypeStopLimit + const OrderTypeTrailingStop + const PermissionRead + const PermissionWrite + const PriceLevelDefault + const RRTBTC + const RRTUSD + const Seq_all + const TRXBTC + const TRXETH + const TRXUSD + const Time_s + const Timestamp + const TradingPrefix + const XMRBTC + const XMRUSD + const XRPBTC + const XRPUSD + const ZECBTC + const ZECUSD + var ErrNotFound = errors.New("not found") + func F64Slice(in []interface{}) ([]float64, error) + func IsRawBook(precision string) bool + func NewMarginInfoFromRaw(raw []interface{}) (o interface{}, err error) + func ToFloat64Array(i [][]interface{}) ([][]float64, error) + func ToFloat64Slice(slice []interface{}) []float64 + func ToInterface(flt []float64) []interface + func ToInterfaceArray(i []interface{}) [][]interface + type BalanceInfo struct + NetAUM float64 + TotalAUM float64 + func NewBalanceInfoFromRaw(raw []interface{}) (o *BalanceInfo, err error) + type BalanceUpdate BalanceInfo + type BookAction bookAction + const BookRemoveEntry + const BookUpdateEntry + type BookFrequency bookFrequency + type BookPrecision bookPrecision + const Precision0 + const Precision1 + const Precision2 + const Precision3 + const PrecisionRawBook + type BookUpdate struct + Action BookAction + Amount float64 + AmountJsNum json.Number + Count int64 + ID int64 + Price float64 + PriceJsNum json.Number + Side OrderSide + Symbol string + func NewBookUpdateFromRaw(symbol, precision string, data []interface{}, raw_numbers interface{}) (b *BookUpdate, err error) + type BookUpdateSnapshot struct + Snapshot []*BookUpdate + func NewBookUpdateSnapshotFromRaw(symbol, precision string, raw [][]float64, raw_numbers interface{}) (*BookUpdateSnapshot, error) + type Candle struct + Close float64 + High float64 + Low float64 + MTS int64 + Open float64 + Resolution CandleResolution + Symbol string + Volume float64 + func NewCandleFromRaw(symbol string, resolution CandleResolution, raw []interface{}) (c *Candle, err error) + type CandleResolution candleResolution + const FifteenMinutes + const FiveMinutes + const OneDay + const OneHour + const OneMinute + const OneMonth + const OneWeek + const SixHours + const ThirtyMinutes + const ThreeHours + const TwelveHours + const TwoWeeks + func CandleResolutionFromString(str string) (CandleResolution, error) + type CandleSnapshot struct + Snapshot []*Candle + func NewCandleSnapshotFromRaw(symbol string, resolution CandleResolution, raw [][]float64) (*CandleSnapshot, error) + type ClaimPositionRequest struct + Id int64 + func (o *ClaimPositionRequest) ToJSON() ([]byte, error) + type Credit struct + Amount float64 + Flags interface{} + Hidden bool + ID int64 + Insure bool + MTSCreated int64 + MTSLastPayout int64 + MTSOpened int64 + MTSUpdated int64 + NoClose bool + Notify bool + Period int64 + PositionPair string + Rate float64 + RateReal float64 + Renew bool + Side string + Status CreditStatus + Symbol string + func NewCreditFromRaw(raw []interface{}) (o *Credit, err error) + type CreditStatus string + const CreditStatusActive + const CreditStatusCanceled + const CreditStatusExecuted + const CreditStatusPartiallyFilled + type CurrencyConf struct + Currency string + Explorers ExplorerConf + Label string + Pairs []string + Pools []string + Symbol string + Unit string + func NewCurrencyConfFromRaw(raw []RawCurrencyConf) ([]CurrencyConf, error) + type CurrencyConfigMapping string + const CurrencyExchangeMap + const CurrencyExplorerMap + const CurrencyLabelMap + const CurrencySymbolMap + const CurrencyUnitMap + type DerivativeStatus struct + FundingAccrued float64 + FundingStep float64 + InsuranceFundBalance float64 + MTS int64 + Price float64 + SpotPrice float64 + Symbol string + func NewDerivativeStatusFromRaw(raw []interface{}) (*DerivativeStatus, error) + func NewDerivativeStatusFromWsRaw(symbol string, raw []interface{}) (*DerivativeStatus, error) + type DerivativeStatusSnapshot struct + Snapshot []*DerivativeStatus + func NewDerivativeSnapshotFromRaw(raw [][]interface{}) (*DerivativeStatusSnapshot, error) + type ExplorerConf struct + AddressUri string + BaseUri string + TransactionUri string + type FundingCreditCancel Credit + type FundingCreditNew Credit + type FundingCreditSnapshot struct + Snapshot []*Credit + func NewFundingCreditSnapshotFromRaw(raw []interface{}) (snap *FundingCreditSnapshot, err error) + type FundingCreditUpdate Credit + type FundingInfo struct + DurationLend float64 + DurationLoan float64 + Symbol string + YieldLend float64 + YieldLoan float64 + func NewFundingInfoFromRaw(raw []interface{}) (o *FundingInfo, err error) + type FundingLoanCancel Loan + type FundingLoanNew Loan + type FundingLoanSnapshot struct + Snapshot []*Loan + func NewFundingLoanSnapshotFromRaw(raw []interface{}) (snap *FundingLoanSnapshot, err error) + type FundingLoanUpdate Loan + type FundingOfferCancel Offer + type FundingOfferCancelRequest struct + Id int64 + func (o *FundingOfferCancelRequest) MarshalJSON() ([]byte, error) + func (o *FundingOfferCancelRequest) ToJSON() ([]byte, error) + type FundingOfferNew Offer + type FundingOfferRequest struct + Amount float64 + Hidden bool + Period int64 + Rate float64 + Symbol string + Type string + func (o *FundingOfferRequest) MarshalJSON() ([]byte, error) + func (o *FundingOfferRequest) ToJSON() ([]byte, error) + type FundingOfferSnapshot struct + Snapshot []*Offer + func NewFundingOfferSnapshotFromRaw(raw []interface{}) (snap *FundingOfferSnapshot, err error) + type FundingOfferUpdate Offer + type FundingTrade struct + Amount float64 + ID int64 + MTSCreated int64 + Maker int64 + OfferID int64 + Period int64 + Rate float64 + Symbol string + func NewFundingTradeFromRaw(raw []interface{}) (o *FundingTrade, err error) + type FundingTradeExecution FundingTrade + type FundingTradeSnapshot struct + Snapshot []*FundingTrade + func NewFundingTradeSnapshotFromRaw(raw []interface{}) (snap *FundingTradeSnapshot, err error) + type FundingTradeUpdate FundingTrade + type Heartbeat struct + type HistoricalCredit Credit + type HistoricalFundingTradeSnapshot FundingTradeSnapshot + type HistoricalLoan Loan + type HistoricalOffer Offer + type HistoricalTradeSnapshot TradeExecutionUpdateSnapshot + type Ledger struct + Amount float64 + Balance float64 + Currency string + Description string + ID int64 + MTS int64 + Nil1 float64 + Nil2 float64 + Nil3 float64 + func NewLedgerFromRaw(raw []interface{}) (o *Ledger, err error) + type LedgerSnapshot struct + Snapshot []*Ledger + func NewLedgerSnapshotFromRaw(raw []interface{}) (s *LedgerSnapshot, err error) + type Loan struct + Amount float64 + Flags interface{} + Hidden bool + ID int64 + Insure bool + MTSCreated int64 + MTSLastPayout int64 + MTSOpened int64 + MTSUpdated int64 + NoClose bool + Notify bool + Period int64 + Rate float64 + RateReal float64 + Renew bool + Side string + Status LoanStatus + Symbol string + func NewLoanFromRaw(raw []interface{}) (o *Loan, err error) + type LoanStatus string + const LoanStatusActive + const LoanStatusCanceled + const LoanStatusExecuted + const LoanStatusPartiallyFilled + type MarginInfoBase struct + MarginBalance float64 + MarginNet float64 + UserProfitLoss float64 + UserSwaps float64 + func NewMarginInfoBaseFromRaw(raw []interface{}) (o *MarginInfoBase, err error) + type MarginInfoUpdate struct + Symbol string + TradableBalance float64 + func NewMarginInfoUpdateFromRaw(symbol string, raw []interface{}) (o *MarginInfoUpdate, err error) + type Mts int64 + type Notification struct + Code int64 + MTS int64 + MessageID int64 + NotifyInfo interface{} + Status string + Text string + Type string + func NewNotificationFromRaw(raw []interface{}) (o *Notification, err error) + type Offer struct + Amount float64 + AmountOrig float64 + Flags interface{} + Hidden bool + ID int64 + Insure bool + MTSCreated int64 + MTSUpdated int64 + Notify bool + Period int64 + Rate float64 + RateReal float64 + Renew bool + Status OfferStatus + Symbol string + Type string + func NewOfferFromRaw(raw []interface{}) (o *Offer, err error) + type OfferStatus string + const OfferStatusActive + const OfferStatusCanceled + const OfferStatusExecuted + const OfferStatusPartiallyFilled + type Order struct + Amount float64 + AmountOrig float64 + CID int64 + Flags int64 + GID int64 + Hidden bool + ID int64 + MTSCreated int64 + MTSTif int64 + MTSUpdated int64 + Notify bool + PlacedID int64 + Price float64 + PriceAuxLimit float64 + PriceAvg float64 + PriceTrailing float64 + Status OrderStatus + Symbol string + Type string + TypePrev string + func NewOrderFromRaw(raw []interface{}) (o *Order, err error) + type OrderCancel Order + type OrderCancelRequest struct + CID int64 + CIDDate string + ID int64 + func (o *OrderCancelRequest) MarshalJSON() ([]byte, error) + func (o *OrderCancelRequest) ToJSON() ([]byte, error) + type OrderNew Order + type OrderNewRequest struct + Amount float64 + CID int64 + Close bool + GID int64 + Hidden bool + Leverage int64 + OcoOrder bool + PostOnly bool + Price float64 + PriceAuxLimit float64 + PriceOcoStop float64 + PriceTrailing float64 + Symbol string + TimeInForce string + Type string + func (o *OrderNewRequest) MarshalJSON() ([]byte, error) + func (o *OrderNewRequest) ToJSON() ([]byte, error) + type OrderSide orderSide + const Ask + const Bid + const Long + const Short + type OrderSnapshot struct + Snapshot []*Order + func NewOrderSnapshotFromRaw(raw []interface{}) (s *OrderSnapshot, err error) + type OrderStatus string + const OrderStatusActive + const OrderStatusCanceled + const OrderStatusExecuted + const OrderStatusPartiallyFilled + type OrderType string + type OrderUpdate Order + type OrderUpdateRequest struct + Amount float64 + Delta float64 + GID int64 + Hidden bool + ID int64 + Leverage int64 + PostOnly bool + Price float64 + PriceAuxLimit float64 + PriceTrailing float64 + TimeInForce string + func (o *OrderUpdateRequest) MarshalJSON() ([]byte, error) + func (o *OrderUpdateRequest) ToJSON() ([]byte, error) + type PermissionType string + type Position struct + Amount float64 + BasePrice float64 + Id int64 + Leverage float64 + LiquidationPrice float64 + MarginFunding float64 + MarginFundingType int64 + ProfitLoss float64 + ProfitLossPercentage float64 + Status PositionStatus + Symbol string + func NewPositionFromRaw(raw []interface{}) (o *Position, err error) + type PositionCancel Position + type PositionNew Position + type PositionSnapshot struct + Snapshot []*Position + func NewPositionSnapshotFromRaw(raw []interface{}) (s *PositionSnapshot, err error) + type PositionStatus string + const PositionStatusActive + const PositionStatusClosed + type PositionUpdate Position + type QueryLimit int + const QueryLimitMax + type RawCurrencyConf struct + Data interface{} + Mapping string + type SortOrder int + const NewestFirst + const OldestFirst + type Stat struct + Period int64 + Volume float64 + type StatKey string + const CreditSizeKey + const CreditSizeSymKey + const FundingSizeKey + const PositionSizeKey + type StatusType string + const DerivativeStatusType + type Ticker struct + Ask float64 + AskPeriod int64 + AskSize float64 + Bid float64 + BidPeriod int64 + BidSize float64 + DailyChange float64 + DailyChangePerc float64 + High float64 + LastPrice float64 + Low float64 + Symbol string + Volume float64 + func NewTickerFromRaw(symbol string, raw []interface{}) (t *Ticker, err error) + func NewTickerFromRestRaw(raw []interface{}) (t *Ticker, err error) + type TickerSnapshot struct + Snapshot []*Ticker + func NewTickerSnapshotFromRaw(symbol string, raw [][]float64) (*TickerSnapshot, error) + type TickerUpdate Ticker + type Trade struct + Amount float64 + ID int64 + MTS int64 + Pair string + Price float64 + Side OrderSide + func NewTradeFromRaw(pair string, raw []interface{}) (o *Trade, err error) + type TradeExecution struct + Amount float64 + ID int64 + MTS int64 + Maker int + OrderID int64 + OrderPrice float64 + OrderType string + Pair string + Price float64 + func NewTradeExecutionFromRaw(raw []interface{}) (o *TradeExecution, err error) + type TradeExecutionUpdate struct + ExecAmount float64 + ExecPrice float64 + Fee float64 + FeeCurrency string + ID int64 + MTS int64 + Maker int + OrderID int64 + OrderPrice float64 + OrderType string + Pair string + func NewTradeExecutionUpdateFromRaw(raw []interface{}) (o *TradeExecutionUpdate, err error) + type TradeExecutionUpdateSnapshot struct + Snapshot []*TradeExecutionUpdate + func NewTradeExecutionUpdateSnapshotFromRaw(raw []interface{}) (s *TradeExecutionUpdateSnapshot, err error) + type TradeSnapshot struct + Snapshot []*Trade + func NewTradeSnapshotFromRaw(pair string, raw [][]float64) (*TradeSnapshot, error) + type Wallet struct + Balance float64 + BalanceAvailable float64 + Currency string + Type string + UnsettledInterest float64 + func NewWalletFromRaw(raw []interface{}) (o *Wallet, err error) + type WalletSnapshot struct + Snapshot []*Wallet + func NewWalletSnapshotFromRaw(raw []interface{}) (s *WalletSnapshot, err error) + type WalletUpdate Wallet