sbtc-developer-release icon indicating copy to clipboard operation
sbtc-developer-release copied to clipboard

[stacks-signer] Construct a BTC transaction from a list of pending stx transaction withdrawals

Open jferrant opened this issue 2 years ago • 0 comments

Description

Create a function to construct a single BTC transaction that fulfills a list of pending stx transactions.

Context

Signers need to be able to convert multiple stx withdrawal transaction into a single BTC transaction that fulfills them. This relies on a clear definition of the withdrawal fulfillment format to enable the stacks node to burn tokens accordingly/clear pending withdrawals from the signer to do list.

Expected Approach

Construct a BTC transaction that consumes the current wallet utxo and constructs an output utxo to each withdrawal address, and change back to the wallet.

Acceptance Criteria

  • [ ] PR adds the feature
  • [ ] Unit test to validate the constructed BTC transaction
  • [ ] Integration test that verifies the STACKS node accepts and processes the resulting BTC transaction as a withdrawal/burning tokens accordingly

jferrant avatar Nov 08 '23 21:11 jferrant