Skip to content

How to import privateKey exported from station to feather.js or terra.js; PLS help 🙏🙏🙏 #67

@mnuestc

Description

@mnuestc

it seems different privateKey standard; the key exported from station seems too long than nomal private key;
this is my code:
const keyStr = process.env.KEY; if (keyStr === undefined) { console.error('Environment variable KEY is not set.'); process.exit(1); } const privateKey = Buffer.from(keyStr, 'hex'); const mk = new RawKey (privateKey); const wallet = client.wallet(mk); console.log({address:wallet.key.accAddress});

Error: Expected private key to be an Uint8Array with length 32

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions