Find All Coins Available For Futures Trading From Binance
I want to get a list of all the coins available for futures trading for Binance. Originally I found a website and just put the coins in an array, but then I came accross this function:
exchange_info = client.get_exchange_info()
So one element in this array looks like this:
{
'symbol': 'ETHBTC',
'status': 'TRADING',
'baseAsset': 'ETH',
'baseAssetPrecision': 8,
'quoteAsset': 'BTC',
'quotePrecision': 8,
'quoteAssetPrecision': 8,
'baseCommissionPrecision': 8,
'quoteCommissionPrecision': 8,
'orderTypes': ['LIMIT', 'LIMIT_MAKER', 'MARKET', 'STOP_LOSS_LIMIT', 'TAKE_PROFIT_LIMIT'],
'icebergAllowed': True,
'ocoAllowed': True,
'quoteOrderQtyMarketAllowed': True,
'isSpotTradingAllowed': True,
'isMarginTradingAllowed': True,
'filters': [{
'filterType': 'PRICE_FILTER',
'minPrice': '0.00000100',
'maxPrice': '922327.00000000',
'tickSize': '0.00000100'
}, {
'filterType': 'PERCENT_PRICE',
'multiplierUp': '5',
'multiplierDown': '0.2',
'avgPriceMins': 5
}, {
'filterType': 'LOT_SIZE',
'minQty': '0.00010000',
'maxQty': '100000.00000000',
'stepSize': '0.00010000'
}, {
'filterType': 'MIN_NOTIONAL',
'minNotional': '0.00010000',
'applyToMarket': True,
'avgPriceMins': 5
}, {
'filterType': 'ICEBERG_PARTS',
'limit': 10
}, {
'filterType': 'MARKET_LOT_SIZE',
'minQty': '0.00000000',
'maxQty': '913.13969153',
'stepSize': '0.00000000'
}, {
'filterType': 'MAX_NUM_ORDERS',
'maxNumOrders': 200
}, {
'filterType': 'MAX_NUM_ALGO_ORDERS',
'maxNumAlgoOrders': 5
}],
'permissions': ['SPOT', 'MARGIN']
}
And I thought well, surely the permissions will tell me whether its a FUTURES coin or not. But looping through the all 1885 coins the vales in permissions are either SPOT, MARGIN, LEVERAGED. And when I filter for each of these, not all of the coins listed are available in Binance Futures.
LEVERAGED would have been my best bet, but this only returns 40 coinpairs - where are a lot more than that available in Binance Futures. What is the criteria to search for here?
Is there a dynamic way to get this information?
Answer
You can find a list of all the coins available for futures trading for Binance by using api below:
futures_exchange_info = client.futures_exchange_info() # request info on all futures symbols
trading_pairs = [info['symbol'] for info in futures_exchange_info['symbols']]
Related Questions
- → What are the pluses/minuses of different ways to configure GPIOs on the Beaglebone Black?
- → Django, code inside <script> tag doesn't work in a template
- → React - Django webpack config with dynamic 'output'
- → GAE Python app - Does URL matter for SEO?
- → Put a Rendered Django Template in Json along with some other items
- → session disappears when request is sent from fetch
- → Python Shopify API output formatted datetime string in django template
- → Can't turn off Javascript using Selenium
- → WebDriver click() vs JavaScript click()
- → Shopify app: adding a new shipping address via webhook
- → Shopify + Python library: how to create new shipping address
- → shopify python api: how do add new assets to published theme?
- → Access 'HTTP_X_SHOPIFY_SHOP_API_CALL_LIMIT' with Python Shopify Module