Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Questions about sendBitcoin #203

Open
Kntt opened this issue Jun 12, 2024 · 4 comments
Open

Questions about sendBitcoin #203

Kntt opened this issue Jun 12, 2024 · 4 comments

Comments

@Kntt
Copy link

Kntt commented Jun 12, 2024

When I call unisat.sendBitcoin('address', maxBalance), the unisat wallet prompts Insufficient btc utxo
maxBalance is get from unisat.getBalance

However, when using Unisat Send, fill in Max Balance, and it will be successful

I hope unisat.sendBitcoin will be consistent with unisat send

Because it's too difficult to calculate feeRate on the front end

@GGG888GGG
Copy link
Collaborator

@huanniangstudio @abangZ

@0xBeycan
Copy link

0xBeycan commented Nov 7, 2024

having same problem

@MatthewR586
Copy link

Same

@cloud6605
Copy link
Collaborator

sendBitcoin function needs extra utxo to pay for the gas. And you will get the same value as you input.
But on unisat wallet, it will include the gas fee when sending Max. And what you get will less than Max value.
You may get fee rate by mempool api. And the size is uaully fixed. Then you can know how much fee rate you set, how much gas fee you need to pay.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants