Anderson-Juhasc / bip84

BIP84 - Derives segwit + bech32 addresses bc1/tb1 from seed, zprv/zpub and vprv/vpub in javascript
20 stars 10 forks source link

How do I derive taproot addresses? #11

Closed meglio closed 1 year ago

meglio commented 1 year ago

Hi, is it possible to use this library to derive taproot addresses from xpub/zpub?

Anderson-Juhasc commented 1 year ago

Hi @meglio, i have made the bip86 to generate taproot addresses to, you can see here: https://github.com/Anderson-Juhasc/bip86

meglio commented 1 year ago

@Anderson-Juhasc but that does not work with zprv/zpub and vprv/vpub.

Anderson-Juhasc commented 1 year ago

@meglio you can convert the zprv to xprv or just use the same mnemonic words with the bip86 and you can get the xprv for that.

I think in these lines I converted the xprv to zprv: https://github.com/Anderson-Juhasc/bip84/blob/master/src/index.js#L82-L109 and you can do the opposite.

Let me know if it helped you.

Cheers!