Expand description
Bitcoin key and address derivation library for address generation, script hash calculation, and private key management.
This library provides secure methods for:
- BIP39 mnemonic generation
- Address generation (Legacy, SegWit, and Taproot)
- Script hash calculation
- Private key generation
Structs§
- GetAddress
Response - Response structure for address generation containing the address, derivation path, and public key.
- GetAddresses
Response - Response structure containing multiple generated Bitcoin addresses.
Enums§
- Derivation
Error - Custom error type for bitcoin key and address operations
- Word
Count - BIP39 mnemonic word count options
Functions§
- calculate_
script_ hash - Calculates a script hash for a given Bitcoin address and network type.
- derive_
bitcoin_ address - Derives a Bitcoin address from a mnemonic phrase, derivation path, network type, and optional BIP39 passphrase.
- derive_
bitcoin_ addresses - Derives multiple Bitcoin addresses from a single mnemonic by iterating through a range of indices.
- derive_
private_ key - Derives a private key in WIF format from a mnemonic phrase, derivation path, network type, and optional BIP39 passphrase.
- entropy_
to_ mnemonic - Converts entropy bytes to a mnemonic phrase.
- generate_
mnemonic - Generates a new BIP39 mnemonic phrase using a specified word count.
- get_
bip39_ suggestions - Gets word suggestions for partial input (autocomplete).
- get_
bip39_ wordlist - Gets the full BIP39 wordlist for the specified language.
- is_
valid_ bip39_ word - Checks if a word is a valid BIP39 word for the specified language.
- mnemonic_
to_ entropy - Converts a mnemonic phrase to entropy bytes.
- mnemonic_
to_ seed - Converts a mnemonic phrase to a seed with optional passphrase.
- validate_
mnemonic - Validates a BIP39 mnemonic phrase.