constp2pkh_data= { mainnet_address:'1...', testnet_address:'m...'// 'm' or 'n' on testnet or regtest network};constp2wpkh_data= { mainnet_address:'bc1q...',// Length of 42 (SegWit variant of P2PKH) testnet_address:'tb1q...'};constp2sh_data= { mainnet_address:'3...',// Length of 34 testnet_address:'2...'};constp2wsh_data= { mainnet_address:'bc1q...',// Length of 62 (SegWit variant of P2SH)}constp2tr_data= { mainnet_address:'bc1p...', testnet_address:'tb1p...'};
Convert public key to bitcoin payment object and address