ccxt 4.2.88__py2.py3-none-any.whl → 4.2.89__py2.py3-none-any.whl
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.
Potentially problematic release.
This version of ccxt might be problematic. Click here for more details.
- ccxt/__init__.py +1 -1
- ccxt/ascendex.py +5 -3
- ccxt/async_support/__init__.py +1 -1
- ccxt/async_support/ascendex.py +5 -3
- ccxt/async_support/base/exchange.py +3 -2
- ccxt/async_support/bigone.py +2 -2
- ccxt/async_support/binance.py +7 -5
- ccxt/async_support/bingx.py +2 -2
- ccxt/async_support/bit2c.py +2 -2
- ccxt/async_support/bitbank.py +2 -2
- ccxt/async_support/bitfinex.py +2 -2
- ccxt/async_support/bitfinex2.py +3 -3
- ccxt/async_support/bitflyer.py +4 -2
- ccxt/async_support/bitget.py +10 -5
- ccxt/async_support/bitmart.py +6 -4
- ccxt/async_support/bitmex.py +2 -2
- ccxt/async_support/bitopro.py +3 -3
- ccxt/async_support/bitrue.py +2 -2
- ccxt/async_support/bitso.py +2 -2
- ccxt/async_support/bitstamp.py +89 -97
- ccxt/async_support/bitteam.py +2 -2
- ccxt/async_support/bitvavo.py +3 -3
- ccxt/async_support/bl3p.py +2 -2
- ccxt/async_support/blockchaincom.py +2 -2
- ccxt/async_support/blofin.py +4 -2
- ccxt/async_support/bybit.py +7 -5
- ccxt/async_support/cex.py +3 -3
- ccxt/async_support/coinbase.py +2 -2
- ccxt/async_support/coinbaseinternational.py +2 -2
- ccxt/async_support/coinbasepro.py +3 -3
- ccxt/async_support/coincheck.py +2 -2
- ccxt/async_support/coinex.py +5 -5
- ccxt/async_support/coinlist.py +3 -3
- ccxt/async_support/coinmate.py +2 -2
- ccxt/async_support/coinmetro.py +2 -2
- ccxt/async_support/coinone.py +2 -2
- ccxt/async_support/coinsph.py +6 -4
- ccxt/async_support/currencycom.py +3 -3
- ccxt/async_support/delta.py +2 -2
- ccxt/async_support/deribit.py +3 -3
- ccxt/async_support/digifinex.py +6 -4
- ccxt/async_support/exmo.py +3 -3
- ccxt/async_support/gate.py +6 -4
- ccxt/async_support/gemini.py +3 -3
- ccxt/async_support/hitbtc.py +7 -5
- ccxt/async_support/hollaex.py +3 -3
- ccxt/async_support/htx.py +6 -4
- ccxt/async_support/huobijp.py +2 -2
- ccxt/async_support/hyperliquid.py +2 -2
- ccxt/async_support/idex.py +3 -3
- ccxt/async_support/independentreserve.py +2 -2
- ccxt/async_support/kraken.py +3 -3
- ccxt/async_support/kucoin.py +42 -18
- ccxt/async_support/kuna.py +2 -2
- ccxt/async_support/latoken.py +7 -3
- ccxt/async_support/lbank.py +7 -5
- ccxt/async_support/luno.py +4 -2
- ccxt/async_support/lykke.py +2 -2
- ccxt/async_support/mexc.py +56 -9
- ccxt/async_support/ndax.py +2 -2
- ccxt/async_support/oceanex.py +2 -2
- ccxt/async_support/okcoin.py +2 -2
- ccxt/async_support/okx.py +6 -4
- ccxt/async_support/onetrading.py +3 -3
- ccxt/async_support/phemex.py +2 -2
- ccxt/async_support/poloniex.py +3 -3
- ccxt/async_support/probit.py +2 -2
- ccxt/async_support/timex.py +6 -4
- ccxt/async_support/upbit.py +2 -2
- ccxt/async_support/wazirx.py +2 -2
- ccxt/async_support/whitebit.py +3 -3
- ccxt/async_support/woo.py +3 -3
- ccxt/async_support/yobit.py +2 -2
- ccxt/base/exchange.py +14 -7
- ccxt/base/types.py +32 -0
- ccxt/bigone.py +2 -2
- ccxt/binance.py +7 -5
- ccxt/bingx.py +2 -2
- ccxt/bit2c.py +2 -2
- ccxt/bitbank.py +2 -2
- ccxt/bitfinex.py +2 -2
- ccxt/bitfinex2.py +3 -3
- ccxt/bitflyer.py +4 -2
- ccxt/bitget.py +10 -5
- ccxt/bitmart.py +6 -4
- ccxt/bitmex.py +2 -2
- ccxt/bitopro.py +3 -3
- ccxt/bitrue.py +2 -2
- ccxt/bitso.py +2 -2
- ccxt/bitstamp.py +89 -97
- ccxt/bitteam.py +2 -2
- ccxt/bitvavo.py +3 -3
- ccxt/bl3p.py +2 -2
- ccxt/blockchaincom.py +2 -2
- ccxt/blofin.py +4 -2
- ccxt/bybit.py +7 -5
- ccxt/cex.py +3 -3
- ccxt/coinbase.py +2 -2
- ccxt/coinbaseinternational.py +2 -2
- ccxt/coinbasepro.py +3 -3
- ccxt/coincheck.py +2 -2
- ccxt/coinex.py +5 -5
- ccxt/coinlist.py +3 -3
- ccxt/coinmate.py +2 -2
- ccxt/coinmetro.py +2 -2
- ccxt/coinone.py +2 -2
- ccxt/coinsph.py +6 -4
- ccxt/currencycom.py +3 -3
- ccxt/delta.py +2 -2
- ccxt/deribit.py +3 -3
- ccxt/digifinex.py +6 -4
- ccxt/exmo.py +3 -3
- ccxt/gate.py +6 -4
- ccxt/gemini.py +3 -3
- ccxt/hitbtc.py +7 -5
- ccxt/hollaex.py +3 -3
- ccxt/htx.py +6 -4
- ccxt/huobijp.py +2 -2
- ccxt/hyperliquid.py +2 -2
- ccxt/idex.py +3 -3
- ccxt/independentreserve.py +2 -2
- ccxt/kraken.py +3 -3
- ccxt/kucoin.py +42 -18
- ccxt/kuna.py +2 -2
- ccxt/latoken.py +7 -3
- ccxt/lbank.py +7 -5
- ccxt/luno.py +4 -2
- ccxt/lykke.py +2 -2
- ccxt/mexc.py +56 -9
- ccxt/ndax.py +2 -2
- ccxt/oceanex.py +2 -2
- ccxt/okcoin.py +2 -2
- ccxt/okx.py +6 -4
- ccxt/onetrading.py +3 -3
- ccxt/phemex.py +2 -2
- ccxt/poloniex.py +3 -3
- ccxt/pro/__init__.py +1 -1
- ccxt/pro/bitget.py +2 -0
- ccxt/pro/bitvavo.py +2 -2
- ccxt/probit.py +2 -2
- ccxt/timex.py +6 -4
- ccxt/upbit.py +2 -2
- ccxt/wazirx.py +2 -2
- ccxt/whitebit.py +3 -3
- ccxt/woo.py +3 -3
- ccxt/yobit.py +2 -2
- {ccxt-4.2.88.dist-info → ccxt-4.2.89.dist-info}/METADATA +4 -4
- {ccxt-4.2.88.dist-info → ccxt-4.2.89.dist-info}/RECORD +150 -150
- {ccxt-4.2.88.dist-info → ccxt-4.2.89.dist-info}/WHEEL +0 -0
- {ccxt-4.2.88.dist-info → ccxt-4.2.89.dist-info}/top_level.txt +0 -0
ccxt/__init__.py
CHANGED
ccxt/ascendex.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.ascendex import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Account, Balances, Currency, Int, Leverage, Leverages, MarginMode, MarginModes, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
9
|
+
from ccxt.base.types import Account, Balances, Currencies, Currency, Int, Leverage, Leverages, MarginMode, MarginModes, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFees, Transaction, TransferEntry
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -395,7 +395,7 @@ class ascendex(Exchange, ImplicitAPI):
|
|
395
395
|
lowercaseAccount = account.lower()
|
396
396
|
return self.capitalize(lowercaseAccount)
|
397
397
|
|
398
|
-
def fetch_currencies(self, params={}):
|
398
|
+
def fetch_currencies(self, params={}) -> Currencies:
|
399
399
|
"""
|
400
400
|
fetches all available currencies on an exchange
|
401
401
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
@@ -1394,7 +1394,7 @@ class ascendex(Exchange, ImplicitAPI):
|
|
1394
1394
|
'trades': None,
|
1395
1395
|
}, market)
|
1396
1396
|
|
1397
|
-
def fetch_trading_fees(self, params={}):
|
1397
|
+
def fetch_trading_fees(self, params={}) -> TradingFees:
|
1398
1398
|
"""
|
1399
1399
|
fetch the trading fees for multiple markets
|
1400
1400
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
@@ -1437,6 +1437,8 @@ class ascendex(Exchange, ImplicitAPI):
|
|
1437
1437
|
'symbol': symbol,
|
1438
1438
|
'maker': self.safe_number(takerMaker, 'maker'),
|
1439
1439
|
'taker': self.safe_number(takerMaker, 'taker'),
|
1440
|
+
'percentage': None,
|
1441
|
+
'tierBased': None,
|
1440
1442
|
}
|
1441
1443
|
return result
|
1442
1444
|
|
ccxt/async_support/__init__.py
CHANGED
ccxt/async_support/ascendex.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.ascendex import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Account, Balances, Currency, Int, Leverage, Leverages, MarginMode, MarginModes, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
9
|
+
from ccxt.base.types import Account, Balances, Currencies, Currency, Int, Leverage, Leverages, MarginMode, MarginModes, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFees, Transaction, TransferEntry
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -395,7 +395,7 @@ class ascendex(Exchange, ImplicitAPI):
|
|
395
395
|
lowercaseAccount = account.lower()
|
396
396
|
return self.capitalize(lowercaseAccount)
|
397
397
|
|
398
|
-
async def fetch_currencies(self, params={}):
|
398
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
399
399
|
"""
|
400
400
|
fetches all available currencies on an exchange
|
401
401
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
@@ -1394,7 +1394,7 @@ class ascendex(Exchange, ImplicitAPI):
|
|
1394
1394
|
'trades': None,
|
1395
1395
|
}, market)
|
1396
1396
|
|
1397
|
-
async def fetch_trading_fees(self, params={}):
|
1397
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
1398
1398
|
"""
|
1399
1399
|
fetch the trading fees for multiple markets
|
1400
1400
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
@@ -1437,6 +1437,8 @@ class ascendex(Exchange, ImplicitAPI):
|
|
1437
1437
|
'symbol': symbol,
|
1438
1438
|
'maker': self.safe_number(takerMaker, 'maker'),
|
1439
1439
|
'taker': self.safe_number(takerMaker, 'taker'),
|
1440
|
+
'percentage': None,
|
1441
|
+
'tierBased': None,
|
1440
1442
|
}
|
1441
1443
|
return result
|
1442
1444
|
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
# -----------------------------------------------------------------------------
|
4
4
|
|
5
|
-
__version__ = '4.2.
|
5
|
+
__version__ = '4.2.89'
|
6
6
|
|
7
7
|
# -----------------------------------------------------------------------------
|
8
8
|
|
@@ -1406,7 +1406,8 @@ class Exchange(BaseExchange):
|
|
1406
1406
|
async def fetch_trading_fee(self, symbol: str, params={}):
|
1407
1407
|
if not self.has['fetchTradingFees']:
|
1408
1408
|
raise NotSupported(self.id + ' fetchTradingFee() is not supported yet')
|
1409
|
-
|
1409
|
+
fees = await self.fetch_trading_fees(params)
|
1410
|
+
return self.safe_dict(fees, symbol)
|
1410
1411
|
|
1411
1412
|
async def fetch_funding_rate(self, symbol: str, params={}):
|
1412
1413
|
if self.has['fetchFundingRates']:
|
ccxt/async_support/bigone.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bigone import ImplicitAPI
|
8
8
|
import asyncio
|
9
|
-
from ccxt.base.types import Balances, Bool, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
9
|
+
from ccxt.base.types import Balances, Bool, Currencies, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -340,7 +340,7 @@ class bigone(Exchange, ImplicitAPI):
|
|
340
340
|
},
|
341
341
|
})
|
342
342
|
|
343
|
-
async def fetch_currencies(self, params={}):
|
343
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
344
344
|
"""
|
345
345
|
fetches all available currencies on an exchange
|
346
346
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
ccxt/async_support/binance.py
CHANGED
@@ -8,7 +8,7 @@ from ccxt.abstract.binance import ImplicitAPI
|
|
8
8
|
import asyncio
|
9
9
|
import hashlib
|
10
10
|
import json
|
11
|
-
from ccxt.base.types import Balances, Currency, Greeks, Int, Leverage, Leverages, MarginMode, MarginModes, MarginModification, Market, MarketInterface, Num, Option, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
11
|
+
from ccxt.base.types import Balances, Currencies, Currency, Greeks, Int, Leverage, Leverages, MarginMode, MarginModes, MarginModification, Market, MarketInterface, Num, Option, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFeeInterface, TradingFees, Transaction, TransferEntry
|
12
12
|
from typing import List
|
13
13
|
from ccxt.base.errors import ExchangeError
|
14
14
|
from ccxt.base.errors import PermissionDenied
|
@@ -2593,7 +2593,7 @@ class binance(Exchange, ImplicitAPI):
|
|
2593
2593
|
response = await self.publicGetTime(query)
|
2594
2594
|
return self.safe_integer(response, 'serverTime')
|
2595
2595
|
|
2596
|
-
async def fetch_currencies(self, params={}):
|
2596
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
2597
2597
|
"""
|
2598
2598
|
fetches all available currencies on an exchange
|
2599
2599
|
:see: https://binance-docs.github.io/apidocs/spot/en/#all-coins-39-information-user_data
|
@@ -8037,7 +8037,7 @@ class binance(Exchange, ImplicitAPI):
|
|
8037
8037
|
# {id: '9a67628b16ba4988ae20d329333f16bc'}
|
8038
8038
|
return self.parse_transaction(response, currency)
|
8039
8039
|
|
8040
|
-
def parse_trading_fee(self, fee, market: Market = None):
|
8040
|
+
def parse_trading_fee(self, fee, market: Market = None) -> TradingFeeInterface:
|
8041
8041
|
#
|
8042
8042
|
# spot
|
8043
8043
|
# [
|
@@ -8062,9 +8062,11 @@ class binance(Exchange, ImplicitAPI):
|
|
8062
8062
|
'symbol': symbol,
|
8063
8063
|
'maker': self.safe_number_2(fee, 'makerCommission', 'makerCommissionRate'),
|
8064
8064
|
'taker': self.safe_number_2(fee, 'takerCommission', 'takerCommissionRate'),
|
8065
|
+
'percentage': None,
|
8066
|
+
'tierBased': None,
|
8065
8067
|
}
|
8066
8068
|
|
8067
|
-
async def fetch_trading_fee(self, symbol: str, params={}):
|
8069
|
+
async def fetch_trading_fee(self, symbol: str, params={}) -> TradingFeeInterface:
|
8068
8070
|
"""
|
8069
8071
|
fetch the trading fees for a market
|
8070
8072
|
:see: https://binance-docs.github.io/apidocs/spot/en/#trade-fee-user_data
|
@@ -8127,7 +8129,7 @@ class binance(Exchange, ImplicitAPI):
|
|
8127
8129
|
data = self.safe_dict(data, 0, {})
|
8128
8130
|
return self.parse_trading_fee(data, market)
|
8129
8131
|
|
8130
|
-
async def fetch_trading_fees(self, params={}):
|
8132
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
8131
8133
|
"""
|
8132
8134
|
fetch the trading fees for multiple markets
|
8133
8135
|
:see: https://binance-docs.github.io/apidocs/spot/en/#trade-fee-user_data
|
ccxt/async_support/bingx.py
CHANGED
@@ -8,7 +8,7 @@ from ccxt.abstract.bingx import ImplicitAPI
|
|
8
8
|
import asyncio
|
9
9
|
import hashlib
|
10
10
|
import numbers
|
11
|
-
from ccxt.base.types import Balances, Currency, Int, Leverage, MarginMode, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Position, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
11
|
+
from ccxt.base.types import Balances, Currencies, Currency, Int, Leverage, MarginMode, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Position, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
12
12
|
from typing import List
|
13
13
|
from ccxt.base.errors import ExchangeError
|
14
14
|
from ccxt.base.errors import PermissionDenied
|
@@ -455,7 +455,7 @@ class bingx(Exchange, ImplicitAPI):
|
|
455
455
|
data = self.safe_dict(response, 'data')
|
456
456
|
return self.safe_integer(data, 'serverTime')
|
457
457
|
|
458
|
-
async def fetch_currencies(self, params={}):
|
458
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
459
459
|
"""
|
460
460
|
fetches all available currencies on an exchange
|
461
461
|
:see: https://bingx-api.github.io/docs/#/common/account-api.html#All%20Coins
|
ccxt/async_support/bit2c.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bit2c import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Ticker, Trade
|
9
|
+
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Ticker, Trade, TradingFees
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -360,7 +360,7 @@ class bit2c(Exchange, ImplicitAPI):
|
|
360
360
|
raise ExchangeError(response)
|
361
361
|
return self.parse_trades(response, market, since, limit)
|
362
362
|
|
363
|
-
async def fetch_trading_fees(self, params={}):
|
363
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
364
364
|
"""
|
365
365
|
fetch the trading fees for multiple markets
|
366
366
|
:see: https://bit2c.co.il/home/api#balance
|
ccxt/async_support/bitbank.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bitbank import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Ticker, Trade, Transaction
|
9
|
+
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Ticker, Trade, TradingFees, Transaction
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -390,7 +390,7 @@ class bitbank(Exchange, ImplicitAPI):
|
|
390
390
|
trades = self.safe_list(data, 'transactions', [])
|
391
391
|
return self.parse_trades(trades, market, since, limit)
|
392
392
|
|
393
|
-
async def fetch_trading_fees(self, params={}):
|
393
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
394
394
|
"""
|
395
395
|
fetch the trading fees for multiple markets
|
396
396
|
:see: https://github.com/bitbankinc/bitbank-api-docs/blob/38d6d7c6f486c793872fd4b4087a0d090a04cd0a/rest-api.md#get-all-pairs-info
|
ccxt/async_support/bitfinex.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bitfinex import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
9
|
+
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFees, Transaction, TransferEntry
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -480,7 +480,7 @@ class bitfinex(Exchange, ImplicitAPI):
|
|
480
480
|
'info': fee,
|
481
481
|
}
|
482
482
|
|
483
|
-
async def fetch_trading_fees(self, params={}):
|
483
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
484
484
|
"""
|
485
485
|
fetch the trading fees for multiple markets
|
486
486
|
:see: https://docs.bitfinex.com/v1/reference/rest-auth-summary
|
ccxt/async_support/bitfinex2.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bitfinex2 import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
9
|
+
from ccxt.base.types import Balances, Currencies, Currency, Int, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFees, Transaction, TransferEntry
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -630,7 +630,7 @@ class bitfinex2(Exchange, ImplicitAPI):
|
|
630
630
|
})
|
631
631
|
return result
|
632
632
|
|
633
|
-
async def fetch_currencies(self, params={}):
|
633
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
634
634
|
"""
|
635
635
|
fetches all available currencies on an exchange
|
636
636
|
:see: https://docs.bitfinex.com/reference/rest-public-conf
|
@@ -2261,7 +2261,7 @@ class bitfinex2(Exchange, ImplicitAPI):
|
|
2261
2261
|
},
|
2262
2262
|
}
|
2263
2263
|
|
2264
|
-
async def fetch_trading_fees(self, params={}):
|
2264
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
2265
2265
|
"""
|
2266
2266
|
fetch the trading fees for multiple markets
|
2267
2267
|
:see: https://docs.bitfinex.com/reference/rest-auth-summary
|
ccxt/async_support/bitflyer.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bitflyer import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, Market, MarketInterface, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Trade, Transaction
|
9
|
+
from ccxt.base.types import Balances, Currency, Int, Market, MarketInterface, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Trade, TradingFeeInterface, Transaction
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import ArgumentsRequired
|
@@ -493,7 +493,7 @@ class bitflyer(Exchange, ImplicitAPI):
|
|
493
493
|
#
|
494
494
|
return self.parse_trades(response, market, since, limit)
|
495
495
|
|
496
|
-
async def fetch_trading_fee(self, symbol: str, params={}):
|
496
|
+
async def fetch_trading_fee(self, symbol: str, params={}) -> TradingFeeInterface:
|
497
497
|
"""
|
498
498
|
fetch the trading fees for a market
|
499
499
|
:see: https://lightning.bitflyer.com/docs?lang=en#get-trading-commission
|
@@ -518,6 +518,8 @@ class bitflyer(Exchange, ImplicitAPI):
|
|
518
518
|
'symbol': market['symbol'],
|
519
519
|
'maker': fee,
|
520
520
|
'taker': fee,
|
521
|
+
'percentage': None,
|
522
|
+
'tierBased': None,
|
521
523
|
}
|
522
524
|
|
523
525
|
async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: Num = None, params={}):
|
ccxt/async_support/bitget.py
CHANGED
@@ -8,7 +8,7 @@ from ccxt.abstract.bitget import ImplicitAPI
|
|
8
8
|
import asyncio
|
9
9
|
import hashlib
|
10
10
|
import json
|
11
|
-
from ccxt.base.types import Balances, Currency, FundingHistory, Int, Liquidation, Leverage, MarginMode, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Position, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
11
|
+
from ccxt.base.types import Balances, Currencies, Currency, FundingHistory, Int, Liquidation, Leverage, MarginMode, MarginModification, Market, Num, Order, OrderBook, OrderRequest, OrderSide, OrderType, Position, Str, Strings, Ticker, Tickers, Trade, TradingFeeInterface, TradingFees, Transaction, TransferEntry
|
12
12
|
from typing import List
|
13
13
|
from ccxt.base.errors import ExchangeError
|
14
14
|
from ccxt.base.errors import PermissionDenied
|
@@ -1814,7 +1814,7 @@ class bitget(Exchange, ImplicitAPI):
|
|
1814
1814
|
data = self.safe_value(response, 'data', [])
|
1815
1815
|
return self.parse_markets(data)
|
1816
1816
|
|
1817
|
-
async def fetch_currencies(self, params={}):
|
1817
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
1818
1818
|
"""
|
1819
1819
|
fetches all available currencies on an exchange
|
1820
1820
|
:see: https://www.bitget.com/api-doc/spot/market/Get-Coin-List
|
@@ -2558,7 +2558,10 @@ class bitget(Exchange, ImplicitAPI):
|
|
2558
2558
|
#
|
2559
2559
|
marketId = self.safe_string(ticker, 'symbol')
|
2560
2560
|
close = self.safe_string(ticker, 'lastPr')
|
2561
|
-
|
2561
|
+
timestampString = self.omit_zero(self.safe_string(ticker, 'ts')) # exchange sometimes provided 0
|
2562
|
+
timestamp = None
|
2563
|
+
if timestampString is not None:
|
2564
|
+
timestamp = self.parse_to_int(timestampString)
|
2562
2565
|
change = self.safe_string(ticker, 'change24h')
|
2563
2566
|
open24 = self.safe_string(ticker, 'open24')
|
2564
2567
|
open = self.safe_string(ticker, 'open')
|
@@ -3005,7 +3008,7 @@ class bitget(Exchange, ImplicitAPI):
|
|
3005
3008
|
data = self.safe_list(response, 'data', [])
|
3006
3009
|
return self.parse_trades(data, market, since, limit)
|
3007
3010
|
|
3008
|
-
async def fetch_trading_fee(self, symbol: str, params={}):
|
3011
|
+
async def fetch_trading_fee(self, symbol: str, params={}) -> TradingFeeInterface:
|
3009
3012
|
"""
|
3010
3013
|
fetch the trading fees for a market
|
3011
3014
|
:see: https://www.bitget.com/api-doc/common/public/Get-Trade-Rate
|
@@ -3043,7 +3046,7 @@ class bitget(Exchange, ImplicitAPI):
|
|
3043
3046
|
data = self.safe_value(response, 'data', {})
|
3044
3047
|
return self.parse_trading_fee(data, market)
|
3045
3048
|
|
3046
|
-
async def fetch_trading_fees(self, params={}):
|
3049
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
3047
3050
|
"""
|
3048
3051
|
fetch the trading fees for multiple markets
|
3049
3052
|
:see: https://www.bitget.com/api-doc/spot/market/Get-Symbols
|
@@ -3163,6 +3166,8 @@ class bitget(Exchange, ImplicitAPI):
|
|
3163
3166
|
'symbol': self.safe_symbol(marketId, market),
|
3164
3167
|
'maker': self.safe_number(data, 'makerFeeRate'),
|
3165
3168
|
'taker': self.safe_number(data, 'takerFeeRate'),
|
3169
|
+
'percentage': None,
|
3170
|
+
'tierBased': None,
|
3166
3171
|
}
|
3167
3172
|
|
3168
3173
|
def parse_ohlcv(self, ohlcv, market: Market = None) -> list:
|
ccxt/async_support/bitmart.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bitmart import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
9
|
+
from ccxt.base.types import Balances, Currencies, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFeeInterface, Transaction, TransferEntry
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -985,7 +985,7 @@ class bitmart(Exchange, ImplicitAPI):
|
|
985
985
|
contract = await self.fetch_contract_markets(params)
|
986
986
|
return self.array_concat(spot, contract)
|
987
987
|
|
988
|
-
async def fetch_currencies(self, params={}):
|
988
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
989
989
|
"""
|
990
990
|
fetches all available currencies on an exchange
|
991
991
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
@@ -1999,7 +1999,7 @@ class bitmart(Exchange, ImplicitAPI):
|
|
1999
1999
|
#
|
2000
2000
|
return self.custom_parse_balance(response, marketType)
|
2001
2001
|
|
2002
|
-
def parse_trading_fee(self, fee, market: Market = None):
|
2002
|
+
def parse_trading_fee(self, fee, market: Market = None) -> TradingFeeInterface:
|
2003
2003
|
#
|
2004
2004
|
# {
|
2005
2005
|
# "symbol": "ETH_USDT",
|
@@ -2014,9 +2014,11 @@ class bitmart(Exchange, ImplicitAPI):
|
|
2014
2014
|
'symbol': symbol,
|
2015
2015
|
'maker': self.safe_number(fee, 'maker_fee_rate'),
|
2016
2016
|
'taker': self.safe_number(fee, 'taker_fee_rate'),
|
2017
|
+
'percentage': None,
|
2018
|
+
'tierBased': None,
|
2017
2019
|
}
|
2018
2020
|
|
2019
|
-
async def fetch_trading_fee(self, symbol: str, params={}):
|
2021
|
+
async def fetch_trading_fee(self, symbol: str, params={}) -> TradingFeeInterface:
|
2020
2022
|
"""
|
2021
2023
|
fetch the trading fees for a market
|
2022
2024
|
:param str symbol: unified market symbol
|
ccxt/async_support/bitmex.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bitmex import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, Leverage, Leverages, Market, MarketType, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
|
9
|
+
from ccxt.base.types import Balances, Currencies, Currency, Int, Leverage, Leverages, Market, MarketType, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import PermissionDenied
|
@@ -290,7 +290,7 @@ class bitmex(Exchange, ImplicitAPI):
|
|
290
290
|
},
|
291
291
|
})
|
292
292
|
|
293
|
-
async def fetch_currencies(self, params={}):
|
293
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
294
294
|
"""
|
295
295
|
fetches all available currencies on an exchange
|
296
296
|
:see: https://www.bitmex.com/api/explorer/#not /Wallet/Wallet_getAssetsConfig
|
ccxt/async_support/bitopro.py
CHANGED
@@ -7,7 +7,7 @@ from ccxt.async_support.base.exchange import Exchange
|
|
7
7
|
from ccxt.abstract.bitopro import ImplicitAPI
|
8
8
|
import hashlib
|
9
9
|
import math
|
10
|
-
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
|
10
|
+
from ccxt.base.types import Balances, Currencies, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFees, Transaction
|
11
11
|
from typing import List
|
12
12
|
from ccxt.base.errors import ExchangeError
|
13
13
|
from ccxt.base.errors import ArgumentsRequired
|
@@ -220,7 +220,7 @@ class bitopro(Exchange, ImplicitAPI):
|
|
220
220
|
},
|
221
221
|
})
|
222
222
|
|
223
|
-
async def fetch_currencies(self, params={}):
|
223
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
224
224
|
"""
|
225
225
|
fetches all available currencies on an exchange
|
226
226
|
:see: https://github.com/bitoex/bitopro-offical-api-docs/blob/master/api/v3/public/get_currency_info.md
|
@@ -617,7 +617,7 @@ class bitopro(Exchange, ImplicitAPI):
|
|
617
617
|
#
|
618
618
|
return self.parse_trades(trades, market, since, limit)
|
619
619
|
|
620
|
-
async def fetch_trading_fees(self, params={}):
|
620
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
621
621
|
"""
|
622
622
|
fetch the trading fees for multiple markets
|
623
623
|
:see: https://github.com/bitoex/bitopro-offical-api-docs/blob/master/api/v3/public/get_limitations_and_fees.md
|
ccxt/async_support/bitrue.py
CHANGED
@@ -8,7 +8,7 @@ from ccxt.abstract.bitrue import ImplicitAPI
|
|
8
8
|
import asyncio
|
9
9
|
import hashlib
|
10
10
|
import json
|
11
|
-
from ccxt.base.types import Balances, Currency, Int, MarginModification, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
11
|
+
from ccxt.base.types import Balances, Currencies, Currency, Int, MarginModification, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, TransferEntry
|
12
12
|
from typing import List
|
13
13
|
from ccxt.base.errors import ExchangeError
|
14
14
|
from ccxt.base.errors import PermissionDenied
|
@@ -593,7 +593,7 @@ class bitrue(Exchange, ImplicitAPI):
|
|
593
593
|
}
|
594
594
|
return self.safe_string_2(networksById, networkId, uppercaseNetworkId, networkId)
|
595
595
|
|
596
|
-
async def fetch_currencies(self, params={}):
|
596
|
+
async def fetch_currencies(self, params={}) -> Currencies:
|
597
597
|
"""
|
598
598
|
fetches all available currencies on an exchange
|
599
599
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
ccxt/async_support/bitso.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
from ccxt.async_support.base.exchange import Exchange
|
7
7
|
from ccxt.abstract.bitso import ImplicitAPI
|
8
8
|
import hashlib
|
9
|
-
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Trade, Transaction
|
9
|
+
from ccxt.base.types import Balances, Currency, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Trade, TradingFees, Transaction
|
10
10
|
from typing import List
|
11
11
|
from ccxt.base.errors import ExchangeError
|
12
12
|
from ccxt.base.errors import ArgumentsRequired
|
@@ -814,7 +814,7 @@ class bitso(Exchange, ImplicitAPI):
|
|
814
814
|
response = await self.publicGetTrades(self.extend(request, params))
|
815
815
|
return self.parse_trades(response['payload'], market, since, limit)
|
816
816
|
|
817
|
-
async def fetch_trading_fees(self, params={}):
|
817
|
+
async def fetch_trading_fees(self, params={}) -> TradingFees:
|
818
818
|
"""
|
819
819
|
fetch the trading fees for multiple markets
|
820
820
|
:see: https://docs.bitso.com/bitso-api/docs/list-fees
|