Skip to content
github-actions[bot] edited this page May 8, 2026 · 2 revisions

weex{docsify-ignore}

Kind: global class
Extends: Exchange

fetchStatus{docsify-ignore}

the latest known information on the availability of the exchange API

Kind: instance method of weex
Returns: object - a status structure

See: https://www.weex.com/api-doc/spot/ConfigAPI/Ping

Param Type Required Description
params object No extra parameters specific to the exchange API endpoint
weex.fetchStatus ([params])

fetchTime{docsify-ignore}

fetches the current integer timestamp in milliseconds from the exchange server

Kind: instance method of weex
Returns: int - the current integer timestamp in milliseconds from the exchange server

See

Param Type Required Description
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap', default is 'spot'
weex.fetchTime ([params])

fetchCurrencies{docsify-ignore}

fetches all available currencies on an exchange

Kind: instance method of weex
Returns: object - an associative dictionary of currencies

See: https://www.weex.com/api-doc/spot/ConfigAPI/CurrencyInfo

Param Type Required Description
params object No extra parameters specific to the exchange API endpoint
weex.fetchCurrencies ([params])

fetchMarkets{docsify-ignore}

retrieves data on all markets for exchagne

Kind: instance method of weex
Returns: Array<object> - an array of objects representing market data

See

Param Type Required Description
params object No extra parameters specific to the exchange API endpoint
weex.fetchMarkets ([params])

fetchTickers{docsify-ignore}

fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market

Kind: instance method of weex
Returns: object - a ticker structure

See

Param Type Required Description
symbols string Yes unified symbol of the market to fetch the ticker for
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap', default is 'spot' (used if symbols are not provided)
weex.fetchTickers (symbols[, params])

fetchBidsAsks{docsify-ignore}

fetches the bid and ask price and volume for multiple markets

Kind: instance method of weex
Returns: object - a dictionary of ticker structures

See

Param Type Required Description
symbols Array<string>, undefined Yes unified symbols of the markets to fetch the bids and asks for, all markets are returned if not assigned
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap', default is 'spot' (used if symbols are not provided)
weex.fetchBidsAsks (symbols[, params])

fetchOrderBook{docsify-ignore}

fetches information on open orders with bid (buy) and ask (sell) prices, volumes and other data

Kind: instance method of weex
Returns: object - A dictionary of order book structures indexed by market symbols

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch the order book for
limit int No the maximum amount of order book entries to return (default 15, max 200)
params object No extra parameters specific to the exchange API endpoint
weex.fetchOrderBook (symbol[, limit, params])

fetchOHLCV{docsify-ignore}

fetches historical candlestick data containing the open, high, low, and close price, and the volume of a market

Kind: instance method of weex
Returns: Array<Array<int>> - A list of candles ordered as timestamp, open, high, low, close, volume

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch OHLCV data for
timeframe string Yes the length of time each candle represents
since int No timestamp in ms of the earliest candle to fetch
limit int No the maximum amount of candles to fetch (default 100, max 300)
params object No extra parameters specific to the exchange API endpoint Check fetchSpotOHLCV() and fetchContractOHLCV() for more details on the extra parameters that can be used in params
weex.fetchOHLCV (symbol, timeframe[, since, limit, params])

fetchTrades{docsify-ignore}

get the list of most recent trades for a particular symbol

Kind: instance method of weex
Returns: Array<Trade> - a list of trade structures

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch trades for
since int No timestamp in ms of the earliest trade to fetch
limit int No the maximum amount of trades to fetch (default 100, max 1000)
params object No extra parameters specific to the exchange API endpoint
weex.fetchTrades (symbol[, since, limit, params])

fetchOpenInterest{docsify-ignore}

retrieves the open interest of a contract trading pair

Kind: instance method of weex
Returns: object - an open interest structurehttps://docs.ccxt.com/?id=open-interest-structure

See: https://www.weex.com/api-doc/contract/Market_API/GetOpenInterest

Param Type Required Description
symbol string Yes unified CCXT market symbol
params object No exchange specific parameters
weex.fetchOpenInterest (symbol[, params])

