Documentation ¶
Overview ¶
Code generated by go generate; DO NOT EDIT.
Index ¶
- func TrimLowerString(original string) string
- func TrimUpperString(original string) string
- type Candle
- type ErrorResponse
- type Exchange
- func (e *Exchange) CancelOrders(ctx context.Context, orders ...types.Order) error
- func (e *Exchange) IsSupportedInterval(interval types.Interval) bool
- func (e *Exchange) Name() types.ExchangeName
- func (e *Exchange) NewStream() types.Stream
- func (e *Exchange) PlatformFeeCurrency() string
- func (e *Exchange) QueryAccount(ctx context.Context) (*types.Account, error)
- func (e *Exchange) QueryAccountBalances(ctx context.Context) (types.BalanceMap, error)
- func (e *Exchange) QueryClosedOrders(ctx context.Context, symbol string, since, until time.Time, lastOrderID uint64) (orders []types.Order, err error)
- func (e *Exchange) QueryDepositHistory(ctx context.Context, asset string, since, until time.Time) (allDeposits []types.Deposit, err error)
- func (e *Exchange) QueryKLines(ctx context.Context, symbol string, interval types.Interval, ...) ([]types.KLine, error)
- func (e *Exchange) QueryMarkets(ctx context.Context) (types.MarketMap, error)
- func (e *Exchange) QueryOpenOrders(ctx context.Context, symbol string) (orders []types.Order, err error)
- func (e *Exchange) QueryOrder(ctx context.Context, q types.OrderQuery) (*types.Order, error)
- func (e *Exchange) QueryTicker(ctx context.Context, symbol string) (*types.Ticker, error)
- func (e *Exchange) QueryTickers(ctx context.Context, symbol ...string) (map[string]types.Ticker, error)
- func (e *Exchange) QueryTrades(ctx context.Context, symbol string, options *types.TradeQueryOptions) ([]types.Trade, error)
- func (e *Exchange) SubmitOrders(ctx context.Context, orders ...types.SubmitOrder) (types.OrderSlice, error)
- func (e *Exchange) SupportedInterval() map[types.Interval]int
- func (e *Exchange) Transfer(ctx context.Context, coin string, size float64, destination string) (string, error)
- type HistoricalPricesResponse
- type MarketMap
- type MarketTicker
- type OrderType
- type Stream
- type TransferPayload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func TrimLowerString ¶ added in v1.14.0
func TrimUpperString ¶ added in v1.14.0
Types ¶
type Candle ¶ added in v1.15.3
type Candle struct { Close fixedpoint.Value `json:"close"` High fixedpoint.Value `json:"high"` Low fixedpoint.Value `json:"low"` Open fixedpoint.Value `json:"open"` StartTime datetime `json:"startTime"` Volume fixedpoint.Value `json:"volume"` }
type ErrorResponse ¶
type ErrorResponse struct { *util.Response IsSuccess bool `json:"success"` ErrorString string `json:"error,omitempty"` }
func (*ErrorResponse) Error ¶
func (r *ErrorResponse) Error() string
type Exchange ¶
type Exchange struct {
// contains filtered or unexported fields
}
func NewExchange ¶
func (*Exchange) CancelOrders ¶
func (*Exchange) IsSupportedInterval ¶ added in v1.21.0
func (*Exchange) Name ¶
func (e *Exchange) Name() types.ExchangeName
func (*Exchange) PlatformFeeCurrency ¶
func (*Exchange) QueryAccount ¶
func (*Exchange) QueryAccountBalances ¶
func (*Exchange) QueryClosedOrders ¶
func (e *Exchange) QueryClosedOrders(ctx context.Context, symbol string, since, until time.Time, lastOrderID uint64) (orders []types.Order, err error)
symbol, since and until are all optional. FTX can only query by order created time, not updated time. FTX doesn't support lastOrderID, so we will query by the time range first, and filter by the lastOrderID.
func (*Exchange) QueryDepositHistory ¶
func (*Exchange) QueryKLines ¶
func (*Exchange) QueryMarkets ¶
func (*Exchange) QueryOpenOrders ¶
func (*Exchange) QueryOrder ¶ added in v1.28.0
func (*Exchange) QueryTicker ¶ added in v1.13.0
func (*Exchange) QueryTickers ¶ added in v1.13.0
func (*Exchange) QueryTrades ¶
func (*Exchange) SubmitOrders ¶
func (e *Exchange) SubmitOrders(ctx context.Context, orders ...types.SubmitOrder) (types.OrderSlice, error)
func (*Exchange) SupportedInterval ¶ added in v1.21.0
type HistoricalPricesResponse ¶ added in v1.15.3
type HistoricalPricesResponse struct { Success bool `json:"success"` Result []Candle `json:"result"` }
{ "success": true, "result": [ { "close": 11055.25, "high": 11089.0, "low": 11043.5, "open": 11059.25, "startTime": "2019-06-24T17:15:00+00:00", "volume": 464193.95725 } ] }
type MarketMap ¶ added in v1.21.0
type MarketMap map[string]MarketTicker
type MarketTicker ¶ added in v1.21.0
type MarketTicker struct { Market types.Market Price fixedpoint.Value Ask fixedpoint.Value Bid fixedpoint.Value Last fixedpoint.Value }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.