ccxt 4.4.43__py2.py3-none-any.whl → 4.4.44__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.
Files changed (78) hide show
  1. ccxt/__init__.py +1 -1
  2. ccxt/abstract/binance.py +1 -0
  3. ccxt/abstract/binancecoinm.py +1 -0
  4. ccxt/abstract/binanceus.py +1 -0
  5. ccxt/abstract/binanceusdm.py +1 -0
  6. ccxt/async_support/__init__.py +1 -1
  7. ccxt/async_support/base/exchange.py +1 -1
  8. ccxt/async_support/binance.py +57 -45
  9. ccxt/async_support/bingx.py +5 -0
  10. ccxt/async_support/bitfinex.py +6 -2
  11. ccxt/async_support/bitget.py +3 -1
  12. ccxt/async_support/bitmart.py +4 -7
  13. ccxt/async_support/bitmex.py +3 -5
  14. ccxt/async_support/bitstamp.py +5 -0
  15. ccxt/async_support/bybit.py +8 -23
  16. ccxt/async_support/coinbase.py +13 -9
  17. ccxt/async_support/coinbaseinternational.py +13 -9
  18. ccxt/async_support/coincatch.py +2 -2
  19. ccxt/async_support/coinex.py +5 -5
  20. ccxt/async_support/cryptocom.py +4 -2
  21. ccxt/async_support/defx.py +2 -2
  22. ccxt/async_support/delta.py +1 -1
  23. ccxt/async_support/gate.py +9 -4
  24. ccxt/async_support/gemini.py +5 -0
  25. ccxt/async_support/hashkey.py +9 -9
  26. ccxt/async_support/htx.py +101 -3
  27. ccxt/async_support/hyperliquid.py +5 -0
  28. ccxt/async_support/kraken.py +9 -2
  29. ccxt/async_support/krakenfutures.py +5 -0
  30. ccxt/async_support/kucoin.py +9 -7
  31. ccxt/async_support/kucoinfutures.py +5 -5
  32. ccxt/async_support/mexc.py +18 -12
  33. ccxt/async_support/ndax.py +1 -1
  34. ccxt/async_support/oceanex.py +1 -1
  35. ccxt/async_support/okx.py +5 -6
  36. ccxt/async_support/whitebit.py +4 -2
  37. ccxt/async_support/woo.py +5 -3
  38. ccxt/async_support/woofipro.py +5 -2
  39. ccxt/base/exchange.py +1 -1
  40. ccxt/binance.py +57 -45
  41. ccxt/bingx.py +5 -0
  42. ccxt/bitfinex.py +6 -2
  43. ccxt/bitget.py +3 -1
  44. ccxt/bitmart.py +4 -7
  45. ccxt/bitmex.py +3 -5
  46. ccxt/bitstamp.py +5 -0
  47. ccxt/bybit.py +8 -23
  48. ccxt/coinbase.py +13 -9
  49. ccxt/coinbaseinternational.py +13 -9
  50. ccxt/coincatch.py +2 -2
  51. ccxt/coinex.py +5 -5
  52. ccxt/cryptocom.py +4 -2
  53. ccxt/defx.py +2 -2
  54. ccxt/delta.py +1 -1
  55. ccxt/gate.py +9 -4
  56. ccxt/gemini.py +5 -0
  57. ccxt/hashkey.py +9 -9
  58. ccxt/htx.py +101 -3
  59. ccxt/hyperliquid.py +5 -0
  60. ccxt/kraken.py +9 -2
  61. ccxt/krakenfutures.py +5 -0
  62. ccxt/kucoin.py +9 -7
  63. ccxt/kucoinfutures.py +5 -5
  64. ccxt/mexc.py +18 -12
  65. ccxt/ndax.py +1 -1
  66. ccxt/oceanex.py +1 -1
  67. ccxt/okx.py +5 -6
  68. ccxt/pro/__init__.py +1 -1
  69. ccxt/pro/bitcoincom.py +4 -1
  70. ccxt/pro/bitopro.py +1 -1
  71. ccxt/whitebit.py +4 -2
  72. ccxt/woo.py +5 -3
  73. ccxt/woofipro.py +5 -2
  74. {ccxt-4.4.43.dist-info → ccxt-4.4.44.dist-info}/METADATA +4 -4
  75. {ccxt-4.4.43.dist-info → ccxt-4.4.44.dist-info}/RECORD +78 -78
  76. {ccxt-4.4.43.dist-info → ccxt-4.4.44.dist-info}/LICENSE.txt +0 -0
  77. {ccxt-4.4.43.dist-info → ccxt-4.4.44.dist-info}/WHEEL +0 -0
  78. {ccxt-4.4.43.dist-info → ccxt-4.4.44.dist-info}/top_level.txt +0 -0
