ccxt 4.4.64 → 4.4.65

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.
@@ -1,71 +0,0 @@
1
- import { implicitReturnType } from '../base/types.js';
2
- import { Exchange as _Exchange } from '../base/Exchange.js';
3
- interface Exchange {
4
- publicGetV1Time(params?: {}): Promise<implicitReturnType>;
5
- publicGetV1ExchangeInfo(params?: {}): Promise<implicitReturnType>;
6
- publicGetV1Depth(params?: {}): Promise<implicitReturnType>;
7
- publicGetV1AggTrades(params?: {}): Promise<implicitReturnType>;
8
- publicGetV1Klines(params?: {}): Promise<implicitReturnType>;
9
- publicGetV1Ticker24hr(params?: {}): Promise<implicitReturnType>;
10
- publicGetV2Time(params?: {}): Promise<implicitReturnType>;
11
- publicGetV2ExchangeInfo(params?: {}): Promise<implicitReturnType>;
12
- publicGetV2Depth(params?: {}): Promise<implicitReturnType>;
13
- publicGetV2AggTrades(params?: {}): Promise<implicitReturnType>;
14
- publicGetV2Klines(params?: {}): Promise<implicitReturnType>;
15
- publicGetV2Ticker24hr(params?: {}): Promise<implicitReturnType>;
16
- marketcapGetV1Assets(params?: {}): Promise<implicitReturnType>;
17
- marketcapGetV1Candles(params?: {}): Promise<implicitReturnType>;
18
- marketcapGetV1Orderbook(params?: {}): Promise<implicitReturnType>;
19
- marketcapGetV1Summary(params?: {}): Promise<implicitReturnType>;
20
- marketcapGetV1Ticker(params?: {}): Promise<implicitReturnType>;
21
- marketcapGetV1TokenAssets(params?: {}): Promise<implicitReturnType>;
22
- marketcapGetV1TokenOrderbook(params?: {}): Promise<implicitReturnType>;
23
- marketcapGetV1TokenSummary(params?: {}): Promise<implicitReturnType>;
24
- marketcapGetV1TokenTicker(params?: {}): Promise<implicitReturnType>;
25
- marketcapGetV1TokenTrades(params?: {}): Promise<implicitReturnType>;
26
- marketcapGetV1TokenCryptoOHLC(params?: {}): Promise<implicitReturnType>;
27
- marketcapGetV1TokenCryptoAssets(params?: {}): Promise<implicitReturnType>;
28
- marketcapGetV1TokenCryptoOrderbook(params?: {}): Promise<implicitReturnType>;
29
- marketcapGetV1TokenCryptoSummary(params?: {}): Promise<implicitReturnType>;
30
- marketcapGetV1TokenCryptoTicker(params?: {}): Promise<implicitReturnType>;
31
- marketcapGetV1TokenCryptoTrades(params?: {}): Promise<implicitReturnType>;
32
- marketcapGetV1Trades(params?: {}): Promise<implicitReturnType>;
33
- privateGetV1Account(params?: {}): Promise<implicitReturnType>;
34
- privateGetV1Currencies(params?: {}): Promise<implicitReturnType>;
35
- privateGetV1Deposits(params?: {}): Promise<implicitReturnType>;
36
- privateGetV1DepositAddress(params?: {}): Promise<implicitReturnType>;
37
- privateGetV1Ledger(params?: {}): Promise<implicitReturnType>;
38
- privateGetV1LeverageSettings(params?: {}): Promise<implicitReturnType>;
39
- privateGetV1MyTrades(params?: {}): Promise<implicitReturnType>;
40
- privateGetV1OpenOrders(params?: {}): Promise<implicitReturnType>;
41
- privateGetV1TradingPositions(params?: {}): Promise<implicitReturnType>;
42
- privateGetV1TradingPositionsHistory(params?: {}): Promise<implicitReturnType>;
43
- privateGetV1Transactions(params?: {}): Promise<implicitReturnType>;
44
- privateGetV1Withdrawals(params?: {}): Promise<implicitReturnType>;
45
- privateGetV2Account(params?: {}): Promise<implicitReturnType>;
46
- privateGetV2Currencies(params?: {}): Promise<implicitReturnType>;
47
- privateGetV2Deposits(params?: {}): Promise<implicitReturnType>;
48
- privateGetV2DepositAddress(params?: {}): Promise<implicitReturnType>;
49
- privateGetV2Ledger(params?: {}): Promise<implicitReturnType>;
50
- privateGetV2LeverageSettings(params?: {}): Promise<implicitReturnType>;
51
- privateGetV2MyTrades(params?: {}): Promise<implicitReturnType>;
52
- privateGetV2OpenOrders(params?: {}): Promise<implicitReturnType>;
53
- privateGetV2TradingPositions(params?: {}): Promise<implicitReturnType>;
54
- privateGetV2TradingPositionsHistory(params?: {}): Promise<implicitReturnType>;
55
- privateGetV2Transactions(params?: {}): Promise<implicitReturnType>;
56
- privateGetV2Withdrawals(params?: {}): Promise<implicitReturnType>;
57
- privateGetV2FetchOrder(params?: {}): Promise<implicitReturnType>;
58
- privatePostV1Order(params?: {}): Promise<implicitReturnType>;
59
- privatePostV1UpdateTradingPosition(params?: {}): Promise<implicitReturnType>;
60
- privatePostV1UpdateTradingOrder(params?: {}): Promise<implicitReturnType>;
61
- privatePostV1CloseTradingPosition(params?: {}): Promise<implicitReturnType>;
62
- privatePostV2Order(params?: {}): Promise<implicitReturnType>;
63
- privatePostV2UpdateTradingPosition(params?: {}): Promise<implicitReturnType>;
64
- privatePostV2UpdateTradingOrder(params?: {}): Promise<implicitReturnType>;
65
- privatePostV2CloseTradingPosition(params?: {}): Promise<implicitReturnType>;
66
- privateDeleteV1Order(params?: {}): Promise<implicitReturnType>;
67
- privateDeleteV2Order(params?: {}): Promise<implicitReturnType>;
68
- }
69
- declare abstract class Exchange extends _Exchange {
70
- }
71
- export default Exchange;
@@ -1,11 +0,0 @@
1
- // ----------------------------------------------------------------------------
2
-
3
- // PLEASE DO NOT EDIT THIS FILE, IT IS GENERATED AND WILL BE OVERWRITTEN:
4
- // https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-contribute-code
5
- // EDIT THE CORRESPONDENT .ts FILE INSTEAD
6
-
7
- // -------------------------------------------------------------------------------
8
- import { Exchange as _Exchange } from '../base/Exchange.js';
9
- class Exchange extends _Exchange {
10
- }
11
- export default Exchange;
@@ -1,284 +0,0 @@
1
- import Exchange from './abstract/currencycom.js';
2
- import type { Balances, Currency, Int, Market, OHLCV, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, Leverage, Num, Account, Currencies, TradingFees, Dict, int, LedgerEntry, DepositAddress } from './base/types.js';
3
- /**
4
- * @class currencycom
5
- * @augments Exchange
6
- */
7
- export default class currencycom extends Exchange {
8
- describe(): any;
9
- nonce(): number;
10
- /**
11
- * @method
12
- * @name currencycom#fetchTime
13
- * @description fetches the current integer timestamp in milliseconds from the exchange server
14
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/timeUsingGET
15
- * @param {object} [params] extra parameters specific to the exchange API endpoint
16
- * @returns {int} the current integer timestamp in milliseconds from the exchange server
17
- */
18
- fetchTime(params?: {}): Promise<Int>;
19
- /**
20
- * @method
21
- * @name currencycom#fetchCurrencies
22
- * @description fetches all available currencies on an exchange
23
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getCurrenciesUsingGET
24
- * @param {object} [params] extra parameters specific to the exchange API endpoint
25
- * @returns {object} an associative dictionary of currencies
26
- */
27
- fetchCurrencies(params?: {}): Promise<Currencies>;
28
- /**
29
- * @method
30
- * @name currencycom#fetchMarkets
31
- * @description retrieves data on all markets for currencycom
32
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/exchangeInfoUsingGET
33
- * @param {object} [params] extra parameters specific to the exchange API endpoint
34
- * @returns {object[]} an array of objects representing market data
35
- */
36
- fetchMarkets(params?: {}): Promise<Market[]>;
37
- /**
38
- * @method
39
- * @name currencycom#fetchAccounts
40
- * @description fetch all the accounts associated with a profile
41
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/accountUsingGET
42
- * @param {object} [params] extra parameters specific to the exchange API endpoint
43
- * @returns {object} a dictionary of [account structures]{@link https://docs.ccxt.com/#/?id=account-structure} indexed by the account type
44
- */
45
- fetchAccounts(params?: {}): Promise<Account[]>;
46
- /**
47
- * @method
48
- * @name currencycom#fetchTradingFees
49
- * @description fetch the trading fees for multiple markets
50
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/accountUsingGET
51
- * @param {object} [params] extra parameters specific to the exchange API endpoint
52
- * @returns {object} a dictionary of [fee structures]{@link https://docs.ccxt.com/#/?id=fee-structure} indexed by market symbols
53
- */
54
- fetchTradingFees(params?: {}): Promise<TradingFees>;
55
- parseBalance(response: any, type?: any): Balances;
56
- /**
57
- * @method
58
- * @name currencycom#fetchBalance
59
- * @description query for balance and get the amount of funds available for trading or funds locked in orders
60
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/accountUsingGET
61
- * @param {object} [params] extra parameters specific to the exchange API endpoint
62
- * @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
63
- */
64
- fetchBalance(params?: {}): Promise<Balances>;
65
- /**
66
- * @method
67
- * @name currencycom#fetchOrderBook
68
- * @description fetches information on open orders with bid (buy) and ask (sell) prices, volumes and other data
69
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/depthUsingGET
70
- * @param {string} symbol unified symbol of the market to fetch the order book for
71
- * @param {int} [limit] the maximum amount of order book entries to return
72
- * @param {object} [params] extra parameters specific to the exchange API endpoint
73
- * @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
74
- */
75
- fetchOrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
76
- parseTicker(ticker: Dict, market?: Market): Ticker;
77
- /**
78
- * @method
79
- * @name currencycom#fetchTicker
80
- * @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
81
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/ticker_24hrUsingGET
82
- * @param {string} symbol unified symbol of the market to fetch the ticker for
83
- * @param {object} [params] extra parameters specific to the exchange API endpoint
84
- * @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
85
- */
86
- fetchTicker(symbol: string, params?: {}): Promise<Ticker>;
87
- /**
88
- * @method
89
- * @name currencycom#fetchTickers
90
- * @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
91
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/ticker_24hrUsingGET
92
- * @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
93
- * @param {object} [params] extra parameters specific to the exchange API endpoint
94
- * @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
95
- */
96
- fetchTickers(symbols?: Strings, params?: {}): Promise<Tickers>;
97
- parseOHLCV(ohlcv: any, market?: Market): OHLCV;
98
- /**
99
- * @method
100
- * @name currencycom#fetchOHLCV
101
- * @description fetches historical candlestick data containing the open, high, low, and close price, and the volume of a market
102
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/klinesUsingGET
103
- * @param {string} symbol unified symbol of the market to fetch OHLCV data for
104
- * @param {string} timeframe the length of time each candle represents
105
- * @param {int} [since] timestamp in ms of the earliest candle to fetch
106
- * @param {int} [limit] the maximum amount of candles to fetch
107
- * @param {object} [params] extra parameters specific to the exchange API endpoint
108
- * @returns {int[][]} A list of candles ordered as timestamp, open, high, low, close, volume
109
- */
110
- fetchOHLCV(symbol: string, timeframe?: string, since?: Int, limit?: Int, params?: {}): Promise<OHLCV[]>;
111
- parseTrade(trade: Dict, market?: Market): Trade;
112
- /**
113
- * @method
114
- * @name currencycom#fetchTrades
115
- * @description get the list of most recent trades for a particular symbol
116
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/aggTradesUsingGET
117
- * @param {string} symbol unified symbol of the market to fetch trades for
118
- * @param {int} [since] timestamp in ms of the earliest trade to fetch
119
- * @param {int} [limit] the maximum amount of trades to fetch
120
- * @param {object} [params] extra parameters specific to the exchange API endpoint
121
- * @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
122
- */
123
- fetchTrades(symbol: string, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
124
- parseOrder(order: Dict, market?: Market): Order;
125
- parseOrderStatus(status: Str): string;
126
- parseOrderType(status: any): string;
127
- parseOrderTimeInForce(status: any): string;
128
- parseOrderSide(status: any): string;
129
- /**
130
- * @method
131
- * @name currencycom#createOrder
132
- * @description create a trade order
133
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/orderUsingPOST
134
- * @param {string} symbol unified symbol of the market to create an order in
135
- * @param {string} type 'market' or 'limit'
136
- * @param {string} side 'buy' or 'sell'
137
- * @param {float} amount how much of currency you want to trade in units of base currency
138
- * @param {float} [price] the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
139
- * @param {object} [params] extra parameters specific to the exchange API endpoint
140
- * @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
141
- */
142
- createOrder(symbol: string, type: OrderType, side: OrderSide, amount: number, price?: Num, params?: {}): Promise<Order>;
143
- /**
144
- * @method
145
- * @name currencycom#fetchOrder
146
- * @description fetches information on an order made by the user
147
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getOrderUsingGET
148
- * @param {string} id order id
149
- * @param {string} symbol unified symbol of the market the order was made in
150
- * @param {object} [params] extra parameters specific to the exchange API endpoint
151
- * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
152
- */
153
- fetchOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
154
- /**
155
- * @method
156
- * @name currencycom#fetchOpenOrders
157
- * @description fetch all unfilled currently open orders
158
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/openOrdersUsingGET
159
- * @param {string} symbol unified market symbol
160
- * @param {int} [since] the earliest time in ms to fetch open orders for
161
- * @param {int} [limit] the maximum number of open orders structures to retrieve
162
- * @param {object} [params] extra parameters specific to the exchange API endpoint
163
- * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
164
- */
165
- fetchOpenOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
166
- /**
167
- * @method
168
- * @name currencycom#cancelOrder
169
- * @description cancels an open order
170
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/cancelOrderUsingDELETE
171
- * @param {string} id order id
172
- * @param {string} symbol unified symbol of the market the order was made in
173
- * @param {object} [params] extra parameters specific to the exchange API endpoint
174
- * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
175
- */
176
- cancelOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
177
- /**
178
- * @method
179
- * @name currencycom#fetchMyTrades
180
- * @description fetch all trades made by the user
181
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/myTradesUsingGET
182
- * @param {string} symbol unified market symbol
183
- * @param {int} [since] the earliest time in ms to fetch trades for
184
- * @param {int} [limit] the maximum number of trades structures to retrieve
185
- * @param {object} [params] extra parameters specific to the exchange API endpoint
186
- * @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
187
- */
188
- fetchMyTrades(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
189
- /**
190
- * @method
191
- * @name currencycom#fetchDeposits
192
- * @description fetch all deposits made to an account
193
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getDepositsUsingGET
194
- * @param {string} code unified currency code
195
- * @param {int} [since] the earliest time in ms to fetch deposits for
196
- * @param {int} [limit] the maximum number of deposits structures to retrieve
197
- * @param {object} [params] extra parameters specific to the exchange API endpoint
198
- * @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
199
- */
200
- fetchDeposits(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
201
- /**
202
- * @method
203
- * @name currencycom#fetchWithdrawals
204
- * @description fetch all withdrawals made from an account
205
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getWithdrawalsUsingGET
206
- * @param {string} code unified currency code
207
- * @param {int} [since] the earliest time in ms to fetch withdrawals for
208
- * @param {int} [limit] the maximum number of withdrawals structures to retrieve
209
- * @param {object} [params] extra parameters specific to the exchange API endpoint
210
- * @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
211
- */
212
- fetchWithdrawals(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
213
- /**
214
- * @method
215
- * @name currencycom#fetchDepositsWithdrawals
216
- * @description fetch history of deposits and withdrawals
217
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getTransactionsUsingGET
218
- * @param {string} [code] unified currency code for the currency of the deposit/withdrawals, default is undefined
219
- * @param {int} [since] timestamp in ms of the earliest deposit/withdrawal, default is undefined
220
- * @param {int} [limit] max number of deposit/withdrawals to return, default is undefined
221
- * @param {object} [params] extra parameters specific to the exchange API endpoint
222
- * @returns {object} a list of [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
223
- */
224
- fetchDepositsWithdrawals(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
225
- fetchTransactionsByMethod(method: any, code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
226
- parseTransaction(transaction: Dict, currency?: Currency): Transaction;
227
- parseTransactionStatus(status: Str): string;
228
- parseTransactionType(type: any): string;
229
- /**
230
- * @method
231
- * @name currencycom#fetchLedger
232
- * @description fetch the history of changes, actions done by the user or operations that altered the balance of the user
233
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getLedgerUsingGET
234
- * @param {string} [code] unified currency code, default is undefined
235
- * @param {int} [since] timestamp in ms of the earliest ledger entry, default is undefined
236
- * @param {int} [limit] max number of ledger entries to return, default is undefined
237
- * @param {object} [params] extra parameters specific to the exchange API endpoint
238
- * @returns {object} a [ledger structure]{@link https://docs.ccxt.com/#/?id=ledger}
239
- */
240
- fetchLedger(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<LedgerEntry[]>;
241
- parseLedgerEntry(item: Dict, currency?: Currency): LedgerEntry;
242
- parseLedgerEntryStatus(status: any): string;
243
- parseLedgerEntryType(type: any): string;
244
- /**
245
- * @method
246
- * @name currencycom#fetchLeverage
247
- * @description fetch the set leverage for a market
248
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/leverageSettingsUsingGET
249
- * @param {string} symbol unified market symbol
250
- * @param {object} [params] extra parameters specific to the exchange API endpoint
251
- * @returns {object} a [leverage structure]{@link https://docs.ccxt.com/#/?id=leverage-structure}
252
- */
253
- fetchLeverage(symbol: string, params?: {}): Promise<Leverage>;
254
- parseLeverage(leverage: Dict, market?: Market): Leverage;
255
- /**
256
- * @method
257
- * @name currencycom#fetchDepositAddress
258
- * @description fetch the deposit address for a currency associated with this account
259
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getDepositAddressUsingGET
260
- * @param {string} code unified currency code
261
- * @param {object} [params] extra parameters specific to the exchange API endpoint
262
- * @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
263
- */
264
- fetchDepositAddress(code: string, params?: {}): Promise<DepositAddress>;
265
- parseDepositAddress(depositAddress: any, currency?: Currency): DepositAddress;
266
- sign(path: any, api?: string, method?: string, params?: {}, headers?: any, body?: any): {
267
- url: string;
268
- method: string;
269
- body: any;
270
- headers: any;
271
- };
272
- /**
273
- * @method
274
- * @name currencycom#fetchPositions
275
- * @description fetch all open positions
276
- * @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/tradingPositionsUsingGET
277
- * @param {string[]|undefined} symbols list of unified market symbols
278
- * @param {object} [params] extra parameters specific to the exchange API endpoint
279
- * @returns {object[]} a list of [position structure]{@link https://docs.ccxt.com/#/?id=position-structure}
280
- */
281
- fetchPositions(symbols?: Strings, params?: {}): Promise<import("./base/types.js").Position[]>;
282
- parsePosition(position: Dict, market?: Market): import("./base/types.js").Position;
283
- handleErrors(httpCode: int, reason: string, url: string, method: string, headers: Dict, body: string, response: any, requestHeaders: any, requestBody: any): any;
284
- }