fetchFundingRates{docsify-ignore}

fetch the funding rate for multiple markets

Kind: instance method of weex
Returns: Array<object> - a list of funding rate structures, indexed by market symbols

See: https://www.weex.com/api-doc/contract/Market_API/GetCurrentFundingRate

Param Type Required Description
symbols Array<string>, undefined Yes list of unified market symbols
params object No extra parameters specific to the exchange API endpoint
params.subType string No "linear" or "inverse"
weex.fetchFundingRates (symbols[, params])

fetchFundingRateHistory{docsify-ignore}

fetches historical funding rate prices

Kind: instance method of weex
Returns: Array<object> - a list of funding rate structures

See: https://www.weex.com/api-doc/contract/Market_API/GetFundingRateHistory

Param Type Required Description
symbol string Yes unified symbol of the market to fetch the funding rate history for
since int No timestamp in ms of the earliest funding rate to fetch
limit int No the maximum amount of funding rate records to fetch (default 100, max 1000)
params object No extra parameters specific to the exchange API endpoint
params.until int No timestamp in ms of the latest funding rate
weex.fetchFundingRateHistory (symbol[, since, limit, params])

fetchBalance{docsify-ignore}

query for balance and get the amount of funds available for trading or funds locked in positions

Kind: instance method of weex
Returns: object - a balance structure

See

Param Type Required Description
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap' (default is 'spot')
weex.fetchBalance ([params])

fetchTransfers{docsify-ignore}

fetch a history of internal transfers made on an account

Kind: instance method of weex
Returns: Array<object> - a list of transfer structures

See: https://www.weex.com/api-doc/spot/AccountAPI/TransferRecords

Param Type Required Description
code string No unified currency code of the currency transferred
since int No the earliest time in ms to fetch transfers for
limit int No the maximum number of transfers structures to retrieve (default 10, max 100)
params object No extra parameters specific to the exchange API endpoint
params.paginate boolean No default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the available parameters
weex.fetchTransfers ([code, since, limit, params])

createOrder{docsify-ignore}

Create an order on the exchange

Kind: instance method of weex
Returns: object - an order structure

See

Param Type Required Description
symbol string Yes Unified CCXT market symbol
type string Yes 'limit' or 'market'
side string Yes 'buy' or 'sell'
amount float Yes the amount of currency to trade
price float No the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
params object No extra parameters specific to the exchange API endpoint Check createSpotOrder() and createContractOrder() for more details on the extra parameters that can be used in params
weex.createOrder (symbol, type, side, amount[, price, params])

createSpotOrder{docsify-ignore}

helper method for creating spot orders

Kind: instance method of weex
Returns: object - an order structure

See: https://www.weex.com/api-doc/spot/orderApi/PlaceOrder

Param Type Required Description
symbol string Yes Unified CCXT market symbol
type string Yes 'limit' or 'market'
side string Yes 'buy' or 'sell'
amount float Yes the amount of currency to trade
price float No the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
params object No extra parameters specific to the exchange API endpoint
params.clientOrderId string No client order id
params.timeInForce string No 'GTC', 'IOC', or 'FOK'
weex.createSpotOrder (symbol, type, side, amount[, price, params])

createContractOrder{docsify-ignore}

helper method for creating contract orders

Kind: instance method of weex
Returns: object - an order structure

See

Param Type Required Description
symbol string Yes Unified CCXT market symbol
type string Yes 'limit' or 'market'
side string Yes 'buy' or 'sell'
amount float Yes the amount of currency to trade
price float No the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
params object No extra parameters specific to the exchange API endpoint
params.clientOrderId string No client order id
params.takeProfit object No takeProfit object in params containing the triggerPrice at which the attached take profit order will be triggered and the triggerPriceType
params.takeProfit.triggerPrice float No The price at which the take profit order will be triggered
params.takeProfit.triggerPriceType string No The type of the trigger price for the take profit order, either 'last' or 'mark' (default is 'last')
params.stopLoss object No stopLoss object in params containing the triggerPrice at which the attached stop loss order will be triggered and the triggerPriceType
params.stopLoss.triggerPrice float No The price at which the stop loss order will be triggered
params.stopLoss.triggerPriceType string No The type of the trigger price for the stop loss order, either 'last' or 'mark' (default is 'last')
params.stopLossPrice float No price to trigger stop-loss orders
params.stopLossPriceType string No The type of the trigger price for the stop loss order, either 'last' or 'mark' (default is 'last')
params.takeProfitPrice float No price to trigger take-profit orders
params.takeProfitPriceType string No The type of the trigger price for the take profit order, either 'last' or 'mark' (default is 'last')
params.reduceOnly bool No A mark to reduce the position size only. Set to false by default. Need to set the position size when reduceOnly is true.
params.timeInForce string No GTC, IOC, or FOK (default is GTC for limit orders)
weex.createContractOrder (symbol, type, side, amount[, price, params])