ccxt/__init__.py CHANGED
@@ -22,7 +22,7 @@
22
22
 
23
23
  # ----------------------------------------------------------------------------
24
24
 
25
- __version__ = '4.4.43'
25
+ __version__ = '4.4.44'
26
26
 
27
27
  # ----------------------------------------------------------------------------
28
28
 
ccxt/abstract/binance.py CHANGED
@@ -762,3 +762,4 @@ class ImplicitAPI:
762
762
  papi_delete_margin_allopenorders = papiDeleteMarginAllOpenOrders = Entry('margin/allOpenOrders', 'papi', 'DELETE', {'cost': 5})
763
763
  papi_delete_margin_orderlist = papiDeleteMarginOrderList = Entry('margin/orderList', 'papi', 'DELETE', {'cost': 2})
764
764
  papi_delete_listenkey = papiDeleteListenKey = Entry('listenKey', 'papi', 'DELETE', {'cost': 0.2})
765
+ papiv2_get_um_account = papiV2GetUmAccount = Entry('um/account', 'papiV2', 'GET', {'cost': 1})
@@ -762,3 +762,4 @@ class ImplicitAPI:
762
762
  papi_delete_margin_allopenorders = papiDeleteMarginAllOpenOrders = Entry('margin/allOpenOrders', 'papi', 'DELETE', {'cost': 5})
763
763
  papi_delete_margin_orderlist = papiDeleteMarginOrderList = Entry('margin/orderList', 'papi', 'DELETE', {'cost': 2})
764
764
  papi_delete_listenkey = papiDeleteListenKey = Entry('listenKey', 'papi', 'DELETE', {'cost': 0.2})
765
+ papiv2_get_um_account = papiV2GetUmAccount = Entry('um/account', 'papiV2', 'GET', {'cost': 1})
@@ -814,3 +814,4 @@ class ImplicitAPI:
814
814
  papi_delete_margin_allopenorders = papiDeleteMarginAllOpenOrders = Entry('margin/allOpenOrders', 'papi', 'DELETE', {'cost': 5})
815
815
  papi_delete_margin_orderlist = papiDeleteMarginOrderList = Entry('margin/orderList', 'papi', 'DELETE', {'cost': 2})
816
816
  papi_delete_listenkey = papiDeleteListenKey = Entry('listenKey', 'papi', 'DELETE', {'cost': 0.2})
817
+ papiv2_get_um_account = papiV2GetUmAccount = Entry('um/account', 'papiV2', 'GET', {'cost': 1})
@@ -762,3 +762,4 @@ class ImplicitAPI:
762
762
  papi_delete_margin_allopenorders = papiDeleteMarginAllOpenOrders = Entry('margin/allOpenOrders', 'papi', 'DELETE', {'cost': 5})
763
763
  papi_delete_margin_orderlist = papiDeleteMarginOrderList = Entry('margin/orderList', 'papi', 'DELETE', {'cost': 2})
764
764
  papi_delete_listenkey = papiDeleteListenKey = Entry('listenKey', 'papi', 'DELETE', {'cost': 0.2})
765
+ papiv2_get_um_account = papiV2GetUmAccount = Entry('um/account', 'papiV2', 'GET', {'cost': 1})
@@ -4,7 +4,7 @@
4
4
 
5
5
  # -----------------------------------------------------------------------------
6
6
 
7
- __version__ = '4.4.43'
7
+ __version__ = '4.4.44'
8
8
 
9
9
  # -----------------------------------------------------------------------------
10
10
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  # -----------------------------------------------------------------------------
4
4
 
5
- __version__ = '4.4.43'
5
+ __version__ = '4.4.44'
6
6
 
7
7
  # -----------------------------------------------------------------------------
8
8
 
@@ -249,6 +249,7 @@ class binance(Exchange, ImplicitAPI):
249
249
  'private': 'https://api.binance.com/api/v3',
250
250
  'v1': 'https://api.binance.com/api/v1',
251
251
  'papi': 'https://papi.binance.com/papi/v1',
252
+ 'papiV2': 'https://papi.binance.com/papi/v2',
252
253
  },
253
254
  'www': 'https://www.binance.com',
254
255
  'referral': {
@@ -1191,6 +1192,11 @@ class binance(Exchange, ImplicitAPI):
1191
1192
  'listenKey': 0.2,
1192
1193
  },
1193
1194
  },
1195
+ 'papiV2': {
1196
+ 'get': {
1197
+ 'um/account': 1,
1198
+ },
1199
+ },
1194
1200
  },
