Author: BTCBot Chinese

This article is reproduced from https://medium.com/btcbotcn/btcbot-runes-Technical solution-Zero cost automatic collection-Increase the transaction rate of sell orders-e8fa1e017699


The Runes market has been very hot recently, but many participants have found that the sell orders on many trading platforms are one by one, rather than relatively large orders of 5 or 10. Today we will explain the impact of this phenomenon, the causes of it, and BTCBot's technical solutions.

The impact of a single sell order

A large number of single sell orders in the market greatly affect the trader's experience. If the mint fee of a token is 10U, and the current market order is also 10U, there is only one Runes, and the current gas price is 100sat/vB, then the price for the buyer to buy this token will be slightly higher than 20U, that is, the comprehensive purchase cost increases to 200% (20U).

If it is a sell order of 20 units, then 20 units, i.e. 200U, can be traded at one time, and the buyer still has to pay about 10U gas fee. At this time, the impact of gas fee is only 10/200=5%, and the comprehensive purchase cost is: (200+10) ÷ 20 = 10.5U.

The purchase gas fee has a great impact, and the overall purchase cost has increased significantly — this is the reason why a large number of single Runes token sell orders have no buyers.

The purchase gas fee has little impact, and the overall purchase cost is greatly reduced — — this is why large orders of merged Runes tokens can even be traded at a price 10%-20% higher than the floor price.

Reasons for a single sell order

If the participant only wants to mint 1 Runes, then of course 1 Runes will be placed in the order. The real problem is that when the user submits 5, 10 or 20 Runes, after the mint comes out, only independent sell orders can be listed one by one. Why does this happen? Because many Runes minting platforms on the market adopt the "parallel mint" solution (first split UTXO, then mint Runes). The detailed explanation is as follows:

Take playing 20 cards as an example.

First, split a large UTXO into 20 small UTXOs, and then use these 20 small UTXOs to make one each. Finally, there will be 20 runes of one each left in the wallet. When placing orders on the exchange, you can only place orders one by one. Assuming that the coin price is the same as the mint price, this means that the gas that the buyer has to pay to buy one is already equivalent to the price of this one, and the slippage is close to 100%. It is difficult to sell without a sharp increase in price.

In addition, in terms of cost, playing 20 cards in this way will generate 21 transactions. The first transaction is the transaction of splitting UTXO. This transaction does not mint any runes, but it generates the equivalent of 7 mint fees, as shown below.


Therefore, without considering the change in gas, minting 20 pieces in this way is equivalent to spending the minting cost of 27 pieces.

BTCBot technical solution: tandem mint

BTCBot will first create a temporary address generated for this batch mint, transfer the available UTXO to this account and print a sheet, then use this temporary address to organize 18 transactions in series using the received UTXO, and then transfer the remaining UTXO back to the user's original address in the last transaction and print the last sheet.

This kind of serial transaction does not require the UTXO to be split in advance. The previous UTXO contains 2 runes, and the new UTXO generated by the next transaction in series contains 3 runes. The collection is automatically completed in the serial transactions. Finally, there will be a UTXO containing 20 runes in the user's wallet, which can be posted to the trading market at one time. The buyer can pay a gas fee to buy 20 runes, and the slippage is less than 5%.


It is worth mentioning that in terms of cost, this method only generates 20 transactions. Playing 20 runes is equivalent to spending about 20 gas fees. Almost all gas fees are used for real minting, without waste. For example, in BTCBot, if a user plays 50 Runes, they will be automatically grouped into 2 20-cards and 1 10-cards, which saves money and facilitates placing orders for selling.

Simplify the understanding of the above technical content: collect while typing, save gas fees, and facilitate placing orders and selling.

Summarize

This article briefly describes the Runes market, the causes and impacts of a large number of single sell orders, and BTCBot’s technical solutions. I hope it will be helpful to everyone!