cancelOrder{docsify-ignore}

cancels an open order

Kind: instance method of weex
Returns: object - an order structure

See

Param Type Required Description
id string Yes order id
symbol string No unified symbol of the market the order was made in
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap' (default is 'spot')
params.trigger boolean No contract orders only whether the order to cancel is a trigger order
params.clientOrderId string No non-trigger orders only a unique id for the order
weex.cancelOrder (id[, symbol, params])

cancelAllOrders{docsify-ignore}

cancel all open orders

Kind: instance method of weex
Returns: Response from the exchange

See

Param Type Required Description
symbol string Yes unified market symbol, only orders in the market of this symbol are cancelled when symbol is not undefined
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
params.trigger boolean No swap only true for cancelling trigger orders (default is false)
weex.cancelAllOrders (symbol[, params])

cancelOrders{docsify-ignore}

cancel multiple orders

Kind: instance method of weex
Returns: object - an list of order structures

See

Param Type Required Description
ids Array<string> Yes order ids
symbol string No unified market symbol, default is undefined
params object No extra parameters specific to the exchange API endpoint
params.clientOrderIds Array<string> No client order ids (could be an alternative to ids)
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
weex.cancelOrders (ids[, symbol, params])

fetchOrder{docsify-ignore}

fetches information on an order made by the user

Kind: instance method of weex
Returns: object - An order structure

See

Param Type Required Description
id string Yes order id
symbol string Yes unified symbol of the market the order was made in
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
params.clientOrderId string No spot only a unique id for the order, used if id is not provided
weex.fetchOrder (id, symbol[, params])

fetchOpenOrders{docsify-ignore}

fetch all unfilled currently open orders

Kind: instance method of weex
Returns: Array<Order> - a list of order structures

See

Param Type Required Description
symbol string Yes unified market symbol
since int No the earliest time in ms to fetch open orders for
limit int No the maximum number of open orders structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
params.trigger boolean No swap only whether to fetch trigger orders (default is false)
weex.fetchOpenOrders (symbol[, since, limit, params])

fetchClosedOrders{docsify-ignore}

fetches information on multiple closed orders made by the user

Kind: instance method of weex
Returns: Array<Order> - a list of order structures

See

Param Type Required Description
symbol string Yes unified market symbol of the market orders were made in
since int No the earliest time in ms to fetch orders for
limit int No the maximum number of order structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.until int No the latest time in ms to fetch orders for
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
weex.fetchClosedOrders (symbol[, since, limit, params])

fetchCanceledOrders{docsify-ignore}

fetches information on multiple canceled orders made by the user

Kind: instance method of weex
Returns: Array<Order> - a list of order structures

See

Param Type Required Description
symbol string Yes unified market symbol of the market orders were made in
since int No the earliest time in ms to fetch orders for
limit int No the maximum number of order structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.until int No the latest time in ms to fetch orders for
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
weex.fetchCanceledOrders (symbol[, since, limit, params])

fetchOrders{docsify-ignore}

fetches information on multiple spot orders made by the user

Kind: instance method of weex
Returns: Array<Order> - a list of order structures

See: https://www.weex.com/api-doc/spot/orderApi/HistoryOrders // spot

