UNPKG

ccxt

Version:

A JavaScript / TypeScript / Python / C# / PHP cryptocurrency trading library with support for 100+ exchanges

60 lines (59 loc) 3.91 kB
import bithumbRest from '../bithumb.js'; import type { Int, OrderBook, Ticker, Trade, Strings, Tickers } from '../base/types.js'; import Client from '../base/ws/Client.js'; export default class bithumb extends bithumbRest { describe(): any; /** * @method * @name bithumb#watchTicker * @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market * @see https://apidocs.bithumb.com/v1.2.0/reference/%EB%B9%97%EC%8D%B8-%EA%B1%B0%EB%9E%98%EC%86%8C-%EC%A0%95%EB%B3%B4-%EC%88%98%EC%8B%A0 * @param {string} symbol unified symbol of the market to fetch the ticker for * @param {object} [params] extra parameters specific to the exchange API endpoint * @param {string} [params.channel] the channel to subscribe to, tickers by default. Can be tickers, sprd-tickers, index-tickers, block-tickers * @returns {object} a [ticker structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#ticker-structure} */ watchTicker(symbol: string, params?: {}): Promise<Ticker>; /** * @method * @name bithumb#watchTickers * @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for all markets of a specific list * @see https://apidocs.bithumb.com/v1.2.0/reference/%EB%B9%97%EC%8D%B8-%EA%B1%B0%EB%9E%98%EC%86%8C-%EC%A0%95%EB%B3%B4-%EC%88%98%EC%8B%A0 * @param {string[]} symbols unified symbol of the market to fetch the ticker for * @param {object} [params] extra parameters specific to the exchange API endpoint * @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure} */ watchTickers(symbols?: Strings, params?: {}): Promise<Tickers>; handleTicker(client: Client, message: any): void; parseWsTicker(ticker: any, market?: any): Ticker; /** * @method * @name bithumb#watchOrderBook * @see https://apidocs.bithumb.com/v1.2.0/reference/%EB%B9%97%EC%8D%B8-%EA%B1%B0%EB%9E%98%EC%86%8C-%EC%A0%95%EB%B3%B4-%EC%88%98%EC%8B%A0 * @description watches information on open orders with bid (buy) and ask (sell) prices, volumes and other data * @param {string} symbol unified symbol of the market to fetch the order book for * @param {int} [limit] the maximum amount of order book entries to return * @param {object} [params] extra parameters specific to the exchange API endpoint * @returns {object} A dictionary of [order book structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-book-structure} indexed by market symbols */ watchOrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>; handleOrderBook(client: Client, message: any): void; handleDelta(orderbook: any, delta: any): void; handleDeltas(orderbook: any, deltas: any): void; /** * @method * @name bithumb#watchTrades * @description get the list of most recent trades for a particular symbol * @see https://apidocs.bithumb.com/v1.2.0/reference/%EB%B9%97%EC%8D%B8-%EA%B1%B0%EB%9E%98%EC%86%8C-%EC%A0%95%EB%B3%B4-%EC%88%98%EC%8B%A0 * @param {string} symbol unified symbol of the market to fetch trades for * @param {int} [since] timestamp in ms of the earliest trade to fetch * @param {int} [limit] the maximum amount of trades to fetch * @param {object} [params] extra parameters specific to the exchange API endpoint * @returns {object[]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#public-trades} */ watchTrades(symbol: string, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>; handleTrades(client: any, message: any): void; parseWsTrade(trade: any, market?: any): Trade; handleErrorMessage(client: Client, message: any): boolean; handleMessage(client: Client, message: any): void; }