trezor / blockbook

:blue_book: Trezor address/account balance backend
https://trezor.io
GNU Affero General Public License v3.0
670 stars 655 forks source link

important | about estimatefee endpoint #1098

Closed dev-dantealighieri closed 5 months ago

dev-dantealighieri commented 5 months ago

hi,

i need to get estimated fee per bye using blockbook, does your endpoint return fee for 1KB? or does it return estimated fee? how can i get fee per byte using blockbook?

thanks, dante

martinboehm commented 5 months ago

There is only websockedtendpoint for fee estimate. For bitcoin type coins, it returns fee for 1KB to get to the given block.

dev-dantealighieri commented 5 months ago

sometimes it returns -1 for 1 block pass estimation, i dont understand why, 2/3/4 etc. works fine, but 1 returns -1, is there a reason?

martinboehm commented 5 months ago

It returns -1 when backend returns -1. It may not have the estimate for 1 block pass. I do not know what coin you are using but for less used coins the fee estimate does not work very well.

dev-dantealighieri commented 5 months ago

i got -1 from Doge

I'm using Litecoin, Ravencoin, Bitcoin, and Bitcoin Testnet. I only get -1 when using Dogecoin, but it's not a big deal, thanks!