Ethereum: Delphi + Binance Api + Limit Order Problem Invalid signatur

Here is a sample of your problem:

Ethereum API error: Delphi + Binance API + Limit Order Problem

Ethereum: Delphi + Binance Api + Limit Order Problem Invalid signatur

In this article, we will tell you that you encounter an incorrect signature error worth it, the Etherum application of subsrupion. We allo discuss possable solutions and provide code examples to solm.

Topic

Error message Invalid signature. 'Happens wen your Binance API requist does not meet the signature format. This can happen for a number of reasons souch as:

  • Invalid API terminal or method

  • Insufficient account balance or perishes the rights

  • Missing or irrelevant parameters

Code Example

Use this problem by repeating a simple example in Delph. We are a form that displays a button and tries to the order a book the Binance interface.

delphinst1.pas

Procedure torm1.button1click (sender: …

start

// Set the Binance API operating data (API key, secret key)

arm

Mirikey: string;

Apisecret: sliding;

// platform Binance API object

API: = tbinancei.create;

API.Setapikey (Mirikey);

API.Setapisecret (Apisecret);

// Get your current account balance

Var balance: integer;

API.GETBALANCE (‘ETH’, ‘USDT’, balance, zero, zero);

// Create a new order

VAR order: Torder;

Order.symbol: = ‘BTC/USDT’;

Order.Side: = Order.buy;

Order.quaantity: = 1;

Order.marketprice: = Float64 (1000.00);

Order.Pricingfee: = floting64 (10.00); // assume a 10%fee

Order.Sellingfee: = floating64 (20.00); // assume a 20%fee

// triying to make an order

If Api.order (‘Border’, ‘Buy’, Order)

Writeln (‘orderly placed successfullly!’);

other

Writeln (‘error investment order.’);

end;

`

problem

In this example, we will try to take place the boarder purchase (buy) Bitcoin/USDT with the Binance application interface. We define from application subscription information and receive the current account balance. There is desired features.

Finally, we try to place an order use Api.order ('boarder', 'buy', order).

Solution

To solve that problem you need to:

– Binance’s API users a specal signature system for boarders.

  • Check your account balance : Make of your yourscunt has a loss ing to your order.

  • Use the rights of control features

    : Check the double control ubject properties, that you will ‘api.order (). In particular, make of the "MarketPrice" field correspons to the price you want.

Here's an example of an example wth soome insprations:

delphinst1.pas

Procedure torm1.button1click (sender: …

start

// Set the Binance API operating data (API key, secret key)

arm

Mirikey: string;

Apisecret: sliding;

// platform Binance API object

API: = tbinancei.create;

API.Setapikey (Mirikey);

API.Setapisecret (Apisecret);

// Get youurent account balance

Var balance: integer;

If API.GetBalance (‘ETH’, ‘USDT’, Balance, zero, zero)

Writeln (‘account balance is valid.’);

other

Writeln (‘Getting an error account balance:’, api.getbalanceerror);

end;

// Create a new order

VAR order: Torder;

If order.SYMBOL = ‘BTC/USDT’

Order.Side: = Order.buy;

Order.quaantity: = 1;

Order.marketprice: = Float64 (1000.00); // assume that way price is $10,000

Order.Pricingfee: = floting64 (10.00); // assume a 10%fee

Order.Sellingfee: = floating64 (20.00); // assume a 20%fee

// triying to make an order

If Api.order (‘Border’, ‘Buy’, Order)

Writeln (‘order placed succexfully!’);

other

Writeln (‘Error Investment Order:’, Api.Getbalanceerror);

end;

other

Writeln (‘Invalid symbol:’, order.

exchange cross platform trading market

پاسخ دهید

آدرس ایمیل شما منتشر نخواهد شد. فیلدهای الزامی هستند.