1195
1201
  'fees': {
1196
1202
  'trading': {
@@ -1583,7 +1589,6 @@ class binance(Exchange, ImplicitAPI):
1583
1589
  },
1584
1590
  },
1585
1591
  'features': {
1586
- # https://developers.binance.com/docs/binance-spot-api-docs/rest-api#:~:text=quoteOrderQty
1587
1592
  'spot': {
1588
1593
  'sandbox': True,
1589
1594
  'createOrder': {
@@ -1601,12 +1606,13 @@ class binance(Exchange, ImplicitAPI):
1601
1606
  'GTD': False,
1602
1607
  },
1603
1608
  'hedged': True,
1609
+ 'leverage': False,
1610
+ 'marketBuyRequiresPrice': False,
1611
+ 'marketBuyByCost': True,
1604
1612
  # exchange-supported features
1605
- 'selfTradePrevention': True,
1613
+ 'selfTradePrevention': True, # todo
1606
1614
  'trailing': True,
1607
- 'twap': False,
1608
- 'iceberg': True,
1609
- 'oco': False,
1615
+ 'iceberg': True, # todo implementation
1610
1616
  },
1611
1617
  'createOrders': None,
1612
1618
  'fetchMyTrades': {
@@ -1669,11 +1675,12 @@ class binance(Exchange, ImplicitAPI):
1669
1675
  },
1670
1676
  'hedged': True,
1671
1677
  # exchange-supported features
1672
- 'selfTradePrevention': True,
1678
+ 'selfTradePrevention': True, # todo
1673
1679
  'trailing': True,
1674
- 'twap': False,
1675
1680
  'iceberg': False,
1676
- 'oco': False,
1681
+ 'leverage': False,
1682
+ 'marketBuyRequiresPrice': False,
1683
+ 'marketBuyByCost': True,
1677
1684
  },
