What are the symbols used in Binance's dapi (coin futures api)?

Viewed 6022

I am trying to download historical price data of BTC/USD perpetual futures using binance's api for coin futures, specifically, I'd like to use this endpoint. However, I cannot find what 'symbol' I have to specify for BTC/USD. I've tried multiple variations to no avail (such as BTCUSD, BTCUSD_perpetual, etc. I constantly get the error: "Invalid symbol."

2 Answers

If anyone is interested, I found out that you can get a list of all symbols using: GET /dapi/v1/exchangeInfo​. The BTC/USD perpetual futures one is: BTCUSD_PERP.

The solution above is for coin futures, so in case anyone needs it for the other futures like BTCUSDTPERP, what worked for me was changing to the futures function: client.futures_create_order(symbol=symbol, side=side, type=order_type, quantity=quantity) and using "BTCUSDT".

More info here https://python-binance.readthedocs.io/en/latest/binance.html

Related