Skip to content

Add btc send endpoints - #9

Merged
gofman8 merged 2 commits into
mainfrom
feat/add-btc-send-endpoints
Oct 27, 2026
Merged

gofman8 merged 2 commits into
mainfrom
feat/add-btc-send-endpoints

Conversation

@rmn-boiko

Copy link
Copy Markdown
Contributor

Add BTC send and witness receive endpoints

Changes

  • POST /wallet/sendbtcbegin with {address, amount, fee_rate} returns {psbt}.
  • POST /wallet/sendbtcend with {signed_psbt} broadcasts and returns {txid}.
  • POST /wallet/witnessreceive takes the same body as /wallet/blindreceive and returns
    the same ReceiveData. Recipient ids look like bcrt:wvout:…, and the sender funds the
    output via witness_data.amount_sat.
  • The receive path now takes a ReceiveKind (Blind / Witness) and calls rgb-lib's
    blind_receive or witness_receive. RgbWalletState::blind_receive_token is renamed
    to receive_token.
  • Docs: README API table, CHANGELOG (Unreleased → Added), and the swagger spec, which gains
    the new paths plus SendBtcBeginRequestModel and SendBtcResponse.

Existing routes and response shapes are unchanged.

Notes for review

  • Unlike the other begin endpoints, fee_rate on sendbtcbegin has no default. All three
    fields are required.
  • sendbtcend uses the shared Psbt request struct, so it also accepts the legacy
    signedPsbt spelling. The spec documents only signed_psbt.

@rmn-boiko rmn-boiko changed the title Feat/add btc send endpoints Add btc send endpoints Oct 27, 2026
@gofman8
gofman8 merged commit 0280e0e into main Oct 27, 2026
3 checks passed
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

Successfully merging this pull request may close these issues.

2 participants