Unshielding fee increases as the amount increases but why?

Hey @Support,

While developing inquery, I’ve noticed that unshielding fee increases as the amount increases. This is just for BTC unshielding. I didn’t come across the same thing for ETH and ERC-20 tokens.

What is the reason for this?


Btw, could one of the devs please answer this question? abduraman - InQuery - In Cognito We Query .

It is really so simple. Not require so much time. I strongly think that the formula used for calculating the prices in https://api.incognito.org/ptoken/list is incorrect. If agreed, could you fix it before the weekend? Since I gave the formula, it is so simple too. Thanks.

3 Likes

Hey, you may know that BTC chain has the utxo mechanism while ETH/ERC-20 do not. The more utxo contains in your transaction, the heavier byte will become. As a result, your unshielding fee will increase accordingly.

9 Likes

When can we just switch to segwit on the backend, it would eliminate 42 percent of fees and doesn’t suffer from this issue

#btcbridge
@duc

5 Likes

I guess @binh and @elvis.p are working on it. Could you guys please give an ETA for it?

2 Likes

Can gen a new segwit address, receive coin with segwit address, but now we can not send btc from a segwit address with the library we are using. So we will notify when there is a new solution.

3 Likes

So the bridge relies on a specific explorer api for bitcoin? And you are using a go wrapped version of this api… can you use another explorer api that has segwit api support wrapped in go?

1 Like

We will consider more about this, as it will take more time to experiment.

Let me know if you need specific help like finding a go wrapped library for you. I’m unsure of the bridge inner workings but I’d have to guess it’s all written in go and from what you described it runs off an explorer api for btc. Can it run off just a regular btc node or is there something customized about the data you get from blockcypher explorer you can’t get on a btc node via rpc calls?

As I mentioned above, we haven’t found the way to send BTC from a segwit address with this library yet.
We don’t have time to do this right now but we will be back soon.
If you have any instructional documents to help us, please send them to me via DM.
Thank you!