Class: ColdcardExportExtendedPublicKey

coldcard.ColdcardExportExtendedPublicKey(options)

Reads an extended public key and (optionally) derives deeper from data in an exported JSON file uploaded from the Coldcard.

Constructor

new ColdcardExportExtendedPublicKey(options)

Parameters:
Name Type Description
options object

options argument

Properties
Name Type Description
network string

bitcoin network (needed for derivations)

bip32Path string

BIP32 paths

Source:
Example
const interaction = new ColdcardExportExtendedPublicKey({network: MAINNET, bip32Path: 'm/45'/0/0'});
const reader = new FileReader(); // application dependent
const jsonFile = reader.readAsText('ccxp-0F056943.json'); // application dependent
const {xpub, rootFingerprint, bip32Path} = interaction.parse(jsonFile);
console.log(xpub);
// "xpub..."
console.log(rootFingerprint);
// "0f056943"
console.log(bip32Path);
// "m/45'/0/0"

Extends

  • ColdcardMultisigSettingsFileParser