CCXT

coinex

coinex cryptocurrency exchange — CCXT unified API: methods, parameters and endpoints.

coinex

Kind: global class
Extends: Exchange

fetchCurrencies

fetches all available currencies on an exchange

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

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/list-all-deposit-withdrawal-config

ParamTypeRequiredDescription
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchCurrencies (params?)

fetchMarkets

retrieves data on all markets for coinex

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

See

ParamTypeRequiredDescription
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchMarkets (params?)

fetchTicker

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

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch the ticker for
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchTicker (symbol, params?)

fetchTickers

fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market

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

See

ParamTypeRequiredDescription
symbolsArray<string>, undefinedYesunified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchTickers (symbols, params?)

fetchTime

fetches the current integer timestamp in milliseconds from the exchange server

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

See: https://docs.coinex.com/api/v2/common/http/time

ParamTypeRequiredDescription
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchTime (params?)

fetchOrderBook

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

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch the order book for
limitintNothe maximum amount of order book entries to return
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchOrderBook (symbol, limit?, params?)

fetchTrades

get the list of the most recent trades for a particular symbol

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch trades for
sinceintNotimestamp in ms of the earliest trade to fetch
limitintNothe maximum amount of trades to fetch
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchTrades (symbol, since?, limit?, params?)

fetchTradingFee

fetch the trading fees for a market

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

See

ParamTypeRequiredDescription
symbolstringYesunified market symbol
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchTradingFee (symbol, params?)

fetchTradingFees

fetch the trading fees for multiple markets

Kind: instance method of coinex
Returns: object - a dictionary of fee structures indexed by market symbols

See

ParamTypeRequiredDescription
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchTradingFees (params?)

fetchOHLCV

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

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch OHLCV data for
timeframestringYesthe length of time each candle represents
sinceintNotimestamp in ms of the earliest candle to fetch
limitintNothe maximum amount of candles to fetch
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchOHLCV (symbol, timeframe, since?, limit?, params?)

fetchBalance

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

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

See

ParamTypeRequiredDescription
paramsobjectNoextra parameters specific to the exchange API endpoint
params.typestringNo'margin', 'swap', 'financial', or 'spot'
coinex.fetchBalance (params?)

createMarketBuyOrderWithCost

create a market buy order by providing the symbol and cost

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to create an order in
costfloatYeshow much you want to trade in units of the quote currency
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.createMarketBuyOrderWithCost (symbol, cost, params?)

createOrder

create a trade order

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to create an order in
typestringYes'market' or 'limit'
sidestringYes'buy' or 'sell'
amountfloatYeshow much you want to trade in units of the base currency
pricefloatNothe price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
paramsobjectNoextra parameters specific to the exchange API endpoint
params.triggerPricefloatNoprice to trigger stop orders
params.stopLossPricefloatNoprice to trigger stop loss orders
params.takeProfitPricefloatNoprice to trigger take profit orders
params.timeInForcestringNo'GTC', 'IOC', 'FOK', 'PO'
params.postOnlybooleanNoset to true if you wish to make a post only order
params.reduceOnlybooleanNocontract only indicates if this order is to reduce the size of a position
coinex.createOrder (symbol, type, side, amount, price?, params?)

createOrders

create a list of trade orders (all orders should be of the same symbol)

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

See

ParamTypeRequiredDescription
ordersArrayYeslist of orders to create, each object should contain the parameters required by createOrder, namely symbol, type, side, amount, price and params
paramsobjectNoextra parameters specific to the api endpoint
coinex.createOrders (orders, params?)

cancelOrders

cancel multiple orders

Kind: instance method of coinex
Returns: object - a list of order structures

See

ParamTypeRequiredDescription
idsArray<string>Yesorder ids
symbolstringYesunified market symbol
paramsobjectNoextra parameters specific to the exchange API endpoint
params.triggerbooleanNoset to true for canceling stop orders
coinex.cancelOrders (ids, symbol, params?)

editOrder

edit a trade order

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

See

ParamTypeRequiredDescription
idstringYesorder id
symbolstringYesunified symbol of the market to create an order in
typestringYes'market' or 'limit'
sidestringYes'buy' or 'sell'
amountfloatYeshow much of the currency you want to trade in units of the base currency
pricefloatNothe price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
paramsobjectNoextra parameters specific to the exchange API endpoint
params.triggerPricefloatNothe price to trigger stop orders
coinex.editOrder (id, symbol, type, side, amount, price?, params?)

editOrders

edit a list of trade orders

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

See

