Create a new wallet.
This will use EtherWallet's createRandom()
(with defaults and entropy)
and use the resulting private key to instantiate a new SoftwareWallet.
A new wallet object
Open an existing wallet
Using either mnemonic
, private key
or encrypted keystore
This will try to extract the private key from a mnemonic (if available), and create a new SoftwareWallet instance using whichever key is available. (the on passed in or the one extracted from the mnemonic).
A new wallet object (or undefined) if somehwere along the line an error is thrown.
Generated using TypeDoc
@purser/software
A
javascript
library to interact with a software Ethereum wallet, based on the ethers.js library.It extracts all the complexity from setting up, maintaining and interacting with it, while providing you with a predictable interface.
Installation
Quick Usage
import { open } from '@purser/software' const wallet = await open({ mnemonic: '...' }); console.log(wallet); // { address: '...', privateKey: '...', publicKey: '...' }
Documentation
You can find more in-depth description for this module's API in the purser docs.
Contributing
This package is part of the purser monorepo package.
Please read our Contributing Guidelines for how to get started.
License
The
purser-software
library along with the whole purser monorepo are MIT licensed.