Param Type Required Description
symbol string Yes unified market symbol of the market orders were made in (required for spot orders)
since int No the earliest time in ms to fetch orders for
limit int No the maximum number of order structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.until object No end time, ms
params.paginate boolean No default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the available parameters
weex.fetchOrders (symbol[, since, limit, params])

fetchCanceledAndClosedOrders{docsify-ignore}

fetches information on multiple closed and canceled orders made by the user

Kind: instance method of weex
Returns: Array<Order> - a list of order structures

See: https://www.weex.com/api-doc/contract/Transaction_API/GetOrderHistory // contract

Param Type Required Description
symbol string No unified market symbol of the market orders were made in (required for spot orders)
since int No the earliest time in ms to fetch orders for
limit int No the maximum number of order structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.until object No end time, ms
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
params.paginate boolean No default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the available parameters
weex.fetchCanceledAndClosedOrders ([symbol, since, limit, params])

fetchOrderTrades{docsify-ignore}

fetch all the trades made from a single order

Kind: instance method of weex
Returns: Array<object> - a list of trade structures

See

Param Type Required Description
id string Yes order id
symbol string No unified market symbol
since int No the earliest time in ms to fetch trades for
limit int No the maximum number of trades to retrieve
params object No extra parameters specific to the exchange API endpoint
weex.fetchOrderTrades (id[, symbol, since, limit, params])

fetchMyTrades{docsify-ignore}

fetch all trades made by the user

Kind: instance method of weex
Returns: Array<Trade> - a list of trade structures

See

Param Type Required Description
symbol string Yes unified market symbol
since int No the earliest time in ms to fetch trades for
limit int No the maximum number of trades structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.paginate boolean No default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the availble parameters
params.type string No 'spot' or 'swap', used if symbol is not provided (default is 'spot')
weex.fetchMyTrades (symbol[, since, limit, params])

fetchLedger{docsify-ignore}

fetch the history of changes, actions done by the user or operations that altered the balance of the user

Kind: instance method of weex
Returns: object - a ledger structure

See

Param Type Required Description
code string No unified currency code, default is undefined
since int No timestamp in ms of the earliest ledger entry, default is undefined
limit int No max number of ledger entries to return, default is undefined, max is 100
params object No extra parameters specific to the exchange API endpoint
params.until int No timestamp in ms of the latest ledger entry
params.type string No 'spot', 'funding' or 'swap' (default is 'spot')
params.paginate boolean No default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the available parameters
weex.fetchLedger ([code, since, limit, params])

fetchPositions{docsify-ignore}

fetch all open positions

Kind: instance method of weex
Returns: Array<object> - a list of position structure

See: https://www.weex.com/api-doc/contract/Account_API/GetAllPositions

Param Type Required Description
symbols Array<string> No list of unified market symbols
params object No extra parameters specific to the exchange API endpoint
weex.fetchPositions ([symbols, params])

fetchPosition{docsify-ignore}

fetch data on an open position

Kind: instance method of weex
Returns: object - a position structure

See: https://www.weex.com/api-doc/contract/Account_API/GetSinglePosition

Param Type Required Description
symbol string Yes unified market symbol of the market the position is held in
params object No extra parameters specific to the exchange API endpoint
weex.fetchPosition (symbol[, params])

fetchPositionsForSymbol{docsify-ignore}

fetch all open positions for specific symbol

Kind: instance method of weex
Returns: Array<object> - a list of position structure

See: https://www.weex.com/api-doc/contract/Account_API/GetSinglePosition

Param Type Required Description
symbol string Yes unified market symbol
params object No extra parameters specific to the exchange API endpoint
weex.fetchPositionsForSymbol (symbol[, params])

closeAllPositions{docsify-ignore}

closes all open positions for a market type

Kind: instance method of weex
Returns: Array<object> - A list of position structures

See: https://www.weex.com/api-doc/contract/Transaction_API/ClosePositions

Param Type Required Description
params object No extra parameters specific to the exchange API endpoint
weex.closeAllPositions ([params])

closePosition{docsify-ignore}

closes open positions for a market

Kind: instance method of weex
Returns: object - an order structure

See: https://www.weex.com/api-doc/contract/Transaction_API/ClosePositions

Param Type Required Description
symbol string Yes Unified CCXT market symbol
side string No not used by current exchange
params object No extra parameters specific to the exchange API endpoint
weex.closePosition (symbol[, side, params])

fetchTradingFee{docsify-ignore}

fetch the trading fees for a contract market

Kind: instance method of weex
Returns: object - a fee structure

See: https://www.weex.com/api-doc/contract/Account_API/GetCommissionRate // contract

Param Type Required Description
symbol string Yes unified market symbol
params object No extra parameters specific to the exchange API endpoint
weex.fetchTradingFee (symbol[, params])

fetchMarginMode{docsify-ignore}

fetches the margin mode of a specific symbol

Kind: instance method of weex
Returns: object - a margin mode structure

See: https://www.weex.com/api-doc/contract/Account_API/GetSymbolConfig

Param Type Required Description
symbol string Yes unified symbol of the market the order was made in
params object No extra parameters specific to the exchange API endpoint
weex.fetchMarginMode (symbol[, params])

fetchMarginModes{docsify-ignore}

fetches margin modes the symbols, with symbols=undefined all markets are returned

Kind: instance method of weex
Returns: object - a list of margin mode structures

See: https://www.weex.com/api-doc/contract/Account_API/GetSymbolConfig

Param Type Required Description
symbols Array<string> Yes unified market symbols
params object No extra parameters specific to the exchange API endpoint
weex.fetchMarginModes (symbols[, params])

setMarginMode{docsify-ignore}

set margin mode to 'cross' or 'isolated'

Kind: instance method of weex
Returns: object - response from the exchange

See: https://www.weex.com/api-doc/contract/Account_API/ChangeMarginModeTRADE

Param Type Required Description
marginMode string Yes 'cross' or 'isolated'
symbol string Yes unified market symbol
params object No extra parameters specific to the exchange API endpoint
weex.setMarginMode (marginMode, symbol[, params])

fetchLeverage{docsify-ignore}

fetch the set leverage for a market

Kind: instance method of weex
Returns: object - a leverage structure

See: https://www.weex.com/api-doc/contract/Account_API/GetSymbolConfig

Param Type Required Description
symbol string Yes unified market symbol
params object No extra parameters specific to the exchange API endpoint
weex.fetchLeverage (symbol[, params])

fetchLeverages{docsify-ignore}

fetch the set leverage for all markets

Kind: instance method of weex
Returns: object - a list of leverage structures

See: https://www.weex.com/api-doc/contract/Account_API/GetSymbolConfig

Param Type Required Description
symbols Array<string> No a list of unified market symbols
params object No extra parameters specific to the exchange API endpoint
weex.fetchLeverages ([symbols, params])

setLeverage{docsify-ignore}

set the level of leverage for a market

Kind: instance method of weex
Returns: object - response from the exchange

See: https://www.weex.com/api-doc/contract/Account_API/UpdateLeverageTRADE

Param Type Required Description
leverage float Yes the rate of leverage
symbol string Yes unified market symbol
params object No extra parameters specific to the exchange API endpoint
params.marginMode string No 'cross' or 'isolated' (default is 'cross' if specific leverage parameters are not provided)
params.crossLeverage number No cross margin mode only leverage for cross margin mode when marginMode is 'cross'
params.isolatedLongLeverage number No isolated margin mode only leverage for long positions when marginMode is 'isolated'
params.isolatedShortLeverage number No isolated margin mode only leverage for short positions when marginMode is 'isolated' If specific leverage parameters are not provided the leverage value will be applied to both long and short positions if marginMode is 'isolated' or to cross margin mode if marginMode is 'cross' If marginMode is not provided and specific leverage parameters are not provided too the leverage value will be applied to cross leverage
weex.setLeverage (leverage, symbol[, params])

fetchPositionMode{docsify-ignore}

fetchs the position mode, hedged or one way

Kind: instance method of weex
Returns: object - an object detailing whether the market is in hedged or one-way mode

See: https://www.weex.com/api-doc/contract/Account_API/GetSymbolConfig