ParamTypeRequiredDescription
ordersArrayYeslist of orders to edit, each object should contain the parameters required by editOrder, namely id, symbol, amount, price and params
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.editOrders (orders, params?)

cancelOrder

cancels an open order

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

See

ParamTypeRequiredDescription
idstringYesorder id
symbolstringYesunified symbol of the market the order was made in
paramsobjectNoextra parameters specific to the exchange API endpoint
params.clientOrderIdstringNoclient order id, defaults to id if not passed
params.triggerbooleanNoset to true for canceling a trigger order
coinex.cancelOrder (id, symbol, params?)

cancelAllOrders

cancel all open orders in a market

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

See

ParamTypeRequiredDescription
symbolstringYesunified market symbol of the market to cancel orders in
paramsobjectNoextra parameters specific to the exchange API endpoint
params.marginModestringNo'cross' or 'isolated' for canceling spot margin orders
coinex.cancelAllOrders (symbol, params?)

fetchOrder

fetches information on an order made by the user

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

See

ParamTypeRequiredDescription
idstringYesorder id
symbolstringYesunified symbol of the market the order was made in
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchOrder (id, symbol, params?)

fetchOrdersByStatus

fetch a list of orders

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

See

ParamTypeRequiredDescription
statusstringYesorder status to fetch for
symbolstringYesunified market symbol of the market orders were made in
sinceintNothe earliest time in ms to fetch orders for
limitintNothe maximum number of order structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
params.triggerbooleanNoset to true for fetching trigger orders
params.marginModestringNo'cross' or 'isolated' for fetching spot margin orders
coinex.fetchOrdersByStatus (status, symbol, since?, limit?, params?)

fetchOpenOrders

fetch all unfilled currently open orders

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

See

ParamTypeRequiredDescription
symbolstringYesunified market symbol
sinceintNothe earliest time in ms to fetch open orders for
limitintNothe maximum number of open order structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
params.triggerbooleanNoset to true for fetching trigger orders
params.marginModestringNo'cross' or 'isolated' for fetching spot margin orders
coinex.fetchOpenOrders (symbol, since?, limit?, params?)

fetchClosedOrders

fetches information on multiple closed orders made by the user

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

See

ParamTypeRequiredDescription
symbolstringYesunified market symbol of the market orders were made in
sinceintNothe earliest time in ms to fetch orders for
limitintNothe maximum number of order structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
params.triggerbooleanNoset to true for fetching trigger orders
params.marginModestringNo'cross' or 'isolated' for fetching spot margin orders
coinex.fetchClosedOrders (symbol, since?, limit?, params?)

createDepositAddress

create a currency deposit address

Kind: instance method of coinex
Returns: object - an address structure

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/update-deposit-address

ParamTypeRequiredDescription
codestringYesunified currency code of the currency for the deposit address
paramsobjectNoextra parameters specific to the exchange API endpoint
params.networkstringNothe blockchain network to create a deposit address on
coinex.createDepositAddress (code, params?)

fetchDepositAddress

fetch the deposit address for a currency associated with this account

Kind: instance method of coinex
Returns: object - an address structure

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/get-deposit-address

ParamTypeRequiredDescription
codestringYesunified currency code
paramsobjectNoextra parameters specific to the exchange API endpoint
params.networkstringNothe blockchain network to create a deposit address on
coinex.fetchDepositAddress (code, params?)

fetchMyTrades

fetch all trades made by the user

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

See

ParamTypeRequiredDescription
symbolstringYesunified market symbol
sinceintNothe earliest time in ms to fetch trades for
limitintNothe maximum number of trade structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
params.untilintNotimestamp in ms of the latest trades
params.sidestringNothe side of the trades, either 'buy' or 'sell', required for swap
coinex.fetchMyTrades (symbol, since?, limit?, params?)

fetchPositions

fetch all open positions

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

See

ParamTypeRequiredDescription
symbolsArray<string>Nolist of unified market symbols
paramsobjectNoextra parameters specific to the exchange API endpoint
params.methodstringNothe method to use 'v2PrivateGetFuturesPendingPosition' or 'v2PrivateGetFuturesFinishedPosition' default is 'v2PrivateGetFuturesPendingPosition'
coinex.fetchPositions (symbols?, params?)

fetchPosition

fetch data on a single open contract trade position

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

See: https://docs.coinex.com/api/v2/futures/position/http/list-pending-position

ParamTypeRequiredDescription
symbolstringYesunified market symbol of the market the position is held in
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchPosition (symbol, params?)

setMarginMode

set margin mode to 'cross' or 'isolated'

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

See: https://docs.coinex.com/api/v2/futures/position/http/adjust-position-leverage

