1

I was wondering how can we build a transaction with a fixed amount of fees already FIXED.

Let's have this configuration 2 Inputs (X:0 = 520 BTC, X:1 = 102 BTC) => 1 RECEIVER (+510 BTC) Fees are: 0.001 BTC / byte

How can we build a transaction wheras we don't even know the signature size ? Can you show your steps please ?

Loopite
  • 301
  • 2
  • 10
  • Do you mean a “fixed feerate [sat/vB]” rather than a “fixed fee [sat]”? – Murch May 12 '23 at 19:12
  • I think the instructions I wrote here just earlier today would also work for you: https://bitcoin.stackexchange.com/a/118302/5406 – Murch May 12 '23 at 19:15
  • Your answer uses RPC interactions. But, I'd like to know the steps to BUILD a new transaction in Python or something like that by specifying all conditions. This is more an algorithm conception. – Loopite May 12 '23 at 19:24
  • Please edit your question to incorporate that information, drop the “bitcoin-core”-tag and instead add “python”. – Murch May 12 '23 at 19:45

1 Answers1

0

Okay, I finally found an algorithm which can fit to my wishes.

Available at : Calculating fee based on fee rate for bitcoin transaction

This can be easily converted into a Python code in order to build a transaction correctly.

Loopite
  • 301
  • 2
  • 10