Param Type Required Description
symbol string Yes unified symbol of the market to fetch the order book for
params object No extra parameters specific to the exchange API endpoint
weex.fetchPositionMode (symbol[, params])

setPositionMode{docsify-ignore}

set hedged to true or false for a market

Kind: instance method of weex
Returns: object - response from the exchange

See: https://www.weex.com/api-doc/contract/Account_API/ChangeMarginModeTRADE

Param Type Required Description
hedged bool Yes set to true to use dualSidePosition
symbol string Yes unified market symbol
params object No extra parameters specific to the exchange API endpoint
params.marginMode string Yes 'cross' or 'isolated' (default is 'cross')
weex.setPositionMode (hedged, symbol[, params])

reduceMargin{docsify-ignore}

remove margin from a position

Kind: instance method of weex
Returns: object - a margin structure

See: https://www.weex.com/api-doc/contract/Account_API/AdjustPositionMarginTRADE

Param Type Required Description
symbol string Yes unified market symbol
amount float Yes the amount of margin to remove
params object No extra parameters specific to the exchange API endpoint
params.positionId string Yes the id of the position to reduce margin from, required
weex.reduceMargin (symbol, amount[, params])

addMargin{docsify-ignore}

add margin

Kind: instance method of weex
Returns: object - a margin structure

See: https://www.weex.com/api-doc/contract/Account_API/AdjustPositionMarginTRADE

Param Type Required Description
symbol string Yes unified market symbol
amount float Yes amount of margin to add
params object No extra parameters specific to the exchange API endpoint
params.positionId string Yes the id of the position to add margin to, required
weex.addMargin (symbol, amount[, params])

watchTicker{docsify-ignore}

watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market

Kind: instance method of weex
Returns: object - a ticker structure

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch the ticker for
params object No extra parameters specific to the exchange API endpoint
params.name string No stream to use can be ticker or miniTicker
weex.watchTicker (symbol[, params])

watchTickers{docsify-ignore}

watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for all markets of a specific list

Kind: instance method of weex
Returns: object - a ticker structure

See

Param Type Required Description
symbols Array<string> Yes unified symbol of the market to fetch the ticker for
params object No extra parameters specific to the exchange API endpoint
weex.watchTickers (symbols[, params])

unWatchTicker{docsify-ignore}

unWatches a price ticker, a statistical calculation with the information calculated over the past 24 hours for all markets of a specific list

Kind: instance method of weex
Returns: object - a ticker structure

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch the ticker for
params object No extra parameters specific to the exchange API endpoint
weex.unWatchTicker (symbol[, params])

unWatchTickers{docsify-ignore}

unWatches a price ticker, a statistical calculation with the information calculated over the past 24 hours for all markets of a specific list

Kind: instance method of weex
Returns: object - a ticker structure

See

Param Type Required Description
symbols Array<string> Yes unified symbol of the market to fetch the ticker for
params object No extra parameters specific to the exchange API endpoint
weex.unWatchTickers (symbols[, params])

watchTrades{docsify-ignore}

get the list of most recent trades for a particular symbol

Kind: instance method of weex
Returns: Array<object> - a list of trade structures

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch trades for
since int No timestamp in ms of the earliest trade to fetch
limit int No the maximum amount of trades to fetch
params object No extra parameters specific to the exchange API endpoint
weex.watchTrades (symbol[, since, limit, params])

watchTradesForSymbols{docsify-ignore}

get the list of most recent trades for a list of symbols

Kind: instance method of weex
Returns: Array<object> - a list of trade structures

See

Param Type Required Description
symbols Array<string> Yes unified symbol of the market to fetch trades for
since int No timestamp in ms of the earliest trade to fetch
limit int No the maximum amount of trades to fetch
params object No extra parameters specific to the exchange API endpoint
weex.watchTradesForSymbols (symbols[, since, limit, params])

unWatchTrades{docsify-ignore}

unsubscribes from the trades channel

Kind: instance method of weex
Returns: Array<object> - a list of trade structures

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch trades for
params object No extra parameters specific to the exchange API endpoint
weex.unWatchTrades (symbol[, params])

unWatchTradesForSymbols{docsify-ignore}

unsubscribes from the trades channel

