ccxt-ir 4.9.4 → 4.9.10
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 +7 -7
- package/dist/ccxt.browser.min.js +4 -4
- package/dist/cjs/ccxt.js +22 -1
- package/dist/cjs/src/abantether.js +88 -69
- package/dist/cjs/src/abstract/bitbarg.js +11 -0
- package/dist/cjs/src/abstract/bydfi.js +11 -0
- package/dist/cjs/src/abstract/cafearz.js +11 -0
- package/dist/cjs/src/abstract/kifpoolme.js +11 -0
- package/dist/cjs/src/abstract/mazdax.js +11 -0
- package/dist/cjs/src/abstract/pingi.js +11 -0
- package/dist/cjs/src/abstract/pooleno.js +11 -0
- package/dist/cjs/src/afratether.js +84 -36
- package/dist/cjs/src/arzplus.js +32 -15
- package/dist/cjs/src/bitbarg.js +313 -0
- package/dist/cjs/src/bydfi.js +435 -0
- package/dist/cjs/src/cafearz.js +347 -0
- package/dist/cjs/src/kifpoolme.js +411 -0
- package/dist/cjs/src/mazdax.js +536 -0
- package/dist/cjs/src/pingi.js +448 -0
- package/dist/cjs/src/pooleno.js +348 -0
- package/dist/cjs/src/tetherland.js +8 -4
- package/dist/cjs/src/twox.js +55 -28
- package/js/ccxt.d.ts +23 -2
- package/js/ccxt.js +16 -2
- package/js/src/abantether.js +88 -69
- package/js/src/abstract/abantether.d.ts +1 -1
- package/js/src/abstract/bitbarg.d.ts +8 -0
- package/js/src/abstract/bitbarg.js +11 -0
- package/js/src/abstract/bydfi.d.ts +11 -0
- package/js/src/abstract/bydfi.js +11 -0
- package/js/src/abstract/cafearz.d.ts +8 -0
- package/js/src/abstract/cafearz.js +11 -0
- package/js/src/abstract/kifpoolme.d.ts +9 -0
- package/js/src/abstract/kifpoolme.js +11 -0
- package/js/src/abstract/mazdax.d.ts +11 -0
- package/js/src/abstract/mazdax.js +11 -0
- package/js/src/abstract/pingi.d.ts +9 -0
- package/js/src/abstract/pingi.js +11 -0
- package/js/src/abstract/pooleno.d.ts +8 -0
- package/js/src/abstract/pooleno.js +11 -0
- package/js/src/afratether.js +84 -36
- package/js/src/arzplus.d.ts +3 -2
- package/js/src/arzplus.js +32 -15
- package/js/src/base/Exchange.d.ts +2 -2
- package/js/src/bitbarg.d.ts +21 -0
- package/js/src/bitbarg.js +312 -0
- package/js/src/bydfi.d.ts +23 -0
- package/js/src/bydfi.js +434 -0
- package/js/src/cafearz.d.ts +21 -0
- package/js/src/cafearz.js +346 -0
- package/js/src/coinbaseexchange.d.ts +1 -1
- package/js/src/kifpoolme.d.ts +23 -0
- package/js/src/kifpoolme.js +410 -0
- package/js/src/mazdax.d.ts +23 -0
- package/js/src/mazdax.js +535 -0
- package/js/src/pingi.d.ts +22 -0
- package/js/src/pingi.js +447 -0
- package/js/src/pooleno.d.ts +21 -0
- package/js/src/pooleno.js +347 -0
- package/js/src/protobuf/mexc/compiled.d.cts +0 -6
- package/js/src/static_dependencies/fflake/browser.d.ts +5 -5
- package/js/src/static_dependencies/jsencrypt/lib/asn1js/asn1.d.ts +2 -2
- package/js/src/static_dependencies/jsencrypt/lib/jsbn/jsbn.d.ts +1 -1
- package/js/src/static_dependencies/qs/formats.d.cts +0 -6
- package/js/src/static_dependencies/qs/index.d.cts +0 -6
- package/js/src/static_dependencies/qs/parse.d.cts +0 -6
- package/js/src/static_dependencies/qs/stringify.d.cts +0 -6
- package/js/src/static_dependencies/qs/utils.d.cts +0 -6
- package/js/src/static_dependencies/starknet/utils/calldata/parser/index.d.ts +1 -1
- package/js/src/tetherland.js +5 -4
- package/js/src/twox.js +55 -28
- package/package.json +1 -1
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.9.
|
|
41
|
+
const version = '4.9.10';
|
|
42
42
|
Exchange.ccxtVersion = version;
|
|
43
43
|
//-----------------------------------------------------------------------------
|
|
44
44
|
import abantether from './src/abantether.js';
|
|
@@ -58,6 +58,7 @@ import bingx from './src/bingx.js';
|
|
|
58
58
|
import bit24 from './src/bit24.js';
|
|
59
59
|
import bit2c from './src/bit2c.js';
|
|
60
60
|
import bitbank from './src/bitbank.js';
|
|
61
|
+
import bitbarg from './src/bitbarg.js';
|
|
61
62
|
import bitbns from './src/bitbns.js';
|
|
62
63
|
import bitfinex from './src/bitfinex.js';
|
|
63
64
|
import bitflyer from './src/bitflyer.js';
|
|
@@ -83,6 +84,8 @@ import btcbox from './src/btcbox.js';
|
|
|
83
84
|
import btcmarkets from './src/btcmarkets.js';
|
|
84
85
|
import btcturk from './src/btcturk.js';
|
|
85
86
|
import bybit from './src/bybit.js';
|
|
87
|
+
import bydfi from './src/bydfi.js';
|
|
88
|
+
import cafearz from './src/cafearz.js';
|
|
86
89
|
import cex from './src/cex.js';
|
|
87
90
|
import coinbase from './src/coinbase.js';
|
|
88
91
|
import coinbaseadvanced from './src/coinbaseadvanced.js';
|
|
@@ -128,6 +131,7 @@ import independentreserve from './src/independentreserve.js';
|
|
|
128
131
|
import indodax from './src/indodax.js';
|
|
129
132
|
import jibitex from './src/jibitex.js';
|
|
130
133
|
import kcex from './src/kcex.js';
|
|
134
|
+
import kifpoolme from './src/kifpoolme.js';
|
|
131
135
|
import kraken from './src/kraken.js';
|
|
132
136
|
import krakenfutures from './src/krakenfutures.js';
|
|
133
137
|
import kucoin from './src/kucoin.js';
|
|
@@ -135,6 +139,7 @@ import kucoinfutures from './src/kucoinfutures.js';
|
|
|
135
139
|
import latoken from './src/latoken.js';
|
|
136
140
|
import lbank from './src/lbank.js';
|
|
137
141
|
import luno from './src/luno.js';
|
|
142
|
+
import mazdax from './src/mazdax.js';
|
|
138
143
|
import mercado from './src/mercado.js';
|
|
139
144
|
import mexc from './src/mexc.js';
|
|
140
145
|
import modetrade from './src/modetrade.js';
|
|
@@ -154,7 +159,9 @@ import p2b from './src/p2b.js';
|
|
|
154
159
|
import paradex from './src/paradex.js';
|
|
155
160
|
import paymium from './src/paymium.js';
|
|
156
161
|
import phemex from './src/phemex.js';
|
|
162
|
+
import pingi from './src/pingi.js';
|
|
157
163
|
import poloniex from './src/poloniex.js';
|
|
164
|
+
import pooleno from './src/pooleno.js';
|
|
158
165
|
import probit from './src/probit.js';
|
|
159
166
|
import ramzinex from './src/ramzinex.js';
|
|
160
167
|
import sarmayex from './src/sarmayex.js';
|
|
@@ -270,6 +277,7 @@ const exchanges = {
|
|
|
270
277
|
'bit24': bit24,
|
|
271
278
|
'bit2c': bit2c,
|
|
272
279
|
'bitbank': bitbank,
|
|
280
|
+
'bitbarg': bitbarg,
|
|
273
281
|
'bitbns': bitbns,
|
|
274
282
|
'bitfinex': bitfinex,
|
|
275
283
|
'bitflyer': bitflyer,
|
|
@@ -295,6 +303,8 @@ const exchanges = {
|
|
|
295
303
|
'btcmarkets': btcmarkets,
|
|
296
304
|
'btcturk': btcturk,
|
|
297
305
|
'bybit': bybit,
|
|
306
|
+
'bydfi': bydfi,
|
|
307
|
+
'cafearz': cafearz,
|
|
298
308
|
'cex': cex,
|
|
299
309
|
'coinbase': coinbase,
|
|
300
310
|
'coinbaseadvanced': coinbaseadvanced,
|
|
@@ -340,6 +350,7 @@ const exchanges = {
|
|
|
340
350
|
'indodax': indodax,
|
|
341
351
|
'jibitex': jibitex,
|
|
342
352
|
'kcex': kcex,
|
|
353
|
+
'kifpoolme': kifpoolme,
|
|
343
354
|
'kraken': kraken,
|
|
344
355
|
'krakenfutures': krakenfutures,
|
|
345
356
|
'kucoin': kucoin,
|
|
@@ -347,6 +358,7 @@ const exchanges = {
|
|
|
347
358
|
'latoken': latoken,
|
|
348
359
|
'lbank': lbank,
|
|
349
360
|
'luno': luno,
|
|
361
|
+
'mazdax': mazdax,
|
|
350
362
|
'mercado': mercado,
|
|
351
363
|
'mexc': mexc,
|
|
352
364
|
'modetrade': modetrade,
|
|
@@ -366,7 +378,9 @@ const exchanges = {
|
|
|
366
378
|
'paradex': paradex,
|
|
367
379
|
'paymium': paymium,
|
|
368
380
|
'phemex': phemex,
|
|
381
|
+
'pingi': pingi,
|
|
369
382
|
'poloniex': poloniex,
|
|
383
|
+
'pooleno': pooleno,
|
|
370
384
|
'probit': probit,
|
|
371
385
|
'ramzinex': ramzinex,
|
|
372
386
|
'sarmayex': sarmayex,
|
|
@@ -478,6 +492,6 @@ pro.exchanges = Object.keys(pro);
|
|
|
478
492
|
pro['Exchange'] = Exchange; // now the same for rest and ts
|
|
479
493
|
//-----------------------------------------------------------------------------
|
|
480
494
|
const ccxt = Object.assign({ version, Exchange, Precise, 'exchanges': Object.keys(exchanges), 'pro': pro }, exchanges, functions, errors);
|
|
481
|
-
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, bequant, bigone, binance, binancecoinm, binanceus, binanceusdm, bingx, bit24, bit2c, bitbank, 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, cex, 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, jibitex, kcex, kraken, krakenfutures, kucoin, kucoinfutures, latoken, lbank, luno, mercado, mexc, modetrade, myokx, ndax, nobitex, novadax, oceanex, okcoin, okexchange, okx, okxus, ompfinex, onetrading, oxfun, p2b, paradex, paymium, phemex, poloniex, probit, ramzinex, sarmayex, sarrafex, tabdeal, tetherland, timex, tokocrypto, toobit, tradeogre, twox, ubitex, upbit, vertex, wallex, wavesexchange, whitebit, woo, woofipro, xt, yobit, zaif, zonda, };
|
|
495
|
+
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, bequant, 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, 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, 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, oxfun, p2b, paradex, paymium, phemex, pingi, poloniex, pooleno, probit, ramzinex, sarmayex, sarrafex, tabdeal, tetherland, timex, tokocrypto, toobit, tradeogre, twox, ubitex, upbit, vertex, wallex, wavesexchange, whitebit, woo, woofipro, xt, yobit, zaif, zonda, };
|
|
482
496
|
export default ccxt;
|
|
483
497
|
//-----------------------------------------------------------------------------
|
package/js/src/abantether.js
CHANGED
|
@@ -24,7 +24,7 @@ export default class abantether extends Exchange {
|
|
|
24
24
|
'pro': false,
|
|
25
25
|
'has': {
|
|
26
26
|
'CORS': undefined,
|
|
27
|
-
'spot':
|
|
27
|
+
'spot': false,
|
|
28
28
|
'margin': false,
|
|
29
29
|
'swap': false,
|
|
30
30
|
'future': false,
|
|
@@ -80,6 +80,7 @@ export default class abantether extends Exchange {
|
|
|
80
80
|
'fetchTradingFee': false,
|
|
81
81
|
'fetchTradingFees': false,
|
|
82
82
|
'fetchWithdrawals': false,
|
|
83
|
+
'otc': true,
|
|
83
84
|
'setLeverage': false,
|
|
84
85
|
'setMarginMode': false,
|
|
85
86
|
'transfer': false,
|
|
@@ -89,7 +90,7 @@ export default class abantether extends Exchange {
|
|
|
89
90
|
'urls': {
|
|
90
91
|
'logo': 'https://cdn.arz.digital/cr-odin/img/exchanges/abantether/64x64.png',
|
|
91
92
|
'api': {
|
|
92
|
-
'public': 'https://abantether.com',
|
|
93
|
+
'public': 'https://api.abantether.com',
|
|
93
94
|
},
|
|
94
95
|
'www': 'https://abantether.com',
|
|
95
96
|
'doc': [
|
|
@@ -99,7 +100,7 @@ export default class abantether extends Exchange {
|
|
|
99
100
|
'api': {
|
|
100
101
|
'public': {
|
|
101
102
|
'get': {
|
|
102
|
-
'
|
|
103
|
+
'manager/coins/data': 1,
|
|
103
104
|
},
|
|
104
105
|
},
|
|
105
106
|
},
|
|
@@ -118,23 +119,24 @@ export default class abantether extends Exchange {
|
|
|
118
119
|
* @method
|
|
119
120
|
* @name abantether#fetchMarkets
|
|
120
121
|
* @description retrieves data on all markets for abantether
|
|
121
|
-
* @see https://abantether.com/
|
|
122
|
+
* @see https://api.abantether.com/manager/coins/data
|
|
122
123
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
123
124
|
* @returns {object[]} an array of objects representing market data
|
|
124
125
|
*/
|
|
125
|
-
const response = await this.
|
|
126
|
+
const response = await this.publicGetManagerCoinsData(params);
|
|
127
|
+
const data = this.safeList(response, 'data', []);
|
|
126
128
|
const result = [];
|
|
127
129
|
const quotes = ['IRT', 'USDT'];
|
|
128
|
-
for (let i = 0; i <
|
|
129
|
-
const base = this.safeString(
|
|
130
|
+
for (let i = 0; i < data.length; i++) {
|
|
131
|
+
const base = this.safeString(data[i], 'symbol');
|
|
130
132
|
for (let index = 0; index < quotes.length; index++) {
|
|
131
133
|
const quote = quotes[index];
|
|
132
|
-
|
|
133
|
-
|
|
134
|
+
data[i]['base'] = base;
|
|
135
|
+
data[i]['quote'] = quote;
|
|
134
136
|
if (base === quote) {
|
|
135
137
|
continue;
|
|
136
138
|
}
|
|
137
|
-
const market = this.parseMarket(
|
|
139
|
+
const market = this.parseMarket(data[i]);
|
|
138
140
|
result.push(market);
|
|
139
141
|
}
|
|
140
142
|
}
|
|
@@ -142,29 +144,38 @@ export default class abantether extends Exchange {
|
|
|
142
144
|
}
|
|
143
145
|
parseMarket(market) {
|
|
144
146
|
// {
|
|
145
|
-
//
|
|
146
|
-
//
|
|
147
|
-
//
|
|
148
|
-
//
|
|
149
|
-
//
|
|
150
|
-
//
|
|
151
|
-
//
|
|
152
|
-
//
|
|
153
|
-
//
|
|
154
|
-
//
|
|
155
|
-
//
|
|
156
|
-
//
|
|
157
|
-
//
|
|
158
|
-
//
|
|
159
|
-
//
|
|
160
|
-
//
|
|
161
|
-
//
|
|
162
|
-
//
|
|
163
|
-
//
|
|
164
|
-
//
|
|
165
|
-
//
|
|
166
|
-
//
|
|
167
|
-
//
|
|
147
|
+
// "id": 1,
|
|
148
|
+
// "name": "Tether USDt",
|
|
149
|
+
// "symbol": "USDT",
|
|
150
|
+
// "persian_name": "تتر",
|
|
151
|
+
// "is_active": true,
|
|
152
|
+
// "is_withdrawal_active": true,
|
|
153
|
+
// "is_deposit_active": true,
|
|
154
|
+
// "is_mid_wallet_transfer_active": true,
|
|
155
|
+
// "is_buy_active": true,
|
|
156
|
+
// "is_sell_active": true,
|
|
157
|
+
// "is_credit_active": true,
|
|
158
|
+
// "min_trade": "1.00",
|
|
159
|
+
// "max_trade": "100000.00",
|
|
160
|
+
// "tether_price": "1",
|
|
161
|
+
// "price_buy": "113540.0",
|
|
162
|
+
// "price_sell": "112630.0",
|
|
163
|
+
// "volume24h": "225163179366.25",
|
|
164
|
+
// "percent_change_1h": "0.00",
|
|
165
|
+
// "percent_change_24h": "0.00",
|
|
166
|
+
// "percent_change_7d": "0.04",
|
|
167
|
+
// "market_cap": "179884960573.99",
|
|
168
|
+
// "coin_type": "COIN",
|
|
169
|
+
// "exchange_type": "fake",
|
|
170
|
+
// "icon": "f71021586005413ea6f3a0bd1f7d8a55",
|
|
171
|
+
// "fund_tether_buy": "0",
|
|
172
|
+
// "fund_tether_sell": "0",
|
|
173
|
+
// "irt_decimal_point": 2,
|
|
174
|
+
// "tether_decimal_point": 6,
|
|
175
|
+
// "amount_decimal_point": 6,
|
|
176
|
+
// "base": "BTC",
|
|
177
|
+
// "qoute": "USDT",
|
|
178
|
+
// },
|
|
168
179
|
let baseId = this.safeString(market, 'base');
|
|
169
180
|
let quoteId = this.safeString(market, 'quote');
|
|
170
181
|
const base = this.safeCurrencyCode(baseId);
|
|
@@ -227,7 +238,7 @@ export default class abantether extends Exchange {
|
|
|
227
238
|
* @method
|
|
228
239
|
* @name abantether#fetchTickers
|
|
229
240
|
* @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
|
|
230
|
-
* @see https://abantether.com/
|
|
241
|
+
* @see https://api.abantether.com/manager/coins/data
|
|
231
242
|
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
232
243
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
233
244
|
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
@@ -236,20 +247,21 @@ export default class abantether extends Exchange {
|
|
|
236
247
|
if (symbols !== undefined) {
|
|
237
248
|
symbols = this.marketSymbols(symbols);
|
|
238
249
|
}
|
|
239
|
-
const response = await this.
|
|
250
|
+
const response = await this.publicGetManagerCoinsData(params);
|
|
251
|
+
const data = this.safeList(response, 'data', []);
|
|
240
252
|
const result = {};
|
|
241
253
|
const quotes = ['IRT', 'USDT'];
|
|
242
|
-
for (let i = 0; i <
|
|
243
|
-
const base = this.safeString(
|
|
254
|
+
for (let i = 0; i < data.length; i++) {
|
|
255
|
+
const base = this.safeString(data[i], 'symbol');
|
|
244
256
|
for (let index = 0; index < quotes.length; index++) {
|
|
245
257
|
const quote = quotes[index];
|
|
246
258
|
if (base === quote) {
|
|
247
259
|
continue;
|
|
248
260
|
}
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
const ticker = this.parseTicker(
|
|
261
|
+
data[i]['base'] = base;
|
|
262
|
+
data[i]['quote'] = quote;
|
|
263
|
+
data[i]['symbol'] = base + quote;
|
|
264
|
+
const ticker = this.parseTicker(data[i]);
|
|
253
265
|
const symbol = ticker['symbol'];
|
|
254
266
|
result[symbol] = ticker;
|
|
255
267
|
}
|
|
@@ -261,7 +273,7 @@ export default class abantether extends Exchange {
|
|
|
261
273
|
* @method
|
|
262
274
|
* @name abantether#fetchTicker
|
|
263
275
|
* @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
264
|
-
* @see https://abantether.com/
|
|
276
|
+
* @see https://api.abantether.com/manager/coins/data
|
|
265
277
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
266
278
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
267
279
|
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
@@ -271,38 +283,45 @@ export default class abantether extends Exchange {
|
|
|
271
283
|
}
|
|
272
284
|
parseTicker(ticker, market = undefined) {
|
|
273
285
|
// {
|
|
274
|
-
//
|
|
275
|
-
//
|
|
276
|
-
//
|
|
277
|
-
//
|
|
278
|
-
//
|
|
279
|
-
//
|
|
280
|
-
//
|
|
281
|
-
//
|
|
282
|
-
//
|
|
283
|
-
//
|
|
284
|
-
//
|
|
285
|
-
//
|
|
286
|
-
//
|
|
287
|
-
//
|
|
288
|
-
//
|
|
289
|
-
//
|
|
290
|
-
//
|
|
291
|
-
//
|
|
292
|
-
//
|
|
293
|
-
//
|
|
294
|
-
//
|
|
295
|
-
//
|
|
296
|
-
//
|
|
286
|
+
// "id": 2,
|
|
287
|
+
// "name": "Bitcoin",
|
|
288
|
+
// "symbol": "BTC",
|
|
289
|
+
// "persian_name": "بیت کوین",
|
|
290
|
+
// "is_active": true,
|
|
291
|
+
// "is_withdrawal_active": true,
|
|
292
|
+
// "is_deposit_active": true,
|
|
293
|
+
// "is_mid_wallet_transfer_active": true,
|
|
294
|
+
// "is_buy_active": true,
|
|
295
|
+
// "is_sell_active": true,
|
|
296
|
+
// "is_credit_active": true,
|
|
297
|
+
// "min_trade": "1.00",
|
|
298
|
+
// "max_trade": "65000.00",
|
|
299
|
+
// "tether_price": "114909.43000000",
|
|
300
|
+
// "price_buy": "13049114870.800000000",
|
|
301
|
+
// "price_sell": "12944547289.500000000",
|
|
302
|
+
// "volume24h": "93585526493.26",
|
|
303
|
+
// "percent_change_1h": "-0.29",
|
|
304
|
+
// "percent_change_24h": "3.22",
|
|
305
|
+
// "percent_change_7d": "-7.19",
|
|
306
|
+
// "market_cap": "2292874615411.72",
|
|
307
|
+
// "coin_type": "COIN",
|
|
308
|
+
// "exchange_type": "binance",
|
|
309
|
+
// "icon": "561aa10abc0c45f7aa4499f48d618c80",
|
|
310
|
+
// "fund_tether_buy": "0",
|
|
311
|
+
// "fund_tether_sell": "0",
|
|
312
|
+
// "irt_decimal_point": 0,
|
|
313
|
+
// "tether_decimal_point": 2,
|
|
314
|
+
// "amount_decimal_point": 9
|
|
315
|
+
// },
|
|
297
316
|
const marketType = 'otc';
|
|
298
317
|
const marketId = this.safeString(ticker, 'symbol');
|
|
299
318
|
const symbol = this.safeSymbol(marketId, market, undefined, marketType);
|
|
300
|
-
let last = this.safeFloat(ticker, '
|
|
319
|
+
let last = this.safeFloat(ticker, 'tether_price', 0);
|
|
301
320
|
if (ticker['quote'] === 'IRT') {
|
|
302
|
-
last = this.safeFloat(ticker, '
|
|
321
|
+
last = this.safeFloat(ticker, 'price_buy', 0);
|
|
303
322
|
}
|
|
304
|
-
const change = this.safeFloat(ticker, '
|
|
305
|
-
const baseVolume = this.safeFloat(ticker, '
|
|
323
|
+
const change = this.safeFloat(ticker, 'percent_change_24h', 0);
|
|
324
|
+
const baseVolume = this.safeFloat(ticker, 'volume24h', 0);
|
|
306
325
|
return this.safeTicker({
|
|
307
326
|
'symbol': symbol,
|
|
308
327
|
'timestamp': undefined,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { implicitReturnType } from '../base/types.js';
|
|
2
2
|
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
3
|
interface Exchange {
|
|
4
|
-
|
|
4
|
+
publicGetManagerCoinsData(params?: {}): Promise<implicitReturnType>;
|
|
5
5
|
}
|
|
6
6
|
declare abstract class Exchange extends _Exchange {
|
|
7
7
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetApiV1Currencies(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
}
|
|
6
|
+
declare abstract class Exchange extends _Exchange {
|
|
7
|
+
}
|
|
8
|
+
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;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetApiSpotProductList(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
publicGetApiTvTradingViewHistory(params?: {}): Promise<implicitReturnType>;
|
|
6
|
+
quoteGetTickers(params?: {}): Promise<implicitReturnType>;
|
|
7
|
+
quoteGetMkpaiDepthV2(params?: {}): Promise<implicitReturnType>;
|
|
8
|
+
}
|
|
9
|
+
declare abstract class Exchange extends _Exchange {
|
|
10
|
+
}
|
|
11
|
+
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;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetApiClientV1CurrenciesPricesDigital(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
}
|
|
6
|
+
declare abstract class Exchange extends _Exchange {
|
|
7
|
+
}
|
|
8
|
+
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;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetApiSpotPrice(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
publicGetApiSpotTickers1m(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;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetMarketSymbols(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
publicGetMarketRollingprice(params?: {}): Promise<implicitReturnType>;
|
|
6
|
+
publicGetMarketCandle(params?: {}): Promise<implicitReturnType>;
|
|
7
|
+
publicGetMarketOrder(params?: {}): Promise<implicitReturnType>;
|
|
8
|
+
}
|
|
9
|
+
declare abstract class Exchange extends _Exchange {
|
|
10
|
+
}
|
|
11
|
+
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;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetMarketPrices(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
publicGetUdfHistory(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;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { implicitReturnType } from '../base/types.js';
|
|
2
|
+
import { Exchange as _Exchange } from '../base/Exchange.js';
|
|
3
|
+
interface Exchange {
|
|
4
|
+
publicGetApiV1TokensPublic(params?: {}): Promise<implicitReturnType>;
|
|
5
|
+
}
|
|
6
|
+
declare abstract class Exchange extends _Exchange {
|
|
7
|
+
}
|
|
8
|
+
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;
|