Versions in this module Expand all Collapse all v0 v0.1.0 Sep 1, 2026 Changes in this version + const Version + var ErrDepthDesync = errors.New("binance: depth cache sequence gap") + var ErrInvalidInterval = errors.New("binance: unknown kline interval") + var ErrMissingAPIKey = errors.New("binance: api key is required") + var ErrMissingAPISecret = errors.New("binance: api secret or private key is required") + var ErrNoProgress = errors.New("binance: historical pagination made no progress") + var ErrStreamClosed = errors.New("binance: websocket stream closed") + var ErrStreamOverflow = errors.New("binance: websocket event buffer overflow") + func IntervalDuration(interval Interval) (int64, bool) + func NewClientOrderID() string + func RedactQuery(raw string) string + type APIError struct + Code int + HTTPStatus int + Message string + func (e *APIError) Error() string + func (e *APIError) IsRateLimited() bool + type Account struct + AccountType string + Balances []Balance + Brokered bool + BuyerCommission int + CanDeposit bool + CanTrade bool + CanWithdraw bool + MakerCommission int + Permissions []string + PreventSor bool + RequireSelfTradePrevention bool + SellerCommission int + TakerCommission int + UID int64 + UpdateTime TimeMS + func (a *Account) BalanceOf(asset string) (Balance, bool) + type AccountAPIStatus struct + Data struct{ ... } + type AccountRequest struct + OmitZeroBalances bool + RecvWindow int64 + type AccountSnapshot struct + Code int + Msg string + SnapshotVos []AccountSnapshotPayload + type AccountSnapshotPayload struct + Data jsonRawSnapshot + Type string + UpdateTime TimeMS + type AccountSnapshotRequest struct + EndTime int64 + Limit int + RecvWindow int64 + StartTime int64 + Type string + type AccountStatus struct + Data string + type AggTrade struct + AggTradeID int64 + FirstTradeID int64 + IsBestMatch bool + IsBuyerMaker bool + LastTradeID int64 + Price string + Quantity string + Timestamp TimeMS + type AggTradeEvent struct + AggTradeID int64 + EventTime TimeMS + EventType string + FirstTradeID int64 + IsBuyerMaker bool + LastTradeID int64 + Price string + Quantity string + Symbol string + TradeTime TimeMS + type AggTradeIterator struct + func (it *AggTradeIterator) AggTrade() AggTrade + func (it *AggTradeIterator) Err() error + func (it *AggTradeIterator) Next(ctx context.Context) bool + type AggTradeQuery struct + EndTime int64 + FromID int64 + Limit int + StartTime int64 + Symbol string + type AggTradesRequest struct + EndTime int64 + FromID int64 + Limit int + StartTime int64 + Symbol string + type AllOrdersRequest struct + EndTime int64 + Limit int + OrderID int64 + RecvWindow int64 + StartTime int64 + Symbol string + type AssetDetail map[string]AssetDetailEntry + type AssetDetailEntry struct + DepositStatus bool + DepositTip string + MinWithdrawAmount string + WithdrawFee any + WithdrawStatus bool + type AuthError struct + Msg string + func (e *AuthError) Error() string + type AvgPrice struct + CloseTime TimeMS + Mins int + Price string + type Balance struct + Asset string + Free string + Locked string + type BookTicker struct + AskPrice string + AskQty string + BidPrice string + BidQty string + Symbol string + type BookTickerEvent struct + AskPrice string + AskQty string + BidPrice string + BidQty string + Symbol string + UpdateID int64 + type BookTickerRequest struct + Symbol string + Symbols []string + type BorrowRepayRequest struct + Amount string + Asset string + IsIsolated string + RecvWindow int64 + Symbol string + Type string + type BorrowRepayResult struct + TranID int64 + type CancelOrderRequest struct + CancelRestrictions string + NewClientOrderID string + OrderID int64 + OrigClientOrderID string + RecvWindow int64 + Symbol string + type CancelReplaceRequest struct + CancelClientOrderID string + CancelOrderID int64 + CancelReplaceMode string + type Client struct + func NewClient(apiKey, apiSecret string, opts ...Option) *Client + func (c *Client) AggTrades(q AggTradeQuery) *AggTradeIterator + func (c *Client) CancelOrder(ctx context.Context, req CancelOrderRequest) (*Order, error) + func (c *Client) CoinFutures() *CoinFuturesService + func (c *Client) Convert() *ConvertService + func (c *Client) CreateOrder(ctx context.Context, req OrderRequest) (*Order, error) + func (c *Client) DepthCache(ctx context.Context, symbol string, opts ...DepthCacheOption) (*DepthCache, error) + func (c *Client) Earn() *EarnService + func (c *Client) Environment() Environment + func (c *Client) Futures() *FuturesService + func (c *Client) FuturesWSAPI() *WSAPI + func (c *Client) GetAccount(ctx context.Context) (*Account, error) + func (c *Client) GetExchangeInfo(ctx context.Context) (*ExchangeInfo, error) + func (c *Client) GetHistoricalKlines(ctx context.Context, symbol string, interval Interval, ...) ([]Kline, error) + func (c *Client) GetOrder(ctx context.Context, req QueryOrderRequest) (*Order, error) + func (c *Client) GetOrderBook(ctx context.Context, symbol string, limit int) (*OrderBook, error) + func (c *Client) GetServerTime(ctx context.Context) (int64, error) + func (c *Client) GetSymbolTicker(ctx context.Context, symbol string) (*SymbolPrice, error) + func (c *Client) GiftCard() *GiftCardService + func (c *Client) HistoricalKlines(q KlineQuery) *KlineIterator + func (c *Client) Margin() *MarginService + func (c *Client) Options() *OptionsService + func (c *Client) Ping(ctx context.Context) error + func (c *Client) Portfolio() *PortfolioService + func (c *Client) SetTimeOffset(ms int64) + func (c *Client) Spot() *SpotService + func (c *Client) String() string + func (c *Client) SubAccount() *SubAccountService + func (c *Client) Subscribe(ctx context.Context, specs ...StreamSpec) (*Stream, error) + func (c *Client) SyncTime(ctx context.Context) error + func (c *Client) TestOrder(ctx context.Context, req OrderRequest) error + func (c *Client) TimeOffset() int64 + func (c *Client) UsedWeight() int + func (c *Client) UserData(ctx context.Context) (*Stream, error) + func (c *Client) UserStream() *UserStreamService + func (c *Client) WSAPI() *WSAPI + func (c *Client) Wallet() *WalletService + func (c *Client) WebSocket() *WebSocketService + type CoinFuturesService struct + func (s *CoinFuturesService) Account(ctx context.Context, recv int64) (*FuturesAccount, error) + func (s *CoinFuturesService) AllOrders(ctx context.Context, req AllOrdersRequest, pair string) ([]FuturesOrder, error) + func (s *CoinFuturesService) Balance(ctx context.Context, recv int64) ([]FuturesBalance, error) + func (s *CoinFuturesService) BookTicker(ctx context.Context, symbol string) ([]BookTicker, error) + func (s *CoinFuturesService) CancelAllOpenOrders(ctx context.Context, symbol string, recv int64) error + func (s *CoinFuturesService) CancelOrder(ctx context.Context, req CancelOrderRequest) (*FuturesOrder, error) + func (s *CoinFuturesService) ChangeLeverage(ctx context.Context, symbol string, leverage int, recv int64) error + func (s *CoinFuturesService) ChangeMarginType(ctx context.Context, symbol string, marginType MarginType, recv int64) error + func (s *CoinFuturesService) ChangePositionMode(ctx context.Context, dualSide bool, recv int64) error + func (s *CoinFuturesService) CloseListenKey(ctx context.Context, listenKey string) error + func (s *CoinFuturesService) CreateOrder(ctx context.Context, req FuturesOrderRequest) (*FuturesOrder, error) + func (s *CoinFuturesService) DepthCache(ctx context.Context, symbol string) (*DepthCache, error) + func (s *CoinFuturesService) ExchangeInfo(ctx context.Context) (*FuturesExchangeInfo, error) + func (s *CoinFuturesService) GetOrder(ctx context.Context, req QueryOrderRequest) (*FuturesOrder, error) + func (s *CoinFuturesService) GetPositionMode(ctx context.Context, recv int64) (*PositionMode, error) + func (s *CoinFuturesService) IncomeHistory(ctx context.Context, req IncomeHistoryRequest) ([]Income, error) + func (s *CoinFuturesService) KeepListenKey(ctx context.Context, listenKey string) error + func (s *CoinFuturesService) Klines(ctx context.Context, req KlinesRequest) ([]Kline, error) + func (s *CoinFuturesService) ListenKey(ctx context.Context) (string, error) + func (s *CoinFuturesService) MarkPrice(ctx context.Context, symbol, pair string) ([]MarkPrice, error) + func (s *CoinFuturesService) OpenOrders(ctx context.Context, symbol, pair string, recv int64) ([]FuturesOrder, error) + func (s *CoinFuturesService) OrderBook(ctx context.Context, req OrderBookRequest) (*OrderBook, error) + func (s *CoinFuturesService) Ping(ctx context.Context) error + func (s *CoinFuturesService) Positions(ctx context.Context, marginAsset, pair string, recv int64) ([]FuturesPosition, error) + func (s *CoinFuturesService) ServerTime(ctx context.Context) (int64, error) + func (s *CoinFuturesService) Ticker24h(ctx context.Context, symbol string) ([]Ticker24h, error) + func (s *CoinFuturesService) TickerPrice(ctx context.Context, symbol string) ([]SymbolPrice, error) + func (s *CoinFuturesService) UserData(ctx context.Context) (*Stream, error) + func (s *CoinFuturesService) UserTrades(ctx context.Context, req MyTradesRequest, pair string) ([]FuturesUserTrade, error) + type CoinInfo struct + Coin string + DepositAllEnable bool + Free string + Freeze string + Ipoable string + Ipoing string + IsLegalMoney bool + Locked string + Name string + NetworkList []CoinNetwork + Storage string + Trading bool + WithdrawAllEnable bool + Withdrawing string + type CoinNetwork struct + AddressRegex string + Coin string + DepositDesc string + DepositEnable bool + IsDefault bool + MemoRegex string + MinConfirm int + Name string + Network string + ResetAddressStatus bool + SpecialTips string + UnLockConfirm int + WithdrawDesc string + WithdrawEnable bool + WithdrawFee string + WithdrawIntegerMultiple string + WithdrawMax string + WithdrawMin string + type ContractType string + const ContractCurrentMonth + const ContractCurrentQuarter + const ContractNextMonth + const ContractNextQuarter + const ContractPerpetual + type ConvertPair struct + FromAsset string + FromAssetMaxAmount string + FromAssetMinAmount string + ToAsset string + ToAssetMaxAmount string + ToAssetMinAmount string + type ConvertQuote struct + FromAmount string + InverseRatio string + QuoteID string + Ratio string + ToAmount string + ValidTimestamp int64 + type ConvertService struct + func (s *ConvertService) AcceptQuote(ctx context.Context, quoteID string, recv int64) (*UniversalTransferResult, error) + func (s *ConvertService) ExchangeInfo(ctx context.Context, fromAsset, toAsset string) ([]ConvertPair, error) + func (s *ConvertService) GetQuote(ctx context.Context, fromAsset, toAsset, fromAmount string, recv int64) (*ConvertQuote, error) + func (s *ConvertService) OrderStatus(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + type DecodeError struct + Err error + Op string + Status int + func (e *DecodeError) Error() string + func (e *DecodeError) Unwrap() error + type Deposit struct + Address string + AddressTag string + Amount string + Coin string + ConfirmTimes string + ID string + InsertTime TimeMS + Network string + Status int + TransferType int + TxID string + UnlockConfirm int + WalletType int + type DepositAddress struct + Address string + Coin string + Tag string + URL string + type DepositAddressRequest struct + Coin string + Network string + RecvWindow int64 + type DepositHistoryRequest struct + Coin string + EndTime int64 + Limit int + Offset int + RecvWindow int64 + StartTime int64 + Status int + TxID string + type DepthCache struct + func (d *DepthCache) Asks() []PriceLevel + func (d *DepthCache) Bids() []PriceLevel + func (d *DepthCache) Close() error + func (d *DepthCache) LastUpdateID() int64 + func (d *DepthCache) Updates() <-chan struct{} + func (d *DepthCache) Wait(ctx context.Context) (struct{}, error) + type DepthCacheOption func(*DepthCache) + func WithDepthMarket(m Market) DepthCacheOption + type DepthEvent struct + Asks []PriceLevel + Bids []PriceLevel + EventTime TimeMS + EventType string + FinalUpdateID int64 + FirstUpdateID int64 + PrevUpdateID int64 + Symbol string + type DepthLevel string + const DepthLevel10 + const DepthLevel20 + const DepthLevel5 + type EarnPage struct + Rows []EarnProduct + Total int + type EarnProduct struct + Asset string + CanPurchase bool + CanRedeem bool + Hot bool + IsSoldOut bool + LatestAnnualPercentageRate string + MinPurchaseAmount string + ProductID string + Status string + SubscriptionStartTime TimeMS + TierAnnualPercentageRate map[string]string + type EarnService struct + func (s *EarnService) Account(ctx context.Context, recv int64) (map[string]string, error) + func (s *EarnService) FlexiblePosition(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + func (s *EarnService) FlexibleProducts(ctx context.Context, asset string, recv int64) (*EarnPage, error) + func (s *EarnService) LockedPosition(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + func (s *EarnService) LockedProducts(ctx context.Context, asset string, recv int64) (*EarnPage, error) + func (s *EarnService) RedeemFlexible(ctx context.Context, productID, amount string, recv int64) (*UniversalTransferResult, error) + func (s *EarnService) SubscribeFlexible(ctx context.Context, productID, amount string, recv int64) (*UniversalTransferResult, error) + type Environment int + const EnvDemo + const EnvProduction + const EnvTestnet + type Event struct + AggTrade *AggTradeEvent + BookTicker *BookTickerEvent + Depth *DepthEvent + Err error + EventTime time.Time + Kline *KlineEvent + MiniTicker *MiniTickerEvent + Raw json.RawMessage + Stream string + Ticker *TickerEvent + Trade *TradeEvent + Type string + User json.RawMessage + type ExchangeInfo struct + ExchangeFilters []map[string]any + RateLimits []RateLimit + ServerTime TimeMS + Symbols []SymbolInfo + Timezone string + type ExchangeInfoRequest struct + Symbol string + Symbols []string + type Fill struct + Commission string + CommissionAsset string + Price string + Qty string + TradeID int64 + type FundingRate struct + FundingRate string + FundingTime TimeMS + Symbol string + type FuturesAccount struct + Assets []FuturesAsset + AvailableBalance string + CanDeposit bool + CanTrade bool + CanWithdraw bool + FeeTier int + MaxWithdrawAmount string + Positions []FuturesPosition + TotalCrossUnPnl string + TotalCrossWalletBalance string + TotalInitialMargin string + TotalMaintMargin string + TotalMarginBalance string + TotalOpenOrderInitialMargin string + TotalPositionInitialMargin string + TotalUnrealizedProfit string + TotalWalletBalance string + UpdateTime TimeMS + type FuturesAsset struct + Asset string + AvailableBalance string + CrossUnPnl string + CrossWalletBalance string + InitialMargin string + MaintMargin string + MarginBalance string + MaxWithdrawAmount string + OpenOrderInitialMargin string + PositionInitialMargin string + UnrealizedProfit string + UpdateTime TimeMS + WalletBalance string + type FuturesBalance struct + AccountAlias string + Asset string + AvailableBalance string + Balance string + CrossUnPnl string + CrossWalletBalance string + MarginAvailable bool + MaxWithdrawAmount string + UpdateTime TimeMS + type FuturesExchangeInfo struct + RateLimits []RateLimit + ServerTime TimeMS + Symbols []FuturesSymbolInfo + Timezone string + type FuturesOrder struct + AvgPrice string + ClientOrderID string + ClosePosition bool + CumQty string + CumQuote string + ExecutedQty string + OrderID int64 + OrigQty string + OrigType OrderType + PositionSide PositionSide + Price string + PriceProtect bool + ReduceOnly bool + Side Side + Status OrderStatus + StopPrice string + Symbol string + TimeInForce TimeInForce + Type OrderType + UpdateTime TimeMS + WorkingType WorkingType + type FuturesOrderRequest struct + ActivationPrice string + CallbackRate string + ClientOrderID string + ClosePosition string + GoodTillDate int64 + NewOrderRespType OrderRespType + PositionSide PositionSide + Price string + PriceMatch string + PriceProtect string + Quantity string + RecvWindow int64 + ReduceOnly string + SelfTradePreventionMode SelfTradePreventionMode + Side Side + StopPrice string + Symbol string + TimeInForce TimeInForce + Type OrderType + WorkingType WorkingType + type FuturesPosition struct + BreakEvenPrice string + EntryPrice string + IsAutoAddMargin string + IsolatedMargin string + IsolatedWallet string + Leverage string + LiquidationPrice string + MarginType MarginType + MarkPrice string + MaxNotionalValue string + Notional string + PositionAmt string + PositionSide PositionSide + Symbol string + UnRealizedProfit string + UpdateTime TimeMS + type FuturesService struct + func (s *FuturesService) Account(ctx context.Context, recv int64) (*FuturesAccount, error) + func (s *FuturesService) AllOrders(ctx context.Context, req AllOrdersRequest) ([]FuturesOrder, error) + func (s *FuturesService) Balance(ctx context.Context, recv int64) ([]FuturesBalance, error) + func (s *FuturesService) BookTicker(ctx context.Context, symbol string) ([]BookTicker, error) + func (s *FuturesService) CancelAllOpenOrders(ctx context.Context, symbol string, recv int64) error + func (s *FuturesService) CancelOrder(ctx context.Context, req CancelOrderRequest) (*FuturesOrder, error) + func (s *FuturesService) ChangeLeverage(ctx context.Context, symbol string, leverage int, recv int64) error + func (s *FuturesService) ChangeMarginType(ctx context.Context, symbol string, marginType MarginType, recv int64) error + func (s *FuturesService) ChangePositionMode(ctx context.Context, dualSide bool, recv int64) error + func (s *FuturesService) CloseListenKey(ctx context.Context, listenKey string) error + func (s *FuturesService) CreateOrder(ctx context.Context, req FuturesOrderRequest) (*FuturesOrder, error) + func (s *FuturesService) DepthCache(ctx context.Context, symbol string) (*DepthCache, error) + func (s *FuturesService) ExchangeInfo(ctx context.Context) (*FuturesExchangeInfo, error) + func (s *FuturesService) FundingRateHistory(ctx context.Context, symbol string, start, end int64, limit int) ([]FundingRate, error) + func (s *FuturesService) GetOrder(ctx context.Context, req QueryOrderRequest) (*FuturesOrder, error) + func (s *FuturesService) GetPositionMode(ctx context.Context, recv int64) (*PositionMode, error) + func (s *FuturesService) IncomeHistory(ctx context.Context, req IncomeHistoryRequest) ([]Income, error) + func (s *FuturesService) KeepListenKey(ctx context.Context, listenKey string) error + func (s *FuturesService) Klines(ctx context.Context, req KlinesRequest) ([]Kline, error) + func (s *FuturesService) ListenKey(ctx context.Context) (string, error) + func (s *FuturesService) MarkPrice(ctx context.Context, symbol string) ([]MarkPrice, error) + func (s *FuturesService) OpenOrders(ctx context.Context, symbol string, recv int64) ([]FuturesOrder, error) + func (s *FuturesService) OrderBook(ctx context.Context, req OrderBookRequest) (*OrderBook, error) + func (s *FuturesService) Ping(ctx context.Context) error + func (s *FuturesService) Positions(ctx context.Context, symbol string, recv int64) ([]FuturesPosition, error) + func (s *FuturesService) ServerTime(ctx context.Context) (int64, error) + func (s *FuturesService) TestOrder(ctx context.Context, req FuturesOrderRequest) error + func (s *FuturesService) Ticker24h(ctx context.Context, symbol string) ([]Ticker24h, error) + func (s *FuturesService) TickerPrice(ctx context.Context, symbol string) ([]SymbolPrice, error) + func (s *FuturesService) UserData(ctx context.Context) (*Stream, error) + func (s *FuturesService) UserTrades(ctx context.Context, req MyTradesRequest) ([]FuturesUserTrade, error) + type FuturesSymbolInfo struct + BaseAsset string + ContractType ContractType + Filters []SymbolFilter + MarginAsset string + OrderTypes []OrderType + Pair string + PricePrecision int + QuantityPrecision int + QuoteAsset string + Status string + Symbol string + TimeInForce []TimeInForce + UnderlyingType string + type FuturesUserTrade struct + Buyer bool + Commission string + CommissionAsset string + ID int64 + Maker bool + OrderID int64 + PositionSide PositionSide + Price string + Qty string + QuoteQty string + RealizedPnl string + Side Side + Symbol string + Time TimeMS + type GiftCardService struct + func (s *GiftCardService) CreateCode(ctx context.Context, token, amount string, recv int64) (json.RawMessage, error) + func (s *GiftCardService) Redeem(ctx context.Context, code string, recv int64) (json.RawMessage, error) + func (s *GiftCardService) TokenLimit(ctx context.Context, baseToken string, recv int64) (json.RawMessage, error) + func (s *GiftCardService) Verify(ctx context.Context, referenceNo string, recv int64) (json.RawMessage, error) + type HistoricalTradesRequest struct + FromID int64 + Limit int + Symbol string + type Income struct + Asset string + Income string + IncomeType string + Info string + Symbol string + Time TimeMS + TradeID string + TranID int64 + type IncomeHistoryRequest struct + EndTime int64 + IncomeType string + Limit int + Page int + RecvWindow int64 + StartTime int64 + Symbol string + type InterestHistoryPage struct + Rows []InterestRecord + Total int + type InterestHistoryRequest struct + Asset string + Current int + EndTime int64 + IsolatedSymbol string + RecvWindow int64 + Size int + StartTime int64 + type InterestRecord struct + Asset string + Interest string + InterestAccuredTime TimeMS + InterestRate string + IsolatedSymbol string + Principal string + RawAsset string + TxID int64 + Type string + type Interval string + const Interval12h + const Interval15m + const Interval1M + const Interval1d + const Interval1h + const Interval1m + const Interval1s + const Interval1w + const Interval2h + const Interval30m + const Interval3d + const Interval3m + const Interval4h + const Interval5m + const Interval6h + const Interval8h + type IsolatedMarginAccount struct + Assets []IsolatedMarginPair + TotalAssetOfBtc string + TotalLiabilityOfBtc string + TotalNetAssetOfBtc string + type IsolatedMarginPair struct + BaseAsset MarginAsset + Enabled bool + IndexPrice string + IsolatedCreated bool + LiquidatePrice string + LiquidateRate string + MarginLevel string + MarginLevelStatus string + MarginRatio string + QuoteAsset MarginAsset + Symbol string + TradeEnabled bool + type IsolatedTransferRequest struct + Amount string + Asset string + RecvWindow int64 + Symbol string + TransFrom string + TransTo string + type Kline struct + Close string + CloseTime TimeMS + High string + Low string + NumberOfTrades int64 + Open string + OpenTime TimeMS + QuoteAssetVolume string + TakerBuyBaseAssetVolume string + TakerBuyQuoteAssetVolume string + Volume string + func (k *Kline) UnmarshalJSON(b []byte) error + type KlineEvent struct + EventTime TimeMS + EventType string + Kline KlineFrame + Symbol string + type KlineFrame struct + Close string + CloseTime TimeMS + Closed bool + FirstTradeID int64 + High string + Interval Interval + LastTradeID int64 + Low string + Open string + QuoteVolume string + StartTime TimeMS + Symbol string + TakerBuyBase string + TakerBuyQuote string + TradeCount int64 + Volume string + type KlineIterator struct + func (it *KlineIterator) Err() error + func (it *KlineIterator) Kline() Kline + func (it *KlineIterator) Next(ctx context.Context) bool + type KlineQuery struct + EndTime int64 + Interval Interval + Limit int + Market Market + StartTime int64 + Symbol string + type KlinesRequest struct + EndTime int64 + Interval Interval + Limit int + StartTime int64 + Symbol string + TimeZone string + type ListenKeyResponse struct + ListenKey string + type Logger interface + Debug func(msg string, args ...any) + Error func(msg string, args ...any) + Info func(msg string, args ...any) + type MarginAccount struct + AccountType string + BorrowEnabled bool + MarginLevel string + TotalAssetOfBtc string + TotalLiabilityOfBtc string + TotalNetAssetOfBtc string + TradeEnabled bool + TransferEnabled bool + UserAssets []MarginAsset + type MarginAsset struct + Asset string + Borrowed string + Free string + Interest string + Locked string + NetAsset string + type MarginOrderRequest struct + AutoRepayAtCancel *bool + IsIsolated string + SideEffectType string + type MarginService struct + func (s *MarginService) Account(ctx context.Context, recv int64) (*MarginAccount, error) + func (s *MarginService) AllOrders(ctx context.Context, req AllOrdersRequest, isolated string) ([]Order, error) + func (s *MarginService) Borrow(ctx context.Context, req BorrowRepayRequest) (*BorrowRepayResult, error) + func (s *MarginService) CancelOrder(ctx context.Context, req CancelOrderRequest, isolated string) (*Order, error) + func (s *MarginService) CreateOrder(ctx context.Context, req MarginOrderRequest) (*Order, error) + func (s *MarginService) DisableIsolated(ctx context.Context, symbol string, recv int64) error + func (s *MarginService) EnableIsolated(ctx context.Context, symbol string, recv int64) error + func (s *MarginService) GetOrder(ctx context.Context, req QueryOrderRequest, isolated string) (*Order, error) + func (s *MarginService) InterestHistory(ctx context.Context, req InterestHistoryRequest) (*InterestHistoryPage, error) + func (s *MarginService) IsolatedAccount(ctx context.Context, symbols string, recv int64) (*IsolatedMarginAccount, error) + func (s *MarginService) IsolatedTransfer(ctx context.Context, req IsolatedTransferRequest) (*UniversalTransferResult, error) + func (s *MarginService) ListenKey(ctx context.Context) (string, error) + func (s *MarginService) MaxBorrowable(ctx context.Context, asset, isolatedSymbol string, recv int64) (*MaxBorrowable, error) + func (s *MarginService) OpenOrders(ctx context.Context, symbol, isolated string, recv int64) ([]Order, error) + func (s *MarginService) Repay(ctx context.Context, req BorrowRepayRequest) (*BorrowRepayResult, error) + func (s *MarginService) Transfer(ctx context.Context, req TransferRequest) (*UniversalTransferResult, error) + type MarginType string + const MarginTypeCrossed + const MarginTypeIsolated + type MarkPrice struct + EstimatedSettlePrice string + IndexPrice string + InterestRate string + LastFundingRate string + MarkPrice string + NextFundingTime TimeMS + Symbol string + Time TimeMS + type Market int + const MarketCoinFutures + const MarketOptions + const MarketPortfolio + const MarketSpot + const MarketUSDFutures + type MaxBorrowable struct + Amount string + BorrowLimit string + type MiniTickerEvent struct + ClosePrice string + EventTime TimeMS + EventType string + HighPrice string + LowPrice string + OpenPrice string + QuoteVolume string + Symbol string + Volume string + type MyTrade struct + Commission string + CommissionAsset string + ID int64 + IsBestMatch bool + IsBuyer bool + IsMaker bool + OrderID int64 + OrderListID int64 + Price string + Qty string + QuoteQty string + Symbol string + Time TimeMS + type MyTradesRequest struct + EndTime int64 + FromID int64 + Limit int + OrderID int64 + RecvWindow int64 + StartTime int64 + Symbol string + type OCORequest struct + AboveClientOrderID string + AbovePrice string + AboveStopPrice string + AboveTimeInForce TimeInForce + AboveType OrderType + BelowClientOrderID string + BelowPrice string + BelowStopPrice string + BelowTimeInForce TimeInForce + BelowType OrderType + ListClientOrderID string + NewOrderRespType OrderRespType + Quantity string + RecvWindow int64 + SelfTradePreventionMode SelfTradePreventionMode + Side Side + Symbol string + type OpenOrdersRequest struct + RecvWindow int64 + Symbol string + type Option func(*config) + func WithAutoTimeSync() Option + func WithBaseURL(raw string) Option + func WithCoinFuturesBaseURL(raw string) Option + func WithDebug() Option + func WithDemo() Option + func WithEd25519PrivateKey(pemBytes []byte, password []byte) Option + func WithFuturesBaseURL(raw string) Option + func WithFuturesWSAPIURL(raw string) Option + func WithHTTPClient(c *http.Client) Option + func WithHeader(key, value string) Option + func WithLogger(l Logger) Option + func WithOptionsURL(raw string) Option + func WithPortfolioURL(raw string) Option + func WithProxy(raw string) Option + func WithRSAPrivateKey(pemBytes []byte, password []byte) Option + func WithRateLimiter(l RateLimiter) Option + func WithRecvWindow(ms int64) Option + func WithRetry(r RetryConfig) Option + func WithSigner(s Signer) Option + func WithTLD(tld string) Option + func WithTestnet() Option + func WithTimeout(d time.Duration) Option + func WithWSAPIURL(raw string) Option + func WithWSBuffer(n int) Option + func WithWSReconnect(maxRetries int, minBackoff, maxBackoff time.Duration) Option + func WithWebSocketURL(raw string) Option + type OptionsExchangeInfo struct + OptionSymbols []FuturesSymbolInfo + ServerTime TimeMS + Timezone string + type OptionsService struct + func (s *OptionsService) Account(ctx context.Context, recv int64) (*FuturesAccount, error) + func (s *OptionsService) CancelOrder(ctx context.Context, req CancelOrderRequest) (*FuturesOrder, error) + func (s *OptionsService) CloseListenKey(ctx context.Context, listenKey string) error + func (s *OptionsService) CreateOrder(ctx context.Context, req FuturesOrderRequest) (*FuturesOrder, error) + func (s *OptionsService) ExchangeInfo(ctx context.Context) (*OptionsExchangeInfo, error) + func (s *OptionsService) KeepListenKey(ctx context.Context, listenKey string) error + func (s *OptionsService) Klines(ctx context.Context, req KlinesRequest) ([]Kline, error) + func (s *OptionsService) ListenKey(ctx context.Context) (string, error) + func (s *OptionsService) MarkPrice(ctx context.Context, symbol string) ([]MarkPrice, error) + func (s *OptionsService) OpenOrders(ctx context.Context, symbol string, recv int64) ([]FuturesOrder, error) + func (s *OptionsService) OrderBook(ctx context.Context, req OrderBookRequest) (*OrderBook, error) + func (s *OptionsService) Ping(ctx context.Context) error + func (s *OptionsService) Positions(ctx context.Context, symbol string, recv int64) ([]FuturesPosition, error) + func (s *OptionsService) ServerTime(ctx context.Context) (int64, error) + func (s *OptionsService) Ticker24h(ctx context.Context, symbol string) ([]Ticker24h, error) + func (s *OptionsService) UserData(ctx context.Context) (*Stream, error) + func (s *OptionsService) UserTrades(ctx context.Context, req MyTradesRequest) ([]FuturesUserTrade, error) + type Order struct + ClientOrderID string + CummulativeQuoteQty string + ExecutedQty string + Fills []Fill + IcebergQty string + IsWorking bool + OrderID int64 + OrderListID int64 + OrigQty string + OrigQuoteOrderQty string + Price string + SelfTradePreventionMode string + Side Side + Status OrderStatus + StopPrice string + Symbol string + Time TimeMS + TimeInForce TimeInForce + TransactTime TimeMS + Type OrderType + UpdateTime TimeMS + WorkingTime TimeMS + type OrderBook struct + Asks []PriceLevel + Bids []PriceLevel + E int64 + LastUpdateID int64 + T int64 + type OrderBookRequest struct + Limit int + Symbol string + type OrderCount struct + Count int + Interval string + IntervalNum int + Limit int + RateLimitType string + type OrderList struct + ContingencyType string + ListClientOrderID string + ListOrderStatus string + ListStatusType string + OrderListID int64 + OrderReports []Order + Orders []Order + Symbol string + TransactionTime TimeMS + type OrderRequest struct + ClientOrderID string + IcebergQty string + NewOrderRespType OrderRespType + Price string + Quantity string + QuoteOrderQty string + RecvWindow int64 + SelfTradePreventionMode SelfTradePreventionMode + Side Side + StopPrice string + StrategyID int64 + StrategyType int + Symbol string + TimeInForce TimeInForce + TrailingDelta int64 + Type OrderType + type OrderRespType string + const OrderRespACK + const OrderRespFull + const OrderRespResult + type OrderStatus string + const OrderStatusCanceled + const OrderStatusExpired + const OrderStatusExpiredInMatch + const OrderStatusFilled + const OrderStatusNew + const OrderStatusPartiallyFilled + const OrderStatusPendingCancel + const OrderStatusRejected + type OrderType string + const OrderTypeLimit + const OrderTypeLimitMaker + const OrderTypeMarket + const OrderTypeStop + const OrderTypeStopLoss + const OrderTypeStopLossLimit + const OrderTypeStopMarket + const OrderTypeTakeProfit + const OrderTypeTakeProfitLimit + const OrderTypeTakeProfitMarket + const OrderTypeTrailingStopMarket + type PortfolioService struct + func (s *PortfolioService) Account(ctx context.Context, recv int64) (*FuturesAccount, error) + func (s *PortfolioService) Balance(ctx context.Context, asset string, recv int64) ([]FuturesBalance, error) + func (s *PortfolioService) CMPositions(ctx context.Context, symbol string, recv int64) ([]FuturesPosition, error) + func (s *PortfolioService) CancelUMOrder(ctx context.Context, req CancelOrderRequest) (*FuturesOrder, error) + func (s *PortfolioService) CloseListenKey(ctx context.Context, listenKey string) error + func (s *PortfolioService) CreateCMOrder(ctx context.Context, req FuturesOrderRequest) (*FuturesOrder, error) + func (s *PortfolioService) CreateUMOrder(ctx context.Context, req FuturesOrderRequest) (*FuturesOrder, error) + func (s *PortfolioService) KeepListenKey(ctx context.Context, listenKey string) error + func (s *PortfolioService) ListenKey(ctx context.Context) (string, error) + func (s *PortfolioService) Ping(ctx context.Context) error + func (s *PortfolioService) SetUMLeverage(ctx context.Context, symbol string, leverage int, recv int64) error + func (s *PortfolioService) UMPositions(ctx context.Context, symbol string, recv int64) ([]FuturesPosition, error) + func (s *PortfolioService) UserData(ctx context.Context) (*Stream, error) + type PositionMode struct + DualSidePosition bool + type PositionSide string + const PositionSideBoth + const PositionSideLong + const PositionSideShort + type PriceLevel struct + Price string + Quantity string + func (p *PriceLevel) UnmarshalJSON(b []byte) error + func (p PriceLevel) MarshalJSON() ([]byte, error) + type QueryOrderRequest struct + OrderID int64 + OrigClientOrderID string + RecvWindow int64 + Symbol string + type RateLimit struct + Interval string + IntervalNum int + Limit int + RateLimitType string + type RateLimitError struct + Err error + HTTPStatus int + RetryAfter time.Duration + UsedWeight int + func (e *RateLimitError) Error() string + func (e *RateLimitError) Unwrap() error + type RateLimiter interface + Wait func(ctx context.Context, weight int) error + type RecentTradesRequest struct + Limit int + Symbol string + type RequestError struct + Err error + Method string + Path string + func (e *RequestError) Error() string + func (e *RequestError) Unwrap() error + type RetryConfig struct + MaxAttempts int + MaxBackoff time.Duration + MinBackoff time.Duration + Retry429 bool + type RollingTicker struct + CloseTime TimeMS + Count int64 + FirstID int64 + HighPrice string + LastID int64 + LastPrice string + LowPrice string + OpenPrice string + OpenTime TimeMS + PriceChange string + PriceChangePercent string + QuoteVolume string + Symbol string + Volume string + WeightedAvgPrice string + type RollingTickerRequest struct + Symbol string + Symbols []string + Type string + WindowSize string + type SelfTradePreventionMode string + const STPDecrementCancel + const STPExpireBoth + const STPExpireMaker + const STPExpireTaker + const STPNone + type ServerTime struct + ServerTime int64 + type Side string + const SideBuy + const SideSell + type Signer interface + Sign func(payload string) (string, error) + type SpotService struct + func (s *SpotService) APITradingStatus(ctx context.Context, recv int64) (*AccountAPIStatus, error) + func (s *SpotService) Account(ctx context.Context, req AccountRequest) (*Account, error) + func (s *SpotService) AggTrades(ctx context.Context, req AggTradesRequest) ([]AggTrade, error) + func (s *SpotService) AllOrders(ctx context.Context, req AllOrdersRequest) ([]Order, error) + func (s *SpotService) AvgPrice(ctx context.Context, symbol string) (*AvgPrice, error) + func (s *SpotService) BookTicker(ctx context.Context, req BookTickerRequest) ([]BookTicker, error) + func (s *SpotService) CancelAllOpenOrders(ctx context.Context, symbol string, recv int64) ([]Order, error) + func (s *SpotService) CancelOrder(ctx context.Context, req CancelOrderRequest) (*Order, error) + func (s *SpotService) CancelOrderList(ctx context.Context, symbol string, orderListID int64, ...) (*OrderList, error) + func (s *SpotService) CancelReplace(ctx context.Context, req CancelReplaceRequest) (*Order, error) + func (s *SpotService) CreateOCO(ctx context.Context, req OCORequest) (*OrderList, error) + func (s *SpotService) CreateOrder(ctx context.Context, req OrderRequest) (*Order, error) + func (s *SpotService) ExchangeInfo(ctx context.Context, req ExchangeInfoRequest) (*ExchangeInfo, error) + func (s *SpotService) GetOrder(ctx context.Context, req QueryOrderRequest) (*Order, error) + func (s *SpotService) HistoricalTrades(ctx context.Context, req HistoricalTradesRequest) ([]Trade, error) + func (s *SpotService) Klines(ctx context.Context, req KlinesRequest) ([]Kline, error) + func (s *SpotService) MyTrades(ctx context.Context, req MyTradesRequest) ([]MyTrade, error) + func (s *SpotService) OpenOrderLists(ctx context.Context, recv int64) ([]OrderList, error) + func (s *SpotService) OpenOrders(ctx context.Context, req OpenOrdersRequest) ([]Order, error) + func (s *SpotService) OrderBook(ctx context.Context, req OrderBookRequest) (*OrderBook, error) + func (s *SpotService) OrderCountUsage(ctx context.Context, recv int64) ([]OrderCount, error) + func (s *SpotService) Ping(ctx context.Context) error + func (s *SpotService) RecentTrades(ctx context.Context, req RecentTradesRequest) ([]Trade, error) + func (s *SpotService) RollingTicker(ctx context.Context, req RollingTickerRequest) ([]RollingTicker, error) + func (s *SpotService) SAPIAccountStatus(ctx context.Context, recv int64) (*AccountStatus, error) + func (s *SpotService) ServerTime(ctx context.Context) (int64, error) + func (s *SpotService) TestOrder(ctx context.Context, req OrderRequest) error + func (s *SpotService) Ticker24h(ctx context.Context, req Ticker24hRequest) ([]Ticker24h, error) + func (s *SpotService) TickerPrice(ctx context.Context, req TickerPriceRequest) ([]SymbolPrice, error) + func (s *SpotService) UIKlines(ctx context.Context, req KlinesRequest) ([]Kline, error) + type StdLogger struct + Printf func(format string, args ...any) + func (l StdLogger) Debug(msg string, args ...any) + func (l StdLogger) Error(msg string, args ...any) + func (l StdLogger) Info(msg string, args ...any) + type Stream struct + func (s *Stream) Close() error + func (s *Stream) Events() <-chan Event + func (s *Stream) Healthy() bool + func (s *Stream) Next(ctx context.Context) (Event, error) + type StreamSpec struct + Market Market + Name string + func StreamAggTrade(symbol string) StreamSpec + func StreamBookTicker(symbol string) StreamSpec + func StreamCoinFuturesTrade(symbol string) StreamSpec + func StreamDepth(symbol string) StreamSpec + func StreamDepth100ms(symbol string) StreamSpec + func StreamFuturesTrade(symbol string) StreamSpec + func StreamKline(symbol string, interval Interval) StreamSpec + func StreamMiniTicker(symbol string) StreamSpec + func StreamPartialDepth(symbol string, level DepthLevel, ms100 bool) StreamSpec + func StreamTicker(symbol string) StreamSpec + func StreamTrade(symbol string) StreamSpec + type SubAccount struct + CreateTime TimeMS + Email string + IsAssetManagementSubAccount bool + IsFreeze bool + IsManagedSubAccount bool + type SubAccountService struct + func (s *SubAccountService) Assets(ctx context.Context, email string, recv int64) ([]Balance, error) + func (s *SubAccountService) List(ctx context.Context, email string, recv int64) ([]SubAccount, error) + func (s *SubAccountService) UniversalTransfer(ctx context.Context, req SubAccountTransferRequest) (*UniversalTransferResult, error) + type SubAccountTransferRequest struct + Amount string + Asset string + FromAccountType string + FromEmail string + RecvWindow int64 + ToAccountType string + ToEmail string + type SymbolFilter struct + ApplyMinToMarket bool + FilterType string + MaxNumOrders int + MaxPrice string + MaxQty string + MinNotional string + MinPrice string + MinQty string + StepSize string + TickSize string + type SymbolInfo struct + AllowTrailingStop bool + AllowedSelfTradePreventionModes []string + BaseAsset string + BaseAssetPrecision int + CancelReplaceAllowed bool + DefaultSelfTradePreventionMode string + Filters []SymbolFilter + IcebergAllowed bool + IsMarginTradingAllowed bool + IsSpotTradingAllowed bool + OCOAllowed bool + OTOAllowed bool + OrderTypes []OrderType + Permissions []string + QuoteAsset string + QuoteAssetPrecision int + QuoteOrderQtyMarketAllowed bool + QuotePrecision int + Status string + Symbol string + type SymbolPrice struct + Price string + Symbol string + type SystemStatus struct + Msg string + Status int + type Ticker24h struct + AskPrice string + AskQty string + BidPrice string + BidQty string + CloseTime TimeMS + Count int64 + FirstID int64 + HighPrice string + LastID int64 + LastPrice string + LastQty string + LowPrice string + OpenPrice string + OpenTime TimeMS + PrevClosePrice string + PriceChange string + PriceChangePercent string + QuoteVolume string + Symbol string + Volume string + WeightedAvgPrice string + type Ticker24hRequest struct + Symbol string + Symbols []string + Type string + type TickerEvent struct + BestAskPrice string + BestAskQty string + BestBidPrice string + BestBidQty string + CloseTime TimeMS + Count int64 + EventTime TimeMS + EventType string + FirstTradeID int64 + FirstTradePrice string + HighPrice string + LastPrice string + LastQty string + LastTradeID int64 + LowPrice string + OpenPrice string + OpenTime TimeMS + PriceChange string + PriceChangePercent string + QuoteVolume string + Symbol string + Volume string + WeightedAvgPrice string + type TickerPriceRequest struct + Symbol string + Symbols []string + type TimeInForce string + const TimeInForceFOK + const TimeInForceGTC + const TimeInForceGTD + const TimeInForceGTX + const TimeInForceIOC + type TimeMS int64 + func (t TimeMS) Time() time.Time + type Trade struct + ID int64 + IsBestMatch bool + IsBuyerMaker bool + Price string + Qty string + QuoteQty string + Time TimeMS + type TradeEvent struct + BuyerOrderID int64 + EventTime TimeMS + EventType string + IsBuyerMaker bool + Price string + Quantity string + SellerOrderID int64 + Symbol string + TradeID int64 + TradeTime TimeMS + type TradeFee struct + MakerCommission string + Symbol string + TakerCommission string + type TransferRequest struct + Amount string + Asset string + RecvWindow int64 + Type int + type TransferType string + const TransferCMFutureToMain + const TransferFundingToMain + const TransferMainToCMFuture + const TransferMainToFunding + const TransferMainToMargin + const TransferMainToUMFuture + const TransferMarginToMain + const TransferMarginToUMFuture + const TransferUMFutureToMain + const TransferUMFutureToMargin + type UniversalTransferRequest struct + Amount string + Asset string + FromSymbol string + RecvWindow int64 + ToSymbol string + Type TransferType + type UniversalTransferResult struct + TranID int64 + type UserStreamService struct + func (s *UserStreamService) Close(ctx context.Context, listenKey string) error + func (s *UserStreamService) Create(ctx context.Context) (string, error) + func (s *UserStreamService) Keepalive(ctx context.Context, listenKey string) error + type WSAPI struct + func (w *WSAPI) CancelOrder(ctx context.Context, req CancelOrderRequest) (*Order, error) + func (w *WSAPI) Close() error + func (w *WSAPI) CreateFuturesOrder(ctx context.Context, req FuturesOrderRequest) (*FuturesOrder, error) + func (w *WSAPI) CreateOrder(ctx context.Context, req OrderRequest) (*Order, error) + func (w *WSAPI) GetAccount(ctx context.Context) (*Account, error) + func (w *WSAPI) GetOrder(ctx context.Context, req QueryOrderRequest) (*Order, error) + func (w *WSAPI) GetSymbolTicker(ctx context.Context, symbol string) (*SymbolPrice, error) + func (w *WSAPI) Ping(ctx context.Context) error + func (w *WSAPI) ServerTime(ctx context.Context) (int64, error) + func (w *WSAPI) TestOrder(ctx context.Context, req OrderRequest) error + type WalletService struct + func (s *WalletService) APIRestrictions(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + func (s *WalletService) APITradingStatus(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + func (s *WalletService) AccountSnapshot(ctx context.Context, req AccountSnapshotRequest) (*AccountSnapshot, error) + func (s *WalletService) AssetDetail(ctx context.Context, asset string, recv int64) (AssetDetail, error) + func (s *WalletService) AssetDividend(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + func (s *WalletService) Coins(ctx context.Context, recv int64) ([]CoinInfo, error) + func (s *WalletService) DepositAddress(ctx context.Context, req DepositAddressRequest) (*DepositAddress, error) + func (s *WalletService) DepositHistory(ctx context.Context, req DepositHistoryRequest) ([]Deposit, error) + func (s *WalletService) DustLog(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + func (s *WalletService) DustTransfer(ctx context.Context, assets []string, recv int64) (jsonRawSnapshot, error) + func (s *WalletService) SpotDelistSchedule(ctx context.Context, recv int64, extra map[string]string) (json.RawMessage, error) + func (s *WalletService) SystemStatus(ctx context.Context) (*SystemStatus, error) + func (s *WalletService) TradeFee(ctx context.Context, symbol string, recv int64) ([]TradeFee, error) + func (s *WalletService) UniversalTransfer(ctx context.Context, req UniversalTransferRequest) (*UniversalTransferResult, error) + func (s *WalletService) Withdraw(ctx context.Context, req WithdrawRequest) (*WithdrawResult, error) + func (s *WalletService) WithdrawHistory(ctx context.Context, req WithdrawHistoryRequest) ([]Withdrawal, error) + type WebSocketService struct + func (s *WebSocketService) AggTrade(ctx context.Context, symbol string) (*Stream, error) + func (s *WebSocketService) BookTicker(ctx context.Context, symbol string) (*Stream, error) + func (s *WebSocketService) Combined(ctx context.Context, specs ...StreamSpec) (*Stream, error) + func (s *WebSocketService) Depth(ctx context.Context, symbol string) (*Stream, error) + func (s *WebSocketService) FuturesTrade(ctx context.Context, symbol string) (*Stream, error) + func (s *WebSocketService) Kline(ctx context.Context, symbol string, interval Interval) (*Stream, error) + func (s *WebSocketService) MiniTicker(ctx context.Context, symbol string) (*Stream, error) + func (s *WebSocketService) Ticker(ctx context.Context, symbol string) (*Stream, error) + func (s *WebSocketService) Trade(ctx context.Context, symbol string) (*Stream, error) + func (s *WebSocketService) UserData(ctx context.Context) (*Stream, error) + type WebsocketError struct + Err error + Op string + func (e *WebsocketError) Error() string + func (e *WebsocketError) Unwrap() error + type WeightLimiter struct + func NewWeightLimiter(weight int, window time.Duration) *WeightLimiter + func (l *WeightLimiter) Wait(ctx context.Context, weight int) error + type WithdrawHistoryRequest struct + Coin string + EndTime int64 + Limit int + Offset int + RecvWindow int64 + StartTime int64 + Status int + WithdrawOrderID string + type WithdrawRequest struct + Address string + AddressTag string + Amount string + Coin string + Name string + Network string + RecvWindow int64 + TransactionFeeFlag bool + WalletType int + WithdrawOrderID string + type WithdrawResult struct + ID string + type Withdrawal struct + Address string + Amount string + ApplyTime string + Coin string + ConfirmNo int + ID string + Info string + Network string + Status int + TransactionFee string + TransferType int + TxID string + TxKey string + WalletType int + WithdrawOrderID string + type WorkingType string + const WorkingTypeContractPrice + const WorkingTypeMarkPrice