cryptocoinjs/coininfo

Where do you get the versions information for different coins?

SethMcGuire opened this issue · 6 comments

// base58Prefixes
versions: {
bip32: {
private: 0x0488ade4,
public: 0x0488b21e
},
bip44: 2301,
private: 0x80,
public: 0x3A,
scripthash: 0x32
}

I'd like to find that information for several different coins that aren't on coininfo so I can add them to a bitcoinjs project.

All what you pasted here located in source code, except bip44 what is located here: https://github.com/satoshilabs/slips/blob/master/slip-0044.md

In the source code of each coin? That's a ton of code, do you know where exactly I might find that for bitcoin cash?

Can not say for bitcoin cash, but for bitcoin you can find this values in chainparams.cpp.

cenyG commented

for example we have btc data here:
// base58Prefixes
versions: {
bip32: {
private: 0x0488ade4,
public: 0x0488b21e
},
bip44: 0,
private: 0x80,
public: 0x00,
scripthash: 0x05
}
and code here:
https://github.com/bitcoin/bitcoin/blob/master/src/chainparams.cpp
For me it is not obvious how to get this data from this code.

cenyG commented

cool, very fast , thnx