Binance Futures - Change Leverage (Python)
See original GitHub issueI’m not able to change the leverage with the “fapiPrivate_post_leverage” function. Can someone help me?
- OS: Windows 10 x64
- Programming Language version: Python 3.8.2
- CCXT version: 1.28.3
Code:
import ccxt
binance = ccxt.binance({
"options": {"defaultType": "future"},
"timeout": 30000,
"apiKey":"xxx",
"secret": "xxx",
"enableRateLimit": True,
})
binance.fapiPrivate_post_leverage("BTC/USDT", 10)
Error message:
TypeError: inner() takes from 1 to 2 positional arguments but 3 were given
Issue Analytics
- State:
- Created 3 years ago
- Comments:16 (9 by maintainers)
Top Results From Across the Web
How can i adjust the leverage with Bianance API
To change leverage with python-binance library you should use futures_change_leverage() method. Code example: new_lvrg = ...
Read more >Futures Trading with python-binance | Analytics Vidhya
This will ensure that all trades you execute in the terminal session for the specified symbol take on the leverage set above. If...
Read more >Binance API — python-binance 0.2.0 documentation
Change user's initial leverage of specific symbol market. https://binance-docs.github.io/apidocs/futures/en/#change-initial-leverage-trade.
Read more >how to get the max leverage for futures using the binance API?
GET /fapi/v1/leverageBracket get the different leverages from here. Thanks for your answer.
Read more >Change Log – Binance API Documentation - GitHub Pages
New endpoint GET /fapi/v1/income/asyn to get Download Id For Futures ... Previous Leverage Update event ACCOUNT_CONFIG_UPDATE expanded as account ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi!
Please, see:
You should pass an object containing the params, instead of supplying the params as arguments:
Let us know if the above does not help.
The code I made was reusing the same instance over and over again. I need to change it to reduce burdens of binance api server. Thank you so much for your guidance for all bunch of stuffs!!