feat(abstract-utxo): support custom change wallets in explainPsbt(Wasm)#7548
Merged
OttoAllmendinger merged 8 commits intomasterfrom Nov 20, 2025
Merged
Conversation
Add `toXpub()` helper function to extract an xpub string from various keychain formats, and `toXpubTriple()` to convert triple keychain objects to an array of xpub strings. Issue: BG-62732 Co-authored-by: llm-git <llm-git@ttll.de>
Enables direct conversion of RootWalletKeys objects to BIP32 triples. Also adds validation for array length. Issue: BTC-2732 Co-authored-by: llm-git <llm-git@ttll.de>
Document the parameters of the explainPsbt function with JSDoc comments to improve code readability and developer experience. Issue: BTC-2732 Co-authored-by: llm-git <llm-git@ttll.de>
Clarify that network requests for address validation are only needed for legacy transaction formats. Add more precise formatting to enhance readability. Issue: BTC-2732 Co-authored-by: llm-git <llm-git@ttll.de>
Implement support for identifying custom change outputs in transaction explanations. This feature helps users understand which outputs are regular wallet change vs. custom change, such as those from BitGo's sweep consolidation wallets. Issue: BTC-2732 Co-authored-by: llm-git <llm-git@ttll.de>
Add a test case to verify that the reference implementation correctly identifies and handles custom change outputs in PSBTs. Issue: BTC-2732 Co-authored-by: llm-git <llm-git@ttll.de>
Improve type safety for PSBT outputs by creating dedicated type guards and helper functions for wallet and external outputs. This makes the code more maintainable and adds explicit error handling for invalid output types. Issue: BG-62732 Co-authored-by: llm-git <llm-git@ttll.de>
Add support for parsing custom change outputs using provided wallet xpubs. This enhances the transaction explanation function to identify outputs that might belong to a different wallet than the main one. Issue: BTC-2732 Co-authored-by: llm-git <llm-git@ttll.de>
b81a2d3 to
80284e0
Compare
davidkaplanbitgo
approved these changes
Nov 19, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Support this category of change outputs at the explainPsbt level. This simplifies the parse
functions later on.
Issue: BTC-2732