JKorf / Binance.Net

A C# .netstandard client library for the Binance REST and Websocket Spot and Futures API focusing on clear usage and models
https://jkorf.github.io/Binance.Net/
MIT License
1.03k stars 425 forks source link

"Not authorized" when transfering from Futures to Spot #733

Closed Jenscaasen closed 3 years ago

Jenscaasen commented 3 years ago

Hi, i am not entirely sure this is an issue with the lib, it could also be an API Key issue if you need "withdrawal" rights for the key to do transfers (do you?). Anyway:

var transferResult = client.Spot.Futures.TransferFuturesAccount(transferType: FuturesTransferType.FromUsdtFuturesToSpot, asset: "USDT", amount: 10); This results in ""You are not authorized to execute this request."

The guess, why this might be an issue with the Lib is this: https://dev.binance.vision/t/isolated-margin-order-api-not-authorized/675

Similar situation, solution is described as:

"In Python requests the request body needs to be sent as “params” not as “data”. It works as “data” at spot trading but not at margin trading."

Does this lib maybe also use "data" instead of "params" in terms of futures?

JKorf commented 3 years ago

Just enable Withdraw permission and see if it works ;)

JKorf commented 3 years ago

Also; duplicate of #730