There are 2 ways to stop a bot on Futures.
1. In the list on the Home page of Veles
https://veles.finance/cabinet/
find your bot, click “Stop”. The bot switches to the “AWAITING TERMINATION” status. But it continues to run the opened deal to the correct end (until the take profit or stop loss is executed), it will execute and place new orders as programmed.
Stop with an error (due to liquidation or lack of margin) is also still possible.
If no errors occur, then after executing all orders, the bot switches to the “TERMINATED” status, and does not enter new deals. This is considered the safest way, but it takes time.
2. To stop the bot immediately, you need to find its deal on the “Active deals” page
https://veles.finance/cabinet/deals
and click “Cancel” on the expanded deals card. After that, the bot will cancel all created orders (both grid and take profits), the bot will stop, the deal itself will disappear from the list of “Active deals”. The deposit that was reserved for grid orders (which have not yet been executed) will be released on the exchange and returned to the supporting margin. In this case, the liquidation price will move away if it is shown for this position.
Attention! The bot’s position after cancelling of the deal in Veles remains open on the exchange and goes under manual control. Liquidation is still possible (if the price moves in an unfavorable direction). For a position, you need to manually create a closing order (limit – at the right price, it will take time to execute, or market – close at the current price, immediately). It is not recommended to launch the bot again while the position exists.
How to stop the Spot bot
When trading on Spot, when the bot stops, the same thing happens – the bot will run the deal to the end, and only then stops.
When canceling a bot’s deal on the Spot (that is, immediate stop), you first need to save (write down to yourself) the average price of buying or selling a coin (depending on the bot’s algorithm, Long or Short) in order to know at what price you should sell or buy back the asset later.
.
To close a position on Futures manually, you need to open the exchange’s application or website. Then go to the “Derivatives” section – “Perpetual USDT”. Under the coin chart, you need to find the “Positions” tab, on it you can find the position (for that coin) that this bot created.
For this position, you need to find the “Close by” element, select “Limit” and set the order price, which will give you the desired profit (or acceptable loss) as a result. At the same time, the exchange tells you in a dialog box with what result the order will be executed if it is created. Then you need to confirm – create this order (it will appear in the “Current Orders” tab) and wait for its execution.
That is, if the position has negative PnL now, you can create an order that will be saved on the exchange and will be executed with a profit.
If you decide to close the position immediately, then the closing order will be a market one.
Each position has two indicators – “Realized PnL” and “Unrealized PnL”. The Realized PnL has already been applied (added or subtracted) to the balance. The Unrealized PnL will be applied to your balance after the position is closed by a market order.
Example.
You deposited 300 USDT on the exchange’s trading account balance.
The bot was launched, it created a position, then the deal was canceled in the bot (by Active deals => Cancel) and there are no more orders on the exchange.
But the position has a Realized PnL = -0.14 USDT and an Unrealized PnL = -30.54 USDT.
Then, when you close a position by the market order, you will have the balance remaining
300 – 0,14 – 30,54 = 269.32 USDT.
Why is it important to delete orders
Trading on exchanges is done through orders to buy or sell (coins or coin contracts). You create an order, the exchange reserves funds from your trading account for it – and this order can hang in the list for a long time until it is executed. Or until you cancel it if you change your mind. Or the exchange sometimes cancels itself, for its own reasons (for example, the coin for this order get delisted).
Orders can be created manually through the exchange interface (for manual trading) – then you should remember about this order yourself. To avoid a situation where you created an order to buy something, forgot about it – and suddenly the price fell, and these contracts were bought, and went further into the negative – to create a loss for you, if not liquidation.
And if you set up a bot to trade on the exchange instead of yourself, then the bot creates the necessary orders according to the algorithm and removes unnecessary ones. The bot manages to serve a much larger number of orders than a human (“remember” about the placed 30 orders and delete those that were not useful in the deal, constantly recreate Take Profits). While it is working fine, the bot carefully removes all unnecessary orders. But if it stopped with an error, it leaves the position and orders. It will not delete unnecessary orders, it will not create the necessary ones – to exit the deal on a signal (that is, the price will reach the desired level, but the position will not close, the moment is lost).
You should always check if there are any orders left on the exchange yourself. And ensure that the bot works with a sufficient amount of margin on the account so that it can do its job smoothly.