public void CreateAndExecuteNeoOrderSellAndCreateCancelation_Test() { var pair = "SWTH_NEO"; var amount = 1.2M; var price = .004M; var side = Side.sell; var order = _repoAuth.CreateNeoOrder(pair, side, price, amount, false).Result; Assert.NotNull(order); var executedOrder = _repoAuth.BroadcastOrder(order).Result; Assert.NotNull(executedOrder); var cancellation = _repoAuth.CreateCancellation(executedOrder).Result; Assert.NotNull(cancellation); }
/// <summary> /// This is the first API call required to cancel an order. /// Only orders with makes and with /// an available_amount of more than 0 can be cancelled. /// It can be executed through ExecuteCancellation. /// EXECUTE REQUIRED /// </summary> /// <param name="orderId">Order Id to be cancelled</param> /// <returns>TransactionResponse when complete</returns> public TransactionResponse CreateCancellation(string orderId) { return(_repository.CreateCancellation(orderId).Result); }