Documentation ¶
Index ¶
- type AccountFees
- type AccountInfo
- type AccountSummary
- type Balance
- type BalanceHistory
- type Bitfinex
- func (b *Bitfinex) CancelAllOrders() (string, error)
- func (b *Bitfinex) CancelMultipleOrders(OrderIDs []int64) (string, error)
- func (b *Bitfinex) CancelOffer(OfferID int64) (Offer, error)
- func (b *Bitfinex) CancelOrder(OrderID int64) (Order, error)
- func (b *Bitfinex) ClaimPosition(PositionID int) (Position, error)
- func (b *Bitfinex) CloseMarginFunding(SwapID int64) (Offer, error)
- func (b *Bitfinex) GetAccountBalance() ([]Balance, error)
- func (b *Bitfinex) GetAccountFees() (AccountFees, error)
- func (b *Bitfinex) GetAccountInfo() ([]AccountInfo, error)
- func (b *Bitfinex) GetAccountSummary() (AccountSummary, error)
- func (b *Bitfinex) GetActiveCredits() ([]Offer, error)
- func (b *Bitfinex) GetActiveMarginFunding() ([]MarginFunds, error)
- func (b *Bitfinex) GetActiveOffers() ([]Offer, error)
- func (b *Bitfinex) GetActiveOrders() ([]Order, error)
- func (b *Bitfinex) GetActivePositions() ([]Position, error)
- func (b *Bitfinex) GetBalanceHistory(symbol string, timeSince, timeUntil time.Time, limit int, wallet string) ([]BalanceHistory, error)
- func (b *Bitfinex) GetExchangeAccountInfo() (exchange.AccountInfo, error)
- func (b *Bitfinex) GetFundingBook(symbol string) (FundingBook, error)
- func (b *Bitfinex) GetKeyPermissions() (KeyPermissions, error)
- func (b *Bitfinex) GetLendbook(symbol string, values url.Values) (Lendbook, error)
- func (b *Bitfinex) GetLends(symbol string, values url.Values) ([]Lends, error)
- func (b *Bitfinex) GetMarginInfo() ([]MarginInfo, error)
- func (b *Bitfinex) GetMarginTotalTakenFunds() ([]MarginTotalTakenFunds, error)
- func (b *Bitfinex) GetMovementHistory(symbol, method string, timeSince, timeUntil time.Time, limit int) ([]MovementHistory, error)
- func (b *Bitfinex) GetOfferStatus(OfferID int64) (Offer, error)
- func (b *Bitfinex) GetOrderStatus(OrderID int64) (Order, error)
- func (b *Bitfinex) GetOrderbook(currencyPair string, values url.Values) (Orderbook, error)
- func (b *Bitfinex) GetOrderbookEx(p pair.CurrencyPair, assetType string) (orderbook.Base, error)
- func (b *Bitfinex) GetStats(symbol string) ([]Stat, error)
- func (b *Bitfinex) GetSymbols() ([]string, error)
- func (b *Bitfinex) GetSymbolsDetails() ([]SymbolDetails, error)
- func (b *Bitfinex) GetTicker(symbol string, values url.Values) (Ticker, error)
- func (b *Bitfinex) GetTickerPrice(p pair.CurrencyPair, assetType string) (ticker.Price, error)
- func (b *Bitfinex) GetTradeHistory(currencyPair string, timestamp, until time.Time, limit, reverse int) ([]TradeHistory, error)
- func (b *Bitfinex) GetTrades(currencyPair string, values url.Values) ([]TradeStructure, error)
- func (b *Bitfinex) GetUnusedMarginFunds() ([]MarginFunds, error)
- func (b *Bitfinex) NewDeposit(method, walletName string, renew int) (DepositResponse, error)
- func (b *Bitfinex) NewOffer(symbol string, amount, rate float64, period int64, direction string) (Offer, error)
- func (b *Bitfinex) NewOrder(currencyPair string, amount float64, price float64, buy bool, Type string, ...) (Order, error)
- func (b *Bitfinex) NewOrderMulti(orders []PlaceOrder) (OrderMultiResponse, error)
- func (b *Bitfinex) ReplaceOrder(OrderID int64, Symbol string, Amount float64, Price float64, Buy bool, ...) (Order, error)
- func (b *Bitfinex) Run()
- func (b *Bitfinex) SendAuthenticatedHTTPRequest(method, path string, params map[string]interface{}, result interface{}) error
- func (b *Bitfinex) SetDefaults()
- func (b *Bitfinex) Setup(exch config.ExchangeConfig)
- func (b *Bitfinex) Start()
- func (b *Bitfinex) UpdateOrderbook(p pair.CurrencyPair, assetType string) (orderbook.Base, error)
- func (b *Bitfinex) UpdateTicker(p pair.CurrencyPair, assetType string) (ticker.Price, error)
- func (b *Bitfinex) WalletTransfer(amount float64, currency, walletFrom, walletTo string) ([]WalletTransfer, error)
- func (b *Bitfinex) WebsocketAddSubscriptionChannel(chanID int, channel, pair string)
- func (b *Bitfinex) WebsocketClient()
- func (b *Bitfinex) WebsocketPingHandler() error
- func (b *Bitfinex) WebsocketSend(data interface{}) error
- func (b *Bitfinex) WebsocketSendAuth() error
- func (b *Bitfinex) WebsocketSendUnauth() error
- func (b *Bitfinex) WebsocketSubscribe(channel string, params map[string]string) error
- func (b *Bitfinex) Withdrawal(withdrawType, wallet, address string, amount float64) ([]Withdrawal, error)
- type Book
- type Currency
- type DepositResponse
- type ErrorCapture
- type Fee
- type FundingBook
- type GenericResponse
- type KeyPermissions
- type Lendbook
- type Lends
- type MarginData
- type MarginFunds
- type MarginInfo
- type MarginLimits
- type MarginTotalTakenFunds
- type MovementHistory
- type Offer
- type Order
- type OrderMultiResponse
- type Orderbook
- type Permission
- type PlaceOrder
- type Position
- type Stat
- type SymbolDetails
- type Ticker
- type TradeHistory
- type TradeStructure
- type WalletTransfer
- type WebsocketBook
- type WebsocketChanInfo
- type WebsocketOrder
- type WebsocketPosition
- type WebsocketTicker
- type WebsocketTrade
- type WebsocketTradeExecuted
- type WebsocketWallet
- type Withdrawal
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccountFees ¶
type AccountFees struct { Withdraw struct { BTC float64 `json:"BTC,string"` LTC float64 `json:"LTC,string"` ETH float64 `json:"ETH,string"` ETC float64 `json:"ETC,string"` ZEC float64 `json:"ZEC,string"` XMR float64 `json:"XMR,string"` DSH float64 `json:"DSH,string"` XRP float64 `json:"XRP,string"` IOT float64 `json:"IOT"` EOS float64 `json:"EOS,string"` SAN float64 `json:"SAN,string"` OMG float64 `json:"OMG,string"` BCH float64 `json:"BCH,string"` } `json:"withdraw"` }
AccountFees stores withdrawal account fee data from Bitfinex
type AccountInfo ¶
type AccountInfo struct { MakerFees string `json:"maker_fees"` TakerFees string `json:"taker_fees"` Fees []struct { Pairs string `json:"pairs"` MakerFees string `json:"maker_fees"` TakerFees string `json:"taker_fees"` } `json:"fees"` }
AccountInfo general account information with fees
type AccountSummary ¶
type AccountSummary struct { TradeVolumePer30D []Currency `json:"trade_vol_30d"` FundingProfit30D []Currency `json:"funding_profit_30d"` MakerFee float64 `json:"maker_fee"` TakerFee float64 `json:"taker_fee"` }
AccountSummary holds account summary data
type Balance ¶
type Balance struct { Type string `json:"type"` Currency string `json:"currency"` Amount float64 `json:"amount,string"` Available float64 `json:"available,string"` }
Balance holds current balance data
type BalanceHistory ¶
type BalanceHistory struct { Currency string `json:"currency"` Amount float64 `json:"amount,string"` Balance float64 `json:"balance,string"` Description string `json:"description"` Timestamp string `json:"timestamp"` }
BalanceHistory holds balance history information
type Bitfinex ¶
type Bitfinex struct { exchange.Base WebsocketConn *websocket.Conn WebsocketSubdChannels map[int]WebsocketChanInfo }
Bitfinex is the overarching type across the bitfinex package Notes: Bitfinex has added a rate limit to the number of REST requests. Rate limit policy can vary in a range of 10 to 90 requests per minute depending on some factors (e.g. servers load, endpoint, etc.).
func (*Bitfinex) CancelAllOrders ¶
CancelAllOrders cancels all active and open orders
func (*Bitfinex) CancelMultipleOrders ¶
CancelMultipleOrders cancels multiple orders
func (*Bitfinex) CancelOffer ¶
CancelOffer cancels offer by offerID
func (*Bitfinex) CancelOrder ¶
CancelOrder cancels a single order
func (*Bitfinex) ClaimPosition ¶
ClaimPosition allows positions to be claimed
func (*Bitfinex) CloseMarginFunding ¶
CloseMarginFunding closes an unused or used taken fund
func (*Bitfinex) GetAccountBalance ¶
GetAccountBalance returns full wallet balance information
func (*Bitfinex) GetAccountFees ¶
func (b *Bitfinex) GetAccountFees() (AccountFees, error)
GetAccountFees - NOT YET IMPLEMENTED
func (*Bitfinex) GetAccountInfo ¶
func (b *Bitfinex) GetAccountInfo() ([]AccountInfo, error)
GetAccountInfo returns information about your account incl. trading fees
func (*Bitfinex) GetAccountSummary ¶
func (b *Bitfinex) GetAccountSummary() (AccountSummary, error)
GetAccountSummary returns a 30-day summary of your trading volume and return on margin funding
func (*Bitfinex) GetActiveCredits ¶
GetActiveCredits returns all available credits
func (*Bitfinex) GetActiveMarginFunding ¶
func (b *Bitfinex) GetActiveMarginFunding() ([]MarginFunds, error)
GetActiveMarginFunding returns an array of active margin funds
func (*Bitfinex) GetActiveOffers ¶
GetActiveOffers returns all current active offers
func (*Bitfinex) GetActiveOrders ¶
GetActiveOrders returns all active orders and statuses
func (*Bitfinex) GetActivePositions ¶
GetActivePositions returns an array of active positions
func (*Bitfinex) GetBalanceHistory ¶
func (b *Bitfinex) GetBalanceHistory(symbol string, timeSince, timeUntil time.Time, limit int, wallet string) ([]BalanceHistory, error)
GetBalanceHistory returns balance history for the account
func (*Bitfinex) GetExchangeAccountInfo ¶
GetExchangeAccountInfo retrieves balances for all enabled currencies on the Bitfinex exchange
func (*Bitfinex) GetFundingBook ¶
func (b *Bitfinex) GetFundingBook(symbol string) (FundingBook, error)
GetFundingBook the entire margin funding book for both bids and asks sides per currency string symbol - example "USD"
func (*Bitfinex) GetKeyPermissions ¶
func (b *Bitfinex) GetKeyPermissions() (KeyPermissions, error)
GetKeyPermissions checks the permissions of the key being used to generate this request.
func (*Bitfinex) GetLendbook ¶
GetLendbook returns a list of the most recent funding data for the given currency: total amount provided and Flash Return Rate (in % by 365 days) over time Symbol - example "USD"
func (*Bitfinex) GetLends ¶
GetLends returns a list of the most recent funding data for the given currency: total amount provided and Flash Return Rate (in % by 365 days) over time Symbol - example "USD"
func (*Bitfinex) GetMarginInfo ¶
func (b *Bitfinex) GetMarginInfo() ([]MarginInfo, error)
GetMarginInfo shows your trading wallet information for margin trading
func (*Bitfinex) GetMarginTotalTakenFunds ¶
func (b *Bitfinex) GetMarginTotalTakenFunds() ([]MarginTotalTakenFunds, error)
GetMarginTotalTakenFunds returns an array of active funding used in a position
func (*Bitfinex) GetMovementHistory ¶
func (b *Bitfinex) GetMovementHistory(symbol, method string, timeSince, timeUntil time.Time, limit int) ([]MovementHistory, error)
GetMovementHistory returns an array of past deposits and withdrawals
func (*Bitfinex) GetOfferStatus ¶
GetOfferStatus checks offer status whether it has been cancelled, execute or is still active
func (*Bitfinex) GetOrderStatus ¶
GetOrderStatus returns order status information
func (*Bitfinex) GetOrderbook ¶
GetOrderbook retieves the orderbook bid and ask price points for a currency pair - By default the response will return 25 bid and 25 ask price points. CurrencyPair - Example "BTCUSD" Values can contain limit amounts for both the asks and bids - Example "limit_bids" = 1000
func (*Bitfinex) GetOrderbookEx ¶
GetOrderbookEx returns the orderbook for a currency pair
func (*Bitfinex) GetSymbols ¶
GetSymbols returns the available currency pairs on the exchange
func (*Bitfinex) GetSymbolsDetails ¶
func (b *Bitfinex) GetSymbolsDetails() ([]SymbolDetails, error)
GetSymbolsDetails a list of valid symbol IDs and the pair details
func (*Bitfinex) GetTickerPrice ¶
GetTickerPrice returns the ticker for a currency pair
func (*Bitfinex) GetTradeHistory ¶
func (b *Bitfinex) GetTradeHistory(currencyPair string, timestamp, until time.Time, limit, reverse int) ([]TradeHistory, error)
GetTradeHistory returns past executed trades
func (*Bitfinex) GetTrades ¶
GetTrades returns a list of the most recent trades for the given curencyPair By default the response will return 100 trades CurrencyPair - Example "BTCUSD" Values can contain limit amounts for the number of trades returned - Example "limit_trades" = 1000
func (*Bitfinex) GetUnusedMarginFunds ¶
func (b *Bitfinex) GetUnusedMarginFunds() ([]MarginFunds, error)
GetUnusedMarginFunds returns an array of funding borrowed but not currently used
func (*Bitfinex) NewDeposit ¶
func (b *Bitfinex) NewDeposit(method, walletName string, renew int) (DepositResponse, error)
NewDeposit returns a new deposit address Method - Example methods accepted: “bitcoin”, “litecoin”, “ethereum”, “tethers", "ethereumc", "zcash", "monero", "iota", "bcash" WalletName - accepted: “trading”, “exchange”, “deposit” renew - Default is 0. If set to 1, will return a new unused deposit address
func (*Bitfinex) NewOffer ¶
func (b *Bitfinex) NewOffer(symbol string, amount, rate float64, period int64, direction string) (Offer, error)
NewOffer submits a new offer
func (*Bitfinex) NewOrder ¶
func (b *Bitfinex) NewOrder(currencyPair string, amount float64, price float64, buy bool, Type string, hidden bool) (Order, error)
NewOrder submits a new order and returns a order information Major Upgrade needed on this function to include all query params
func (*Bitfinex) NewOrderMulti ¶
func (b *Bitfinex) NewOrderMulti(orders []PlaceOrder) (OrderMultiResponse, error)
NewOrderMulti allows several new orders at once
func (*Bitfinex) ReplaceOrder ¶
func (b *Bitfinex) ReplaceOrder(OrderID int64, Symbol string, Amount float64, Price float64, Buy bool, Type string, Hidden bool) (Order, error)
ReplaceOrder replaces an older order with a new order
func (*Bitfinex) SendAuthenticatedHTTPRequest ¶
func (b *Bitfinex) SendAuthenticatedHTTPRequest(method, path string, params map[string]interface{}, result interface{}) error
SendAuthenticatedHTTPRequest sends an autheticated http request and json unmarshals result to a supplied variable
func (*Bitfinex) SetDefaults ¶
func (b *Bitfinex) SetDefaults()
SetDefaults sets the basic defaults for bitfinex
func (*Bitfinex) Setup ¶
func (b *Bitfinex) Setup(exch config.ExchangeConfig)
Setup takes in the supplied exchange configuration details and sets params
func (*Bitfinex) UpdateOrderbook ¶
UpdateOrderbook updates and returns the orderbook for a currency pair
func (*Bitfinex) UpdateTicker ¶
UpdateTicker updates and returns the ticker for a currency pair
func (*Bitfinex) WalletTransfer ¶
func (b *Bitfinex) WalletTransfer(amount float64, currency, walletFrom, walletTo string) ([]WalletTransfer, error)
WalletTransfer move available balances between your wallets Amount - Amount to move Currency - example "BTC" WalletFrom - example "exchange" WalletTo - example "deposit"
func (*Bitfinex) WebsocketAddSubscriptionChannel ¶
WebsocketAddSubscriptionChannel adds a new subscription channel to the WebsocketSubdChannels map in bitfinex.go (Bitfinex struct)
func (*Bitfinex) WebsocketClient ¶
func (b *Bitfinex) WebsocketClient()
WebsocketClient makes a connection with the websocket server
func (*Bitfinex) WebsocketPingHandler ¶
WebsocketPingHandler sends a ping request to the websocket server
func (*Bitfinex) WebsocketSend ¶
WebsocketSend sends data to the websocket server
func (*Bitfinex) WebsocketSendAuth ¶
WebsocketSendAuth sends a autheticated event payload
func (*Bitfinex) WebsocketSendUnauth ¶
WebsocketSendUnauth sends an unauthenticated payload
func (*Bitfinex) WebsocketSubscribe ¶
WebsocketSubscribe subscribes to the websocket channel
func (*Bitfinex) Withdrawal ¶
func (b *Bitfinex) Withdrawal(withdrawType, wallet, address string, amount float64) ([]Withdrawal, error)
Withdrawal requests a withdrawal from one of your wallets. Major Upgrade needed on this function to include all query params
type Book ¶
type Book struct { Price float64 `json:"price,string"` Rate float64 `json:"rate,string"` Amount float64 `json:"amount,string"` Period int `json:"period"` Timestamp string `json:"timestamp"` FlashReturnRate string `json:"frr"` }
Book is a generalised sub-type to hold book information
type Currency ¶
type Currency struct { Currency string `json:"curr"` Volume float64 `json:"vol,string"` Amount float64 `json:"amount,string"` }
Currency is a sub-type for AccountSummary data
type DepositResponse ¶
type DepositResponse struct { Result string `json:"string"` Method string `json:"method"` Currency string `json:"currency"` Address string `json:"address"` }
DepositResponse holds deposit address information
type ErrorCapture ¶
type ErrorCapture struct {
Message string `json:"message"`
}
ErrorCapture is a simple type for returned errors from Bitfinex
type FundingBook ¶
FundingBook holds current the full margin funding book
type GenericResponse ¶
type GenericResponse struct {
Result string `json:"result"`
}
GenericResponse holds the result for a generic response
type KeyPermissions ¶
type KeyPermissions struct { Account Permission `json:"account"` History Permission `json:"history"` Orders Permission `json:"orders"` Positions Permission `json:"positions"` Funding Permission `json:"funding"` Wallets Permission `json:"wallets"` Withdraw Permission `json:"withdraw"` }
KeyPermissions holds the key permissions for the API key set
type Lends ¶
type Lends struct { Rate float64 `json:"rate,string"` AmountLent float64 `json:"amount_lent,string"` AmountUsed float64 `json:"amount_used,string"` Timestamp int64 `json:"timestamp"` }
Lends holds the lent information by currency
type MarginData ¶
type MarginData struct { MarginBalance float64 `json:"margin_balance,string"` TradableBalance float64 `json:"tradable_balance,string"` UnrealizedPL int64 `json:"unrealized_pl"` UnrealizedSwap int64 `json:"unrealized_swap"` NetValue float64 `json:"net_value,string"` RequiredMargin int64 `json:"required_margin"` Leverage float64 `json:"leverage,string"` MarginRequirement float64 `json:"margin_requirement,string"` MarginLimits []MarginLimits `json:"margin_limits"` }
MarginData holds wallet information for margin trading
type MarginFunds ¶
type MarginFunds struct { ID int64 `json:"id"` PositionID int64 `json:"position_id"` Currency string `json:"currency"` Rate float64 `json:"rate,string"` Period int `json:"period"` Amount float64 `json:"amount,string"` Timestamp string `json:"timestamp"` AutoClose bool `json:"auto_close"` }
MarginFunds holds active funding information used in a margin position
type MarginInfo ¶
type MarginInfo struct { Info MarginData Message string `json:"message"` }
MarginInfo holds metadata for margin information from bitfinex
type MarginLimits ¶
type MarginLimits struct { OnPair string `json:"on_pair"` InitialMargin float64 `json:"initial_margin,string"` MarginRequirement float64 `json:"margin_requirement,string"` TradableBalance float64 `json:"tradable_balance,string"` }
MarginLimits holds limit data per pair
type MarginTotalTakenFunds ¶
type MarginTotalTakenFunds struct { PositionPair string `json:"position_pair"` TotalSwaps float64 `json:"total_swaps,string"` }
MarginTotalTakenFunds holds position funding including sum of active backing as total swaps
type MovementHistory ¶
type MovementHistory struct { ID int64 `json:"id"` TxID int64 `json:"txid"` Currency string `json:"currency"` Method string `json:"method"` Type string `json:"withdrawal"` Amount float64 `json:"amount,string"` Description string `json:"description"` Address string `json:"address"` Status string `json:"status"` Timestamp string `json:"timestamp"` TimestampCreated string `json:"timestamp_created"` Fee float64 `json:"fee"` }
MovementHistory holds deposit and withdrawal history data
type Offer ¶
type Offer struct { ID int64 `json:"id"` Currency string `json:"currency"` Rate float64 `json:"rate,string"` Period int64 `json:"period"` Direction string `json:"direction"` Timestamp string `json:"timestamp"` Type string `json:"type"` IsLive bool `json:"is_live"` IsCancelled bool `json:"is_cancelled"` OriginalAmount float64 `json:"original_amount,string"` RemainingAmount float64 `json:"remaining_amount,string"` ExecutedAmount float64 `json:"executed_amount,string"` }
Offer holds offer information
type Order ¶
type Order struct { ID int64 `json:"id"` Symbol string `json:"symbol"` Exchange string `json:"exchange"` Price float64 `json:"price,string"` AverageExecutionPrice float64 `json:"avg_execution_price,string"` Side string `json:"side"` Type string `json:"type"` Timestamp string `json:"timestamp"` IsLive bool `json:"is_live"` IsCancelled bool `json:"is_cancelled"` IsHidden bool `json:"is_hidden"` WasForced bool `json:"was_forced"` OriginalAmount float64 `json:"original_amount,string"` RemainingAmount float64 `json:"remaining_amount,string"` ExecutedAmount float64 `json:"executed_amount,string"` OrderID int64 `json:"order_id"` }
Order holds order information when an order is in the market
type OrderMultiResponse ¶
OrderMultiResponse holds order information on the executed orders
type Permission ¶
Permission sub-type for KeyPermissions
type PlaceOrder ¶
type PlaceOrder struct { Symbol string `json:"symbol"` Amount float64 `json:"amount,string"` Price float64 `json:"price,string"` Exchange string `json:"exchange"` Side string `json:"side"` Type string `json:"type"` }
PlaceOrder is used for order placement
type Position ¶
type Position struct { ID int64 `json:"id"` Symbol string `json:"string"` Status string `json:"active"` Base float64 `json:"base,string"` Amount float64 `json:"amount,string"` Timestamp string `json:"timestamp"` Swap float64 `json:"swap,string"` PL float64 `json:"pl,string"` }
Position holds position information
type SymbolDetails ¶
type SymbolDetails struct { Pair string `json:"pair"` PricePrecision int `json:"price_precision"` InitialMargin float64 `json:"initial_margin,string"` MinimumMargin float64 `json:"minimum_margin,string"` MaximumOrderSize float64 `json:"maximum_order_size,string"` MinimumOrderSize float64 `json:"minimum_order_size,string"` Expiration string `json:"expiration"` }
SymbolDetails holds currency pair information
type Ticker ¶
type Ticker struct { Mid float64 `json:"mid,string"` Bid float64 `json:"bid,string"` Ask float64 `json:"ask,string"` Last float64 `json:"last_price,string"` Low float64 `json:"low,string"` High float64 `json:"high,string"` Volume float64 `json:"volume,string"` Timestamp string `json:"timestamp"` }
Ticker holds basic ticker information from the exchange
type TradeHistory ¶
type TradeHistory struct { Price float64 `json:"price,string"` Amount float64 `json:"amount,string"` Timestamp string `json:"timestamp"` Exchange string `json:"exchange"` Type string `json:"type"` FeeCurrency string `json:"fee_currency"` FeeAmount float64 `json:"fee_amount,string"` TID int64 `json:"tid"` OrderID int64 `json:"order_id"` }
TradeHistory holds trade history data
type TradeStructure ¶
type TradeStructure struct { Timestamp int64 `json:"timestamp"` Tid int64 `json:"tid"` Price float64 `json:"price,string"` Amount float64 `json:"amount,string"` Exchange string `json:"exchange"` Type string `json:"sell"` }
TradeStructure holds executed trade information
type WalletTransfer ¶
WalletTransfer holds status of wallet to wallet content transfer on exchange
type WebsocketBook ¶
WebsocketBook holds booking information
type WebsocketChanInfo ¶
WebsocketChanInfo holds websocket channel information
type WebsocketOrder ¶
type WebsocketOrder struct { OrderID int64 Pair string Amount float64 OrigAmount float64 OrderType string Status string Price float64 PriceAvg float64 Timestamp string Notify int }
WebsocketOrder holds order data
type WebsocketPosition ¶
type WebsocketPosition struct { Pair string Status string Amount float64 Price float64 MarginFunding float64 MarginFundingType int }
WebsocketPosition holds position information
type WebsocketTicker ¶
type WebsocketTicker struct { Bid float64 BidSize float64 Ask float64 AskSize float64 DailyChange float64 DialyChangePerc float64 LastPrice float64 Volume float64 }
WebsocketTicker holds ticker information
type WebsocketTrade ¶
WebsocketTrade holds trade information
type WebsocketTradeExecuted ¶
type WebsocketTradeExecuted struct { TradeID int64 Pair string Timestamp int64 OrderID int64 AmountExecuted float64 PriceExecuted float64 }
WebsocketTradeExecuted holds executed trade data
type WebsocketWallet ¶
type WebsocketWallet struct { Name string Currency string Balance float64 UnsettledInterest float64 }
WebsocketWallet holds wallet information
type Withdrawal ¶
type Withdrawal struct { Status string `json:"status"` Message string `json:"message"` WithdrawalID int64 `json:"withdrawal_id,string"` }
Withdrawal holds withdrawal status information