Crate bitcoin_address_generator

Source
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§

GetAddressResponse
Response structure for address generation containing the address, derivation path, and public key.
GetAddressesResponse
Response structure containing multiple generated Bitcoin addresses.

Enums§

DerivationError
Custom error type for bitcoin key and address operations
WordCount
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.
generate_mnemonic
Generates a new BIP39 mnemonic phrase using a specified word count.