Kind: instance method of weex
Returns: Array<object> - a list of trade structures

See

Param Type Required Description
symbols Array<string> Yes unified symbol of the market to fetch trades for
params object No extra parameters specific to the exchange API endpoint
weex.unWatchTradesForSymbols (symbols[, params])

watchOHLCV{docsify-ignore}

watches historical candlestick data containing the open, high, low, and close price, and the volume of a market

Kind: instance method of weex
Returns: Array<Array<int>> - A list of candles ordered as timestamp, open, high, low, close, volume

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch OHLCV data for
timeframe string Yes the length of time each candle represents
since int No timestamp in ms of the earliest candle to fetch
limit int No the maximum amount of candles to fetch
params object No extra parameters specific to the exchange API endpoint
weex.watchOHLCV (symbol, timeframe[, since, limit, params])

watchOHLCVForSymbols{docsify-ignore}

watches historical candlestick data containing the open, high, low, and close price, and the volume of a market

Kind: instance method of weex
Returns: object - A list of candles ordered as timestamp, open, high, low, close, volume

See

Param Type Required Description
symbolsAndTimeframes Array<Array<string>> Yes array of arrays containing unified symbols and timeframes to fetch OHLCV data for, example 'BTC/USDT', '1m'], ['LTC/USDT', '5m'
since int No timestamp in ms of the earliest candle to fetch
limit int No the maximum amount of candles to fetch
params object No extra parameters specific to the exchange API endpoint
weex.watchOHLCVForSymbols (symbolsAndTimeframes[, since, limit, params])

unWatchOHLCV{docsify-ignore}

unWatches historical candlestick data containing the open, high, low, and close price, and the volume of a market

Kind: instance method of weex
Returns: Array<Array<int>> - A list of candles ordered as timestamp, open, high, low, close, volume

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch OHLCV data for
timeframe string Yes the length of time each candle represents
params object No extra parameters specific to the exchange API endpoint
weex.unWatchOHLCV (symbol, timeframe[, params])

unWatchOHLCVForSymbols{docsify-ignore}

unWatches historical candlestick data containing the open, high, low, and close price, and the volume of a market

Kind: instance method of weex
Returns: Array<Array<int>> - A list of candles ordered as timestamp, open, high, low, close, volume

See

Param Type Required Description
symbolsAndTimeframes Array<Array<string>> Yes array of arrays containing unified symbols and timeframes to fetch OHLCV data for, example 'BTC/USDT', '1m'], ['LTC/USDT', '5m'
params object No extra parameters specific to the exchange API endpoint
weex.unWatchOHLCVForSymbols (symbolsAndTimeframes[, params])

watchOrderBook{docsify-ignore}

watches information on open orders with bid (buy) and ask (sell) prices, volumes and other data

Kind: instance method of weex
Returns: object - A dictionary of order book structures indexed by market symbols

See

Param Type Required Description
symbol string Yes unified symbol of the market to fetch the order book for
limit int No the maximum amount of order book entries to return
params object No extra parameters specific to the exchange API endpoint
weex.watchOrderBook (symbol[, limit, params])

watchOrderBookForSymbols{docsify-ignore}

watches information on open orders with bid (buy) and ask (sell) prices, volumes and other data

Kind: instance method of weex
Returns: object - A dictionary of order book structures indexed by market symbols

See

Param Type Required Description
symbols Array<string> Yes unified array of symbols
limit int No the maximum amount of order book entries to return
params object No extra parameters specific to the exchange API endpoint
weex.watchOrderBookForSymbols (symbols[, limit, params])

unWatchOrderBook{docsify-ignore}

unWatches information on open orders with bid (buy) and ask (sell) prices, volumes and other data

Kind: instance method of weex
Returns: object - A dictionary of order book structures indexed by market symbols

See

Param Type Required Description
symbol string Yes unified array of symbols
params object No extra parameters specific to the exchange API endpoint
weex.unWatchOrderBook (symbol[, params])

unWatchOrderBookForSymbols{docsify-ignore}

unWatches information on open orders with bid (buy) and ask (sell) prices, volumes and other data

Kind: instance method of weex
Returns: object - A dictionary of order book structures indexed by market symbols

See

Param Type Required Description
symbols Array<string> Yes unified array of symbols
params object No extra parameters specific to the exchange API endpoint
weex.unWatchOrderBookForSymbols (symbols[, params])

watchBidsAsks{docsify-ignore}

watches best bid & ask for spot symbols

Kind: instance method of weex
Returns: object - a ticker structure

See: https://www.weex.com/api-doc/spot/Websocket/public/BookTicker-Channel

Param Type Required Description
symbols Array<string> Yes unified symbol of the market to fetch the ticker for
params object No extra parameters specific to the exchange API endpoint
weex.watchBidsAsks (symbols[, params])

unWatchBidsAsks{docsify-ignore}

unWatches best bid & ask for spot symbols

Kind: instance method of weex
Returns: object - a ticker structure

See: https://www.weex.com/api-doc/spot/Websocket/public/BookTicker-Channel

Param Type Required Description
symbols Array<string> Yes unified symbol of the market to fetch the ticker for
params object No extra parameters specific to the exchange API endpoint
weex.unWatchBidsAsks (symbols[, params])

watchMyTrades{docsify-ignore}

watches information on multiple trades made by the user

Kind: instance method of weex
Returns: Array<object> - a list of trade structures

See

Param Type Required Description
symbol string Yes unified market symbol of the market trades were made in
since int No the earliest time in ms to fetch trades for
limit int No the maximum number of trade structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.type string No spot or swap, default is spot if symbol is not provided
weex.watchMyTrades (symbol[, since, limit, params])

unWatchMyTrades{docsify-ignore}

unWatches information on multiple trades made by the user

Kind: instance method of weex
Returns: Array<object> - a list of order structures

See

Param Type Required Description
symbol string No not used by the exchange
params object No extra parameters specific to the exchange API endpoint
params.type string No spot or swap, default is spot
weex.unWatchMyTrades ([symbol, params])

watchOrders{docsify-ignore}

watches information on multiple orders made by the user

Kind: instance method of weex
Returns: Array<object> - a list of order structures

See

Param Type Required Description
symbol string Yes unified market symbol of the market orders were made in
since int No the earliest time in ms to fetch orders for
limit int No the maximum number of order structures to retrieve
params object No extra parameters specific to the exchange API endpoint
params.type string No spot or swap, default is spot if symbol is not provided
weex.watchOrders (symbol[, since, limit, params])

unWatchOrders{docsify-ignore}

unWatches information on multiple orders made by the user

Kind: instance method of weex
Returns: Array<object> - a list of order structures

See

Param Type Required Description
symbol string No not used by the exchange
params object No extra parameters specific to the exchange API endpoint
weex.unWatchOrders ([symbol, params])

watchBalance{docsify-ignore}

query for balance and get the amount of funds available for trading or funds locked in orders

Kind: instance method of weex
Returns: object - a balance structure

See

Param Type Required Description
params object No extra parameters specific to the exchange API endpoint
params.type string No 'spot' or 'swap', default is 'spot'
weex.watchBalance ([params])

watchPositions{docsify-ignore}

watch all open positions

Kind: instance method of weex
Returns: Array<object> - a list of position structure

See: https://www.weex.com/api-doc/contract/Websocket/private/Positions-Channel

Param Type Required Description
symbols Array<string>, undefined Yes list of unified market symbols
since int No the earliest time in ms to fetch positions for
limit int No the maximum number of position structures to retrieve
params object Yes extra parameters specific to the exchange API endpoint
params.accountNumber int No account number to query orders for, required
weex.watchPositions (symbols[, since, limit, params])

unWatchPositions{docsify-ignore}

unWatches all open positions

Kind: instance method of weex
Returns: object - status of the unwatch request

See: https://www.weex.com/api-doc/contract/Websocket/private/Positions-Channel

Param Type Required Description
symbols Array<string> No not used by the exchange, unsubscription from positions is global for all symbols
params object No extra parameters specific to the exchange API endpoint
weex.unWatchPositions ([symbols, params])

Clone this wiki locally