ccxt-ir 4.12.4 → 4.13.1
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 +4 -4
- package/dist/ccxt.browser.min.js +3 -3
- package/dist/cjs/ccxt.js +4 -1
- package/dist/cjs/src/abstract/bitwana.js +11 -0
- package/dist/cjs/src/bitwana.js +420 -0
- package/dist/cjs/src/changefa.js +1 -1
- package/dist/cjs/src/kifpoolme.js +2 -2
- package/js/ccxt.d.ts +5 -2
- package/js/ccxt.js +4 -2
- package/js/src/abstract/bitwana.d.ts +9 -0
- package/js/src/abstract/bitwana.js +11 -0
- package/js/src/base/Exchange.d.ts +2 -2
- package/js/src/bitwana.d.ts +24 -0
- package/js/src/bitwana.js +419 -0
- package/js/src/changefa.js +1 -1
- package/js/src/coinbaseexchange.d.ts +1 -1
- package/js/src/kifpoolme.js +2 -2
- package/js/src/protobuf/mexc/compiled.d.cts +6 -0
- package/js/src/src/bitwana.d.ts +21 -0
- package/js/src/static_dependencies/fflake/browser.d.ts +5 -5
- package/js/src/static_dependencies/jsencrypt/lib/jsbn/jsbn.d.ts +1 -1
- package/js/src/static_dependencies/qs/formats.d.cts +6 -0
- package/js/src/static_dependencies/qs/index.d.cts +6 -0
- package/js/src/static_dependencies/qs/parse.d.cts +6 -0
- package/js/src/static_dependencies/qs/stringify.d.cts +6 -0
- package/js/src/static_dependencies/qs/utils.d.cts +6 -0
- package/js/src/static_dependencies/starknet/utils/calldata/parser/index.d.ts +1 -1
- package/js/test.js +76 -24
- package/package.json +1 -1
package/dist/cjs/ccxt.js
CHANGED
|
@@ -50,6 +50,7 @@ var bitteam = require('./src/bitteam.js');
|
|
|
50
50
|
var bittrade = require('./src/bittrade.js');
|
|
51
51
|
var bitunix = require('./src/bitunix.js');
|
|
52
52
|
var bitvavo = require('./src/bitvavo.js');
|
|
53
|
+
var bitwana = require('./src/bitwana.js');
|
|
53
54
|
var blockchaincom = require('./src/blockchaincom.js');
|
|
54
55
|
var blofin = require('./src/blofin.js');
|
|
55
56
|
var btcalpha = require('./src/btcalpha.js');
|
|
@@ -239,7 +240,7 @@ var xt$1 = require('./src/pro/xt.js');
|
|
|
239
240
|
|
|
240
241
|
//-----------------------------------------------------------------------------
|
|
241
242
|
// this is updated by vss.js when building
|
|
242
|
-
const version = '4.
|
|
243
|
+
const version = '4.13.1';
|
|
243
244
|
Exchange["default"].ccxtVersion = version;
|
|
244
245
|
const exchanges = {
|
|
245
246
|
'abantether': abantether["default"],
|
|
@@ -280,6 +281,7 @@ const exchanges = {
|
|
|
280
281
|
'bittrade': bittrade["default"],
|
|
281
282
|
'bitunix': bitunix["default"],
|
|
282
283
|
'bitvavo': bitvavo["default"],
|
|
284
|
+
'bitwana': bitwana["default"],
|
|
283
285
|
'blockchaincom': blockchaincom["default"],
|
|
284
286
|
'blofin': blofin["default"],
|
|
285
287
|
'btcalpha': btcalpha["default"],
|
|
@@ -558,6 +560,7 @@ exports.bitteam = bitteam["default"];
|
|
|
558
560
|
exports.bittrade = bittrade["default"];
|
|
559
561
|
exports.bitunix = bitunix["default"];
|
|
560
562
|
exports.bitvavo = bitvavo["default"];
|
|
563
|
+
exports.bitwana = bitwana["default"];
|
|
561
564
|
exports.blockchaincom = blockchaincom["default"];
|
|
562
565
|
exports.blofin = blofin["default"];
|
|
563
566
|
exports.btcalpha = btcalpha["default"];
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var Exchange$1 = require('../base/Exchange.js');
|
|
6
|
+
|
|
7
|
+
// ----------------------------------------------------------------------------
|
|
8
|
+
class Exchange extends Exchange$1["default"] {
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
exports["default"] = Exchange;
|
|
@@ -0,0 +1,420 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var bitwana$1 = require('./abstract/bitwana.js');
|
|
6
|
+
|
|
7
|
+
// ----------------------------------------------------------------------------
|
|
8
|
+
// ---------------------------------------------------------------------------
|
|
9
|
+
/**
|
|
10
|
+
* @class bitwana
|
|
11
|
+
* @augments Exchange
|
|
12
|
+
* @description Set rateLimit to 1000 if fully verified
|
|
13
|
+
*/
|
|
14
|
+
class bitwana extends bitwana$1["default"] {
|
|
15
|
+
marketTypeToSymbol(base, quote, marketType = 'spot') {
|
|
16
|
+
return base + '/' + quote;
|
|
17
|
+
}
|
|
18
|
+
describe() {
|
|
19
|
+
return this.deepExtend(super.describe(), {
|
|
20
|
+
'id': 'bitwana',
|
|
21
|
+
'name': 'Bitwana',
|
|
22
|
+
'countries': ['IR'],
|
|
23
|
+
'rateLimit': 1000,
|
|
24
|
+
'version': '1',
|
|
25
|
+
'certified': false,
|
|
26
|
+
'pro': false,
|
|
27
|
+
'has': {
|
|
28
|
+
'CORS': undefined,
|
|
29
|
+
'spot': true,
|
|
30
|
+
'margin': false,
|
|
31
|
+
'swap': false,
|
|
32
|
+
'future': false,
|
|
33
|
+
'option': false,
|
|
34
|
+
'addMargin': false,
|
|
35
|
+
'cancelAllOrders': false,
|
|
36
|
+
'cancelOrder': false,
|
|
37
|
+
'cancelOrders': false,
|
|
38
|
+
'createDepositAddress': false,
|
|
39
|
+
'createOrder': false,
|
|
40
|
+
'createStopLimitOrder': false,
|
|
41
|
+
'createStopMarketOrder': false,
|
|
42
|
+
'createStopOrder': false,
|
|
43
|
+
'editOrder': false,
|
|
44
|
+
'fetchBalance': false,
|
|
45
|
+
'fetchBorrowInterest': false,
|
|
46
|
+
'fetchBorrowRateHistories': false,
|
|
47
|
+
'fetchBorrowRateHistory': false,
|
|
48
|
+
'fetchClosedOrders': false,
|
|
49
|
+
'fetchCrossBorrowRate': false,
|
|
50
|
+
'fetchCrossBorrowRates': false,
|
|
51
|
+
'fetchCurrencies': false,
|
|
52
|
+
'fetchDepositAddress': false,
|
|
53
|
+
'fetchDeposits': false,
|
|
54
|
+
'fetchFundingHistory': false,
|
|
55
|
+
'fetchFundingRate': false,
|
|
56
|
+
'fetchFundingRateHistory': false,
|
|
57
|
+
'fetchFundingRates': false,
|
|
58
|
+
'fetchIndexOHLCV': false,
|
|
59
|
+
'fetchIsolatedBorrowRate': false,
|
|
60
|
+
'fetchIsolatedBorrowRates': false,
|
|
61
|
+
'fetchL2OrderBook': false,
|
|
62
|
+
'fetchL3OrderBook': false,
|
|
63
|
+
'fetchLedger': false,
|
|
64
|
+
'fetchLedgerEntry': false,
|
|
65
|
+
'fetchLeverageTiers': false,
|
|
66
|
+
'fetchMarkets': true,
|
|
67
|
+
'fetchMarkOHLCV': false,
|
|
68
|
+
'fetchMyTrades': false,
|
|
69
|
+
'fetchOHLCV': false,
|
|
70
|
+
'fetchOpenInterestHistory': false,
|
|
71
|
+
'fetchOpenOrders': false,
|
|
72
|
+
'fetchOrder': false,
|
|
73
|
+
'fetchOrderBook': false,
|
|
74
|
+
'fetchOrders': false,
|
|
75
|
+
'fetchOrderTrades': 'emulated',
|
|
76
|
+
'fetchPositions': false,
|
|
77
|
+
'fetchPremiumIndexOHLCV': false,
|
|
78
|
+
'fetchTicker': true,
|
|
79
|
+
'fetchTickers': true,
|
|
80
|
+
'fetchTime': false,
|
|
81
|
+
'fetchTrades': false,
|
|
82
|
+
'fetchTradingFee': false,
|
|
83
|
+
'fetchTradingFees': false,
|
|
84
|
+
'fetchWithdrawals': false,
|
|
85
|
+
'otc': true,
|
|
86
|
+
'setLeverage': false,
|
|
87
|
+
'setMarginMode': false,
|
|
88
|
+
'transfer': false,
|
|
89
|
+
'withdraw': false,
|
|
90
|
+
},
|
|
91
|
+
'comment': 'This comment is optional',
|
|
92
|
+
'urls': {
|
|
93
|
+
'logo': 'https://cdn.arz.digital/cr-odin/img/exchanges/bitwana/64x64.png',
|
|
94
|
+
'api': {
|
|
95
|
+
'public': 'https://bitwana.com',
|
|
96
|
+
},
|
|
97
|
+
'www': 'https://bitwana.com/',
|
|
98
|
+
'doc': [
|
|
99
|
+
'https://bitwana.com/',
|
|
100
|
+
],
|
|
101
|
+
},
|
|
102
|
+
'api': {
|
|
103
|
+
'public': {
|
|
104
|
+
'get': {
|
|
105
|
+
'api/1/markets': 1,
|
|
106
|
+
'api/1/markets/{id}': 1,
|
|
107
|
+
},
|
|
108
|
+
},
|
|
109
|
+
},
|
|
110
|
+
'fees': {},
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
parseSpotMarket(market) {
|
|
114
|
+
// {
|
|
115
|
+
// "id": "BTC_IRT",
|
|
116
|
+
// "symbol": "بیتکوین-تومان",
|
|
117
|
+
// "base": "BTC",
|
|
118
|
+
// "quote": "IRT",
|
|
119
|
+
// "buyPrice": "10222846365",
|
|
120
|
+
// "sellPrice": "10233403625",
|
|
121
|
+
// "userOrderPricePrecision": 0,
|
|
122
|
+
// "quantityPrecision": 6,
|
|
123
|
+
// "minimumOrder": 100000,
|
|
124
|
+
// "maximumOrder": 300000000,
|
|
125
|
+
// "lastTradedPrice": "10249911984",
|
|
126
|
+
// "lowestPrice": "10063564406",
|
|
127
|
+
// "highestPrice": "10320391247",
|
|
128
|
+
// "sourceVolume": "0.036557",
|
|
129
|
+
// "destinationVolume": "371770611.78",
|
|
130
|
+
// "tradingEnabled": true,
|
|
131
|
+
// "otcEnabled": false,
|
|
132
|
+
// }
|
|
133
|
+
const id = this.safeString(market, 'id');
|
|
134
|
+
const baseId = this.safeString(market, 'base');
|
|
135
|
+
const quoteId = this.safeString(market, 'quote');
|
|
136
|
+
const base = this.safeCurrencyCode(baseId);
|
|
137
|
+
const quote = this.safeCurrencyCode(quoteId);
|
|
138
|
+
return {
|
|
139
|
+
'id': id,
|
|
140
|
+
'symbol': this.marketTypeToSymbol(base, quote, 'spot'),
|
|
141
|
+
'base': base,
|
|
142
|
+
'quote': quote,
|
|
143
|
+
'settle': undefined,
|
|
144
|
+
'baseId': baseId,
|
|
145
|
+
'quoteId': quoteId,
|
|
146
|
+
'settleId': undefined,
|
|
147
|
+
'type': 'spot',
|
|
148
|
+
'spot': true,
|
|
149
|
+
'margin': false,
|
|
150
|
+
'swap': false,
|
|
151
|
+
'future': false,
|
|
152
|
+
'option': false,
|
|
153
|
+
'active': true,
|
|
154
|
+
'contract': false,
|
|
155
|
+
'linear': undefined,
|
|
156
|
+
'inverse': undefined,
|
|
157
|
+
'contractSize': undefined,
|
|
158
|
+
'expiry': undefined,
|
|
159
|
+
'expiryDatetime': undefined,
|
|
160
|
+
'strike': undefined,
|
|
161
|
+
'optionType': undefined,
|
|
162
|
+
'precision': {
|
|
163
|
+
'amount': this.safeInteger(market, 'quantityPrecision'),
|
|
164
|
+
'price': this.safeInteger(market, 'userOrderPricePrecision'),
|
|
165
|
+
},
|
|
166
|
+
'limits': {
|
|
167
|
+
'leverage': {
|
|
168
|
+
'min': undefined,
|
|
169
|
+
'max': undefined,
|
|
170
|
+
},
|
|
171
|
+
'amount': {
|
|
172
|
+
'min': undefined,
|
|
173
|
+
'max': undefined,
|
|
174
|
+
},
|
|
175
|
+
'price': {
|
|
176
|
+
'min': undefined,
|
|
177
|
+
'max': undefined,
|
|
178
|
+
},
|
|
179
|
+
'cost': {
|
|
180
|
+
'min': this.safeNumber(market, 'minimumOrder'),
|
|
181
|
+
'max': this.safeNumber(market, 'maximumOrder'),
|
|
182
|
+
},
|
|
183
|
+
},
|
|
184
|
+
'created': undefined,
|
|
185
|
+
'info': market,
|
|
186
|
+
};
|
|
187
|
+
}
|
|
188
|
+
parseOtcMarket(market) {
|
|
189
|
+
const rawId = this.safeString(market, 'id');
|
|
190
|
+
const baseId = this.safeString(market, 'base');
|
|
191
|
+
const quoteId = this.safeString(market, 'quote');
|
|
192
|
+
const base = this.safeCurrencyCode(baseId);
|
|
193
|
+
const quote = this.safeCurrencyCode(quoteId);
|
|
194
|
+
return {
|
|
195
|
+
'id': rawId + '_OTC',
|
|
196
|
+
'symbol': this.marketTypeToSymbol(base, quote, 'otc'),
|
|
197
|
+
'base': base,
|
|
198
|
+
'quote': quote,
|
|
199
|
+
'settle': undefined,
|
|
200
|
+
'baseId': baseId,
|
|
201
|
+
'quoteId': quoteId,
|
|
202
|
+
'settleId': undefined,
|
|
203
|
+
'type': 'otc',
|
|
204
|
+
'spot': false,
|
|
205
|
+
'margin': false,
|
|
206
|
+
'swap': false,
|
|
207
|
+
'future': false,
|
|
208
|
+
'option': false,
|
|
209
|
+
'active': true,
|
|
210
|
+
'contract': false,
|
|
211
|
+
'linear': undefined,
|
|
212
|
+
'inverse': undefined,
|
|
213
|
+
'contractSize': undefined,
|
|
214
|
+
'expiry': undefined,
|
|
215
|
+
'expiryDatetime': undefined,
|
|
216
|
+
'strike': undefined,
|
|
217
|
+
'optionType': undefined,
|
|
218
|
+
'precision': {
|
|
219
|
+
'amount': this.safeInteger(market, 'quantityPrecision'),
|
|
220
|
+
'price': this.safeInteger(market, 'userOrderPricePrecision'),
|
|
221
|
+
},
|
|
222
|
+
'limits': {
|
|
223
|
+
'leverage': {
|
|
224
|
+
'min': undefined,
|
|
225
|
+
'max': undefined,
|
|
226
|
+
},
|
|
227
|
+
'amount': {
|
|
228
|
+
'min': undefined,
|
|
229
|
+
'max': undefined,
|
|
230
|
+
},
|
|
231
|
+
'price': {
|
|
232
|
+
'min': undefined,
|
|
233
|
+
'max': undefined,
|
|
234
|
+
},
|
|
235
|
+
'cost': {
|
|
236
|
+
'min': this.safeNumber(market, 'minimumOrder'),
|
|
237
|
+
'max': this.safeNumber(market, 'maximumOrder'),
|
|
238
|
+
},
|
|
239
|
+
},
|
|
240
|
+
'created': undefined,
|
|
241
|
+
'info': market,
|
|
242
|
+
};
|
|
243
|
+
}
|
|
244
|
+
async fetchMarkets(params = {}) {
|
|
245
|
+
/**
|
|
246
|
+
* @method
|
|
247
|
+
* @name bitwana#fetchMarkets
|
|
248
|
+
* @description retrieves data on all markets for bitwana
|
|
249
|
+
* @see https://bitwana.com/api/1/markets?with_price=true
|
|
250
|
+
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
251
|
+
* @returns {object[]} an array of objects representing market data
|
|
252
|
+
*/
|
|
253
|
+
const marketType = this.safeString(params, 'type', 'spot');
|
|
254
|
+
const request = {
|
|
255
|
+
'with_price': true,
|
|
256
|
+
};
|
|
257
|
+
const response = await this.publicGetApi1Markets(this.extend(request, params));
|
|
258
|
+
const markets = this.safeList(response, 'content', []);
|
|
259
|
+
const result = [];
|
|
260
|
+
for (let i = 0; i < markets.length; i++) {
|
|
261
|
+
const market = markets[i];
|
|
262
|
+
if (marketType === 'otc') {
|
|
263
|
+
result.push(this.parseOtcMarket(market));
|
|
264
|
+
}
|
|
265
|
+
else {
|
|
266
|
+
result.push(this.parseSpotMarket(market));
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
return result;
|
|
270
|
+
}
|
|
271
|
+
async fetchTickers(symbols = undefined, params = {}) {
|
|
272
|
+
/**
|
|
273
|
+
* @method
|
|
274
|
+
* @name bitwana#fetchTickers
|
|
275
|
+
* @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
|
|
276
|
+
* @see https://bitwana.com/api/1/markets?with_price=true
|
|
277
|
+
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
278
|
+
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
279
|
+
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
280
|
+
*/
|
|
281
|
+
const marketType = this.safeString(params, 'type', 'spot');
|
|
282
|
+
await this.loadMarkets(false, { 'type': marketType });
|
|
283
|
+
if (symbols !== undefined) {
|
|
284
|
+
symbols = this.marketSymbols(symbols);
|
|
285
|
+
}
|
|
286
|
+
const request = {
|
|
287
|
+
'with_price': true,
|
|
288
|
+
};
|
|
289
|
+
const response = await this.publicGetApi1Markets(this.extend(request, params));
|
|
290
|
+
const markets = this.safeList(response, 'content', []);
|
|
291
|
+
const result = {};
|
|
292
|
+
for (let i = 0; i < markets.length; i++) {
|
|
293
|
+
const market = markets[i];
|
|
294
|
+
if (marketType === 'otc') {
|
|
295
|
+
const otcTicker = this.parseOtcTicker(market);
|
|
296
|
+
result[otcTicker['symbol']] = otcTicker;
|
|
297
|
+
}
|
|
298
|
+
else {
|
|
299
|
+
const spotTicker = this.parseSpotTicker(market);
|
|
300
|
+
result[spotTicker['symbol']] = spotTicker;
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
return this.filterByArrayTickers(result, 'symbol', symbols);
|
|
304
|
+
}
|
|
305
|
+
async fetchTicker(symbol, params = {}) {
|
|
306
|
+
/**
|
|
307
|
+
* @method
|
|
308
|
+
* @name bitwana#fetchTicker
|
|
309
|
+
* @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
310
|
+
* @see https://bitwana.com/api/1/markets/BTC_IRT?with_price=true
|
|
311
|
+
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
312
|
+
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
313
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
314
|
+
*/
|
|
315
|
+
const marketType = this.safeString(params, 'type', 'spot');
|
|
316
|
+
await this.loadMarkets(false, { 'type': marketType });
|
|
317
|
+
const market = this.market(symbol);
|
|
318
|
+
const request = {
|
|
319
|
+
'id': this.safeString(market['info'], 'id'),
|
|
320
|
+
'with_price': true,
|
|
321
|
+
};
|
|
322
|
+
const response = await this.publicGetApi1MarketsId(this.extend(request, params));
|
|
323
|
+
const ticker = this.safeDict(response, 'content');
|
|
324
|
+
if (marketType === 'otc') {
|
|
325
|
+
return this.parseOtcTicker(ticker, market);
|
|
326
|
+
}
|
|
327
|
+
return this.parseSpotTicker(ticker, market);
|
|
328
|
+
}
|
|
329
|
+
parseSpotTicker(ticker, market = undefined) {
|
|
330
|
+
const baseId = this.safeString(ticker, 'base');
|
|
331
|
+
const quoteId = this.safeString(ticker, 'quote');
|
|
332
|
+
const base = this.safeCurrencyCode(baseId);
|
|
333
|
+
const quote = this.safeCurrencyCode(quoteId);
|
|
334
|
+
let symbol = this.marketTypeToSymbol(base, quote, 'spot');
|
|
335
|
+
if (market !== undefined) {
|
|
336
|
+
symbol = market['symbol'];
|
|
337
|
+
}
|
|
338
|
+
const high = this.safeNumber(ticker, 'highestPrice');
|
|
339
|
+
const low = this.safeNumber(ticker, 'lowestPrice');
|
|
340
|
+
const bid = this.safeNumber(ticker, 'buyPrice');
|
|
341
|
+
const ask = this.safeNumber(ticker, 'sellPrice');
|
|
342
|
+
const last = this.safeNumber(ticker, 'lastTradedPrice');
|
|
343
|
+
const change = this.safeNumber(ticker, 'changePrice');
|
|
344
|
+
const percentage = this.safeNumber(ticker, 'changeRate');
|
|
345
|
+
const baseVolume = this.safeNumber(ticker, 'sourceVolume');
|
|
346
|
+
const quoteVolume = this.safeNumber(ticker, 'destinationVolume');
|
|
347
|
+
return this.safeTicker({
|
|
348
|
+
'symbol': symbol,
|
|
349
|
+
'timestamp': undefined,
|
|
350
|
+
'datetime': undefined,
|
|
351
|
+
'high': high,
|
|
352
|
+
'low': low,
|
|
353
|
+
'bid': bid,
|
|
354
|
+
'bidVolume': undefined,
|
|
355
|
+
'ask': ask,
|
|
356
|
+
'askVolume': undefined,
|
|
357
|
+
'vwap': undefined,
|
|
358
|
+
'open': undefined,
|
|
359
|
+
'close': last,
|
|
360
|
+
'last': last,
|
|
361
|
+
'previousClose': undefined,
|
|
362
|
+
'change': change,
|
|
363
|
+
'percentage': percentage,
|
|
364
|
+
'average': undefined,
|
|
365
|
+
'baseVolume': baseVolume,
|
|
366
|
+
'quoteVolume': quoteVolume,
|
|
367
|
+
'info': ticker,
|
|
368
|
+
}, market);
|
|
369
|
+
}
|
|
370
|
+
parseOtcTicker(ticker, market = undefined) {
|
|
371
|
+
const baseId = this.safeString(ticker, 'base');
|
|
372
|
+
const quoteId = this.safeString(ticker, 'quote');
|
|
373
|
+
const base = this.safeCurrencyCode(baseId);
|
|
374
|
+
const quote = this.safeCurrencyCode(quoteId);
|
|
375
|
+
let symbol = this.marketTypeToSymbol(base, quote, 'otc');
|
|
376
|
+
if (market !== undefined) {
|
|
377
|
+
symbol = market['symbol'];
|
|
378
|
+
}
|
|
379
|
+
const high = this.safeNumber(ticker, 'highestPrice');
|
|
380
|
+
const low = this.safeNumber(ticker, 'lowestPrice');
|
|
381
|
+
const bid = this.safeNumber(ticker, 'buyPrice');
|
|
382
|
+
const ask = this.safeNumber(ticker, 'sellPrice');
|
|
383
|
+
const last = this.safeNumber(ticker, 'lastTradedPrice');
|
|
384
|
+
const change = this.safeNumber(ticker, 'changePrice');
|
|
385
|
+
const percentage = this.safeNumber(ticker, 'changeRate');
|
|
386
|
+
return this.safeTicker({
|
|
387
|
+
'symbol': symbol,
|
|
388
|
+
'timestamp': undefined,
|
|
389
|
+
'datetime': undefined,
|
|
390
|
+
'high': high,
|
|
391
|
+
'low': low,
|
|
392
|
+
'bid': bid,
|
|
393
|
+
'bidVolume': undefined,
|
|
394
|
+
'ask': ask,
|
|
395
|
+
'askVolume': undefined,
|
|
396
|
+
'vwap': undefined,
|
|
397
|
+
'open': undefined,
|
|
398
|
+
'close': last,
|
|
399
|
+
'last': last,
|
|
400
|
+
'previousClose': undefined,
|
|
401
|
+
'change': change,
|
|
402
|
+
'percentage': percentage,
|
|
403
|
+
'average': undefined,
|
|
404
|
+
'baseVolume': undefined,
|
|
405
|
+
'quoteVolume': undefined,
|
|
406
|
+
'info': ticker,
|
|
407
|
+
}, market);
|
|
408
|
+
}
|
|
409
|
+
sign(path, api = 'public', method = 'GET', params = {}, headers = undefined, body = undefined) {
|
|
410
|
+
const query = this.omit(params, this.extractParams(path));
|
|
411
|
+
let url = this.urls['api'][api] + '/' + this.implodeParams(path, params);
|
|
412
|
+
if (Object.keys(query).length) {
|
|
413
|
+
url += '?' + this.urlencode(query);
|
|
414
|
+
}
|
|
415
|
+
headers = { 'Content-Type': 'application/json' };
|
|
416
|
+
return { 'url': url, 'method': method, 'body': body, 'headers': headers };
|
|
417
|
+
}
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
exports["default"] = bitwana;
|
package/dist/cjs/src/changefa.js
CHANGED
|
@@ -226,7 +226,7 @@ class changefa extends Exchange["default"] {
|
|
|
226
226
|
const buyPrice = this.safeNumber(ticker, 'buyPrice');
|
|
227
227
|
const sellPrice = this.safeNumber(ticker, 'sellPrice');
|
|
228
228
|
if ((buyPrice !== undefined) && (sellPrice !== undefined)) {
|
|
229
|
-
last =
|
|
229
|
+
last = sellPrice;
|
|
230
230
|
}
|
|
231
231
|
const weeklyPriceLog = this.safeList(ticker, 'weeklyPriceLog', []);
|
|
232
232
|
let high = undefined;
|
|
@@ -309,8 +309,8 @@ class kifpoolme extends kifpoolme$1["default"] {
|
|
|
309
309
|
let ask = undefined;
|
|
310
310
|
if (quoteId === 'IRT') {
|
|
311
311
|
// For IRT: priceSellIRT is the sell price (bid), priceBuyIRT is the buy price (ask)
|
|
312
|
-
|
|
313
|
-
|
|
312
|
+
ask = this.safeNumber(ticker, 'priceSellIRT');
|
|
313
|
+
bid = this.safeNumber(ticker, 'priceBuyIRT');
|
|
314
314
|
last = ask;
|
|
315
315
|
}
|
|
316
316
|
else {
|
package/js/ccxt.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import * as functions from './src/base/functions.js';
|
|
|
4
4
|
import * as errors from './src/base/errors.js';
|
|
5
5
|
import type { Int, int, Str, Strings, Num, Bool, IndexType, OrderSide, OrderType, MarketType, SubType, Dict, NullableDict, List, NullableList, Fee, OHLCV, OHLCVC, implicitReturnType, Market, Currency, Dictionary, MinMax, FeeInterface, TradingFeeInterface, MarketMarginModes, MarketInterface, Trade, Order, OrderBook, Ticker, Transaction, Tickers, CurrencyInterface, Balance, BalanceAccount, Account, PartialBalances, Balances, DepositAddress, WithdrawalResponse, FundingRate, FundingRates, Position, BorrowInterest, LeverageTier, LedgerEntry, DepositWithdrawFeeNetwork, DepositWithdrawFee, TransferEntry, CrossBorrowRate, IsolatedBorrowRate, FundingRateHistory, OpenInterest, Liquidation, OrderRequest, CancellationRequest, FundingHistory, MarginMode, Greeks, Conversion, Option, LastPrice, Leverage, MarginModification, Leverages, LastPrices, Currencies, TradingFees, MarginModes, OptionChain, IsolatedBorrowRates, CrossBorrowRates, LeverageTiers, LongShortRatio, OrderBooks, OpenInterests, ConstructorArgs } from './src/base/types.js';
|
|
6
6
|
import { BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError } from './src/base/errors.js';
|
|
7
|
-
declare const version = "4.
|
|
7
|
+
declare const version = "4.13.1";
|
|
8
8
|
import abantether from './src/abantether.js';
|
|
9
9
|
import afratether from './src/afratether.js';
|
|
10
10
|
import alpaca from './src/alpaca.js';
|
|
@@ -43,6 +43,7 @@ import bitteam from './src/bitteam.js';
|
|
|
43
43
|
import bittrade from './src/bittrade.js';
|
|
44
44
|
import bitunix from './src/bitunix.js';
|
|
45
45
|
import bitvavo from './src/bitvavo.js';
|
|
46
|
+
import bitwana from './src/bitwana.js';
|
|
46
47
|
import blockchaincom from './src/blockchaincom.js';
|
|
47
48
|
import blofin from './src/blofin.js';
|
|
48
49
|
import btcalpha from './src/btcalpha.js';
|
|
@@ -268,6 +269,7 @@ declare const exchanges: {
|
|
|
268
269
|
bittrade: typeof bittrade;
|
|
269
270
|
bitunix: typeof bitunix;
|
|
270
271
|
bitvavo: typeof bitvavo;
|
|
272
|
+
bitwana: typeof bitwana;
|
|
271
273
|
blockchaincom: typeof blockchaincom;
|
|
272
274
|
blofin: typeof blofin;
|
|
273
275
|
btcalpha: typeof btcalpha;
|
|
@@ -576,6 +578,7 @@ declare const ccxt: {
|
|
|
576
578
|
bittrade: typeof bittrade;
|
|
577
579
|
bitunix: typeof bitunix;
|
|
578
580
|
bitvavo: typeof bitvavo;
|
|
581
|
+
bitwana: typeof bitwana;
|
|
579
582
|
blockchaincom: typeof blockchaincom;
|
|
580
583
|
blofin: typeof blofin;
|
|
581
584
|
btcalpha: typeof btcalpha;
|
|
@@ -690,5 +693,5 @@ declare const ccxt: {
|
|
|
690
693
|
zaif: typeof zaif;
|
|
691
694
|
zonda: typeof zonda;
|
|
692
695
|
} & typeof functions & typeof errors;
|
|
693
|
-
export { version, Exchange, exchanges, pro, Precise, functions, errors, BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError, Int, int, Str, Strings, Num, Bool, IndexType, OrderSide, OrderType, MarketType, SubType, Dict, NullableDict, List, NullableList, Fee, OHLCV, OHLCVC, implicitReturnType, Market, Currency, ConstructorArgs, Dictionary, MinMax, FeeInterface, TradingFeeInterface, MarketMarginModes, MarketInterface, Trade, Order, OrderBook, OrderBooks, Ticker, Transaction, Tickers, CurrencyInterface, Balance, BalanceAccount, Account, PartialBalances, Balances, DepositAddress, WithdrawalResponse, FundingRate, FundingRates, Position, BorrowInterest, LeverageTier, LedgerEntry, DepositWithdrawFeeNetwork, DepositWithdrawFee, TransferEntry, CrossBorrowRate, IsolatedBorrowRate, FundingRateHistory, OpenInterest, OpenInterests, Liquidation, OrderRequest, CancellationRequest, FundingHistory, MarginMode, Greeks, Conversion, Option, LastPrice, Leverage, LongShortRatio, MarginModification, Leverages, LastPrices, Currencies, TradingFees, MarginModes, OptionChain, IsolatedBorrowRates, CrossBorrowRates, LeverageTiers, abantether, afratether, alpaca, apex, arzinja, arzplus, ascendex, asretether, bequant, bidarz, bigone, binance, binancecoinm, binanceus, binanceusdm, bingx, bit24, bit2c, bitbank, bitbarg, bitbns, bitfinex, bitflyer, bitget, bithumb, bitimen, bitir, bitmart, bitmex, bitopro, bitpin, bitrue, bitso, bitstamp, bitteam, bittrade, bitunix, bitvavo, blockchaincom, blofin, btcalpha, btcbox, btcmarkets, btcturk, bybit, bydfi, cafearz, cex, changefa, coinbase, coinbaseadvanced, coinbaseexchange, coinbaseinternational, coincatch, coincheck, coinex, coinmate, coinmetro, coinone, coinsph, coinspot, cryptocom, cryptomus, defx, delta, deribit, derive, digifinex, ellipx, eterex, excoino, exir, exmo, exnovin, farhadexchange, fmfwio, foxbit, gate, gateio, gemini, hamtapay, hashkey, hibachi, hitbtc, hitobit, hollaex, htx, huobi, hyperliquid, independentreserve, indodax, iranexchange, jibitex, kcex, kifpoolme, kraken, krakenfutures, kucoin, kucoinfutures, latoken, lbank, luno, mazdax, mercado, mexc, modetrade, myokx, ndax, nobitex, novadax, oceanex, okcoin, okexchange, okx, okxus, ompfinex, onetrading, ourbit, oxfun, p2b, paradex, paymium, phemex, pingi, poloniex, pooleno, probit, raastin, ramzinex, sarmayex, sarrafex, tabdeal, tehran_exchange, tetherland, timex, tokocrypto, toobit, tradeogre, twox, ubitex, upbit, vertex, wallex, wavesexchange, whitebit, woo, woofipro, xt, yobit, zaif, zonda, };
|
|
696
|
+
export { version, Exchange, exchanges, pro, Precise, functions, errors, BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError, Int, int, Str, Strings, Num, Bool, IndexType, OrderSide, OrderType, MarketType, SubType, Dict, NullableDict, List, NullableList, Fee, OHLCV, OHLCVC, implicitReturnType, Market, Currency, ConstructorArgs, Dictionary, MinMax, FeeInterface, TradingFeeInterface, MarketMarginModes, MarketInterface, Trade, Order, OrderBook, OrderBooks, Ticker, Transaction, Tickers, CurrencyInterface, Balance, BalanceAccount, Account, PartialBalances, Balances, DepositAddress, WithdrawalResponse, FundingRate, FundingRates, Position, BorrowInterest, LeverageTier, LedgerEntry, DepositWithdrawFeeNetwork, DepositWithdrawFee, TransferEntry, CrossBorrowRate, IsolatedBorrowRate, FundingRateHistory, OpenInterest, OpenInterests, Liquidation, OrderRequest, CancellationRequest, FundingHistory, MarginMode, Greeks, Conversion, Option, LastPrice, Leverage, LongShortRatio, MarginModification, Leverages, LastPrices, Currencies, TradingFees, MarginModes, OptionChain, IsolatedBorrowRates, CrossBorrowRates, LeverageTiers, abantether, afratether, alpaca, apex, arzinja, arzplus, ascendex, asretether, bequant, bidarz, bigone, binance, binancecoinm, binanceus, binanceusdm, bingx, bit24, bit2c, bitbank, bitbarg, bitbns, bitfinex, bitflyer, bitget, bithumb, bitimen, bitir, bitmart, bitmex, bitopro, bitpin, bitrue, bitso, bitstamp, bitteam, bittrade, bitunix, bitvavo, bitwana, blockchaincom, blofin, btcalpha, btcbox, btcmarkets, btcturk, bybit, bydfi, cafearz, cex, changefa, coinbase, coinbaseadvanced, coinbaseexchange, coinbaseinternational, coincatch, coincheck, coinex, coinmate, coinmetro, coinone, coinsph, coinspot, cryptocom, cryptomus, defx, delta, deribit, derive, digifinex, ellipx, eterex, excoino, exir, exmo, exnovin, farhadexchange, fmfwio, foxbit, gate, gateio, gemini, hamtapay, hashkey, hibachi, hitbtc, hitobit, hollaex, htx, huobi, hyperliquid, independentreserve, indodax, iranexchange, jibitex, kcex, kifpoolme, kraken, krakenfutures, kucoin, kucoinfutures, latoken, lbank, luno, mazdax, mercado, mexc, modetrade, myokx, ndax, nobitex, novadax, oceanex, okcoin, okexchange, okx, okxus, ompfinex, onetrading, ourbit, oxfun, p2b, paradex, paymium, phemex, pingi, poloniex, pooleno, probit, raastin, ramzinex, sarmayex, sarrafex, tabdeal, tehran_exchange, tetherland, timex, tokocrypto, toobit, tradeogre, twox, ubitex, upbit, vertex, wallex, wavesexchange, whitebit, woo, woofipro, xt, yobit, zaif, zonda, };
|
|
694
697
|
export default ccxt;
|
package/js/ccxt.js
CHANGED
|
@@ -38,7 +38,7 @@ import * as errors from './src/base/errors.js';
|
|
|
38
38
|
import { BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError } from './src/base/errors.js';
|
|
39
39
|
//-----------------------------------------------------------------------------
|
|
40
40
|
// this is updated by vss.js when building
|
|
41
|
-
const version = '4.
|
|
41
|
+
const version = '4.13.1';
|
|
42
42
|
Exchange.ccxtVersion = version;
|
|
43
43
|
//-----------------------------------------------------------------------------
|
|
44
44
|
import abantether from './src/abantether.js';
|
|
@@ -79,6 +79,7 @@ import bitteam from './src/bitteam.js';
|
|
|
79
79
|
import bittrade from './src/bittrade.js';
|
|
80
80
|
import bitunix from './src/bitunix.js';
|
|
81
81
|
import bitvavo from './src/bitvavo.js';
|
|
82
|
+
import bitwana from './src/bitwana.js';
|
|
82
83
|
import blockchaincom from './src/blockchaincom.js';
|
|
83
84
|
import blofin from './src/blofin.js';
|
|
84
85
|
import btcalpha from './src/btcalpha.js';
|
|
@@ -305,6 +306,7 @@ const exchanges = {
|
|
|
305
306
|
'bittrade': bittrade,
|
|
306
307
|
'bitunix': bitunix,
|
|
307
308
|
'bitvavo': bitvavo,
|
|
309
|
+
'bitwana': bitwana,
|
|
308
310
|
'blockchaincom': blockchaincom,
|
|
309
311
|
'blofin': blofin,
|
|
310
312
|
'btcalpha': btcalpha,
|
|
@@ -506,6 +508,6 @@ pro.exchanges = Object.keys(pro);
|
|
|
506
508
|
pro['Exchange'] = Exchange; // now the same for rest and ts
|
|
507
509
|
//-----------------------------------------------------------------------------
|
|
508
510
|
const ccxt = Object.assign({ version, Exchange, Precise, 'exchanges': Object.keys(exchanges), 'pro': pro }, exchanges, functions, errors);
|
|
509
|
-
export { version, Exchange, exchanges, pro, Precise, functions, errors, BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError, abantether, afratether, alpaca, apex, arzinja, arzplus, ascendex, asretether, bequant, bidarz, bigone, binance, binancecoinm, binanceus, binanceusdm, bingx, bit24, bit2c, bitbank, bitbarg, bitbns, bitfinex, bitflyer, bitget, bithumb, bitimen, bitir, bitmart, bitmex, bitopro, bitpin, bitrue, bitso, bitstamp, bitteam, bittrade, bitunix, bitvavo, blockchaincom, blofin, btcalpha, btcbox, btcmarkets, btcturk, bybit, bydfi, cafearz, cex, changefa, coinbase, coinbaseadvanced, coinbaseexchange, coinbaseinternational, coincatch, coincheck, coinex, coinmate, coinmetro, coinone, coinsph, coinspot, cryptocom, cryptomus, defx, delta, deribit, derive, digifinex, ellipx, eterex, excoino, exir, exmo, exnovin, farhadexchange, fmfwio, foxbit, gate, gateio, gemini, hamtapay, hashkey, hibachi, hitbtc, hitobit, hollaex, htx, huobi, hyperliquid, independentreserve, indodax, iranexchange, jibitex, kcex, kifpoolme, kraken, krakenfutures, kucoin, kucoinfutures, latoken, lbank, luno, mazdax, mercado, mexc, modetrade, myokx, ndax, nobitex, novadax, oceanex, okcoin, okexchange, okx, okxus, ompfinex, onetrading, ourbit, oxfun, p2b, paradex, paymium, phemex, pingi, poloniex, pooleno, probit, raastin, ramzinex, sarmayex, sarrafex, tabdeal, tehran_exchange, tetherland, timex, tokocrypto, toobit, tradeogre, twox, ubitex, upbit, vertex, wallex, wavesexchange, whitebit, woo, woofipro, xt, yobit, zaif, zonda, };
|
|
511
|
+
export { version, Exchange, exchanges, pro, Precise, functions, errors, BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, RestrictedLocation, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError, abantether, afratether, alpaca, apex, arzinja, arzplus, ascendex, asretether, bequant, bidarz, bigone, binance, binancecoinm, binanceus, binanceusdm, bingx, bit24, bit2c, bitbank, bitbarg, bitbns, bitfinex, bitflyer, bitget, bithumb, bitimen, bitir, bitmart, bitmex, bitopro, bitpin, bitrue, bitso, bitstamp, bitteam, bittrade, bitunix, bitvavo, bitwana, blockchaincom, blofin, btcalpha, btcbox, btcmarkets, btcturk, bybit, bydfi, cafearz, cex, changefa, coinbase, coinbaseadvanced, coinbaseexchange, coinbaseinternational, coincatch, coincheck, coinex, coinmate, coinmetro, coinone, coinsph, coinspot, cryptocom, cryptomus, defx, delta, deribit, derive, digifinex, ellipx, eterex, excoino, exir, exmo, exnovin, farhadexchange, fmfwio, foxbit, gate, gateio, gemini, hamtapay, hashkey, hibachi, hitbtc, hitobit, hollaex, htx, huobi, hyperliquid, independentreserve, indodax, iranexchange, jibitex, kcex, kifpoolme, kraken, krakenfutures, kucoin, kucoinfutures, latoken, lbank, luno, mazdax, mercado, mexc, modetrade, myokx, ndax, nobitex, novadax, oceanex, okcoin, okexchange, okx, okxus, ompfinex, onetrading, ourbit, oxfun, p2b, paradex, paymium, phemex, pingi, poloniex, pooleno, probit, raastin, ramzinex, sarmayex, sarrafex, tabdeal, tehran_exchange, tetherland, timex, tokocrypto, toobit, tradeogre, twox, ubitex, upbit, vertex, wallex, wavesexchange, whitebit, woo, woofipro, xt, yobit, zaif, zonda, };
|
|
510
512
|
export default ccxt;
|
|
511
513
|
//-----------------------------------------------------------------------------
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetApi1Markets(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
publicGetApi1MarketsId(params?: {}): Promise<implicitReturnType>;
|
|
6
|
+
}
|
|
7
|
+
declare abstract class Exchange extends _Exchange {
|
|
8
|
+
}
|
|
9
|
+
export default Exchange;
|
|
@@ -0,0 +1,11 @@
|
|
|
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;
|
|
@@ -252,7 +252,7 @@ export default class Exchange {
|
|
|
252
252
|
outputLen: number;
|
|
253
253
|
blockLen: number;
|
|
254
254
|
create(): import("../static_dependencies/noble-hashes/utils.js").Hash<import("../static_dependencies/noble-hashes/utils.js").Hash<any>>;
|
|
255
|
-
}, digest?: "
|
|
255
|
+
}, digest?: "hex" | "base64" | "binary") => any;
|
|
256
256
|
arrayConcat: (a: any[], b: any[]) => any[];
|
|
257
257
|
encode: (str: string) => Uint8Array;
|
|
258
258
|
urlencode: (object: object, sort?: boolean) => string;
|
|
@@ -261,7 +261,7 @@ export default class Exchange {
|
|
|
261
261
|
outputLen: number;
|
|
262
262
|
blockLen: number;
|
|
263
263
|
create(): import("../static_dependencies/noble-hashes/utils.js").Hash<import("../static_dependencies/noble-hashes/utils.js").Hash<any>>;
|
|
264
|
-
}, digest?: "
|
|
264
|
+
}, digest?: "hex" | "base64" | "binary") => any;
|
|
265
265
|
numberToString: typeof functions.numberToString;
|
|
266
266
|
parseTimeframe: (timeframe: string) => number;
|
|
267
267
|
safeInteger2: (o: any, k1: IndexType, k2: IndexType, $default?: number) => number;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import Exchange from './abstract/bitwana.js';
|
|
2
|
+
import { Market, Strings, Ticker, Tickers } from './base/types.js';
|
|
3
|
+
/**
|
|
4
|
+
* @class bitwana
|
|
5
|
+
* @augments Exchange
|
|
6
|
+
* @description Set rateLimit to 1000 if fully verified
|
|
7
|
+
*/
|
|
8
|
+
export default class bitwana extends Exchange {
|
|
9
|
+
marketTypeToSymbol(base: string, quote: string, marketType?: string): string;
|
|
10
|
+
describe(): any;
|
|
11
|
+
parseSpotMarket(market: any): Market;
|
|
12
|
+
parseOtcMarket(market: any): Market;
|
|
13
|
+
fetchMarkets(params?: {}): Promise<Market[]>;
|
|
14
|
+
fetchTickers(symbols?: Strings, params?: {}): Promise<Tickers>;
|
|
15
|
+
fetchTicker(symbol: string, params?: {}): Promise<Ticker>;
|
|
16
|
+
parseSpotTicker(ticker: any, market?: Market): Ticker;
|
|
17
|
+
parseOtcTicker(ticker: any, market?: Market): Ticker;
|
|
18
|
+
sign(path: any, api?: string, method?: string, params?: {}, headers?: any, body?: any): {
|
|
19
|
+
url: string;
|
|
20
|
+
method: string;
|
|
21
|
+
body: any;
|
|
22
|
+
headers: any;
|
|
23
|
+
};
|
|
24
|
+
}
|