parsePrivateKey
parsePrivateKey(
chain,input):ParsedKey
Defined in: keys.ts:27
Formats accepted per chain:
- EVM, Tron: 32-byte hex, with or without
0x. - BTC, Zcash: WIF (compressed, mainnet
K…/L…or testnetc…), or 32-byte hex. - Solana: base58 64-byte secret key (Phantom export), the JSON byte array (solana-keygen / Phantom “array” export), or a base58 32-byte seed.
- TON: hex of the 32-byte seed or the 64-byte secret key (seed ‖ public key).
- NEAR:
ed25519:<base58>of the 64-byte secret key (or a 32-byte seed). A 64-byte ed25519 secret must carry its own public key — a mismatch is refused.
Parameters
Section titled “Parameters”string