ccxt / ccxt

A JavaScript / TypeScript / Python / C# / PHP cryptocurrency trading API with support for more than 100 bitcoin/altcoin exchanges
https://docs.ccxt.com
MIT License
31.91k stars 7.37k forks source link

🔴 Binance remove support for backwards compatible defaultType #20361

Open frosty00 opened 6 months ago

frosty00 commented 6 months ago

We will remove support for the backwards compatible Binance defaultType. So in the future the following backwards compatible code will no longer work:


$${\textbf{\color{red}↓ ↓ ↓ DEPRECATED ↓ ↓ ↓}}$$

binance.options['defaultType'] = 'future'
binance.options['defaultType'] = 'delivery'

$${\textbf{\color{red}↑ ↑ ↑ DEPRECATED ↑ ↑ ↑}}$$


Use either the unified defaultSubTypes and defaultTypes or use the unified symbols:

binance.options['defaultType'] = 'swap'
binance.options['defaultSubType'] = 'linear'
binance.options['defaultSubType'] = 'inverse'

DO NOT USE the market ids like 'ETHUSDT' to reference a swap market with the old defaultType of future and delivery

Use the unified market symbols such as 'ETH/USDT:USDT' where possible to avoid any conflicts between spot and swap markets

frosty00 commented 6 months ago

The change is estimated to happen by the end of January