Spot Account Orders
SendOrder
Path: Binance.Spot
DataTypes Namespace: using static FinovoDataTypes.BinanceTypes;
Sends order to binance for opening trade.
public OrderResult SendOrder(
ISymbol Symbol,
OrderTypes OrderType,
OrderDirections Direction,
double Amount,
TimeInForce TimeInForce = TimeInForce.GTC,
double Price = 0,
long Identifier = 0
);
Parameters
Symbol ISymbol
Order symbol to trade.
Binance Symbols Path: Symbols
OrderType OrderTypes
Order type to trade.
OrderDirection OrderDirections
Order direction to trade.
Amount double
Order amount to trade.
TimeInForce TimeInForce
Order execution type.
Price double
Limit order price at which order will execute.
Identifier long
Order identifier to uniquely identify.
Returns
OrderResult OrderResult
Returns OrderResult.
Remarks
Market orders will be executed at current market price.
Limit orders will executed at price specified using Price parameter.Execution type can be controlled by TimeInForce parameter.
There is limit of 50 orders per second. If this limit reached orders will not be sent to exhcange until retry time reaches.
Example
var res = Binance.Spot.SendOrder(Symbol, OrderTypes.Market, OrderDirections.Buy, 0.01);
if (res.IsSuccess)
{
Print("Order opened successfully");
}
else
{
Print("Failed to open order error# "+res.ErrorMessage);
}