Documentation ¶
Overview ¶
Package symbol provides middleware utilities around symbol.
Symbol is a function whereby you have two different currencies that can be traded between one another. When buying and selling a cryptocurrency, it is often swapped with local currency. For example, If you're looking to buy or sell Bitcoin with U.S. Dollar, the trading pair would be BTC to USD
Index ¶
- Variables
- type Core
- func (c Core) Create(ctx context.Context, nSbl NewSymbol) (Symbol, error)
- func (c Core) Query(ctx context.Context, pageNumber int, rowsPerPage int) ([]Symbol, error)
- func (c Core) QueryByID(ctx context.Context, sblID string) (Symbol, error)
- func (c Core) QueryBySymbol(ctx context.Context, sSbl string) (Symbol, error)
- type NewSymbol
- type Symbol
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNotFound = errors.New("symbol not found") ErrAuthenticationFailure = errors.New("authentication failed") ErrInvalidID = errors.New("ID is not in its proper form") ErrInvalidSymbol = errors.New("symbol is not valid") )
Set of error variables for CRUD operations.
Functions ¶
This section is empty.
Types ¶
type Core ¶
type Core struct {
// contains filtered or unexported fields
}
Core manages the set of API's for candle access.
type Symbol ¶
type Symbol struct { ID string `json:"symbol_id"` Symbol string `json:"symbol"` Status string `json:"status"` BaseAsset string `json:"base_asset"` BaseAssetPrecision int `json:"base_asset_precision"` QuoteAsset string `json:"quote_asset"` QuotePrecision int `json:"quote_precision"` BaseCommissionPrecision int `json:"base_commission_precision"` QuoteCommissionPrecision int `json:"quote_commission_precision"` IcebergAllowed bool `json:"iceberg_allowed"` OcoAllowed bool `json:"oco_allowed"` QuoteOrderQtyMarketAllowed bool `json:"quote_order_qty_market_allowed"` IsSpotTradingAllowed bool `json:"is_spot_trading_allowed"` IsMarginTradingAllowed bool `json:"is_margin_trading_allowed"` }
Click to show internal directories.
Click to hide internal directories.