1678
1685
  'createOrders': {
1679
1686
  'max': 5,
@@ -2826,7 +2833,7 @@ class binance(Exchange, ImplicitAPI):
2826
2833
  """
2827
2834
  fetches the current integer timestamp in milliseconds from the exchange server
2828
2835
 
2829
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#check-server-time # spot
2836
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#check-server-time # spot
2830
2837
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Check-Server-Time # swap
2831
2838
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Check-Server-time # future
2832
2839
 
@@ -3062,7 +3069,7 @@ class binance(Exchange, ImplicitAPI):
3062
3069
  """
3063
3070
  retrieves data on all markets for binance
3064
3071
 
3065
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#exchange-information # spot
3072
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#exchange-information # spot
3066
3073
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Exchange-Information # swap
3067
3074
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Exchange-Information # future
3068
3075
  https://developers.binance.com/docs/derivatives/option/market-data/Exchange-Information # option
@@ -3617,7 +3624,7 @@ class binance(Exchange, ImplicitAPI):
3617
3624
  """
3618
3625
  query for balance and get the amount of funds available for trading or funds locked in orders
3619
3626
 
3620
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#account-information-user_data # spot
3627
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#account-information-user_data # spot
3621
3628
  https://developers.binance.com/docs/margin_trading/account/Query-Cross-Margin-Account-Details # cross margin
3622
3629
  https://developers.binance.com/docs/margin_trading/account/Query-Isolated-Margin-Account-Info # isolated margin
3623
3630
  https://developers.binance.com/docs/wallet/asset/funding-wallet # funding
@@ -3875,7 +3882,7 @@ class binance(Exchange, ImplicitAPI):
3875
3882
  """
3876
3883
  fetches information on open orders with bid(buy) and ask(sell) prices, volumes and other data
3877
3884
 
3878
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#order-book # spot
3885
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#order-book # spot
3879
3886
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Order-Book # swap
3880
3887
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Order-Book # future
3881
3888
  https://developers.binance.com/docs/derivatives/option/market-data/Order-Book # option
@@ -4132,8 +4139,8 @@ class binance(Exchange, ImplicitAPI):
4132
4139
  """
4133
4140
  fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
4134
4141
 
4135
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#24hr-ticker-price-change-statistics # spot
4136
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#rolling-window-price-change-statistics # spot
4142
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#24hr-ticker-price-change-statistics # spot
4143
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#rolling-window-price-change-statistics # spot
4137
4144
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/24hr-Ticker-Price-Change-Statistics # swap
4138
4145
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/24hr-Ticker-Price-Change-Statistics # future
4139
4146
  https://developers.binance.com/docs/derivatives/option/market-data/24hr-Ticker-Price-Change-Statistics # option
@@ -4171,7 +4178,7 @@ class binance(Exchange, ImplicitAPI):
4171
4178
  """
4172
4179
  fetches the bid and ask price and volume for multiple markets
4173
4180
 
4174
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#symbol-order-book-ticker # spot
4181
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#symbol-order-book-ticker # spot
4175
4182
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Symbol-Order-Book-Ticker # swap
4176
4183
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Symbol-Order-Book-Ticker # future
4177
4184
 
@@ -4205,7 +4212,7 @@ class binance(Exchange, ImplicitAPI):
4205
4212
  """
4206
4213
  fetches the last price for multiple markets
4207
4214
 
4208
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#symbol-price-ticker # spot
4215
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#symbol-price-ticker # spot
4209
4216
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Symbol-Price-Ticker # swap
4210
4217
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Symbol-Price-Ticker # future
4211
4218
 
@@ -4306,7 +4313,7 @@ class binance(Exchange, ImplicitAPI):
4306
4313
  """
4307
4314
  fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
4308
4315
 
4309
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#24hr-ticker-price-change-statistics # spot
4316
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#24hr-ticker-price-change-statistics # spot
4310
4317
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/24hr-Ticker-Price-Change-Statistics # swap
4311
4318
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/24hr-Ticker-Price-Change-Statistics # future
4312
4319
  https://developers.binance.com/docs/derivatives/option/market-data/24hr-Ticker-Price-Change-Statistics # option
@@ -4467,7 +4474,7 @@ class binance(Exchange, ImplicitAPI):
4467
4474
  """
4468
4475
  fetches historical candlestick data containing the open, high, low, and close price, and the volume of a market
4469
4476
 
4470
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#klinecandlestick-data
4477
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#klinecandlestick-data
4471
4478
  https://developers.binance.com/docs/derivatives/option/market-data/Kline-Candlestick-Data
4472
4479
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Kline-Candlestick-Data
4473
4480
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Index-Price-Kline-Candlestick-Data
@@ -4843,17 +4850,17 @@ class binance(Exchange, ImplicitAPI):
4843
4850
  get the list of most recent trades for a particular symbol
4844
4851
  Default fetchTradesMethod
4845
4852
 
4846
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#compressedaggregate-trades-list # publicGetAggTrades(spot)
4853
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#compressedaggregate-trades-list # publicGetAggTrades(spot)
4847
4854
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Compressed-Aggregate-Trades-List # fapiPublicGetAggTrades(swap)
4848
4855
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Compressed-Aggregate-Trades-List # dapiPublicGetAggTrades(future)
4849
4856
  https://developers.binance.com/docs/derivatives/option/market-data/Recent-Trades-List # eapiPublicGetTrades(option)
4850
4857
 
4851
4858
  Other fetchTradesMethod
4852
4859
 
4853
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#recent-trades-list # publicGetTrades(spot)
4860
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#recent-trades-list # publicGetTrades(spot)
4854
4861
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Recent-Trades-List # fapiPublicGetTrades(swap)
4855
4862
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Recent-Trades-List # dapiPublicGetTrades(future)
4856
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#old-trade-lookup # publicGetHistoricalTrades(spot)
4863
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#old-trade-lookup # publicGetHistoricalTrades(spot)
4857
4864
  https://developers.binance.com/docs/derivatives/usds-margined-futures/market-data/rest-api/Old-Trades-Lookup # fapiPublicGetHistoricalTrades(swap)
4858
4865
  https://developers.binance.com/docs/derivatives/coin-margined-futures/market-data/Old-Trades-Lookup # dapiPublicGetHistoricalTrades(future)
4859
4866
  https://developers.binance.com/docs/derivatives/option/market-data/Old-Trades-Lookup # eapiPublicGetHistoricalTrades(option)
@@ -4980,7 +4987,7 @@ class binance(Exchange, ImplicitAPI):
4980
4987
  @ignore
4981
4988
  edit a trade order
4982
4989
 
4983
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#cancel-an-existing-order-and-send-a-new-order-trade
4990
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#cancel-an-existing-order-and-send-a-new-order-trade
4984
4991
 
4985
4992
  :param str id: cancel order id
4986
4993
  :param str symbol: unified symbol of the market to create an order in
@@ -5220,7 +5227,7 @@ class binance(Exchange, ImplicitAPI):
5220
5227
  """
5221
5228
  edit a trade order
5222
5229
 
5223
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#cancel-an-existing-order-and-send-a-new-order-trade
5230
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#cancel-an-existing-order-and-send-a-new-order-trade
5224
5231
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Modify-Order
5225
5232
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/Modify-Order
5226
5233
 
@@ -5895,13 +5902,13 @@ class binance(Exchange, ImplicitAPI):
5895
5902
  """
5896
5903
  create a trade order
5897
5904
 
5898
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#new-order-trade
5899
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#test-new-order-trade
5905
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#new-order-trade
5906
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#test-new-order-trade
5900
5907
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/New-Order
5901
5908
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/New-Order
5902
5909
  https://developers.binance.com/docs/derivatives/option/trade/New-Order
5903
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#sor
5904
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#test-new-order-using-sor-trade
5910
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#sor
5911
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#test-new-order-using-sor-trade
5905
5912
  https://developers.binance.com/docs/derivatives/portfolio-margin/trade/New-UM-Order
5906
5913
  https://developers.binance.com/docs/derivatives/portfolio-margin/trade/New-CM-Order
5907
5914
  https://developers.binance.com/docs/derivatives/portfolio-margin/trade/New-Margin-Order
@@ -5927,6 +5934,7 @@ class binance(Exchange, ImplicitAPI):
5927
5934
  :param str [params.stopLossOrTakeProfit]: 'stopLoss' or 'takeProfit', required for spot trailing orders
5928
5935
  :param str [params.positionSide]: *swap and portfolio margin only* "BOTH" for one-way mode, "LONG" for buy side of hedged mode, "SHORT" for sell side of hedged mode
5929
5936
  :param bool [params.hedged]: *swap and portfolio margin only* True for hedged mode, False for one way mode, default is False
5937
+ :param float [params.cost]: *spot market buy only* the quote quantity that can be used alternative for the amount
5930
5938
  :returns dict: an `order structure <https://docs.ccxt.com/#/?id=order-structure>`
5931
5939
  """
5932
5940
  await self.load_markets()
@@ -6235,7 +6243,7 @@ class binance(Exchange, ImplicitAPI):
6235
6243
  """
6236
6244
  create a market order by providing the symbol, side and cost
6237
6245
 
6238
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#new-order-trade
6246
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#new-order-trade
6239
6247
 
6240
6248
  :param str symbol: unified symbol of the market to create an order in
6241
6249
  :param str side: 'buy' or 'sell'
@@ -6247,14 +6255,16 @@ class binance(Exchange, ImplicitAPI):
6247
6255
  market = self.market(symbol)
6248
6256
  if not market['spot']:
6249
6257
  raise NotSupported(self.id + ' createMarketOrderWithCost() supports spot orders only')
6250
- params['cost'] = cost
6251
- return await self.create_order(symbol, 'market', side, cost, None, params)
6258
+ req = {
6259
+ 'cost': cost,
6260
+ }
6261
+ return await self.create_order(symbol, 'market', side, 0, None, self.extend(req, params))
6252
6262
 
6253
6263
  async def create_market_buy_order_with_cost(self, symbol: str, cost: float, params={}):
6254
6264
  """
6255
6265
  create a market buy order by providing the symbol and cost
6256
6266
 
6257
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#new-order-trade
6267
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#new-order-trade
6258
6268
 
6259
6269
  :param str symbol: unified symbol of the market to create an order in
6260
6270
  :param float cost: how much you want to trade in units of the quote currency
@@ -6265,14 +6275,16 @@ class binance(Exchange, ImplicitAPI):
6265
6275
  market = self.market(symbol)
6266
6276
  if not market['spot']:
6267
6277
  raise NotSupported(self.id + ' createMarketBuyOrderWithCost() supports spot orders only')
6268
- params['cost'] = cost
6269
- return await self.create_order(symbol, 'market', 'buy', cost, None, params)
6278
+ req = {
6279
+ 'cost': cost,
6280
+ }
6281
+ return await self.create_order(symbol, 'market', 'buy', 0, None, self.extend(req, params))
6270
6282
 
6271
6283
  async def create_market_sell_order_with_cost(self, symbol: str, cost: float, params={}):
6272
6284
  """
6273
6285
  create a market sell order by providing the symbol and cost
6274
6286
 
6275
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#new-order-trade
6287
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#new-order-trade
6276
6288
 
6277
6289
  :param str symbol: unified symbol of the market to create an order in
6278
6290
  :param float cost: how much you want to trade in units of the quote currency
@@ -6290,7 +6302,7 @@ class binance(Exchange, ImplicitAPI):
6290
6302
  """
6291
6303
  fetches information on an order made by the user
6292
6304
 
6293
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#query-order-user_data
6305
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#query-order-user_data
6294
6306
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Query-Order
6295
6307
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/Query-Order
6296
6308
  https://developers.binance.com/docs/derivatives/option/trade/Query-Single-Order
@@ -6355,7 +6367,7 @@ class binance(Exchange, ImplicitAPI):
6355
6367
  """
6356
6368
  fetches information on multiple orders made by the user
6357
6369
 
6358
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#all-orders-user_data
6370
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#all-orders-user_data
6359
6371
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/All-Orders
6360
6372
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/All-Orders
6361
6373
  https://developers.binance.com/docs/derivatives/option/trade/Query-Option-Order-History
@@ -6614,7 +6626,7 @@ class binance(Exchange, ImplicitAPI):
6614
6626
  """
6615
6627
  fetch all unfilled currently open orders
6616
6628
 
6617
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#current-open-orders-user_data
6629
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#current-open-orders-user_data
6618
6630
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Current-All-Open-Orders
6619
6631
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/Current-All-Open-Orders
6620
6632
  https://developers.binance.com/docs/derivatives/option/trade/Query-Current-Open-Option-Orders
@@ -6900,7 +6912,7 @@ class binance(Exchange, ImplicitAPI):
6900
6912
  """
6901
6913
  fetches information on multiple closed orders made by the user
6902
6914
 
6903
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#all-orders-user_data
6915
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#all-orders-user_data
6904
6916
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/All-Orders
6905
6917
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/All-Orders
6906
6918
  https://developers.binance.com/docs/derivatives/option/trade/Query-Option-Order-History
@@ -6929,7 +6941,7 @@ class binance(Exchange, ImplicitAPI):
6929
6941
  """
6930
6942
  fetches information on multiple canceled orders made by the user
6931
6943
 
6932
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#all-orders-user_data
6944
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#all-orders-user_data
6933
6945
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/All-Orders
6934
6946
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/All-Orders
6935
6947
  https://developers.binance.com/docs/derivatives/option/trade/Query-Option-Order-History
@@ -6958,7 +6970,7 @@ class binance(Exchange, ImplicitAPI):
6958
6970
  """
6959
6971
  fetches information on multiple canceled orders made by the user
6960
6972
 
6961
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#all-orders-user_data
6973
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#all-orders-user_data
6962
6974
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/All-Orders
6963
6975
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/All-Orders
6964
6976
  https://developers.binance.com/docs/derivatives/option/trade/Query-Option-Order-History
@@ -6990,7 +7002,7 @@ class binance(Exchange, ImplicitAPI):
6990
7002
  """
6991
7003
  cancels an open order
6992
7004
 
6993
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#cancel-order-trade
7005
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#cancel-order-trade
6994
7006
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Cancel-Order
6995
7007
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/Cancel-Order
6996
7008
  https://developers.binance.com/docs/derivatives/option/trade/Cancel-Option-Order
@@ -7071,7 +7083,7 @@ class binance(Exchange, ImplicitAPI):
7071
7083
  """
7072
7084
  cancel all open orders in a market
7073
7085
 
7074
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#cancel-all-open-orders-on-a-symbol-trade
7086
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#cancel-all-open-orders-on-a-symbol-trade
7075
7087
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Cancel-All-Open-Orders
7076
7088
  https://developers.binance.com/docs/derivatives/option/trade/Cancel-all-Option-orders-on-specific-symbol
7077
7089
  https://developers.binance.com/docs/margin_trading/trade/Margin-Account-Cancel-All-Open-Orders
@@ -7296,7 +7308,7 @@ class binance(Exchange, ImplicitAPI):
7296
7308
  """
7297
7309
  fetch all the trades made from a single order
7298
7310
 
7299
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#account-trade-list-user_data
7311
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#account-trade-list-user_data
7300
7312
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Account-Trade-List
7301
7313
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/Account-Trade-List
7302
7314
  https://developers.binance.com/docs/margin_trading/trade/Query-Margin-Account-Trade-List
@@ -7325,7 +7337,7 @@ class binance(Exchange, ImplicitAPI):
7325
7337
  """
7326
7338
  fetch all trades made by the user
7327
7339
 
7328
- https://developers.binance.com/docs/binance-spot-api-docs/rest-api#account-trade-list-user_data
7340
+ https://developers.binance.com/docs/binance-spot-api-docs/rest-api/public-api-endpoints#account-trade-list-user_data
7329
7341
  https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Account-Trade-List
7330
7342
  https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/Account-Trade-List
7331
7343
  https://developers.binance.com/docs/margin_trading/trade/Query-Margin-Account-Trade-List
@@ -11061,7 +11073,7 @@ class binance(Exchange, ImplicitAPI):
11061
11073
  body = self.urlencode(params)
11062
11074
  else:
11063
11075
  raise AuthenticationError(self.id + ' userDataStream endpoint requires `apiKey` credential')
11064
- elif (api == 'private') or (api == 'eapiPrivate') or (api == 'sapi' and path != 'system/status') or (api == 'sapiV2') or (api == 'sapiV3') or (api == 'sapiV4') or (api == 'dapiPrivate') or (api == 'dapiPrivateV2') or (api == 'fapiPrivate') or (api == 'fapiPrivateV2') or (api == 'fapiPrivateV3') or (api == 'papi' and path != 'ping'):
11076
+ elif (api == 'private') or (api == 'eapiPrivate') or (api == 'sapi' and path != 'system/status') or (api == 'sapiV2') or (api == 'sapiV3') or (api == 'sapiV4') or (api == 'dapiPrivate') or (api == 'dapiPrivateV2') or (api == 'fapiPrivate') or (api == 'fapiPrivateV2') or (api == 'fapiPrivateV3') or (api == 'papi' and path != 'ping') or (api == 'papiV2'):
11065
11077
  self.check_required_credentials()
11066
11078
  if method == 'POST' and ((path == 'order') or (path == 'sor/order')):
11067
11079
  # inject in implicit API calls
@@ -576,6 +576,11 @@ class bingx(Exchange, ImplicitAPI):
576
576
  },
577
577
  'hedged': True,
578
578
  'trailing': True,
579
+ 'leverage': False,
580
+ 'marketBuyRequiresPrice': False,
581
+ 'marketBuyByCost': True,
582
+ 'selfTradePrevention': False,
583
+ 'iceberg': False,
579
584
  },
580
585
  'createOrders': {
581
586
  'max': 5,
@@ -439,8 +439,12 @@ class bitfinex(Exchange, ImplicitAPI):
439
439
  'GTD': False,
440
440
  },
441
441
  'hedged': False,
442
- 'trailing': True, # todo: unify
443
- # todo: leverage unify
442
+ 'trailing': True, # todo: implement
443
+ 'leverage': True, # todo: implement
444
+ 'marketBuyRequiresPrice': False,
445
+ 'marketBuyByCost': True,
446
+ 'selfTradePrevention': False,
447
+ 'iceberg': False,
444
448
  },
445
449
  'createOrders': {
446
450
  'max': 75,
@@ -6614,8 +6614,10 @@ class bitget(Exchange, ImplicitAPI):
6614
6614
  # },
6615
6615
  # ]
6616
6616
  # }
6617
+ symbols = self.market_symbols(symbols)
6617
6618
  data = self.safe_list(response, 'data', [])
6618
- return self.parse_funding_rates(data, market)
6619
+ result = self.parse_funding_rates(data, market)
6620
+ return self.filter_by_array(result, 'symbol', symbols)
6619
6621
 
6620
6622
  def parse_funding_rate(self, contract, market: Market = None) -> FundingRate:
6621
6623
  #
@@ -726,14 +726,11 @@ class bitmart(Exchange, ImplicitAPI):
726
726
  },
727
727
  'hedged': False,
728
728
  'trailing': False,
729
- 'marketBuyRequiresPrice': True,
729
+ 'marketBuyRequiresPrice': False, # todo: https://developer-pro.bitmart.com/en/spot/#new-order-v2-signed
730
730
  'marketBuyByCost': True,
731
- # exchange-supported features
732
- # 'leverage': True,
733
- # 'selfTradePrevention': False,
734
- # 'twap': False,
735
- # 'iceberg': False,
736
- # 'oco': False,
731
+ 'leverage': True, # todo: implement
732
+ 'selfTradePrevention': False,
733
+ 'iceberg': False,
737
734
  },
738
735
  'createOrders': {
739
736
  'max': 10,
@@ -310,11 +310,9 @@ class bitmex(Exchange, ImplicitAPI):
310
310
  'trailing': True,
311
311
  'marketBuyRequiresPrice': False,
312
312
  'marketBuyByCost': False,
313
- # exchange-supported features
314
- # 'selfTradePrevention': True,
315
- # 'twap': False,
316
- # 'iceberg': False,
317
- # 'oco': False,
313
+ 'leverage': False,
314
+ 'selfTradePrevention': False,
315
+ 'iceberg': True, # todo
318
316
  },
319
317
  'createOrders': None,
320
318
  'fetchMyTrades': {
@@ -525,6 +525,11 @@ class bitstamp(Exchange, ImplicitAPI):
525
525
  },
526
526
  'hedged': False,
527
527
  'trailing': False,
528
+ 'leverage': False,
529
+ 'marketBuyByCost': False,
530
+ 'marketBuyRequiresPrice': False,
531
+ 'selfTradePrevention': False,
532
+ 'iceberg': False,
528
533
  },
529
534
  'createOrders': None,
530
535
  'fetchMyTrades': {
@@ -1125,12 +1125,12 @@ class bybit(Exchange, ImplicitAPI):
1125
1125
  'GTD': False,
1126
1126
  },
1127
1127
  'hedged': True,
1128
- # exchange-supported features
1129
- 'selfTradePrevention': True,
1128
+ 'selfTradePrevention': True, # todo: implement
1130
1129
  'trailing': True,
1131
- 'twap': False,
1132
1130
  'iceberg': False,
1133
- 'oco': False,
1131
+ 'leverage': False,
1132
+ 'marketBuyRequiresPrice': False,
1133
+ 'marketBuyByCost': True,
1134
1134
  },
1135
1135
  'createOrders': {
1136
1136
  'max': 10,
@@ -1169,29 +1169,13 @@ class bybit(Exchange, ImplicitAPI):
1169
1169
  'spot': {
1170
1170
  'extends': 'default',
1171
1171
  'createOrder': {
1172
- 'marginMode': False,
1173
- 'triggerPrice': True,
1174
1172
  'triggerPriceType': None,
1175
1173
  'triggerDirection': False,
1176
- 'stopLossPrice': True,
1177
- 'takeProfitPrice': True,
1178
1174
  'attachedStopLossTakeProfit': {
1179
1175
  'triggerPriceType': None,
1180
1176
  'limitPrice': True,
1181
1177
  },
1182
- 'timeInForce': {
1183
- 'IOC': True,
1184
- 'FOK': True,
1185
- 'PO': True,
1186
- 'GTD': False,
1187
- },
1188
- 'hedged': True,
1189
- # exchange-supported features
1190
- 'selfTradePrevention': True,
1191
- 'trailing': True,
1192
- 'twap': False,
1193
- 'iceberg': False,
1194
- 'oco': False,
1178
+ 'marketBuyRequiresPrice': True,
1195
1179
  },
1196
1180
  },
1197
1181
  'swap': {
@@ -2057,6 +2041,7 @@ class bybit(Exchange, ImplicitAPI):
2057
2041
  'quoteId': quoteId,
2058
2042
  'settleId': settleId,
2059
2043
  'type': 'option',
2044
+ 'subType': 'linear',
2060
2045
  'spot': False,
2061
2046
  'margin': False,
2062
2047
  'swap': False,
@@ -2064,8 +2049,8 @@ class bybit(Exchange, ImplicitAPI):
2064
2049
  'option': True,
2065
2050
  'active': isActive,
2066
2051
  'contract': True,
2067
- 'linear': None,
2068
- 'inverse': None,
2052
+ 'linear': True,
2053
+ 'inverse': False,
2069
2054
  'taker': self.safe_number(market, 'takerFee', self.parse_number('0.0006')),
2070
2055
  'maker': self.safe_number(market, 'makerFee', self.parse_number('0.0001')),
2071
2056
  'contractSize': self.parse_number('1'),
@@ -386,7 +386,7 @@ class coinbase(Exchange, ImplicitAPI):
386
386
  'user_native_currency': 'USD', # needed to get fees for v3
387
387
  },
388
388
  'features': {
389
- 'spot': {
389
+ 'default': {
390
390
  'sandbox': False,
391
391
  'createOrder': {
392
392
  'marginMode': True,
@@ -404,6 +404,11 @@ class coinbase(Exchange, ImplicitAPI):
404
404
  },
405
405
  'hedged': False,
406
406
  'trailing': False,
407
+ 'leverage': True, # todo implement
408
+ 'marketBuyByCost': True,
409
+ 'marketBuyRequiresPrice': True,
410
+ 'selfTradePrevention': False,
411
+ 'iceberg': False,
407
412
  },
408
413
  'createOrders': None,
409
414
  'fetchMyTrades': {
@@ -444,21 +449,20 @@ class coinbase(Exchange, ImplicitAPI):
444
449
  'limit': 350,
445
450
  },
446
451
  },
452
+ 'spot': {
453
+ 'extends': 'default',
454
+ },
447
455
  'swap': {
448
456
  'linear': {
449
- 'extends': 'spot',
450
- },
451
- 'inverse': {
452
- 'extends': 'spot',
457
+ 'extends': 'default',
453
458
  },
459
+ 'inverse': None,
454
460
  },
455
461
  'future': {
456
462
  'linear': {
457
- 'extends': 'spot',
458
- },
459
- 'inverse': {
460
- 'extends': 'spot',
463
+ 'extends': 'default',
461
464
  },
465
+ 'inverse': None,
462
466
  },
463
467
  },
464
468
  })