Binance.API.Csharp.Client icon indicating copy to clipboard operation
Binance.API.Csharp.Client copied to clipboard

get Account Info error

Open bilal-hawklogix opened this issue 2 years ago • 1 comments

I am using Binance.API.CSharp.Client.

I need this for testing purpose.

  1. I have registered on https://testnet.binancefuture.com. When i logged in it will give me an api key and secret key wether i have to use these api keys or i have to use api key and secret generated on https://testnet.binance.vision. 2.I have test with both the keys but it didnt work. 3.it give me an error of invalid api key or premission not allowed.
  2. Below is the code.

var apiClient = new ApiClient(apiKey, secretKey, "https://testnet.binance.vision", "wss://testnet.binance.vision/ws"); var binanceClient = new BinanceClient(apiClient); try {

            var accountInfo = binanceClient.GetAccountInfo().Result;         
            return true;
        }
        catch (Exception ex)
        {
            return false;
        }
        

Can you help me out where i am something missing. I need this on urgent basis.

bilal-hawklogix avatar Apr 05 '23 08:04 bilal-hawklogix

Api Error Code: -2015 Message: Invalid API-key, IP, or permissions for action.

bilal-hawklogix avatar Apr 05 '23 08:04 bilal-hawklogix