Calculating fee in unsigned PSBT

Running into a chicken-and-egg problem with calculating fees for unsigned PSBT transactions: to calculate the fee, I need the virtual size of the transaction (let's say I have the fee rate in sats/vB from a 3PBP). To calculate the virtual size of the transaction I need the finalized transaction with change output...which requires knowing the fee.

The only solution I can think of is signing a dummy PSBT with a dummy change output, get the virtual size, then sign the real PSBT with the proper change output. This seems cumbersome as I'd have to sign multiple PSBTs every time I want to send some Bitcoin.

Is there a better way to do this?



from Recent Questions - Bitcoin Stack Exchange https://ift.tt/8cBV5zi
via IFTTT

Popular posts from this blog

Bitcoin Mining Could Be Strengthening The Ruble, Russian Central Bank Says

Crypto Exec Warns Tokenization Is Moving Faster Than Expected

Bitwise Clients Pour $69M Into Solana as Bulls Fight to Reclaim $200 Resistance Zone