ParamTypeRequiredDescription
marginModestringYes'cross' or 'isolated'
symbolstringYesunified market symbol
paramsobjectNoextra parameters specific to the exchange API endpoint
params.leverageintYesthe rate of leverage
coinex.setMarginMode (marginMode, symbol, params?)

setLeverage

set the level of leverage for a market

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

See: https://docs.coinex.com/api/v2/futures/position/http/adjust-position-leverage

ParamTypeRequiredDescription
leveragefloatYesthe rate of leverage
symbolstringYesunified market symbol
paramsobjectNoextra parameters specific to the exchange API endpoint
params.marginModestringNo'cross' or 'isolated' (default is 'cross')
coinex.setLeverage (leverage, symbol, params?)

fetchLeverageTiers

retrieve information on the maximum leverage, and maintenance margin for trades of varying trade sizes

Kind: instance method of coinex
Returns: object - a dictionary of leverage tiers structures, indexed by market symbols

See: https://docs.coinex.com/api/v2/futures/market/http/list-market-position-level

ParamTypeRequiredDescription
symbolsArray<string>, undefinedYeslist of unified market symbols
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchLeverageTiers (symbols, params?)

addMargin

add margin

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

See: https://docs.coinex.com/api/v2/futures/position/http/adjust-position-margin

ParamTypeRequiredDescription
symbolstringYesunified market symbol
amountfloatYesamount of margin to add
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.addMargin (symbol, amount, params?)

reduceMargin

remove margin from a position

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

See: https://docs.coinex.com/api/v2/futures/position/http/adjust-position-margin

ParamTypeRequiredDescription
symbolstringYesunified market symbol
amountfloatYesthe amount of margin to remove
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.reduceMargin (symbol, amount, params?)

fetchFundingHistory

fetch the history of funding fee payments paid and received on this account

Kind: instance method of coinex
Returns: object - a funding history structure

See: https://docs.coinex.com/api/v2/futures/position/http/list-position-funding-history

ParamTypeRequiredDescription
symbolstringYesunified market symbol
sinceintNothe earliest time in ms to fetch funding history for
limitintNothe maximum number of funding history structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchFundingHistory (symbol, since?, limit?, params?)

fetchFundingRate

fetch the current funding rate

Kind: instance method of coinex
Returns: object - a funding rate structure

See: https://docs.coinex.com/api/v2/futures/market/http/list-market-funding-rate

ParamTypeRequiredDescription
symbolstringYesunified market symbol
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchFundingRate (symbol, params?)

fetchFundingInterval

fetch the current funding rate interval

Kind: instance method of coinex
Returns: object - a funding rate structure

See: https://docs.coinex.com/api/v2/futures/market/http/list-market-funding-rate

ParamTypeRequiredDescription
symbolstringYesunified market symbol
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchFundingInterval (symbol, params?)

fetchFundingRates

fetch the current funding rates for multiple markets

Kind: instance method of coinex
Returns: Array<object> - an array of funding rate structures

See: https://docs.coinex.com/api/v2/futures/market/http/list-market-funding-rate

ParamTypeRequiredDescription
symbolsArray<string>Yesunified market symbols
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchFundingRates (symbols, params?)

withdraw

make a withdrawal

Kind: instance method of coinex
Returns: object - a transaction structure

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/withdrawal

ParamTypeRequiredDescription
codestringYesunified currency code
amountfloatYesthe amount to withdraw
addressstringYesthe address to withdraw to
tagstringNomemo
paramsobjectNoextra parameters specific to the exchange API endpoint
params.networkstringNounified network code
coinex.withdraw (code, amount, address, tag?, params?)

fetchFundingRateHistory

fetches historical funding rate prices

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

See: https://docs.coinex.com/api/v2/futures/market/http/list-market-funding-rate-history

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch the funding rate history for
sinceintNotimestamp in ms of the earliest funding rate to fetch
limitintNothe maximum amount of funding rate structures to fetch
paramsobjectNoextra parameters specific to the exchange API endpoint
params.paginatebooleanNodefault false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the available parameters
params.untilintNotimestamp in ms of the latest funding rate
coinex.fetchFundingRateHistory (symbol, since?, limit?, params?)

transfer

transfer currency internally between wallets on the same account

Kind: instance method of coinex
Returns: object - a transfer structure

See: https://docs.coinex.com/api/v2/assets/transfer/http/transfer

ParamTypeRequiredDescription
codestringYesunified currency code
amountfloatYesamount to transfer
fromAccountstringYesaccount to transfer from
toAccountstringYesaccount to transfer to
paramsobjectNoextra parameters specific to the exchange API endpoint
params.symbolstringNounified ccxt symbol, required when either the fromAccount or toAccount is margin
coinex.transfer (code, amount, fromAccount, toAccount, params?)

fetchTransfers

fetch a history of internal transfers made on an account

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

See: https://docs.coinex.com/api/v2/assets/transfer/http/list-transfer-history

ParamTypeRequiredDescription
codestringYesunified currency code of the currency transferred
sinceintNothe earliest time in ms to fetch transfers for
limitintNothe maximum number of transfer structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
params.marginModestringNo'cross' or 'isolated' for fetching transfers to and from your margin account
coinex.fetchTransfers (code, since?, limit?, params?)

fetchWithdrawals

fetch all withdrawals made from an account

Kind: instance method of coinex
Returns: Array<object> - a list of transaction structures

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/list-withdrawal-history

ParamTypeRequiredDescription
codestringNounified currency code
sinceintNothe earliest time in ms to fetch withdrawals for
limitintNothe maximum number of withdrawal structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchWithdrawals (code?, since?, limit?, params?)

fetchDeposits

fetch all deposits made to an account

Kind: instance method of coinex
Returns: Array<object> - a list of transaction structures

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/list-deposit-history

ParamTypeRequiredDescription
codestringNounified currency code
sinceintNothe earliest time in ms to fetch deposits for
limitintNothe maximum number of deposit structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchDeposits (code?, since?, limit?, params?)

fetchIsolatedBorrowRate

fetch the rate of interest to borrow a currency for margin trading

Kind: instance method of coinex
Returns: object - an isolated borrow rate structure

See: https://docs.coinex.com/api/v2/assets/loan-flat/http/list-margin-interest-limit

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch the borrow rate for
paramsobjectNoextra parameters specific to the exchange API endpoint
params.codestringYesunified currency code
coinex.fetchIsolatedBorrowRate (symbol, params?)

fetchBorrowInterest

fetch the interest owed by the user for borrowing currency for margin trading

Kind: instance method of coinex
Returns: Array<object> - a list of borrow interest structures

See: https://docs.coinex.com/api/v2/assets/loan-flat/http/list-margin-borrow-history

ParamTypeRequiredDescription
codestringNounified currency code
symbolstringNounified market symbol when fetch interest in isolated markets
sinceintNothe earliest time in ms to fetch borrrow interest for
limitintNothe maximum number of structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchBorrowInterest (code?, symbol?, since?, limit?, params?)

borrowIsolatedMargin

create a loan to borrow margin

Kind: instance method of coinex
Returns: object - a margin loan structure

See: https://docs.coinex.com/api/v2/assets/loan-flat/http/margin-borrow

ParamTypeRequiredDescription
symbolstringYesunified market symbol, required for coinex
codestringYesunified currency code of the currency to borrow
amountfloatYesthe amount to borrow
paramsobjectNoextra parameters specific to the exchange API endpoint
params.isAutoRenewbooleanNowhether to renew the margin loan automatically or not, default is false
coinex.borrowIsolatedMargin (symbol, code, amount, params?)

repayIsolatedMargin

repay borrowed margin and interest

Kind: instance method of coinex
Returns: object - a margin loan structure

See: https://docs.coinex.com/api/v2/assets/loan-flat/http/margin-repay

ParamTypeRequiredDescription
symbolstringYesunified market symbol, required for coinex
codestringYesunified currency code of the currency to repay
amountfloatYesthe amount to repay
paramsobjectNoextra parameters specific to the exchange API endpoint
params.borrow_idstringNoextra parameter that is not required
coinex.repayIsolatedMargin (symbol, code, amount, params?)

fetchDepositWithdrawFee

fetch the fee for deposits and withdrawals

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

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/get-deposit-withdrawal-config

ParamTypeRequiredDescription
codestringYesunified currency code
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchDepositWithdrawFee (code, params?)

fetchDepositWithdrawFees

fetch the fees for deposits and withdrawals

Kind: instance method of coinex
Returns: object - a dictionary of fee structures

See: https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/list-all-deposit-withdrawal-config

ParamTypeRequiredDescription
codesArray<string>Nolist of unified currency codes
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.fetchDepositWithdrawFees (codes?, params?)

fetchLeverage

fetch the set leverage for a market

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

See: https://docs.coinex.com/api/v2/assets/loan-flat/http/list-margin-interest-limit

ParamTypeRequiredDescription
symbolstringYesunified market symbol
paramsobjectNoextra parameters specific to the exchange API endpoint
params.codestringYesunified currency code
coinex.fetchLeverage (symbol, params?)

fetchPositionHistory

fetches historical positions

Kind: instance method of coinex
Returns: Array<object> - a list of position structures

See: https://docs.coinex.com/api/v2/futures/position/http/list-finished-position

ParamTypeRequiredDescription
symbolstringYesunified contract symbol
sinceintNothe earliest time in ms to fetch positions for
limitintNothe maximum amount of records to fetch, default is 10
paramsobjectNoextra parameters specific to the exchange api endpoint
params.untilintNothe latest time in ms to fetch positions for
coinex.fetchPositionHistory (symbol, since?, limit?, params?)

closePosition

closes an open position for a market

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

See: https://docs.coinex.com/api/v2/futures/position/http/close-position

ParamTypeRequiredDescription
symbolstringYesunified CCXT market symbol
sidestringNobuy or sell, not used by coinex
paramsobjectNoextra parameters specific to the exchange API endpoint
params.typestringYesrequired by coinex, one of: limit, market, maker_only, ioc or fok, default is market
params.pricestringNothe price to fulfill the order, ignored in market orders
params.amountstringNothe amount to trade in units of the base currency
params.clientOrderIdstringNothe client id of the order
coinex.closePosition (symbol, side?, params?)

fetchMarginAdjustmentHistory

fetches the history of margin added or reduced from contract isolated positions

Kind: instance method of coinex
Returns: Array<object> - a list of margin structures

See: https://docs.coinex.com/api/v2/futures/position/http/list-position-margin-history

ParamTypeRequiredDescription
symbolstringYesunified market symbol
typestringNonot used by coinex fetchMarginAdjustmentHistory
sinceintNotimestamp in ms of the earliest change to fetch
limitintNothe maximum amount of changes to fetch, default is 10
paramsobjectYesextra parameters specific to the exchange api endpoint
params.untilintNotimestamp in ms of the latest change to fetch
params.positionIdintNothe id of the position that you want to retrieve margin adjustment history for
coinex.fetchMarginAdjustmentHistory (symbol, type?, since?, limit?, params)

watchBalance

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

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

See

ParamTypeRequiredDescription
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchBalance (params?)

watchMyTrades

watches information on multiple trades made by the user

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

See

ParamTypeRequiredDescription
symbolstringNounified symbol of the market the trades were made in
sinceintNothe earliest time in ms to watch trades
limitintNothe maximum number of trade structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchMyTrades (symbol?, since?, limit?, params?)

watchTicker

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

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch the ticker for
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchTicker (symbol, params?)

watchTickers

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 coinex
Returns: object - a dictionary of ticker structures

See

ParamTypeRequiredDescription
symbolsArray<string>Yesunified symbol of the market to fetch the ticker for
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchTickers (symbols, params?)

watchTrades

get the list of most recent trades for a particular symbol

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch trades for
sinceintNotimestamp in ms of the earliest trade to fetch
limitintNothe maximum amount of trades to fetch
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchTrades (symbol, since?, limit?, params?)

watchTradesForSymbols

watch the most recent trades for a list of symbols

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

See

ParamTypeRequiredDescription
symbolsArray<string>Yesunified symbols of the markets to fetch trades for
sinceintNotimestamp in ms of the earliest trade to fetch
limitintNothe maximum amount of trades to fetch
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchTradesForSymbols (symbols, since?, limit?, params?)

watchOrderBookForSymbols

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

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

See

ParamTypeRequiredDescription
symbolsArray<string>Yesunified array of symbols
limitintNothe maximum amount of order book entries to return
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchOrderBookForSymbols (symbols, limit?, params?)

watchOrderBook

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

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

See

ParamTypeRequiredDescription
symbolstringYesunified symbol of the market to fetch the order book for
limitintNothe maximum amount of order book entries to return
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchOrderBook (symbol, limit?, params?)

watchOrders

watches information on multiple orders made by the user

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

See

ParamTypeRequiredDescription
symbolstringYesunified market symbol of the market orders were made in
sinceintNothe earliest time in ms to fetch orders for
limitintNothe maximum number of order structures to retrieve
paramsobjectNoextra parameters specific to the exchange API endpoint
params.triggerboolNoif the orders to watch are trigger orders or not
coinex.watchOrders (symbol, since?, limit?, params?)

watchBidsAsks

watches best bid & ask for symbols

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

See

ParamTypeRequiredDescription
symbolsArray<string>Nounified symbol of the market to fetch the ticker for
paramsobjectNoextra parameters specific to the exchange API endpoint
coinex.watchBidsAsks (symbols?, params?)

On this page