ccxt 4.5.1 → 4.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +110 -112
- package/dist/ccxt.browser.min.js +3 -3
- package/dist/cjs/ccxt.js +1 -9
- package/dist/cjs/src/ascendex.js +1 -1
- package/dist/cjs/src/binance.js +20 -14
- package/dist/cjs/src/bitget.js +1 -1
- package/dist/cjs/src/indodax.js +11 -12
- package/dist/cjs/src/okx.js +2 -2
- package/dist/cjs/src/poloniex.js +1 -1
- package/dist/cjs/src/pro/bitget.js +161 -26
- package/dist/cjs/src/pro/bitmart.js +1 -1
- package/dist/cjs/src/pro/gemini.js +7 -2
- package/dist/cjs/src/pro/hyperliquid.js +5 -0
- package/dist/cjs/src/pro/kraken.js +4 -6
- package/dist/cjs/src/zonda.js +12 -0
- package/js/ccxt.d.ts +2 -11
- package/js/ccxt.js +2 -8
- package/js/src/ascendex.js +1 -1
- package/js/src/binance.d.ts +1 -1
- package/js/src/binance.js +20 -14
- package/js/src/bitget.js +1 -1
- package/js/src/indodax.js +11 -12
- package/js/src/okx.js +2 -2
- package/js/src/poloniex.js +1 -1
- package/js/src/pro/bitget.d.ts +4 -0
- package/js/src/pro/bitget.js +167 -26
- package/js/src/pro/bitmart.js +1 -1
- package/js/src/pro/gemini.d.ts +1 -1
- package/js/src/pro/gemini.js +7 -2
- package/js/src/pro/hyperliquid.js +5 -0
- package/js/src/pro/kraken.js +4 -6
- package/js/src/zonda.js +12 -0
- package/package.json +2 -1
- package/js/src/abstract/ellipx.d.ts +0 -28
- package/js/src/abstract/ellipx.js +0 -11
- package/js/src/abstract/vertex.d.ts +0 -22
- package/js/src/abstract/vertex.js +0 -11
- package/js/src/ellipx.d.ts +0 -237
- package/js/src/ellipx.js +0 -2071
- package/js/src/pro/vertex.d.ts +0 -104
- package/js/src/pro/vertex.js +0 -999
- package/js/src/vertex.d.ts +0 -346
- package/js/src/vertex.js +0 -3146
package/js/src/ellipx.d.ts
DELETED
|
@@ -1,237 +0,0 @@
|
|
|
1
|
-
import Exchange from './abstract/ellipx.js';
|
|
2
|
-
import { Str, Int, int, Dict, Num, Market, Ticker, OrderBook, OHLCV, Currencies, Trade, Balances, OrderType, OrderSide, Order, DepositAddress, TradingFeeInterface, Transaction } from './base/types.js';
|
|
3
|
-
/**
|
|
4
|
-
* @class ellipx
|
|
5
|
-
* @augments Exchange
|
|
6
|
-
*/
|
|
7
|
-
export default class ellipx extends Exchange {
|
|
8
|
-
describe(): any;
|
|
9
|
-
sign(path: any, api?: string, method?: string, params?: {}, headers?: any, body?: any): {
|
|
10
|
-
url: string;
|
|
11
|
-
method: string;
|
|
12
|
-
body: any;
|
|
13
|
-
headers: any;
|
|
14
|
-
};
|
|
15
|
-
calculateMod(a: any, b: any): number;
|
|
16
|
-
/**
|
|
17
|
-
* @method
|
|
18
|
-
* @name ellipx#fetchMarkets
|
|
19
|
-
* @description Fetches market information from the exchange.
|
|
20
|
-
* @see https://docs.ccxt.com/en/latest/manual.html#markets
|
|
21
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.1a1t05wpgfof
|
|
22
|
-
* @param {object} [params] - Extra parameters specific to the exchange API endpoint
|
|
23
|
-
* @returns {Promise<Market[]>} An array of market structures.
|
|
24
|
-
*/
|
|
25
|
-
fetchMarkets(params?: {}): Promise<Market[]>;
|
|
26
|
-
parseMarket(market: Dict): Market;
|
|
27
|
-
/**
|
|
28
|
-
* @method
|
|
29
|
-
* @name ellipx#fetchTicker
|
|
30
|
-
* @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
31
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.d2jylz4u6pmu
|
|
32
|
-
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
33
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
34
|
-
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
35
|
-
*/
|
|
36
|
-
fetchTicker(symbol: string, params?: {}): Promise<Ticker>;
|
|
37
|
-
parseTicker(ticker: Dict, market?: Market): Ticker;
|
|
38
|
-
/**
|
|
39
|
-
* @method
|
|
40
|
-
* @name ellipx#fetchOrderBook
|
|
41
|
-
* @description fetches information on open orders with bid (buy) and ask (sell) prices, volumes and other data
|
|
42
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.bqmucewhkpdz
|
|
43
|
-
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
44
|
-
* @param {int} [limit] the maximum amount of order book entries to return the exchange not supported yet.
|
|
45
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
46
|
-
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
47
|
-
*/
|
|
48
|
-
fetchOrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
|
|
49
|
-
/**
|
|
50
|
-
* @method
|
|
51
|
-
* @name ellipx#fetchOHLCV
|
|
52
|
-
* @description fetches historical candlestick data containing the open, high, low, and close price, and the volume of a market, default will return the last 24h period.
|
|
53
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.w65baeuhxwt8
|
|
54
|
-
* @param {string} symbol unified symbol of the market to fetch OHLCV data for
|
|
55
|
-
* @param {string} timeframe the length of time each candle represents
|
|
56
|
-
* @param {int} [since] timestamp in ms of the earliest candle to fetch
|
|
57
|
-
* @param {int} [limit] the maximum amount of candles to fetch
|
|
58
|
-
* @param {object} [params] extra parameters specific to the API endpoint
|
|
59
|
-
* @param {int} [params.until] timestamp in ms of the earliest candle to fetch
|
|
60
|
-
* @returns {OHLCV[]} A list of candles ordered as timestamp, open, high, low, close, volume
|
|
61
|
-
*/
|
|
62
|
-
fetchOHLCV(symbol: string, timeframe?: string, since?: Int, limit?: Int, params?: {}): Promise<OHLCV[]>;
|
|
63
|
-
parseOHLCV(ohlcv: any, market?: Market): OHLCV;
|
|
64
|
-
/**
|
|
65
|
-
* @method
|
|
66
|
-
* @name ellipx#fetchCurrencies
|
|
67
|
-
* @description fetches information on all currencies from the exchange, including deposit/withdrawal details and available chains
|
|
68
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.x65f9s9j74jf
|
|
69
|
-
* @param {object} [params] extra parameters specific to the ellipx API endpoint
|
|
70
|
-
* @param {string} [params.Can_Deposit] filter currencies by deposit availability, Y for available
|
|
71
|
-
* @param {number} [params.results_per_page] number of results per page, default 100
|
|
72
|
-
* @param {string} [params._expand] additional fields to expand in response, default '/Crypto_Token,/Crypto_Chain'
|
|
73
|
-
* @returns {Promise<Currencies>} An object of currency structures indexed by currency codes
|
|
74
|
-
*/
|
|
75
|
-
fetchCurrencies(params?: {}): Promise<Currencies>;
|
|
76
|
-
/**
|
|
77
|
-
* @method
|
|
78
|
-
* @name ellipx#fetchTrades
|
|
79
|
-
* @description fetches all completed trades for a particular market/symbol
|
|
80
|
-
* @param {string} symbol unified market symbol (e.g. 'BTC/USDT')
|
|
81
|
-
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
82
|
-
* @param {int} [limit] the maximum amount of trades to fetch
|
|
83
|
-
* @param {object} [params] extra parameters specific to the EllipX API endpoint
|
|
84
|
-
* @param {string} [params.before] get trades before the given trade ID
|
|
85
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
|
|
86
|
-
*/
|
|
87
|
-
fetchTrades(symbol: string, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
|
|
88
|
-
parseTrade(trade: any, market?: any): Trade;
|
|
89
|
-
/**
|
|
90
|
-
* @method
|
|
91
|
-
* @name ellipx#fetchBalance
|
|
92
|
-
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
93
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.ihrjov144txg
|
|
94
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
95
|
-
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
96
|
-
*/
|
|
97
|
-
fetchBalance(params?: {}): Promise<Balances>;
|
|
98
|
-
/**
|
|
99
|
-
* @method
|
|
100
|
-
* @name ellipx#createOrder
|
|
101
|
-
* @description create a new order in a market
|
|
102
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.yzfak2n2bwpo
|
|
103
|
-
* @param {string} symbol unified market symbol (e.g. 'BTC/USDT')
|
|
104
|
-
* @param {string} type order type - the exchange automatically sets type to 'limit' if price defined, 'market' if undefined
|
|
105
|
-
* @param {string} side 'buy' or 'sell'
|
|
106
|
-
* @param {float} [amount] amount of base currency to trade (can be undefined if using Spend_Limit)
|
|
107
|
-
* @param {float} [price] price per unit of base currency for limit orders
|
|
108
|
-
* @param {object} [params] extra parameters specific to the EllipX API endpoint
|
|
109
|
-
* @param {float} [params.cost] maximum amount to spend in quote currency (required for market orders if amount undefined)
|
|
110
|
-
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
111
|
-
*/
|
|
112
|
-
createOrder(symbol: string, type: OrderType, side: OrderSide, amount: number, price?: Num, params?: {}): Promise<Order>;
|
|
113
|
-
/**
|
|
114
|
-
* @method
|
|
115
|
-
* @name ellipx#fetchOrder
|
|
116
|
-
* @description fetches information on an order made by the user
|
|
117
|
-
* @param {string} id the order ID as returned by createOrder or fetchOrders
|
|
118
|
-
* @param {string|undefined} symbol not used by ellipx.fetchOrder
|
|
119
|
-
* @param {object} [params] extra parameters specific to the EllipX API endpoint
|
|
120
|
-
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
121
|
-
*/
|
|
122
|
-
fetchOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
|
|
123
|
-
/**
|
|
124
|
-
* @method
|
|
125
|
-
* @name ellipx#fetchOrdersByStatus
|
|
126
|
-
* @description fetches a list of orders placed on the exchange
|
|
127
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.5z2nh2b5s81n
|
|
128
|
-
* @param {string} status 'open' or 'closed', omit for all orders
|
|
129
|
-
* @param {string} symbol unified market symbol
|
|
130
|
-
* @param {int} [since] timestamp in ms of the earliest order
|
|
131
|
-
* @param {int} [limit] the maximum amount of orders to fetch
|
|
132
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
133
|
-
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
134
|
-
*/
|
|
135
|
-
fetchOrdersByStatus(status: any, symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
|
|
136
|
-
/**
|
|
137
|
-
* @method
|
|
138
|
-
* @name ellipx#fetchOrders
|
|
139
|
-
* @description fetches information on multiple orders made by the user
|
|
140
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.5z2nh2b5s81n
|
|
141
|
-
* @param {string} symbol unified market symbol of the market orders were made in
|
|
142
|
-
* @param {int|undefined} since timestamp in ms of the earliest order
|
|
143
|
-
* @param {int|undefined} limit the maximum amount of orders to fetch
|
|
144
|
-
* @param {object} params extra parameters specific to the exchange API endpoint
|
|
145
|
-
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
146
|
-
*/
|
|
147
|
-
fetchOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
|
|
148
|
-
/**
|
|
149
|
-
* @method
|
|
150
|
-
* @name ellipx#fetchOpenOrders
|
|
151
|
-
* @description fetches information on open orders made by the user
|
|
152
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.5z2nh2b5s81n
|
|
153
|
-
* @param {string} symbol unified market symbol of the market orders were made in
|
|
154
|
-
* @param {int|undefined} since timestamp in ms of the earliest order
|
|
155
|
-
* @param {int|undefined} limit the maximum amount of orders to fetch
|
|
156
|
-
* @param {object} params extra parameters specific to the exchange API endpoint
|
|
157
|
-
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
158
|
-
*/
|
|
159
|
-
fetchOpenOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
|
|
160
|
-
parseOrder(order: any, market?: any): Order;
|
|
161
|
-
/**
|
|
162
|
-
* @method
|
|
163
|
-
* @name ellipx#cancelOrder
|
|
164
|
-
* @description Cancels an open order on the exchange
|
|
165
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.f1qu1pb1rebn
|
|
166
|
-
* @param {string} id - The order ID to cancel (format: mktor-xxxxx-xxxx-xxxx-xxxx-xxxxxxxx)
|
|
167
|
-
* @param {string} [symbol] - ellipx.cancelOrder does not use the symbol parameter
|
|
168
|
-
* @param {object} [params] - Extra parameters specific to the exchange API
|
|
169
|
-
* @returns {Promise<object>} A Promise that resolves to the canceled order info
|
|
170
|
-
*/
|
|
171
|
-
cancelOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
|
|
172
|
-
/**
|
|
173
|
-
* @method
|
|
174
|
-
* @name ellipx#fetchOrderTrades
|
|
175
|
-
* @description fetch all the trades made from a single order
|
|
176
|
-
* @param {string} id order id
|
|
177
|
-
* @param {string} symbol unified market symbol
|
|
178
|
-
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
179
|
-
* @param {int} [limit] the maximum number of trades to retrieve
|
|
180
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
181
|
-
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
|
|
182
|
-
*/
|
|
183
|
-
fetchOrderTrades(id: string, symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
|
|
184
|
-
/**
|
|
185
|
-
* @method
|
|
186
|
-
* @name ellipx#fetchDepositAddress
|
|
187
|
-
* @description fetches a crypto deposit address for a specific currency
|
|
188
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.k7qe5aricayh
|
|
189
|
-
* @param {string} code unified currency code (e.g. "BTC", "ETH", "USDT")
|
|
190
|
-
* @param {object} [params] extra parameters specific to the EllipX API endpoint
|
|
191
|
-
* @returns {object} an address structure {
|
|
192
|
-
* 'currency': string, // unified currency code
|
|
193
|
-
* 'address': string, // the address for deposits
|
|
194
|
-
* 'tag': string|undefined, // tag/memo for deposits if needed
|
|
195
|
-
* 'network': object, // network object from currency info
|
|
196
|
-
* 'info': object // raw response from exchange
|
|
197
|
-
* }
|
|
198
|
-
* @throws {ExchangeError} if currency does not support deposits
|
|
199
|
-
*/
|
|
200
|
-
fetchDepositAddress(code: string, params?: {}): Promise<DepositAddress>;
|
|
201
|
-
/**
|
|
202
|
-
* @method
|
|
203
|
-
* @name ellipx#fetchTradingFee
|
|
204
|
-
* @description Fetches the current trading fees (maker and taker) applicable to the user.
|
|
205
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.kki5jay2c8it
|
|
206
|
-
* @param {string} [symbol] Not used by EllipX as fees are not symbol-specific.
|
|
207
|
-
* @param {object} [params] Extra parameters specific to the EllipX API endpoint.
|
|
208
|
-
* @returns {Promise<object>} A promise resolving to a unified trading fee structure:
|
|
209
|
-
* {
|
|
210
|
-
* 'info': object, // the raw response from the exchange
|
|
211
|
-
* 'symbol': undefined, // symbol is not used for this exchange
|
|
212
|
-
* 'maker': number, // maker fee rate in decimal form
|
|
213
|
-
* 'taker': number, // taker fee rate in decimal form
|
|
214
|
-
* 'percentage': true, // indicates fees are in percentage
|
|
215
|
-
* 'tierBased': false, // indicates fees do not vary by volume tiers
|
|
216
|
-
* }
|
|
217
|
-
*/
|
|
218
|
-
fetchTradingFee(symbol: string, params?: {}): Promise<TradingFeeInterface>;
|
|
219
|
-
/**
|
|
220
|
-
* @method
|
|
221
|
-
* @name ellipx#withdraw
|
|
222
|
-
* @description Make a withdrawal request
|
|
223
|
-
* @see https://docs.google.com/document/d/1ZXzTQYffKE_EglTaKptxGQERRnunuLHEMmar7VC9syM/edit?tab=t.0#heading=h.zegupoa8g4t9
|
|
224
|
-
* @param {string} code unified currency code
|
|
225
|
-
* @param {number} amount Amount to withdraw
|
|
226
|
-
* @param {string} address Destination wallet address
|
|
227
|
-
* @param {string} [tag] Additional tag/memo for currencies that require it
|
|
228
|
-
* @param {object} params Extra parameters specific to the EllipX API endpoint (Crypto_Chain__, Unit__)
|
|
229
|
-
* @returns {object} a [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
|
|
230
|
-
*/
|
|
231
|
-
withdraw(code: string, amount: number, address: string, tag?: Str, params?: {}): Promise<Transaction>;
|
|
232
|
-
parseTransactionStatus(status: string): string;
|
|
233
|
-
parseOrderStatus(status: any): string;
|
|
234
|
-
parseAmount(amount: any): Str;
|
|
235
|
-
toAmount(amount: number, precision: number): Dict;
|
|
236
|
-
handleErrors(code: int, reason: string, url: string, method: string, headers: Dict, body: string, response: any, requestHeaders: any, requestBody: any): any;
|
|
237
|
-
}
|